12.11.2015, 17:54
admin duty
Код:
new aDuty[MAX_PLAYERS]; new pOldSkin[MAX_PLAYERS]; CMD:duty(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >=1) { pOldSkin[playeris] = GetPlayerSkin(playerid); if (aDuty[playerid] == 0) { new Float:x,Float:y,Float:z; GetPlayerPos(playerid, x, y, z); SetPlayerPos(playerid, x, y, z+3); SetSkin(playerid, 294); SetPlayerHealth(playerid,999999); GivePlayerWeapon(playerid, 38, 999999); aDuty[playerid] = 1; } else if (aDuty[playerid] == 1) { SetPlayerSkin(playerid, pOldSkin); SetPlayerHealth(playerid,100); ResetPlayerWeapons(playerid); aDuty[playerid] = 0; } } return 1; }