23.02.2013, 09:49
pawn Код:
public OnPlayerCommandReceived(playerid, cmdtext[])
{
new cmd1[256], stringo[128], tmp[256], idx, pName[MAX_PLAYERS_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
cmd1 = strtok(cmdtext, idx);
format(stringo, sizeof(stringo), "|- [CMD] %s [id:%d] typed: %s -| ", pName ,playerid,cmdtext);
for(new i = 0; i < MAX_PLAYERS; i++) {
if(IsPlayerConnected(i)) {
if(IsPlayerAdmin(i)) {
SendClientMessage(i, COLOR_GREY, stringo);
}
}
}