Script help
#2

Код:
public OnPlayerText(playerid, text[])
{
    if (text[0] == '@') {
        text[0] = ' ';
        new msg[128], pName[MAX_PLAYER_NAME];
        GetPlayerName(playerid, pName, sizeof(pName));
        format(msg, sizeof(msg), "[Team][%s]:%s", pName, text);
        for (new i = 0; i < GetMaxPlayers(); i++) {
            if (GetPlayerTeam(playerid) == GetPlayerTeam(i))
                SendPlayerMessageToPlayer(i, playerid, msg);
        }
        return 0;
    }
    return 1;
}
Reply


Messages In This Thread
Script help - by aDo7 - 25.12.2013, 10:01
Re: Script help - by Excelize - 25.12.2013, 10:05
Re: Script help - by aDo7 - 25.12.2013, 10:12

Forum Jump:


Users browsing this thread: 1 Guest(s)