Turn off audio on exit

If an exit zone is overlapping an audio zone, when exiting, the audio is stopped.
We do this by actually triggering the fact that a user should "leave" all active zones when exiting.
This commit is contained in:
David Négrier 2021-09-15 15:28:55 +02:00
parent 8a6419a3b7
commit 801ec3bf4c
3 changed files with 36 additions and 5 deletions

View file

@ -1236,6 +1236,8 @@ ${escapedMessage}
if (this.mapTransitioning) return;
this.mapTransitioning = true;
this.gameMap.triggerExitCallbacks();
let targetRoom: Room;
try {
targetRoom = await Room.createRoom(roomUrl);