A simple 2D game in Java