From f70c5da0bdde1c7cbe3e6b4138a61c9aa1cbd8e2 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Fri, 31 Mar 2023 22:06:12 -0700 Subject: [PATCH] audio on mobile fix --- packages/client/src/scripts/sound.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/client/src/scripts/sound.ts b/packages/client/src/scripts/sound.ts index 29dd181e92..07d543a33b 100644 --- a/packages/client/src/scripts/sound.ts +++ b/packages/client/src/scripts/sound.ts @@ -30,7 +30,7 @@ export function play(type: string) { export function playFile(file: string, volume: number) { const masterVolume = ColdDeviceStorage.get("sound_masterVolume"); - if (masterVolume === 0) return; + if (masterVolume === 0 || volume === 0 || file.toLowerCase().includes("none")) return; const audio = setVolume(getAudio(file), volume); audio.play();