OnPlayerText (RCON ADMIN)
#4

PHP код:
new TeamColor[9];
format(TeamColorsizeof TeamColor"{ff0000}"); // Team color here, I put RED just for example
public OnPlayerText(playeridtext[])
{
    if(
IsPlayerAdmin(playerid))
    {
     new 
pName[MAX_PLAYER_NAME], String[128], Prefix[] = "{FF0000}[Admin] ";
        
GetPlayerName(playeridpName24);
        
format(Stringsizeof(String), "%s%s%s %s"PrefixpNameTeamColortext);
        
SendClientMessageToAll(-1,String);
        return 
1;
    }
    return 
1;

Define a global variable, in this case TeamColor, use it to save team colors for cases like this.
Reply


Messages In This Thread
OnPlayerText (RCON ADMIN) - by Mohaowmad - 02.03.2019, 12:15
Re: OnPlayerText (RCON ADMIN) - by polygxn - 02.03.2019, 12:28
Re: OnPlayerText (RCON ADMIN) - by Mohaowmad - 02.03.2019, 12:36
Re: OnPlayerText (RCON ADMIN) - by v1k1nG - 02.03.2019, 12:47
Re: OnPlayerText (RCON ADMIN) - by Mohaowmad - 02.03.2019, 13:18
Re: OnPlayerText (RCON ADMIN) - by v1k1nG - 02.03.2019, 13:26
Re: OnPlayerText (RCON ADMIN) - by PPC23 - 02.03.2019, 13:51
Re: OnPlayerText (RCON ADMIN) - by Mohaowmad - 02.03.2019, 14:14

Forum Jump:


Users browsing this thread: 1 Guest(s)