From 91cbe8be87b42d663f539c5ba5a3fb2ba38307b7 Mon Sep 17 00:00:00 2001 From: Stephen Seo Date: Fri, 28 Sep 2018 19:28:20 +0900 Subject: [PATCH] Fix volume of Battle music to check master volume --- .../TurnBasedMinecraft/client/ClientProxy.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/seodisparate/TurnBasedMinecraft/client/ClientProxy.java b/src/main/java/com/seodisparate/TurnBasedMinecraft/client/ClientProxy.java index f5dcbd1..9e0758b 100644 --- a/src/main/java/com/seodisparate/TurnBasedMinecraft/client/ClientProxy.java +++ b/src/main/java/com/seodisparate/TurnBasedMinecraft/client/ClientProxy.java @@ -4,6 +4,7 @@ import com.seodisparate.TurnBasedMinecraft.common.Battle; import com.seodisparate.TurnBasedMinecraft.common.CommonProxy; import net.minecraft.client.Minecraft; +import net.minecraft.client.settings.GameSettings; import net.minecraft.entity.Entity; import net.minecraft.util.SoundCategory; import net.minecraft.util.text.TextComponentString; @@ -92,13 +93,15 @@ public class ClientProxy extends CommonProxy @Override public void playBattleMusic() { - battleMusic.playBattle(Minecraft.getMinecraft().gameSettings.getSoundLevel(SoundCategory.MUSIC)); + GameSettings gs = Minecraft.getMinecraft().gameSettings; + battleMusic.playBattle(gs.getSoundLevel(SoundCategory.MUSIC) * gs.getSoundLevel(SoundCategory.MASTER)); } @Override public void playSillyMusic() { - battleMusic.playSilly(Minecraft.getMinecraft().gameSettings.getSoundLevel(SoundCategory.MUSIC)); + GameSettings gs = Minecraft.getMinecraft().gameSettings; + battleMusic.playSilly(gs.getSoundLevel(SoundCategory.MUSIC) * gs.getSoundLevel(SoundCategory.MASTER)); } @Override