aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/Dungeon.java3
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt11
2 files changed, 12 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Dungeon.java b/src/main/java/at/hannibal2/skyhanni/config/features/Dungeon.java
index 6cc58f211..40f58df81 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/Dungeon.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/Dungeon.java
@@ -48,7 +48,8 @@ public class Dungeon {
public boolean cleanEnd = false;
@Expose
- @ConfigOption(name = "Clean End", desc = "Hide entities and particles after the boss in Floor 1 - 6 has died.")
+ @ConfigOption(name = "Clean Ending", desc = "After the last dungeon boss has died, all entities and " +
+ "particles are no longer displayed and the music stops playing, but the loot chests are still displayed.")
@ConfigEditorBoolean
@ConfigAccordionId(id = 2)
public boolean cleanEndToggle = false;
diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt
index a78f4a64c..85a233619 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt
@@ -105,9 +105,18 @@ class DungeonCleanEnd {
}
@SubscribeEvent
- fun onReceivePacket(event: PlayParticleEvent) {
+ fun onPlayParticle(event: PlayParticleEvent) {
if (shouldBlock()) {
event.isCanceled = true
}
}
+
+ @SubscribeEvent
+ fun onPlaySound(event: PlaySoundEvent) {
+ if (shouldBlock() && !chestsSpawned) {
+ if (event.soundName.startsWith("note.")) {
+ event.isCanceled = true
+ }
+ }
+ }
} \ No newline at end of file