[HELP] portable radio
#1

How to make a portable radio, for players that have:

Код:
if(GetPlayerSkin(playerid) == 157 || GetPlayerSkin(playerid) == 123 || GetPlayerSkin(playerid) == 156)
        {
Reply
#2

Do you mean you want to have all players with each skin stated to communicate with each other? if so..

pawn Код:
stock SendPRTransmission(color, msg[], team)
{
    for(new i; i < MAX_PLAYERS; i++) // foreach(Player, i)
    {
         if(GetPlayerSkin(i) == team)
         {
             SendClientMessage(i, color, msg);
         }
    }
    return 1;    
}

CMD:pr(playerid, params[])
{
   new string[256], name[MAX_PLAYER_NAME];
    if(IsPlayerLogged[playerid]) // Whatever variable you use for checking if logged or not.
    {
        if(isnull(params)) return SendClientMessage(playrid, SOME_COLOR,"USAGE: /pr [text]");
        GetPlayerName(playerid, name, MAX_PLAYER_NAME);
        format(string, sizeof(string),"[PR]: %s: %s", name, params);
        if(GetPlayerSkin(playerid) == 157) return SendPRTransmission(SOME_COLOR, string, 157); // So on.
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)