19.01.2013, 22:26
Quote:
yes you see dis? if (APlayerData[playerid][PlayerLevel] >= 1) { "That { "
Код:
COMMAND:a(playerid, params[]) { if (APlayerData[playerid][PlayerLevel] >= 1) { new result[128]; if(sscanf(params,"s[128]",result)) return SendClientMessage(playerid, 0xFFFFFFFF, "Usage: /a [message]"); new string[128],Name[MAX_PLAYER_NAME]; GetPlayerName(playerid,Name,sizeof(Name); format(string,sizeof(string),"[ADMIN-CHAT] %s (%d): %s",Name,playerid,result); foreach(Player,i) if (APlayerData[i][PlayerLevel] >= 3) SendClientMessage(i,0x00FF00FF,string); } return 1; } |
It checks if the player has admin equal or bigger then 3.. if yes then execute the code below(that is to send message to other admins) else do nothing..(You could send a message saying that he needs level 3 admin or something tho)