diff options
| author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-07-25 03:45:22 +0200 |
|---|---|---|
| committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-07-25 03:45:22 +0200 |
| commit | de61fd6bccbea2a3ceca5a0707a3176938f24ead (patch) | |
| tree | 22296db71bf825818091453a441102e726aa1e50 /src/main/java/at/hannibal2/skyhanni/features/dungeon | |
| parent | 6b4c633716f6998461d701f7c841a16e59c1794b (diff) | |
| download | skyhanni-de61fd6bccbea2a3ceca5a0707a3176938f24ead.tar.gz skyhanni-de61fd6bccbea2a3ceca5a0707a3176938f24ead.tar.bz2 skyhanni-de61fd6bccbea2a3ceca5a0707a3176938f24ead.zip | |
Using LorenzWorldChangeEvent everywhere
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/dungeon')
7 files changed, 11 insertions, 18 deletions
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 49673a208..254a3d607 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCleanEnd.kt @@ -8,7 +8,6 @@ import net.minecraft.client.Minecraft import net.minecraft.client.entity.EntityOtherPlayerMP import net.minecraft.entity.item.EntityArmorStand import net.minecraft.entity.monster.EntityGuardian -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent class DungeonCleanEnd { @@ -39,7 +38,7 @@ class DungeonCleanEnd { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { bossDone = false chestsSpawned = false lastBossId = -1 diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt index bb3be6d0d..48664b835 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt @@ -6,7 +6,6 @@ import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.RenderUtils.renderString import at.hannibal2.skyhanni.utils.StringUtils.matchRegex import net.minecraft.entity.item.EntityArmorStand -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent class DungeonCopilot { @@ -115,7 +114,7 @@ class DungeonCopilot { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { changeNextStep("") } diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonData.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonData.kt index f96788ce0..883f2649f 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonData.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonData.kt @@ -1,14 +1,10 @@ package at.hannibal2.skyhanni.features.dungeon import at.hannibal2.skyhanni.data.ScoreboardData -import at.hannibal2.skyhanni.events.DungeonBossRoomEnterEvent -import at.hannibal2.skyhanni.events.DungeonEnterEvent -import at.hannibal2.skyhanni.events.DungeonStartEvent -import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.* import at.hannibal2.skyhanni.utils.LorenzUtils.equalsOneOf import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import at.hannibal2.skyhanni.utils.StringUtils.removeColor -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import net.minecraftforge.fml.common.gameevent.TickEvent @@ -69,7 +65,7 @@ class DungeonData { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { dungeonFloor = null started = false inBossRoom = false diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonDeathCounter.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonDeathCounter.kt index bf25d664f..e13dbcdb1 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonDeathCounter.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonDeathCounter.kt @@ -4,10 +4,10 @@ import at.hannibal2.skyhanni.SkyHanniMod import at.hannibal2.skyhanni.events.DungeonStartEvent import at.hannibal2.skyhanni.events.GuiRenderEvent import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.RenderUtils.renderString import at.hannibal2.skyhanni.utils.StringUtils.matchRegex -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent class DungeonDeathCounter { @@ -79,7 +79,7 @@ class DungeonDeathCounter { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { deaths = 0 update() } diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonHideItems.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonHideItems.kt index f1c80062f..5f82207bb 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonHideItems.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonHideItems.kt @@ -11,7 +11,6 @@ import at.hannibal2.skyhanni.utils.getLorenzVec import net.minecraft.entity.item.EntityArmorStand import net.minecraft.entity.item.EntityItem import net.minecraft.util.EnumParticleTypes -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent class DungeonHideItems { @@ -234,7 +233,7 @@ class DungeonHideItems { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { hideParticles.clear() movingSkeletonSkulls.clear() } diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonLividFinder.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonLividFinder.kt index 4daaf4dbf..b35fd6f3f 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonLividFinder.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonLividFinder.kt @@ -1,6 +1,7 @@ package at.hannibal2.skyhanni.features.dungeon import at.hannibal2.skyhanni.events.LorenzTickEvent +import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.mixins.hooks.RenderLivingEntityHelper import at.hannibal2.skyhanni.utils.BlockUtils.getBlockStateAt import at.hannibal2.skyhanni.utils.EntityUtils @@ -13,7 +14,6 @@ import net.minecraft.client.entity.EntityOtherPlayerMP import net.minecraft.entity.item.EntityArmorStand import net.minecraft.potion.Potion import net.minecraft.util.AxisAlignedBB -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import java.awt.Color @@ -60,7 +60,7 @@ object DungeonLividFinder { } @SubscribeEvent - fun onWorldLoad(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { livid = null gotBlinded = false } diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonMilestonesDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonMilestonesDisplay.kt index 5bdc812fc..5797c0935 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonMilestonesDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonMilestonesDisplay.kt @@ -4,10 +4,10 @@ import at.hannibal2.skyhanni.SkyHanniMod import at.hannibal2.skyhanni.events.DungeonStartEvent import at.hannibal2.skyhanni.events.GuiRenderEvent import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.RenderUtils.renderString import at.hannibal2.skyhanni.utils.StringUtils.matchRegex -import net.minecraftforge.event.world.WorldEvent import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import kotlin.concurrent.fixedRateTimer @@ -71,7 +71,7 @@ class DungeonMilestonesDisplay { } @SubscribeEvent - fun onWorldChange(event: WorldEvent.Load) { + fun onWorldChange(event: LorenzWorldChangeEvent) { display = "" currentMilestone = 0 } |
