How to slap ?
#7

zcmd slap
Quote:

CMDlap(playerid, params[])
{
new Float, Float:y, Float:z, Float:health;
new str[128], id, reason[128];
if(PlayerAcc[playerid][Admin] >= 3)// replace this
{
if(sscanf(params, "u[128]", id, reason)) return SendClientMessage(playerid, COLOR_RED, "Slap: /slap (id) (reason)");
if(id == INVALID_PLAYER_ID) return ErrorMessages(playerid, 2);
if(id == playerid) return ErrorMessages(playerid, 4);
if(PlayerAcc[id][Jail] == 1) return SendClientMessage(playerid, COLOR_RED, "That player is in jail (Unable to slap!)");// replace this too
GetPlayerPos(id, x, y, z);
GetPlayerHealth(id, health);
SetPlayerHealth(id, health-25);
SetPlayerPos(id, x, y, z+5);
format(str, sizeof(str), "%s(%d) has been slap by Admin %s(%d)", GetName(id), id, GetName(playerid), playerid, GetPlayerHealth(id, health));
SendClientMessageToAll(COLOR_GREEN, str);
PlayerPlaySound(playerid, 1190, 0.0, 0.0, 0.0);
PlayerPlaySound(id, 1190, 0.0, 0.0, 0.0);
}
return 1;
}

Reply


Messages In This Thread
How to slap ? - by Glossy42O - 20.07.2015, 13:31
Re: How to slap ? - by DaniceMcHarley - 20.07.2015, 13:33
Re: How to slap ? - by SoFahim - 20.07.2015, 13:33
Re: How to slap ? - by Jstylezzz - 20.07.2015, 13:33
Re: How to slap ? - by FreddiewJO - 20.07.2015, 13:36
Re: How to slap ? - by Crystallize - 20.07.2015, 14:23
Re: How to slap ? - by suni - 24.07.2015, 19:46
Re: How to slap ? - by Skillex333 - 24.07.2015, 19:54
Re: How to slap ? - by TenTen - 24.07.2015, 21:49
Re: How to slap ? - by XBrianX - 24.07.2015, 23:46

Forum Jump:


Users browsing this thread: 1 Guest(s)