handle spectator closing the emulator