22.07.2011, 00:57
olha champz ve se funfa
no topu
no onplayercomm
OBS: Nгo testei pode nгo funcionar^^
no topu
Код:
new Float:vida; new Float:colete; new Float:slx, Float:sly, Float:slz;
Код:
if(strcmp(cmd, "/slap", true) == 0) { if(IsPlayerConnected(playerid)) { tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, COLOR_GREY, "[USO CORRETO]: /slap [playerid/PartOfName]"); return 1; } new idjogador; idjogador = ReturnUser(tmp); if(IsPlayerAdmin(playerid)) { if(IsPlayerConnected(idjogador)) { if(idjogador != INVALID_PLAYER_ID) { GetPlayerPos(idjogador, slx, sly, slz); GetPlayerHealth(idjogador,vida); GetPlayerArmour(idjogador,colete); SetPlayerPos(idjogador, 1133.0504,-2038.4034,69.0971); CreateExplosion(1133.0504,-2038.4034,69.0971, 7, 1); SetTimerEx("TestarGod",2000, false, "i", idjogador); } } } else { SendClientMessage(playerid, COLOR_GREY, "Apenas Administradores!"); } } return 1; }
Код:
forward TestarGod(playerid); public TestarGod(playerid) { new Float:checkvida,Float:checkcolete; GetPlayerHealth(playerid, checkvida); GetPlayerArmour(playerid, checkcolete); if(checkvida > 99) { SendClientMessageToAll(COLOR_GREY, "O jogador estб com health hack"); } else if(checkvida < 99) { SendClientMessageToAll(COLOR_GREY, "O jogador perdeu hp normalmente"); } if(checkcolete > 99) { SendClientMessageToAll(COLOR_GREY, "O jogador estб com armour hack"); } else if(checkcolete < 99) { SendClientMessageToAll(COLOR_GREY, "O jogador perdeu colete normalmente"); } SetPlayerHealth(playerid, vida); SetPlayerArmour(playerid, colete); SetPlayerPos(playerid, slx, sly, slz); return 1; }