Two commands help
#2

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;
}
Reply


Messages In This Thread
Two commands help - by UnforgiveNNN - 12.11.2015, 17:40
Re: Two commands help - by MeCom - 12.11.2015, 17:54

Forum Jump:


Users browsing this thread: 1 Guest(s)