added end conditions and game over screen