Ajuda msg p ADM
#3

pawn Код:
forward SendAdminMessage(color, string[]);
public SendAdminMessage(color, string[])
{
    for(new i; i != MAX_PLAYERS; ++i) if(IsPlayerConnected(i))
    {
        if(Variбvel >= 1) SendClientMessage(i, color, string);
    }
}

Funзгo/callback
{
    new string[128];
    new Float:pHealth;
    GetPlayerHealth(playerid, pHealth);
    if(pHealth >= 96)
    {
        SendClientMessage(playerid, COLOR_RED,"CHEAT DETECTADO: VIDA");
        format(string, 128, "O galhudo do %s ta usando cheater de VIDA", PlayerName(playerid)), SendAdminMessage(COLOR_RED, string);
        SetPlayerHealth(playerid, 0);
    }

    new Float:pArmour;
    GetPlayerArmour(playerid, pArmour);
    if(pArmour >= 96)
    {
        SendClientMessage(playerid, COLOR_RED,"CHEAT DETECTADO: COLETE");
        format(string, 128, "O galhudo do %s ta usando cheater de colete", PlayerName(playerid)), SendAdminMessage(COLOR_RED, string);
        SetPlayerArmour(playerid, 0);
    }
}

stock PlayerName(playerid)
{
    new nomeplayer[ MAX_PLAYER_NAME ];
    GetPlayerName( playerid, nomeplayer, MAX_PLAYER_NAME );
    return nomeplayer;
}
Resultou ?
Reply


Messages In This Thread
Ajuda msg p ADM - by luccagomes15 - 04.09.2013, 22:27
Re: Ajuda msg p ADM - by DannielCooper - 04.09.2013, 22:35
Re: Ajuda msg p ADM - by Russo66 - 04.09.2013, 22:35

Forum Jump:


Users browsing this thread: 4 Guest(s)