29.11.2015, 08:49
Give all cash command does work
Kicks me as well? plus does display the message before kick
killall command kills me as well. Also it sends 100 client messages and floods my cchat.
this command is kinda bugged i think
Код:
else if(strcmp(cmdtext, "/giveallcash", true) == 0) { if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You need to be rcon admin use /rcon login {pass}"); new var, string[128]; for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { PlayerPlaySound(i,1057,0.0,0.0,0.0); GivePlayerMoney(i,var); } } format(string,sizeof(string)," Administrator \"%s\" has given all Players '$%d'."); return SendClientMessageToAll(COLOR_BLUE, string); }
Код:
else if(strcmp(cmdtext, "/kickall", true) == 0) { if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You need to be rcon admin use /rcon login {pass}"); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i) && (i != playerid))} { PlayerPlaySound(i,1057,0.0,0.0,0.0); Kick(i); } new string[128]; format(string,sizeof(string),"[ Administrator \"%s\" has Kicked all players. ]"); return 1; }
Код:
else if(strcmp(cmdtext, "/killall", true) == 0) { if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You need to be rcon admin use /rcon login {pass}"); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { SetPlayerHealth(i, 0); } SendClientMessage(playerid, COLOR_LIGHTBLUE, "You have killed all players"); } return 1; }
Код:
else if(strcmp(cmdtext, "/getall", true) == 0) { if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You need to be rcon admin use /rcon login {pass}"); new Float:x,Float:y,Float:z, interior = GetPlayerInterior(playerid); GetPlayerPos(playerid,x,y,z); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i) && (i != playerid)) PlayerPlaySound(i,1057,0.0,0.0,0.0); SetPlayerPos(i,x+(playerid/4)+1,y+(playerid/4),z); SetPlayerInterior(i,interior); } SendClientMessage(playerid, COLOR_LIGHTBLUE, "You have got all players to your self"); new string[128]; format(string,sizeof(string)," Administrator \"%s\" has Teleported all players."); return 1; }