[AJUDA] Mensagem mensagem apenas para admin
#1

pawn Код:
if(strcmp(cmd, "/spawn", true) == 0)
{
    new aname[MAX_PLAYER_NAME];
    GetPlayerName(playerid, aname, MAX_PLAYER_NAME);
    new plid;
    tmp = strtok(cmdtext, idx);
    if(!strlen(tmp)) {
        SendClientMessage(playerid, COR_BRANCO, "[x] Digite: /spawn [id]");
        return 1;
    }
    plid = strval(tmp);
    if(IsPlayerConnected(plid)) {
        SpawnPlayer(plid);
        new pname[MAX_PLAYER_NAME];
        GetPlayerName(plid, pname, MAX_PLAYER_NAME);
        format(string, sizeof(string), "{FBFF00}[INFO] O admin {FF0000}%s (%d) {FBFF00}deu spawn em %s (%d)!", aname,playerid,pname,plid);
        SendMessageToAdmins(-1, string);
        return 1;
    }
    else {
        SendClientMessage(playerid, -1, "ID invбlido");
        return 1;
    }
}
Tem como deixar que apenas admin level 4+ possa ver a mensagem? como faz nгo tenho a minima ideia.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)