fixed pausing issue that led to game crash