Loop dies after 2 loops. - 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)
+--- Thread: Loop dies after 2 loops. (
/showthread.php?tid=324494)
Loop dies after 2 loops. ( +REP ) -
CmZxC - 09.03.2012
Found another way, forgetaboutit.
added rep on the helper, not on the smartass who doesn't know about
Re: Loop dies after 2 loops. -
CmZxC - 09.03.2012
EDIT : ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Re: Loop dies after 2 loops. -
jamesbond007 - 09.03.2012
if(x>5) break; ?
maybe thats why sherlock
Re: Loop dies after 2 loops. -
Roko_foko - 09.03.2012
In your while put some printf("(%d)",x); I suggest one before if and one on the end- it should show you know is x increasing, how it becomes higher that 5 in only 2 loops.
Re: Loop dies after 2 loops. -
CmZxC - 09.03.2012
Quote:
Originally Posted by jamesbond007
if(x>5) break; ?
maybe thats why sherlock
|
yeah, thanks 007.
and no, that stops the loop otherwise it creates the infinite loop, yes i tried and it spammed my console with my debug messages.