diff options
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/rift')
3 files changed, 8 insertions, 5 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/rift/area/dreadfarm/WoodenButtonsHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/rift/area/dreadfarm/WoodenButtonsHelper.kt index 516ecfd90..d3fbefa99 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/rift/area/dreadfarm/WoodenButtonsHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/rift/area/dreadfarm/WoodenButtonsHelper.kt @@ -1,5 +1,6 @@ package at.hannibal2.skyhanni.features.rift.area.dreadfarm +import at.hannibal2.skyhanni.api.event.HandleEvent import at.hannibal2.skyhanni.data.ClickType import at.hannibal2.skyhanni.data.IslandGraphs import at.hannibal2.skyhanni.data.jsonobjects.repo.RiftWoodenButtonsJson @@ -105,7 +106,7 @@ object WoodenButtonsHelper { } } - @SubscribeEvent + @HandleEvent fun onBlockClick(event: BlockClickEvent) { if (!checkButtons()) return @@ -115,7 +116,7 @@ object WoodenButtonsHelper { } } - @SubscribeEvent + @HandleEvent fun onItemClick(event: ItemClickEvent) { if (!checkButtons()) return if (event.clickType != ClickType.RIGHT_CLICK) return diff --git a/src/main/java/at/hannibal2/skyhanni/features/rift/area/livingcave/LivingCaveLivingMetalHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/rift/area/livingcave/LivingCaveLivingMetalHelper.kt index 63a4e35cb..08079849e 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/rift/area/livingcave/LivingCaveLivingMetalHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/rift/area/livingcave/LivingCaveLivingMetalHelper.kt @@ -1,6 +1,8 @@ package at.hannibal2.skyhanni.features.rift.area.livingcave +import at.hannibal2.skyhanni.api.event.HandleEvent import at.hannibal2.skyhanni.data.ClickType +import at.hannibal2.skyhanni.data.IslandType import at.hannibal2.skyhanni.events.BlockClickEvent import at.hannibal2.skyhanni.events.LorenzRenderWorldEvent import at.hannibal2.skyhanni.events.ReceiveParticleEvent @@ -22,7 +24,7 @@ object LivingCaveLivingMetalHelper { private var pair: Pair<LorenzVec, LorenzVec>? = null private var startTime = 0L - @SubscribeEvent + @HandleEvent(onlyOnIsland = IslandType.THE_RIFT) fun onBlockClick(event: BlockClickEvent) { if (!isEnabled()) return if (event.clickType == ClickType.LEFT_CLICK) { diff --git a/src/main/java/at/hannibal2/skyhanni/features/rift/everywhere/PunchcardHighlight.kt b/src/main/java/at/hannibal2/skyhanni/features/rift/everywhere/PunchcardHighlight.kt index 10be4a54a..d1fcea62e 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/rift/everywhere/PunchcardHighlight.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/rift/everywhere/PunchcardHighlight.kt @@ -1,6 +1,7 @@ package at.hannibal2.skyhanni.features.rift.everywhere import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.api.event.HandleEvent import at.hannibal2.skyhanni.data.HypixelData import at.hannibal2.skyhanni.data.IslandType import at.hannibal2.skyhanni.data.mob.MobData @@ -169,9 +170,8 @@ object PunchcardHighlight { } } - @SubscribeEvent + @HandleEvent(onlyOnIsland = IslandType.THE_RIFT) fun onPunch(event: EntityClickEvent) { - if (!RiftAPI.inRift()) return val entity = event.clickedEntity if (entity !is AbstractClientPlayer) return if (entity.isNPC()) return |