Re: Displaying Updates Over Time
- Posted by unkmar Oct 08, 2010
- 1011 views
I had to fix a bug in my code. I had used:
if (not counter and get_key() = -1) then -- Reset counter if a key is pressed and counter is 0. counter = 1000 end if
The problem is that the counter will only be reset IF a key has been pressed during that iteration. If you miss it. then the counter continued to decrease into the negatives and never reach zero again.