invalid function call | invalid function call - 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: invalid function call | invalid function call (
/showthread.php?tid=631727)
invalid function call | invalid function call -
Vin Diesel - 03.04.2017
Solved.
Re: invalid function call | invalid function call -
OneDay - 04.04.2017
do if (JobData[i][jobID]) not if (JobData[id][jobID])
Re: invalid function call | invalid function call -
Vince - 04.04.2017
You're increasing i twice per iteration; once before the loop body and once after it. This means it'll skip every other item. So the only items that get checked are 1, 3, 5, 7, etc. Remove the ++ in the condition. And it should probably be < instead of <= as well.
Re: invalid function call | invalid function call -
Vin Diesel - 04.04.2017
Quote:
Originally Posted by OneDay
do if (JobData[i][jobID]) not if (JobData[id][jobID])
|
Thanks solved it yesterday.
Quote:
Originally Posted by Vince
You're increasing i twice per iteration; once before the loop body and once after it. This means it'll skip every other item. So the only items that get checked are 1, 3, 5, 7, etc. Remove the ++ in the condition. And it should probably be < instead of <= as well.
|
Thanks solved it yesterday.