[HELP] lighters and cigars
#2

You can do something like:
pawn Код:
new PlayerLight[MAX_PLAYERS];
new Cigars[MAX_PLAYERS];
and then when a player buy cigars:
pawn Код:
Cigars[playerid] = Cigarshere;
PlayerLight[playerid] = 10;
and when a player use a lighter to light one cigar:
pawn Код:
Cigars[playerid] --;
PlayerLight[playerid] --;
and when a player is out of a lighter and try to smoke a cigars:
pawn Код:
if(PlayerLight[playerid] == 0) return SendClientMessage(playerid,-1,"You have to buy a lighter again to smoke more!");
Reply


Messages In This Thread
[HELP] lighters and cigars - by Luca12 - 05.10.2014, 08:56
Re: [HELP] lighters and cigars - by Eth - 05.10.2014, 09:02
Re: [HELP] lighters and cigars - by Luca12 - 05.10.2014, 09:05
Re: [HELP] lighters and cigars - by Stinged - 05.10.2014, 09:06
Re: [HELP] lighters and cigars - by Eth - 05.10.2014, 09:07
Re: [HELP] lighters and cigars - by Luca12 - 05.10.2014, 09:18
Re: [HELP] lighters and cigars - by MacT - 05.10.2014, 10:13
Re: [HELP] lighters and cigars - by Eth - 05.10.2014, 11:36

Forum Jump:


Users browsing this thread: 5 Guest(s)