Chat Help
#9

pawn Код:
CMD:v(playerid, params[])
{
    new message[80];
    if(Player[playerid][VipRank] < 1 && Player[playerid][AdminLevel] < 1) return SendClientMessage(playerid, WHITE, "Only VIP Members/Administrators Can Use This Command!");
    if(sscanf(params, "s", message)) return SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]");
    if(strlen(message) > 80) return SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]");
    new string[150];
    if(Player[playerid][AdminLevel] > 0)
    {
        format(string,sizeof(string),"[VIP] {FF0000}%s {F2C200}says (%d): %s",GetName(playerid),Player[playerid][VipRank],message);
    }
    else
    {
        format(string,sizeof(string),"[VIP] %s says (%d): %s",GetName(playerid),Player[playerid][VipRank],message);
    }
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            if(Player[i][VipRank] > 0)
            {
                if(Player[i][ToggedVIP] == 0)
                {
                    SendClientMessage(i, 0xF2C200FF, string);
                }
            }
        }
    }
    return 1;
}
Reply


Messages In This Thread
Chat Help - by KiiD - 17.09.2012, 08:39
Re: Chat Help - by clarencecuzz - 17.09.2012, 08:51
Re: Chat Help - by [ABK]Antonio - 17.09.2012, 08:52
Re: Chat Help - by KiiD - 17.09.2012, 09:08
Re: Chat Help - by [ABK]Antonio - 17.09.2012, 09:09
Re: Chat Help - by KiiD - 17.09.2012, 09:13
Re: Chat Help - by clarencecuzz - 17.09.2012, 09:15
Re: Chat Help - by [ABK]Antonio - 17.09.2012, 09:15
Re: Chat Help - by clarencecuzz - 17.09.2012, 09:20

Forum Jump:


Users browsing this thread: 4 Guest(s)