Skip to content

Commit

Permalink
🐛 fix audio playing n times where n is the number of players
Browse files Browse the repository at this point in the history
  • Loading branch information
marutypes committed Mar 19, 2023
1 parent 7a7b26a commit 54c66d1
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions scripts/main.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ Hooks.on("updateCombat", (combat, changed) => {
return;
}

if (game.user.isGM == false) {
return;
}

if (changed.round) {
// This code will run at the start of each round
console.log(`Starting round ${combat.round}`);
Expand Down Expand Up @@ -47,6 +51,10 @@ Hooks.on("updateCombat", (combat, changed) => {
});

Hooks.on("deleteCombat", () => {
if (game.user.isGM == false) {
return;
}

if (settings.currentTheme == "none") {
return;
}
Expand Down

0 comments on commit 54c66d1

Please sign in to comment.