refactoring gameOver in the inGame