Wierdness with arrays returning wrong value.
I've defined an array at the top of my code as follows:
Code:
And, at the end of the plugin_init, just to be sure (because of this bug) i'm zero it again with: Code:
Now I've gone through my code and the only operations I do on this array is adding or subtracting one from the value with, for example: Code:
Thing is, liveGrens[1] is fine and never has a problem but liveGrens[0] for some reason seems to hold some stupidly high number, for example 1147707392 even after its initialised and before anything is done with it. I have gone over my code and checked theres no erronious assignment operators instead of comparison ones and it looks fine. Anyone have any idea what it is? I can probably code a work around but I'd rather not do it if its something simple to fix that I've overlooked. |
try this
Code:
and use liveGrens 2 and 1 |
Post complete code?
|
That was gonna be my next suggestion. Kinda hard to tell whats going on with just that. Possibly a loop of some kind. :?
|
Might be a bug in the compiler. Please post the whole code and the compiled file. Thanks.
|
OOh Lord, I coded a hack in to fix it now :P
I'll see if I can write something that replicates the error. |
| All times are GMT -4. The time now is 17:14. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.