Move your mouse to move Doge. He can't pass through walls, if he hits an edge then he will change position and will not be allowed past.
Thanks to 3dgamer. I just made the doge go crazy!