03.07.2011, 04:35
No Topo do GM Coloque estб forward:
No OnPlayerCommandText Coloque isto:
E no Final do GM Coloque Estб Public:
Espero ter ajudado !
Код:
forward Admin(COLOR,const string[],level);
Код:
if(strcmp(cmd, "/pajuda", true) == 0) { if(IsPlayerConnected(playerid)) { new sendername[MAX_PLAYER_NAME]; GetPlayerName(playerid, sendername, sizeof(sendername)); { SendClientMessage(playerid, COLOR_GREEN, "USE: /irajuda"); return 1; } format(string, sizeof(string), "[AJUDA]: O Player %s (id: %d) estб pedindo ajuda, /irajuda", sendername, playerid, (result)); Admin(0xFFFF66FF,string,1); SendClientMessage(playerid, COLOR_RED, "Vocк pediu Ajuda. Aguarde um Administrador te ajudar"); } return 1; }
Код:
public Admin(COLOR,const string[],level) { for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { if (PlayerInfo[i][pAge]) { SendClientMessage(i, COLOR, string); //printf("%s", string); } } } }