more work on game logic