A simple game engine in Java