aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authoringlettronald <inglettronald@gmail.com>2023-06-30 01:34:38 -0500
committeringlettronald <inglettronald@gmail.com>2023-06-30 01:34:38 -0500
commit5e48ef72999741b9379320c29462e9e28aa79cff (patch)
tree59339e8c518e3e37215892f213d383cfd7e7ff7b /src/main
parent8c4b3ea33729823c9cf6b2193788698d6d1628b9 (diff)
downloadDulkirMod-5e48ef72999741b9379320c29462e9e28aa79cff.tar.gz
DulkirMod-5e48ef72999741b9379320c29462e9e28aa79cff.tar.bz2
DulkirMod-5e48ef72999741b9379320c29462e9e28aa79cff.zip
Move Event back to old system for cancelled sound
Diffstat (limited to 'src/main')
-rw-r--r--src/main/kotlin/dulkirmod/features/chat/AbiphoneDND.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/kotlin/dulkirmod/features/chat/AbiphoneDND.kt b/src/main/kotlin/dulkirmod/features/chat/AbiphoneDND.kt
index 242e226..40087b6 100644
--- a/src/main/kotlin/dulkirmod/features/chat/AbiphoneDND.kt
+++ b/src/main/kotlin/dulkirmod/features/chat/AbiphoneDND.kt
@@ -1,9 +1,9 @@
package dulkirmod.features.chat
import dulkirmod.config.DulkirConfig
-import dulkirmod.events.AlwaysPlaySoundEvent
import dulkirmod.utils.TextUtils
import net.minecraftforge.client.event.ClientChatReceivedEvent
+import net.minecraftforge.client.event.sound.PlaySoundEvent
import net.minecraftforge.fml.common.eventhandler.EventPriority
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
@@ -13,7 +13,7 @@ private var lastRing: Long = 0
object AbiphoneDND {
//BLOCK ABIPHONE SOUNDS
@SubscribeEvent(receiveCanceled = false, priority = EventPriority.LOW)
- fun onSound(event: AlwaysPlaySoundEvent) {
+ fun onSound(event: PlaySoundEvent) {
if (!DulkirConfig.abiDND) return
if (System.currentTimeMillis() - lastRing < 5000) {
if (event.name == "note.pling" && event.sound.volume == 0.69f && event.sound.pitch == 1.6666666f) {