I cannot get the rectangle to move right or left using the KeyListener. Can you help me ? Here's the code. I don't really get the paint function, it's kinda strange.



package gamepackage;
...