WASD to move.
It's basically the same as simulation #2, except you loop when you go offscreen and I fixed some other bugs. (Still a little buggy) Most glitches involve frame perfectly jumping off the screen. I've decided the code is good enough to make a game with, working on that now.