[HELP] /usedrug
#1

Quote:

if(strcmp(cmdtext, "/usedrug", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pDrugs] > 0)
{
new Float:health;
GetPlayerHealth(playerid, health);
SetPlayerHealth(playerid, health + 15.0);
SendClientMessage(playerid, COLOR_GREY, " 1 gram drug used !");
PlayerInfo[playerid][pDrugs] -= 1;
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You dont have any drug grams left !");
}
return 1;
}

}

The problem is they can get more then +150 health by using /usedrugs more times how to make it max. to 150 health ? and it should show a message that he have enaugh for now

Pls help
Thanks
Reply


Messages In This Thread
[HELP] /usedrug - by ArTisT - 02.05.2009, 17:35
Re: [HELP] /usedrug - by Houstin_Trint - 24.01.2010, 02:12
Re: [HELP] /usedrug - by Devine - 24.01.2010, 02:22

Forum Jump:


Users browsing this thread: 1 Guest(s)