Receiving error but cannot debug: ArrayIndexOutOfBoundsException

You have to give a longer description:

What happens now falsely, what do you want to happen instead?

Please note that some of the stuff is inside if-clauses. So this stuff shows up only while you hold down the key.

When you don’t want this, do the changes of pixels [] still inside the if, but image() and ellipse outside it

1 Like