From 26c36ab5f0135b50dbe0a983023d80504e2f66b4 Mon Sep 17 00:00:00 2001 From: Lorenz Date: Thu, 14 Jul 2022 11:11:16 +0200 Subject: add ignore guardian feature --- src/main/java/at/lorenz/mod/dungeon/DungeonCleanEnd.kt | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/main/java/at/lorenz/mod/dungeon') diff --git a/src/main/java/at/lorenz/mod/dungeon/DungeonCleanEnd.kt b/src/main/java/at/lorenz/mod/dungeon/DungeonCleanEnd.kt index 9d9f1b4d7..04326c598 100644 --- a/src/main/java/at/lorenz/mod/dungeon/DungeonCleanEnd.kt +++ b/src/main/java/at/lorenz/mod/dungeon/DungeonCleanEnd.kt @@ -10,6 +10,7 @@ import at.lorenz.mod.utils.LorenzUtils.matchRegex 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.minecraft.network.play.server.S1CPacketEntityMetadata import net.minecraft.network.play.server.S2APacketParticles import net.minecraftforge.event.world.WorldEvent @@ -91,6 +92,18 @@ class DungeonCleanEnd { if (entity == Minecraft.getMinecraft().thePlayer) return + if (LorenzMod.feature.dungeon.cleanEndF3IgnoreGuardians) { + if (DungeonData.isOneOf("F3", "M3")) { + if (entity is EntityGuardian) { + if (entity.entityId != lastBossId) { + if (Minecraft.getMinecraft().thePlayer.isSneaking) { + return + } + } + } + } + } + if (chestsSpawned) { if (entity is EntityArmorStand) { if (!entity.hasCustomName()) { -- cgit