29.09.2014, 15:27
(
Последний раз редактировалось awsomedude; 29.09.2014 в 18:41.
)
pawn Код:
GetPlayerWeed(playerid) return Weed[playerid];
Edit:
pawn Код:
GetPlayerWeed(playerid) return Weed[playerid];
CMD:smokeweed(playerid, params[])
{
new string[128];
if(GetPlayerWeed(playerid) == 0) return SendClientMessage(playerid, WHITE, "You do not have any weed seeds!");
if(GetPlayerWeed(playerid) >= 1)
{
ApplyAnimation(playerid, "JST_BUISNESS", "smoke_01", 4.1, 1, 1, 1, 0, 1, 1);
new Float:health;
GetPlayerHealth(playerid, health);
//if(health > 60) return SendClientMessage(playerid, WHITE, "You cannot smoke weed if your health is 60 or above!");
SetPlayerHealth(playerid, health+25);
format(string, sizeof(string), "%s takes out a joint and smokes some weed.", GetOOCName(playerid));
SendNearByMessage(playerid, ACTION_COLOR, string, 4);
}
return 1;
}