From 12c9a696ff24c9d92cc16cca2b3467ab780bef90 Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Sat, 17 Sep 2022 09:50:34 +0200 Subject: added sound to clean end --- .../at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'src/main/java/at/hannibal2/skyhanni/features/dungeon') 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 -- cgit