Help me
#1

Can any one help this msg appear and i see when i login but only other players on my gang must see it
PHP код:
               for(new 0MAX_PLAYERSi++)
            {
                if(
PlayerInfo[i][pFaction] == PlayerInfo[playerid][pFaction] && PlayerInfo[i][pFaction] != 0)
                {
                    
format(stringsizeof(string), "*** %s from your faction has logged in"GetPlayerNameEx(playerid));
                    
SendClientMessage(iCOLOR_JUNIORADMINstring);
                }
                
                 if(
PlayerInfo[i][pGang] == PlayerInfo[playerid][pGang] && PlayerInfo[i][pGang] != 255)
                    {
                   
format(stringsizeof(string), "*** %s from your gang has logged in"GetPlayerNameEx(playerid));
                   
SendClientMessage(iCOLOR_JUNIORADMINstring);
                 }
            } 
Reply
#2

When you want to show up as much as you want, you can not get a message for yourself
PHP код:
    for(new 0MAX_PLAYERSi++)
    {
        if(
PlayerInfo[i][pFaction] == PlayerInfo[playerid][pFaction] && PlayerInfo[i][pFaction] != 0)
        {
            
format(stringsizeof(string), "*** %s from your faction has logged in"GetPlayerNameEx(playerid));
            
SendClientMessageToAllCOLOR_JUNIORADMINstring);
        }
        if(
PlayerInfo[i][pGang] == PlayerInfo[playerid][pGang] && PlayerInfo[i][pGang] != 255)
        {
            
format(stringsizeof(string), "*** %s from your gang has logged in"GetPlayerNameEx(playerid));
            
SendClientMessageToAllCOLOR_JUNIORADMINstring);
        }
    } 
Reply
#3

Quote:
Originally Posted by EmpireSk
Посмотреть сообщение
When you want to show up as much as you want, you can not get a message for yourself
PHP код:
    for(new 0MAX_PLAYERSi++)
    {
        if(
PlayerInfo[i][pFaction] == PlayerInfo[playerid][pFaction] && PlayerInfo[i][pFaction] != 0)
        {
            
format(stringsizeof(string), "*** %s from your faction has logged in"GetPlayerNameEx(playerid));
            
SendClientMessageToAllCOLOR_JUNIORADMINstring);
        }
        if(
PlayerInfo[i][pGang] == PlayerInfo[playerid][pGang] && PlayerInfo[i][pGang] != 255)
        {
            
format(stringsizeof(string), "*** %s from your gang has logged in"GetPlayerNameEx(playerid));
            
SendClientMessageToAllCOLOR_JUNIORADMINstring);
        }
    } 
But if i use that it will appear for all player in gang or not in gang
Reply
#4

Quote:
Originally Posted by jaberaaa
Посмотреть сообщение
But if i use that it will appear for all player in gang or not in gang
Then why do you use these:
&& PlayerInfo[i][pFaction] != 0
&& PlayerInfo[i][pGang] != 255
SendClientMessageToAll
Reply
#5

Quote:
Originally Posted by cuber
Посмотреть сообщение
Then why do you use these:
&& PlayerInfo[i][pFaction] != 0
&& PlayerInfo[i][pGang] != 255
SendClientMessageToAll
I didnt used SendClientMessageToAll
So Give me ? Fixed code i wont see it i want just other members of my gang see it ..
If that possible
Reply
#6

Quote:
Originally Posted by jaberaaa
Посмотреть сообщение
I didnt used SendClientMessageToAll
So Give me ? Fixed code i wont see it i want just other members of my gang see it ..
If that possible
I have Tried to use this new Code
PHP код:
SendGangMessage(gangidcolor, const text[], {Float,_}:...)
{
    static
          
args,
        
str[192];
    if((
args numargs()) <= 3)
    {
        foreach(new 
Player)
        {
            if(
PlayerInfo[i][pLogged] && PlayerInfo[i][pGang] == gangid)
            {
                
SendClientMessage(icolortext);
            }
        }
    }
    else
    {
        while(--
args >= 3)
        {
            
#emit LCTRL     5
            #emit LOAD.alt     args
            #emit SHL.C.alt 2
            #emit ADD.C     12
            #emit ADD
            #emit LOAD.I
            #emit PUSH.pri
        
}
        
#emit PUSH.S     text
        #emit PUSH.C     192
        #emit PUSH.C     str
        #emit PUSH.S    8
        #emit SYSREQ.C     format
        #emit LCTRL     5
        #emit SCTRL     4
        
foreach(new Player)
        {
            if(
PlayerInfo[i][pLogged] && PlayerInfo[i][pGang] == gangid)
            {
                
SendClientMessage(icolorstr);
            }
        }
        
#emit RETN
    
}
    return 
1;

And
PHP код:
                        if(PlayerInfo[playerid][pGang] >= 0)
                        {
                            
SendGangMessage(PlayerInfo[playerid][pGang], COLOR_AQUA"((%s has logged in. ))",GetPlayerRPName(playerid));
                        } 
But it havn't appeared any more
Reply
#7

Upppppp
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)