adding some basic game logic