Help with public OnPlayerCommandText(playerid, cmdtext[])
#1

Hi, i scripted a command for when people do /usecrack and have 2 crack they do an animation and smoke crack, but when they smoke crack its suppose to give them 20.0 armour everytime, but the armour only stays at 20%.

This is my Script:
if (strcmp("/usecrack", cmdtext, true, 10) == 0)
{
if(Crack[playerid] >= 2) { // if he has 2 grams of drug...

SetPlayerSpecialAction(playerid, SPECIAL_ACTION_SMOKE_CIGGY);
Crack[playerid] -=2;
SmokingCrack[playerid] = 1;
SendClientMessage(playerid, -1, "You smoked 2 grams of crack! you lost 2 grams of crack");
SetPlayerArmour(playerid, 20.0);
}
else return SendClientMessage(playerid, COLOR_RED,"You Do Not Have Enough Crack!");
return 1;
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)