Minor refactorings
Added MainGame class to cover the main game logic