Whats Wrong With This - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Whats Wrong With This (
/showthread.php?tid=104329)
Whats Wrong With This -
bubka3 - 23.10.2009
I am trying to make it minus 1 so if its 50 , it becomes 49 and all the way down to zero.
Quote:
PlayerInfo[playerid][pJailTime] -= 1);
|
Errors With This
Quote:
C:\Users\Administrator\Desktop\samp03asvr_win32\ga memodes\b3rpg.pwn(2740) : error 001: expected token: ";", but found ")"
C:\Users\Administrator\Desktop\samp03asvr_win32\ga memodes\b3rpg.pwn(2740) : error 029: invalid expression, assumed zero
C:\Users\Administrator\Desktop\samp03asvr_win32\ga memodes\b3rpg.pwn(2740) : warning 215: expression has no effect
|
Re: Whats Wrong With This -
Vetle - 23.10.2009
Код:
PlayerInfo[playerid][pJailTime]--;
Example: (in a timer i assume)
Код:
PlayerInfo[playerid][pJailTime]--;
if(PlayerInfo[playerid][pJailTime] < 1)
{
// Out of jail
}
else
{
new timeleft[24];
format(timeleft, sizeof(timeleft), "Secounds left: %i", PlayerInfo[playerid][pJailTime]);
GameTextForPlayer(playerid, timeleft, 3000, 4);
}
// correct me if the code is wrong
Re: Whats Wrong With This -
bubka3 - 23.10.2009
Yea I have the timer made up. Thx for the Seconds left. I needed one. And Code Works Like A Charm.