Open TimboKZ opened 6 years ago
Sorrrrrrrry didn't notice this XD right now I'm really using it as a cloud drive and haven't paid much attention to other functions, which is a bit of waste I guess XD
But the issue is removing items from list in inside the loop also causes size of list to change, thus, after removing some bullets, the bullets in the end of list will not be drawn during this call, and as a result they seem to blink a lot. Maybe I should use a temporary variable to store the size of list before loop?
Then I got an IndexOutOfBoundsException XDDDDDDD
https://github.com/ChikamaYan/arduinoProject/blob/d211f89f7f1fc50a1ac16282977406b6cba046a0/processingProgram/bulletHell/bulletHell.pde#L99-L108
Doesn't make too much of a difference in this particular case but performing this in a loop usually tells the compiler/processor these actions can be executed in parallel.