Close game if window is closed