Team Radio help
#1

pawn Код:
CMD:r(playerid, params[])
{
    if (params[0]) return SendClientMessage(playerid,COLOR_TAN,"Usage: /r [Message]");
    new pname[MAX_PLAYER_NAME],string[128];
    GetPlayerName(playerid,pname,sizeof(pname));
    if(GetPlayerTeam(playerid == TEAM_BLUE))
    {
        format(string,sizeof (string), "Radio: %s: %s",pname, params);
        SendClientMessage(TEAM_BLUE, COLOR_TEAM_BLUE, string);
    }
    else if(GetPlayerTeam(playerid == TEAM_RED))
    {
        format(string, sizeof (string), "Radio: %s: %s",pname, params);
        SendClientMessage(TEAM_RED, COLOR_TEAM_RED, string);
    }
    return 1;
}
Thought i did this right, Guess not, It shows the usage, but if i type /r test it shows the usage again. I Know it has something to do with the params. Cant figure out what though.
Reply


Messages In This Thread
Team Radio help - by -Rebel Son- - 21.12.2011, 01:33
Re: Team Radio help - by iTorran - 21.12.2011, 01:51
Re: Team Radio help - by Rob_Maate - 21.12.2011, 01:56
Re: Team Radio help - by -Rebel Son- - 21.12.2011, 02:20
Re: Team Radio help - by iTorran - 21.12.2011, 02:30
Re: Team Radio help - by -Rebel Son- - 21.12.2011, 02:34
Re: Team Radio help - by Fj0rtizFredde - 21.12.2011, 02:55
Re: Team Radio help - by -Rebel Son- - 21.12.2011, 03:05
Re: Team Radio help - by Fj0rtizFredde - 21.12.2011, 03:08
Re: Team Radio help - by -Rebel Son- - 21.12.2011, 03:12

Forum Jump:


Users browsing this thread: 1 Guest(s)