From b48dabaf8ab58773eb51a1c2077b880ee1f28675 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 22 Apr 2021 13:43:33 -0400 Subject: Fix dungeon boss music only playing the first time How did this work for me before? I have no idea. --- src/main/java/me/Danker/features/CustomMusic.java | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 4b1f6bb..342727b 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -66,6 +66,8 @@ public class CustomMusic { if (!prevInDungeonBossRoom) { dungeonboss.start(); } + } else { + inDungeonBossRoom = false; } } } -- cgit From 1ca7e7a34464af3246b3d8f00c5486a357c7b1bc Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 6 May 2021 16:29:20 -0400 Subject: Add shuffling custom music Also fixed: Custom music no longer continues in dungeons if other custom music isn't enabled. File name ending with .wav.wav now registers. --- src/main/java/me/Danker/features/CustomMusic.java | 69 ++++++++++++++--------- 1 file changed, 42 insertions(+), 27 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 342727b..5080821 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -20,7 +20,9 @@ import net.minecraftforge.fml.common.gameevent.TickEvent; import javax.sound.sampled.*; import java.io.File; import java.io.IOException; +import java.util.ArrayList; import java.util.List; +import java.util.Random; public class CustomMusic { @@ -47,7 +49,7 @@ public class CustomMusic { EntityPlayerSP player = mc.thePlayer; World world = mc.theWorld; if (DankersSkyblockMod.tickAmount % 10 == 0) { - if (ToggleCommand.dungeonBossMusic && Utils.inDungeons && world != null && player != null) { + if (Utils.inDungeons && world != null && player != null) { prevInDungeonBossRoom = inDungeonBossRoom; List scoreboard = ScoreboardHandler.getSidebarLines(); if (scoreboard.size() > 2) { @@ -64,7 +66,8 @@ public class CustomMusic { inDungeonBossRoom = true; if (!prevInDungeonBossRoom) { - dungeonboss.start(); + bloodroom.stop(); + if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); } } else { inDungeonBossRoom = false; @@ -91,8 +94,9 @@ public class CustomMusic { dungeonboss.stop(); bloodroom.stop(); dungeon.stop(); - } else if (ToggleCommand.bloodRoomMusic && message.contains("The BLOOD DOOR has been opened!")) { - bloodroom.start(); + } else if (message.contains("The BLOOD DOOR has been opened!")) { + dungeon.stop(); + if (ToggleCommand.bloodRoomMusic) bloodroom.start(); } } } @@ -111,17 +115,9 @@ public class CustomMusic { reset(); - File dungeonBossFile = new File(directory + "/dungeonboss.wav"); - System.out.println("dungeonboss.wav exists?: " + dungeonBossFile.exists()); - dungeonboss = new Song(dungeonBossFile, dungeonbossVolume); - - File bloodRoomFile = new File(directory + "/bloodroom.wav"); - System.out.println("bloodroom.wav exists?: " + bloodRoomFile.exists()); - bloodroom = new Song(bloodRoomFile, bloodroomVolume); - - File dungeonFile = new File(directory + "/dungeon.wav"); - System.out.println("dungeon.wav exists?: " + dungeonFile.exists()); - dungeon = new Song(dungeonFile, dungeonVolume); + dungeonboss = new Song(directory, "dungeonboss", dungeonbossVolume); + bloodroom = new Song(directory, "bloodroom", bloodroomVolume); + dungeon = new Song(directory, "dungeon", dungeonVolume); } public static void reset() { @@ -133,20 +129,33 @@ public class CustomMusic { public static class Song { public Clip music; + private final List playlist = new ArrayList<>(); + + public Song(File directory, String songName, int volume) throws IOException, UnsupportedAudioFileException, LineUnavailableException { + File[] files = directory.listFiles(); + if (files != null) { + for (File file : files) { + if (!file.isDirectory() && file.getName().matches(songName + "\\d*(?:\\.wav)?\\.wav")) { // .wav.wav moment + Clip music = AudioSystem.getClip(); + AudioInputStream ais = AudioSystem.getAudioInputStream(file); + music.open(ais); + playlist.add(music); + System.out.println("Added " + file.getName() + " to " + songName + " playlist."); + } + } + } - public Song(File file, int volume) throws IOException, UnsupportedAudioFileException, LineUnavailableException { - if (file.exists()) { - music = AudioSystem.getClip(); - AudioInputStream ais = AudioSystem.getAudioInputStream(file); - music.open(ais); + setVolume(volume); - setVolume(volume); + if (playlist.size() > 0) { + music = playlist.get(0); } } public void start() { reset(); if (music != null) { + shuffle(); cancelNotes = true; music.setMicrosecondPosition(0); music.start(); @@ -159,21 +168,27 @@ public class CustomMusic { if (music != null) music.stop(); } + public void shuffle() { + if (playlist.size() > 0) music = playlist.get(new Random().nextInt(playlist.size())); + } + public boolean setVolume(int volume) { - EntityPlayer player = Minecraft.getMinecraft().thePlayer; - if (music == null) return false; + if (playlist.size() < 1) return false; if (volume <= 0 || volume > 100) { + EntityPlayer player = Minecraft.getMinecraft().thePlayer; if (player != null) player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Volume can only be set between 0% and 100%.")); return false; } float decibels = (float) (20 * Math.log(volume / 100.0)); - FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); - if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) { - return false; + for (Clip music : playlist) { + FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); + if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) { + return false; + } + control.setValue(decibels); } - control.setValue(decibels); return true; } -- cgit From a49b673bd9badcb7c4c02539f53c39c5b52c1b32 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 31 Jul 2021 19:58:02 -0400 Subject: Add custom music to every area Hub, island, farming islands, gold mine, deep caverns, dwarven mines, crystal hollows, blazing fortress, end, park --- src/main/java/me/Danker/features/CustomMusic.java | 133 +++++++++++++++++----- 1 file changed, 107 insertions(+), 26 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 5080821..d61b640 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -35,6 +35,29 @@ public class CustomMusic { public static int bloodroomVolume; public static Song dungeon; public static int dungeonVolume; + public static Song hub; + public static int hubVolume; + public static Song island; + public static int islandVolume; + public static Song dungeonHub; + public static int dungeonHubVolume; + public static Song farmingIslands; + public static int farmingIslandsVolume; + public static Song goldMine; + public static int goldMineVolume; + public static Song deepCaverns; + public static int deepCavernsVolume; + public static Song dwarvenMines; + public static int dwarvenMinesVolume; + public static Song crystalHollows; + public static int crystalHollowsVolume; + public static Song blazingFortress; + public static int blazingFortressVolume; + public static Song end; + public static int endVolume; + public static Song park; + public static int parkVolume; + @SubscribeEvent public void onWorldChange(WorldEvent.Load event) { @@ -49,28 +72,66 @@ public class CustomMusic { EntityPlayerSP player = mc.thePlayer; World world = mc.theWorld; if (DankersSkyblockMod.tickAmount % 10 == 0) { - if (Utils.inDungeons && world != null && player != null) { - prevInDungeonBossRoom = inDungeonBossRoom; - List scoreboard = ScoreboardHandler.getSidebarLines(); - if (scoreboard.size() > 2) { - String firstLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 1)); - String secondLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 2)); - if (firstLine.contains("30,30") || // F1 - firstLine.contains("30,125") || // F2 - firstLine.contains("30,225") || // F3 - secondLine.contains("- Healthy") || // F3 - firstLine.contains("30,344") || // F4 - firstLine.contains("livid") || // F5 - firstLine.contains("sadan") || // F6 - firstLine.contains("necron")) { // F7 - - inDungeonBossRoom = true; - if (!prevInDungeonBossRoom) { - bloodroom.stop(); - if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); + if (world != null && player != null) { + if (Utils.inDungeons) { + prevInDungeonBossRoom = inDungeonBossRoom; + List scoreboard = ScoreboardHandler.getSidebarLines(); + if (scoreboard.size() > 2) { + String firstLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 1)); + String secondLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 2)); + if (firstLine.contains("30,30") || // F1 + firstLine.contains("30,125") || // F2 + firstLine.contains("30,225") || // F3 + secondLine.contains("- Healthy") || // F3 + firstLine.contains("30,344") || // F4 + firstLine.contains("livid") || // F5 + firstLine.contains("sadan") || // F6 + firstLine.contains("necron")) { // F7 + + inDungeonBossRoom = true; + if (!prevInDungeonBossRoom) { + bloodroom.stop(); + if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); + } + } else { + inDungeonBossRoom = false; } - } else { - inDungeonBossRoom = false; + } + } else { + switch (Utils.tabLocation) { + case "Hub": + if (ToggleCommand.hubMusic) hub.start(); + break; + case "Private World": + if (ToggleCommand.islandMusic) island.start(); + break; + case "Dungeon Hub": + if (ToggleCommand.dungeonHubMusic) dungeonHub.start(); + break; + case "The Farming Islands": + if (ToggleCommand.farmingIslandsMusic) farmingIslands.start(); + break; + case "Gold Mine": + if (ToggleCommand.goldMineMusic) goldMine.start(); + break; + case "Deep Caverns": + if (ToggleCommand.deepCavernsMusic) deepCaverns.start(); + break; + case "Dwarven Mines": + if (ToggleCommand.dwarvenMinesMusic) dwarvenMines.start(); + break; + case "Crystal Hollows": + if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); + break; + case "Blazing Fortress": + if (ToggleCommand.blazingFortressMusic) blazingFortress.start(); + break; + case "The End": + if (ToggleCommand.endMusic) end.start(); + break; + case "The Park": + if (ToggleCommand.parkMusic) park.start(); + break; } } } @@ -118,12 +179,34 @@ public class CustomMusic { dungeonboss = new Song(directory, "dungeonboss", dungeonbossVolume); bloodroom = new Song(directory, "bloodroom", bloodroomVolume); dungeon = new Song(directory, "dungeon", dungeonVolume); + hub = new Song(directory, "hub", hubVolume); + island = new Song(directory, "island", hubVolume); + dungeonHub = new Song(directory, "dungeonhub", dungeonHubVolume); + farmingIslands = new Song(directory, "farmingislands", farmingIslandsVolume); + goldMine = new Song(directory, "goldmine", goldMineVolume); + deepCaverns = new Song(directory, "deepcaverns", deepCavernsVolume); + dwarvenMines = new Song(directory, "dwarvenmines", dwarvenMinesVolume); + crystalHollows = new Song(directory, "crystalhollows", crystalHollowsVolume); + blazingFortress = new Song(directory, "blazingfortress", blazingFortressVolume); + end = new Song(directory, "end", endVolume); + park = new Song(directory, "park", parkVolume); } public static void reset() { if (dungeonboss != null) dungeonboss.stop(); if (bloodroom != null) bloodroom.stop(); if (dungeon != null) dungeon.stop(); + if (hub != null) hub.stop(); + if (island != null) island.stop(); + if (dungeonHub != null) dungeonHub.stop(); + if (farmingIslands != null) farmingIslands.stop(); + if (goldMine != null) goldMine.stop(); + if (deepCaverns != null) deepCaverns.stop(); + if (dwarvenMines != null) dwarvenMines.stop(); + if (crystalHollows != null) crystalHollows.stop(); + if (blazingFortress != null) blazingFortress.stop(); + if (end != null) end.stop(); + if (park != null) park.stop(); } public static class Song { @@ -153,8 +236,8 @@ public class CustomMusic { } public void start() { - reset(); - if (music != null) { + if (music != null && !music.isRunning()) { + reset(); shuffle(); cancelNotes = true; music.setMicrosecondPosition(0); @@ -183,9 +266,7 @@ public class CustomMusic { float decibels = (float) (20 * Math.log(volume / 100.0)); for (Clip music : playlist) { FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); - if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) { - return false; - } + if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) return false; control.setValue(decibels); } -- cgit From d807469333b343e7726536b12d13ff29e3b136c5 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 31 Jul 2021 20:05:00 -0400 Subject: Shuffle custom music at end of song --- src/main/java/me/Danker/features/CustomMusic.java | 82 ++++++++++------------- 1 file changed, 36 insertions(+), 46 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index d61b640..16fef34 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -27,8 +27,6 @@ import java.util.Random; public class CustomMusic { static boolean cancelNotes; - static boolean prevInDungeonBossRoom = false; - public static boolean inDungeonBossRoom = false; public static Song dungeonboss; public static int dungeonbossVolume; public static Song bloodroom; @@ -74,7 +72,6 @@ public class CustomMusic { if (DankersSkyblockMod.tickAmount % 10 == 0) { if (world != null && player != null) { if (Utils.inDungeons) { - prevInDungeonBossRoom = inDungeonBossRoom; List scoreboard = ScoreboardHandler.getSidebarLines(); if (scoreboard.size() > 2) { String firstLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 1)); @@ -88,51 +85,45 @@ public class CustomMusic { firstLine.contains("sadan") || // F6 firstLine.contains("necron")) { // F7 - inDungeonBossRoom = true; - if (!prevInDungeonBossRoom) { - bloodroom.stop(); if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); } - } else { - inDungeonBossRoom = false; } - } - } else { - switch (Utils.tabLocation) { - case "Hub": - if (ToggleCommand.hubMusic) hub.start(); - break; - case "Private World": - if (ToggleCommand.islandMusic) island.start(); - break; - case "Dungeon Hub": - if (ToggleCommand.dungeonHubMusic) dungeonHub.start(); - break; - case "The Farming Islands": - if (ToggleCommand.farmingIslandsMusic) farmingIslands.start(); - break; - case "Gold Mine": - if (ToggleCommand.goldMineMusic) goldMine.start(); - break; - case "Deep Caverns": - if (ToggleCommand.deepCavernsMusic) deepCaverns.start(); - break; - case "Dwarven Mines": - if (ToggleCommand.dwarvenMinesMusic) dwarvenMines.start(); - break; - case "Crystal Hollows": - if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); - break; - case "Blazing Fortress": - if (ToggleCommand.blazingFortressMusic) blazingFortress.start(); - break; - case "The End": - if (ToggleCommand.endMusic) end.start(); - break; - case "The Park": - if (ToggleCommand.parkMusic) park.start(); - break; - } + } else { + switch (Utils.tabLocation) { + case "Hub": + if (ToggleCommand.hubMusic) hub.start(); + break; + case "Private World": + if (ToggleCommand.islandMusic) island.start(); + break; + case "Dungeon Hub": + if (ToggleCommand.dungeonHubMusic) dungeonHub.start(); + break; + case "The Farming Islands": + if (ToggleCommand.farmingIslandsMusic) farmingIslands.start(); + break; + case "Gold Mine": + if (ToggleCommand.goldMineMusic) goldMine.start(); + break; + case "Deep Caverns": + if (ToggleCommand.deepCavernsMusic) deepCaverns.start(); + break; + case "Dwarven Mines": + if (ToggleCommand.dwarvenMinesMusic) dwarvenMines.start(); + break; + case "Crystal Hollows": + if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); + break; + case "Blazing Fortress": + if (ToggleCommand.blazingFortressMusic) blazingFortress.start(); + break; + case "The End": + if (ToggleCommand.endMusic) end.start(); + break; + case "The Park": + if (ToggleCommand.parkMusic) park.start(); + break; + } } } } @@ -242,7 +233,6 @@ public class CustomMusic { cancelNotes = true; music.setMicrosecondPosition(0); music.start(); - music.loop(Clip.LOOP_CONTINUOUSLY); } } -- cgit From 5f2206d383afd3b6424ccda1a2d36522cfbe9b1f Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 31 Jul 2021 21:16:48 -0400 Subject: Add spiders den to custom music I forgot it existed --- src/main/java/me/Danker/features/CustomMusic.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 16fef34..4891fe3 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -49,6 +49,8 @@ public class CustomMusic { public static int dwarvenMinesVolume; public static Song crystalHollows; public static int crystalHollowsVolume; + public static Song spidersDen; + public static int spidersDenVolume; public static Song blazingFortress; public static int blazingFortressVolume; public static Song end; @@ -114,6 +116,9 @@ public class CustomMusic { case "Crystal Hollows": if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); break; + case "Spider's Den": + if (ToggleCommand.spidersDenMusic) spidersDen.start(); + break; case "Blazing Fortress": if (ToggleCommand.blazingFortressMusic) blazingFortress.start(); break; @@ -178,6 +183,7 @@ public class CustomMusic { deepCaverns = new Song(directory, "deepcaverns", deepCavernsVolume); dwarvenMines = new Song(directory, "dwarvenmines", dwarvenMinesVolume); crystalHollows = new Song(directory, "crystalhollows", crystalHollowsVolume); + spidersDen = new Song(directory, "spidersden", spidersDenVolume); blazingFortress = new Song(directory, "blazingfortress", blazingFortressVolume); end = new Song(directory, "end", endVolume); park = new Song(directory, "park", parkVolume); @@ -195,6 +201,7 @@ public class CustomMusic { if (deepCaverns != null) deepCaverns.stop(); if (dwarvenMines != null) dwarvenMines.stop(); if (crystalHollows != null) crystalHollows.stop(); + if (spidersDen != null) spidersDen.stop(); if (blazingFortress != null) blazingFortress.stop(); if (end != null) end.stop(); if (park != null) park.stop(); -- cgit From 4ea49e306ca14e2f4045045f7895e2c1c5d51d6d Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Fri, 27 Aug 2021 03:04:42 -0400 Subject: Update private island custom music detection --- src/main/java/me/Danker/features/CustomMusic.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 4891fe3..7309462 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -95,7 +95,7 @@ public class CustomMusic { case "Hub": if (ToggleCommand.hubMusic) hub.start(); break; - case "Private World": + case "Private Island": if (ToggleCommand.islandMusic) island.start(); break; case "Dungeon Hub": -- cgit From aa78d52025faa74568ccdb3d299c0eb51f29aa90 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 2 Sep 2021 16:24:39 -0400 Subject: Reduce memory issues with custom music --- src/main/java/me/Danker/features/CustomMusic.java | 52 ++++++++++++----------- 1 file changed, 28 insertions(+), 24 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 7309462..1f609cc 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -65,7 +65,7 @@ public class CustomMusic { } @SubscribeEvent(priority = EventPriority.LOW) - public void onTick(TickEvent.ClientTickEvent event) { + public void onTick(TickEvent.ClientTickEvent event) throws UnsupportedAudioFileException, LineUnavailableException, IOException { if (event.phase != TickEvent.Phase.START) return; Minecraft mc = Minecraft.getMinecraft(); @@ -135,7 +135,7 @@ public class CustomMusic { } @SubscribeEvent(receiveCanceled = true) - public void onChat(ClientChatReceivedEvent event) { + public void onChat(ClientChatReceivedEvent event) throws UnsupportedAudioFileException, LineUnavailableException, IOException { String message = StringUtils.stripControlCodes(event.message.getUnformattedText()); if (ToggleCommand.dungeonMusic && Utils.inDungeons) { @@ -165,7 +165,7 @@ public class CustomMusic { } } - public static void init(String configDirectory) throws IOException, LineUnavailableException, UnsupportedAudioFileException { + public static void init(String configDirectory) { if (configDirectory == null) return; File directory = new File(configDirectory + "/dsmmusic"); if (!directory.exists()) directory.mkdir(); @@ -210,33 +210,30 @@ public class CustomMusic { public static class Song { public Clip music; - private final List playlist = new ArrayList<>(); + private final List playlist = new ArrayList<>(); + private int volume; - public Song(File directory, String songName, int volume) throws IOException, UnsupportedAudioFileException, LineUnavailableException { + public Song(File directory, String songName, int volume) { File[] files = directory.listFiles(); if (files != null) { for (File file : files) { if (!file.isDirectory() && file.getName().matches(songName + "\\d*(?:\\.wav)?\\.wav")) { // .wav.wav moment - Clip music = AudioSystem.getClip(); - AudioInputStream ais = AudioSystem.getAudioInputStream(file); - music.open(ais); - playlist.add(music); + playlist.add(file); System.out.println("Added " + file.getName() + " to " + songName + " playlist."); } } } - setVolume(volume); - - if (playlist.size() > 0) { - music = playlist.get(0); - } + this.volume = volume; } - public void start() { - if (music != null && !music.isRunning()) { + public void start() throws UnsupportedAudioFileException, LineUnavailableException, IOException { + + if (music == null) music = AudioSystem.getClip(); + if (!music.isRunning()) { reset(); shuffle(); + setVolume(volume); cancelNotes = true; music.setMicrosecondPosition(0); music.start(); @@ -245,14 +242,23 @@ public class CustomMusic { public void stop() { cancelNotes = false; - if (music != null) music.stop(); + if (music != null) { + music.stop(); + if (music.isOpen()) music.close(); + } } - public void shuffle() { - if (playlist.size() > 0) music = playlist.get(new Random().nextInt(playlist.size())); + public void shuffle() throws LineUnavailableException, UnsupportedAudioFileException, IOException { + if (playlist.size() > 0) { + File file = playlist.get(new Random().nextInt(playlist.size())); + music = AudioSystem.getClip(); + AudioInputStream ais = AudioSystem.getAudioInputStream(file); + music.open(ais); + } } public boolean setVolume(int volume) { + this.volume = volume; if (playlist.size() < 1) return false; if (volume <= 0 || volume > 100) { EntityPlayer player = Minecraft.getMinecraft().thePlayer; @@ -261,11 +267,9 @@ public class CustomMusic { } float decibels = (float) (20 * Math.log(volume / 100.0)); - for (Clip music : playlist) { - FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); - if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) return false; - control.setValue(decibels); - } + FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); + if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) return false; + control.setValue(decibels); return true; } -- cgit From ccd38690657b767d06ccf2771183738b0a35654d Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 10 Mar 2022 21:08:52 -0500 Subject: Prevent crash from playing non .wav music --- src/main/java/me/Danker/features/CustomMusic.java | 25 +++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 1f609cc..5153f91 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -229,14 +229,23 @@ public class CustomMusic { public void start() throws UnsupportedAudioFileException, LineUnavailableException, IOException { - if (music == null) music = AudioSystem.getClip(); - if (!music.isRunning()) { - reset(); - shuffle(); - setVolume(volume); - cancelNotes = true; - music.setMicrosecondPosition(0); - music.start(); + try { + if (music == null) music = AudioSystem.getClip(); + if (!music.isRunning()) { + reset(); + shuffle(); + setVolume(volume); + cancelNotes = true; + music.setMicrosecondPosition(0); + music.start(); + } + } catch (UnsupportedAudioFileException ex) { + ex.printStackTrace(); + + EntityPlayer player = Minecraft.getMinecraft().thePlayer; + if (player != null) { + player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Attempted to play non .wav file. Please use a .wav converter instead of renaming the file.")); + } } } -- cgit From a731568267903caf47a857bc3780de85daa63739 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Wed, 20 Apr 2022 23:42:22 -0400 Subject: Fix crimson isle custom music --- src/main/java/me/Danker/features/CustomMusic.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 5153f91..a31e40a 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -51,8 +51,8 @@ public class CustomMusic { public static int crystalHollowsVolume; public static Song spidersDen; public static int spidersDenVolume; - public static Song blazingFortress; - public static int blazingFortressVolume; + public static Song crimsonIsle; + public static int crimsonIsleVolume; public static Song end; public static int endVolume; public static Song park; @@ -119,8 +119,8 @@ public class CustomMusic { case "Spider's Den": if (ToggleCommand.spidersDenMusic) spidersDen.start(); break; - case "Blazing Fortress": - if (ToggleCommand.blazingFortressMusic) blazingFortress.start(); + case "Crimson Isle": + if (ToggleCommand.crimsonIsleMusic) crimsonIsle.start(); break; case "The End": if (ToggleCommand.endMusic) end.start(); @@ -184,7 +184,7 @@ public class CustomMusic { dwarvenMines = new Song(directory, "dwarvenmines", dwarvenMinesVolume); crystalHollows = new Song(directory, "crystalhollows", crystalHollowsVolume); spidersDen = new Song(directory, "spidersden", spidersDenVolume); - blazingFortress = new Song(directory, "blazingfortress", blazingFortressVolume); + crimsonIsle = new Song(directory, "crimsonisle", crimsonIsleVolume); end = new Song(directory, "end", endVolume); park = new Song(directory, "park", parkVolume); } @@ -202,7 +202,7 @@ public class CustomMusic { if (dwarvenMines != null) dwarvenMines.stop(); if (crystalHollows != null) crystalHollows.stop(); if (spidersDen != null) spidersDen.stop(); - if (blazingFortress != null) blazingFortress.stop(); + if (crimsonIsle != null) crimsonIsle.stop(); if (end != null) end.stop(); if (park != null) park.stop(); } -- cgit From 5586d4588c8d106a3b080bb45ba74b3c81113162 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 28 Apr 2022 20:24:38 -0400 Subject: Add F7 phases to custom music --- src/main/java/me/Danker/features/CustomMusic.java | 132 ++++++++++++++-------- 1 file changed, 82 insertions(+), 50 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index a31e40a..3ea8d1f 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -27,12 +27,21 @@ import java.util.Random; public class CustomMusic { static boolean cancelNotes; + public static Song dungeonboss; public static int dungeonbossVolume; public static Song bloodroom; public static int bloodroomVolume; public static Song dungeon; public static int dungeonVolume; + public static Song phase2; + public static int phase2Volume; + public static Song phase3; + public static int phase3Volume; + public static Song phase4; + public static int phase4Volume; + public static Song phase5; + public static int phase5Volume; public static Song hub; public static int hubVolume; public static Song island; @@ -79,56 +88,56 @@ public class CustomMusic { String firstLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 1)); String secondLine = ScoreboardHandler.cleanSB(scoreboard.get(scoreboard.size() - 2)); if (firstLine.contains("30,30") || // F1 - firstLine.contains("30,125") || // F2 - firstLine.contains("30,225") || // F3 - secondLine.contains("- Healthy") || // F3 - firstLine.contains("30,344") || // F4 - firstLine.contains("livid") || // F5 - firstLine.contains("sadan") || // F6 - firstLine.contains("necron")) { // F7 - - if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); - } - } - } else { - switch (Utils.tabLocation) { - case "Hub": - if (ToggleCommand.hubMusic) hub.start(); - break; - case "Private Island": - if (ToggleCommand.islandMusic) island.start(); - break; - case "Dungeon Hub": - if (ToggleCommand.dungeonHubMusic) dungeonHub.start(); - break; - case "The Farming Islands": - if (ToggleCommand.farmingIslandsMusic) farmingIslands.start(); - break; - case "Gold Mine": - if (ToggleCommand.goldMineMusic) goldMine.start(); - break; - case "Deep Caverns": - if (ToggleCommand.deepCavernsMusic) deepCaverns.start(); - break; - case "Dwarven Mines": - if (ToggleCommand.dwarvenMinesMusic) dwarvenMines.start(); - break; - case "Crystal Hollows": - if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); - break; - case "Spider's Den": - if (ToggleCommand.spidersDenMusic) spidersDen.start(); - break; - case "Crimson Isle": - if (ToggleCommand.crimsonIsleMusic) crimsonIsle.start(); - break; - case "The End": - if (ToggleCommand.endMusic) end.start(); - break; - case "The Park": - if (ToggleCommand.parkMusic) park.start(); - break; + firstLine.contains("30,125") || // F2 + firstLine.contains("30,225") || // F3 + secondLine.contains("- Healthy") || // F3 + firstLine.contains("30,344") || // F4 + firstLine.contains("livid") || // F5 + firstLine.contains("sadan") || // F6 + firstLine.contains("maxor")) { // F7 + + if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); } + } + } else { + switch (Utils.tabLocation) { + case "Hub": + if (ToggleCommand.hubMusic) hub.start(); + break; + case "Private Island": + if (ToggleCommand.islandMusic) island.start(); + break; + case "Dungeon Hub": + if (ToggleCommand.dungeonHubMusic) dungeonHub.start(); + break; + case "The Farming Islands": + if (ToggleCommand.farmingIslandsMusic) farmingIslands.start(); + break; + case "Gold Mine": + if (ToggleCommand.goldMineMusic) goldMine.start(); + break; + case "Deep Caverns": + if (ToggleCommand.deepCavernsMusic) deepCaverns.start(); + break; + case "Dwarven Mines": + if (ToggleCommand.dwarvenMinesMusic) dwarvenMines.start(); + break; + case "Crystal Hollows": + if (ToggleCommand.crystalHollowsMusic) crystalHollows.start(); + break; + case "Spider's Den": + if (ToggleCommand.spidersDenMusic) spidersDen.start(); + break; + case "Crimson Isle": + if (ToggleCommand.crimsonIsleMusic) crimsonIsle.start(); + break; + case "The End": + if (ToggleCommand.endMusic) end.start(); + break; + case "The Park": + if (ToggleCommand.parkMusic) park.start(); + break; + } } } } @@ -147,10 +156,26 @@ public class CustomMusic { if (message.contains(":")) return; if (Utils.inDungeons) { + if (ToggleCommand.dungeonBossMusic) { + if (message.startsWith("[BOSS] Storm: Pathetic Maxor")) { + phase2.start(); + } else if (message.startsWith("[BOSS] Goldor: Who dares trespass into my domain?")) { + phase3.start(); + } else if (message.startsWith("[BOSS] Necron: You went further than any human before")) { + phase4.start(); + } else if (message.startsWith("[BOSS] ") && message.endsWith("You.. again?")) { + phase5.start(); + } + } + if (message.contains("EXTRA STATS ")) { dungeonboss.stop(); bloodroom.stop(); dungeon.stop(); + phase2.stop(); + phase3.stop(); + phase4.stop(); + phase5.stop(); } else if (message.contains("The BLOOD DOOR has been opened!")) { dungeon.stop(); if (ToggleCommand.bloodRoomMusic) bloodroom.start(); @@ -175,6 +200,10 @@ public class CustomMusic { dungeonboss = new Song(directory, "dungeonboss", dungeonbossVolume); bloodroom = new Song(directory, "bloodroom", bloodroomVolume); dungeon = new Song(directory, "dungeon", dungeonVolume); + phase2 = new Song(directory, "phasetwo", phase2Volume); + phase3 = new Song(directory, "phasethree", phase3Volume); + phase4 = new Song(directory, "phasefour", phase4Volume); + phase5 = new Song(directory, "phasefive", phase5Volume); hub = new Song(directory, "hub", hubVolume); island = new Song(directory, "island", hubVolume); dungeonHub = new Song(directory, "dungeonhub", dungeonHubVolume); @@ -193,6 +222,10 @@ public class CustomMusic { if (dungeonboss != null) dungeonboss.stop(); if (bloodroom != null) bloodroom.stop(); if (dungeon != null) dungeon.stop(); + if (phase2 != null) phase2.stop(); + if (phase3 != null) phase3.stop(); + if (phase4 != null) phase4.stop(); + if (phase5 != null) phase5.stop(); if (hub != null) hub.stop(); if (island != null) island.stop(); if (dungeonHub != null) dungeonHub.stop(); @@ -230,7 +263,6 @@ public class CustomMusic { public void start() throws UnsupportedAudioFileException, LineUnavailableException, IOException { try { - if (music == null) music = AudioSystem.getClip(); if (!music.isRunning()) { reset(); shuffle(); -- cgit From 7f71df3d99a2c9b318c0b9de7c4e1577af5c9294 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 30 Apr 2022 13:21:06 -0400 Subject: Fix custom music crash Re-add line I thought was useless --- src/main/java/me/Danker/features/CustomMusic.java | 1 + 1 file changed, 1 insertion(+) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 3ea8d1f..717a3ab 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -263,6 +263,7 @@ public class CustomMusic { public void start() throws UnsupportedAudioFileException, LineUnavailableException, IOException { try { + if (music == null) music = AudioSystem.getClip(); if (!music.isRunning()) { reset(); shuffle(); -- cgit From 77370ce777bf41fec125dbdd3d33b94d579191ba Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Wed, 3 Aug 2022 22:53:06 -0400 Subject: Fix F7 custom music I hope --- src/main/java/me/Danker/features/CustomMusic.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 717a3ab..8ce8c05 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -67,6 +67,8 @@ public class CustomMusic { public static Song park; public static int parkVolume; + static int curPhase = -1; + @SubscribeEvent public void onWorldChange(WorldEvent.Load event) { @@ -96,7 +98,7 @@ public class CustomMusic { firstLine.contains("sadan") || // F6 firstLine.contains("maxor")) { // F7 - if (ToggleCommand.dungeonBossMusic) dungeonboss.start(); + if (ToggleCommand.dungeonBossMusic && curPhase == -1) dungeonboss.start(); } } } else { @@ -159,12 +161,16 @@ public class CustomMusic { if (ToggleCommand.dungeonBossMusic) { if (message.startsWith("[BOSS] Storm: Pathetic Maxor")) { phase2.start(); + curPhase = 2; } else if (message.startsWith("[BOSS] Goldor: Who dares trespass into my domain?")) { phase3.start(); + curPhase = 3; } else if (message.startsWith("[BOSS] Necron: You went further than any human before")) { phase4.start(); + curPhase = 4; } else if (message.startsWith("[BOSS] ") && message.endsWith("You.. again?")) { phase5.start(); + curPhase = 5; } } @@ -238,6 +244,7 @@ public class CustomMusic { if (crimsonIsle != null) crimsonIsle.stop(); if (end != null) end.stop(); if (park != null) park.stop(); + curPhase = -1; } public static class Song { -- cgit From abd656382da708b8cd77df1f4f0a74f2287618c5 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Fri, 5 Aug 2022 00:30:35 -0400 Subject: Add trophy fishing tracker Also update trivia answers and add mod init event --- src/main/java/me/Danker/features/CustomMusic.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 8ce8c05..e6f8131 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -2,6 +2,7 @@ package me.Danker.features; import me.Danker.DankersSkyblockMod; import me.Danker.commands.ToggleCommand; +import me.Danker.events.ModInitEvent; import me.Danker.handlers.ScoreboardHandler; import me.Danker.utils.Utils; import net.minecraft.client.Minecraft; @@ -13,6 +14,7 @@ import net.minecraft.world.World; import net.minecraftforge.client.event.ClientChatReceivedEvent; import net.minecraftforge.client.event.sound.PlaySoundEvent; import net.minecraftforge.event.world.WorldEvent; +import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.eventhandler.EventPriority; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; @@ -196,6 +198,11 @@ public class CustomMusic { } } + @SubscribeEvent + public void init(ModInitEvent event) { + init(event.configDirectory); + } + public static void init(String configDirectory) { if (configDirectory == null) return; File directory = new File(configDirectory + "/dsmmusic"); -- cgit From 66fa83a1942b4ec79c5fa94168c04b84c60c628a Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 6 Aug 2022 22:08:32 -0400 Subject: Add trophy fish completion to display --- src/main/java/me/Danker/features/CustomMusic.java | 1 - 1 file changed, 1 deletion(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index e6f8131..32af6c9 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -14,7 +14,6 @@ import net.minecraft.world.World; import net.minecraftforge.client.event.ClientChatReceivedEvent; import net.minecraftforge.client.event.sound.PlaySoundEvent; import net.minecraftforge.event.world.WorldEvent; -import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.eventhandler.EventPriority; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; -- cgit From 60d3517fc1f70aeeb83dd6627ade3093f7760b04 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Tue, 9 Aug 2022 19:31:36 -0400 Subject: Fix F7 custom music for real this time Also fix /dsmmusic volume not working --- src/main/java/me/Danker/features/CustomMusic.java | 58 ++++++++++++++++------- 1 file changed, 42 insertions(+), 16 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 32af6c9..6c5dd08 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -68,8 +68,7 @@ public class CustomMusic { public static Song park; public static int parkVolume; - static int curPhase = -1; - + static int curPhase = 0; @SubscribeEvent public void onWorldChange(WorldEvent.Load event) { @@ -97,9 +96,29 @@ public class CustomMusic { firstLine.contains("30,344") || // F4 firstLine.contains("livid") || // F5 firstLine.contains("sadan") || // F6 - firstLine.contains("maxor")) { // F7 - - if (ToggleCommand.dungeonBossMusic && curPhase == -1) dungeonboss.start(); + firstLine.contains("maxor") || // F7 + firstLine.contains("f7")) { + + if (ToggleCommand.dungeonBossMusic) { + switch (curPhase) { + case -1: + break; + case 2: + phase2.start(); + break; + case 3: + phase3.start(); + break; + case 4: + phase4.start(); + break; + case 5: + phase5.start(); + break; + default: + dungeonboss.start(); + } + } } } } else { @@ -156,26 +175,27 @@ public class CustomMusic { } } - if (message.contains(":")) return; - if (Utils.inDungeons) { if (ToggleCommand.dungeonBossMusic) { - if (message.startsWith("[BOSS] Storm: Pathetic Maxor")) { + if (phase2.hasSongs() && message.startsWith("[BOSS] Storm: Pathetic Maxor")) { phase2.start(); curPhase = 2; - } else if (message.startsWith("[BOSS] Goldor: Who dares trespass into my domain?")) { + } else if (phase3.hasSongs() && message.startsWith("[BOSS] Goldor: Who dares trespass into my domain?")) { phase3.start(); curPhase = 3; - } else if (message.startsWith("[BOSS] Necron: You went further than any human before")) { + } else if (phase4.hasSongs() && message.startsWith("[BOSS] Necron: You went further than any human before")) { phase4.start(); curPhase = 4; - } else if (message.startsWith("[BOSS] ") && message.endsWith("You.. again?")) { + } else if (phase5.hasSongs() && message.startsWith("[BOSS] ") && message.endsWith("You.. again?")) { phase5.start(); curPhase = 5; } } + if (message.contains(":")) return; + if (message.contains("EXTRA STATS ")) { + curPhase = -1; // force no play dungeonboss.stop(); bloodroom.stop(); dungeon.stop(); @@ -250,7 +270,7 @@ public class CustomMusic { if (crimsonIsle != null) crimsonIsle.stop(); if (end != null) end.stop(); if (park != null) park.stop(); - curPhase = -1; + curPhase = 0; } public static class Song { @@ -321,14 +341,20 @@ public class CustomMusic { return false; } - float decibels = (float) (20 * Math.log(volume / 100.0)); - FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); - if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) return false; - control.setValue(decibels); + if (music != null) { + float decibels = (float) (20 * Math.log(volume / 100.0)); + FloatControl control = (FloatControl) music.getControl(FloatControl.Type.MASTER_GAIN); + if (decibels <= control.getMinimum() || decibels >= control.getMaximum()) return false; + control.setValue(decibels); + } return true; } + public boolean hasSongs() { + return playlist.size() > 0; + } + } } -- cgit From f56302bee3939677fc3fd015a97b12b5100c45b1 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Tue, 9 Aug 2022 20:24:18 -0400 Subject: Fix issues with custom music volume Fix custom music set to 50% volume on first load (ignoring config) Fix island music using hub volume --- src/main/java/me/Danker/features/CustomMusic.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 6c5dd08..38e4ba0 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -3,6 +3,7 @@ package me.Danker.features; import me.Danker.DankersSkyblockMod; import me.Danker.commands.ToggleCommand; import me.Danker.events.ModInitEvent; +import me.Danker.events.PostConfigInitEvent; import me.Danker.handlers.ScoreboardHandler; import me.Danker.utils.Utils; import net.minecraft.client.Minecraft; @@ -218,7 +219,7 @@ public class CustomMusic { } @SubscribeEvent - public void init(ModInitEvent event) { + public void postConfigInit(PostConfigInitEvent event) { init(event.configDirectory); } @@ -237,7 +238,7 @@ public class CustomMusic { phase4 = new Song(directory, "phasefour", phase4Volume); phase5 = new Song(directory, "phasefive", phase5Volume); hub = new Song(directory, "hub", hubVolume); - island = new Song(directory, "island", hubVolume); + island = new Song(directory, "island", islandVolume); dungeonHub = new Song(directory, "dungeonhub", dungeonHubVolume); farmingIslands = new Song(directory, "farmingislands", farmingIslandsVolume); goldMine = new Song(directory, "goldmine", goldMineVolume); -- cgit From e26599e44252d0e16d8399d0b190ccae6e054352 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Tue, 9 Aug 2022 20:41:57 -0400 Subject: PR Fixes --- src/main/java/me/Danker/features/CustomMusic.java | 1 - 1 file changed, 1 deletion(-) (limited to 'src/main/java/me/Danker/features/CustomMusic.java') diff --git a/src/main/java/me/Danker/features/CustomMusic.java b/src/main/java/me/Danker/features/CustomMusic.java index 38e4ba0..01279fd 100644 --- a/src/main/java/me/Danker/features/CustomMusic.java +++ b/src/main/java/me/Danker/features/CustomMusic.java @@ -2,7 +2,6 @@ package me.Danker.features; import me.Danker.DankersSkyblockMod; import me.Danker.commands.ToggleCommand; -import me.Danker.events.ModInitEvent; import me.Danker.events.PostConfigInitEvent; import me.Danker.handlers.ScoreboardHandler; import me.Danker.utils.Utils; -- cgit