![]() |
Condensed Endless Loop...
NPC Code: Yes, I have tried changing i=17 to i==17 but it didn't work :\. |
yes, well keep the i==17 in because thats the correct format. At least thats one problem solved. Also, you have:
if (this.key5=true) it should be if (this.key5==true) like Falcor said, = is an assignment, == means equal to eg this.var = 5; // Makes this.var equal to 5 Also, heres an example of a very simple timeout loop that is stopped: NPC Code: I suggest using : if (timeout && i == 17) { //thingys; } -Ning |
last time i checked graal checks = and == in if/while/for statements as being equals, i always use == but i think = works as well, even though it is technically incorrect
|
kool :P
|
NPC Code: :\, that's the script now. It still doesn't work though... |
In the timeout loop, you set i to 16. SO the timeout loop could never start...I may be reading it wrong, but at a glance thats how it looks
w00t im a member now :D (not junior) <3 |
it says &&i==17, meaning it has to be 17 in the first place, so you have to set that somewhere
(dunno if thats what ningnong meant or not, sorry if it was :X) |
Quote:
|
hmm, why do you have
if (this.key5 == true) this.key5 = false ? since the script is confusing, maybe you should explain in english what your trying to do, then I could whip you up an alternate script :P |
Okay, at the time that this part of the script is executed...
this.key5 could be true or false. i=17 |
the timeout stops for me. *shrugs*
|
Falados, I'll send you the whole script whenever you get on AIM.
|
If you need a variable to be stored longer than the current "frame", you should use this. variables, because other scripts might use the variable as well and therefore mess up your script.
|
Quote:
|
Quote:
|
All times are GMT +2. The time now is 03:55 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.