aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-10-30 19:47:50 +0100
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-10-30 19:47:50 +0100
commita58db22daeeec2477a65f4e585aa62e89d9d2176 (patch)
tree1c288cfa9a5ee11a536ffc3fb35cc986122952ea
parenteb71da803f521a560f79021b65dbb7264b7171f2 (diff)
downloadskyhanni-a58db22daeeec2477a65f4e585aa62e89d9d2176.tar.gz
skyhanni-a58db22daeeec2477a65f4e585aa62e89d9d2176.tar.bz2
skyhanni-a58db22daeeec2477a65f4e585aa62e89d9d2176.zip
code cleanup in MobFinder
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/combat/damageindicator/MobFinder.kt451
1 files changed, 213 insertions, 238 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/combat/damageindicator/MobFinder.kt b/src/main/java/at/hannibal2/skyhanni/features/combat/damageindicator/MobFinder.kt
index 0b7b26572..6cc9b4b85 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/combat/damageindicator/MobFinder.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/combat/damageindicator/MobFinder.kt
@@ -75,59 +75,57 @@ class MobFinder {
private var floor6Sadan = false
private var floor6SadanSpawnTime = 0L
- internal fun tryAdd(entity: EntityLivingBase): EntityResult? {
- return when {
- LorenzUtils.inDungeons -> tryAddDungeon(entity)
- RiftAPI.inRift() -> tryAddRift(entity)
- else -> {
- when (entity) {
- /*
+ internal fun tryAdd(entity: EntityLivingBase) = when {
+ LorenzUtils.inDungeons -> tryAddDungeon(entity)
+ RiftAPI.inRift() -> tryAddRift(entity)
+ else -> {
+ when (entity) {
+ /*
* Note that the order does matter here.
* For example, if you put EntityZombie before EntityPigZombie,
* EntityPigZombie will never be reached because EntityPigZombie extends EntityZombie.
* Please take this into consideration if you are to modify this.
*/
- is EntityOtherPlayerMP -> tryAddEntityOtherPlayerMP(entity)
- is EntityIronGolem -> tryAddEntityIronGolem(entity)
- is EntityPigZombie -> tryAddEntityPigZombie(entity)
- is EntityMagmaCube -> tryAddEntityMagmaCube(entity)
- is EntityEnderman -> tryAddEntityEnderman(entity)
- is EntitySkeleton -> tryAddEntitySkeleton(entity)
- is EntityGuardian -> tryAddEntityGuardian(entity)
- is EntityZombie -> tryAddEntityZombie(entity)
- is EntityWither -> tryAddEntityWither(entity)
- is EntityDragon -> tryAddEntityDragon(entity)
- is EntitySpider -> tryAddEntitySpider(entity)
- is EntityHorse -> tryAddEntityHorse(entity)
- is EntityBlaze -> tryAddEntityBlaze(entity)
- is EntityWolf -> tryAddEntityWolf(entity)
- is EntityLiving -> tryAddEntityLiving(entity)
- else -> null
- }
+ is EntityOtherPlayerMP -> tryAddEntityOtherPlayerMP(entity)
+ is EntityIronGolem -> tryAddEntityIronGolem(entity)
+ is EntityPigZombie -> tryAddEntityPigZombie(entity)
+ is EntityMagmaCube -> tryAddEntityMagmaCube(entity)
+ is EntityEnderman -> tryAddEntityEnderman(entity)
+ is EntitySkeleton -> tryAddEntitySkeleton(entity)
+ is EntityGuardian -> tryAddEntityGuardian(entity)
+ is EntityZombie -> tryAddEntityZombie(entity)
+ is EntityWither -> tryAddEntityWither(entity)
+ is EntityDragon -> tryAddEntityDragon(entity)
+ is EntitySpider -> tryAddEntitySpider(entity)
+ is EntityHorse -> tryAddEntityHorse(entity)
+ is EntityBlaze -> tryAddEntityBlaze(entity)
+ is EntityWolf -> tryAddEntityWolf(entity)
+ is EntityLiving -> tryAddEntityLiving(entity)
+ else -> null
}
}
}
- private fun tryAddDungeon(entity: EntityLivingBase): EntityResult? {
- return when {
- DungeonAPI.isOneOf("F1", "M1") -> tryAddDungeonF1(entity)
- DungeonAPI.isOneOf("F2", "M2") -> tryAddDungeonF2(entity)
- DungeonAPI.isOneOf("F3", "M3") -> tryAddDungeonF3(entity)
- DungeonAPI.isOneOf("F4", "M4") -> tryAddDungeonF4(entity)
- DungeonAPI.isOneOf("F5", "M5") -> tryAddDungeonF5(entity)
- DungeonAPI.isOneOf("F6", "M6") -> tryAddDungeonF6(entity)
- else -> null
- }
+ private fun tryAddDungeon(entity: EntityLivingBase) = when {
+ DungeonAPI.isOneOf("F1", "M1") -> tryAddDungeonF1(entity)
+ DungeonAPI.isOneOf("F2", "M2") -> tryAddDungeonF2(entity)
+ DungeonAPI.isOneOf("F3", "M3") -> tryAddDungeonF3(entity)
+ DungeonAPI.isOneOf("F4", "M4") -> tryAddDungeonF4(entity)
+ DungeonAPI.isOneOf("F5", "M5") -> tryAddDungeonF5(entity)
+ DungeonAPI.isOneOf("F6", "M6") -> tryAddDungeonF6(entity)
+ else -> null
}
- private fun tryAddDungeonF1(entity: EntityLivingBase): EntityResult? {
- if (floor1bonzo1 && entity is EntityOtherPlayerMP && entity.name == "Bonzo ") {
- return EntityResult(floor1bonzo1SpawnTime)
+ private fun tryAddDungeonF1(entity: EntityLivingBase) = when {
+ floor1bonzo1 && entity is EntityOtherPlayerMP && entity.name == "Bonzo " -> {
+ EntityResult(floor1bonzo1SpawnTime)
}
- if (floor1bonzo2 && entity is EntityOtherPlayerMP && entity.name == "Bonzo ") {
- return EntityResult(floor1bonzo2SpawnTime, finalDungeonBoss = true)
+
+ floor1bonzo2 && entity is EntityOtherPlayerMP && entity.name == "Bonzo " -> {
+ EntityResult(floor1bonzo2SpawnTime, finalDungeonBoss = true)
}
- return null
+
+ else -> null
}
private fun tryAddDungeonF2(entity: EntityLivingBase): EntityResult? {
@@ -135,9 +133,8 @@ class MobFinder {
if (floor2summons1 && !floor2summonsDiedOnce.contains(entity)) {
if (entity.health.toInt() != 0) {
return EntityResult(floor2summons1SpawnTime)
- } else {
- floor2summonsDiedOnce.add(entity)
}
+ floor2summonsDiedOnce.add(entity)
}
if (floor2secondPhase) {
return EntityResult(floor2secondPhaseSpawnTime)
@@ -146,8 +143,7 @@ class MobFinder {
if (floor2secondPhase && entity is EntityOtherPlayerMP) {
//TODO only show scarf after (all/at least x) summons are dead?
- val result = entity.name == "Scarf "
- if (result) {
+ if (entity.name == "Scarf ") {
return EntityResult(floor2secondPhaseSpawnTime, finalDungeonBoss = true)
}
}
@@ -205,18 +201,17 @@ class MobFinder {
}
private fun tryAddDungeonF6(entity: EntityLivingBase): EntityResult? {
- if (entity is EntityGiantZombie && !entity.isInvisible) {
- if (floor6Giants && entity.posY > 68) {
- val extraDelay = checkExtraF6GiantsDelay(entity)
- return EntityResult(
- floor6GiantsSpawnTime + extraDelay,
- floor6GiantsSpawnTime + extraDelay + 1_000 > System.currentTimeMillis()
- )
- }
+ if (entity !is EntityGiantZombie || entity.isInvisible) return null
+ if (floor6Giants && entity.posY > 68) {
+ val extraDelay = checkExtraF6GiantsDelay(entity)
+ return EntityResult(
+ floor6GiantsSpawnTime + extraDelay,
+ floor6GiantsSpawnTime + extraDelay + 1_000 > System.currentTimeMillis()
+ )
+ }
- if (floor6Sadan) {
- return EntityResult(floor6SadanSpawnTime, finalDungeonBoss = true)
- }
+ if (floor6Sadan) {
+ return EntityResult(floor6SadanSpawnTime, finalDungeonBoss = true)
}
return null
}
@@ -243,14 +238,13 @@ class MobFinder {
return null
}
- private fun tryAddEntityBlaze(entity: EntityLivingBase): EntityResult? {
- return if (entity.name != "Dinnerbone" && entity.hasNameTagWith(
- 2,
- "§e﴾ §8[§7Lv200§8] §l§8§lAshfang§r "
- ) && entity.hasMaxHealth(50_000_000, true)
- ) {
+ private fun tryAddEntityBlaze(entity: EntityLivingBase) = when {
+ entity.name != "Dinnerbone" && entity.hasNameTagWith(2, "§e﴾ §8[§7Lv200§8] §l§8§lAshfang§r ") &&
+ entity.hasMaxHealth(50_000_000, true) -> {
EntityResult(bossType = BossType.NETHER_ASHFANG)
- } else if (entity.hasNameTagWith(2, "§c☠ §bInferno Demonlord ")) {
+ }
+
+ entity.hasNameTagWith(2, "§c☠ §bInferno Demonlord ") -> {
when {
entity.hasBossHealth(2_500_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_1)
entity.hasBossHealth(10_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_2)
@@ -258,13 +252,13 @@ class MobFinder {
entity.hasBossHealth(150_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_4)
else -> null
}
- } else {
- null
}
+
+ else -> null
}
- private fun tryAddEntitySkeleton(entity: EntityLivingBase): EntityResult? {
- return if (entity.hasNameTagWith(2, "§c☠ §3ⓆⓊⒶⓏⒾⒾ ")) {
+ private fun tryAddEntitySkeleton(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(2, "§c☠ §3ⓆⓊⒶⓏⒾⒾ ") -> {
when {
entity.hasBossHealth(10_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_QUAZII_4)
entity.hasBossHealth(5_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_QUAZII_3)
@@ -272,128 +266,116 @@ class MobFinder {
entity.hasBossHealth(500_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_QUAZII_1)
else -> null
}
- } else if (entity.hasNameTagWith(5, "§e﴾ §8[§7Lv200§8] §l§8§lBladesoul§r ")) {
+ }
+
+ entity.hasNameTagWith(5, "§e﴾ §8[§7Lv200§8] §l§8§lBladesoul§r ") -> {
EntityResult(bossType = BossType.NETHER_BLADESOUL)
- } else {
- null
}
+
+ else -> null
}
- private fun tryAddEntityOtherPlayerMP(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.name == "Mage Outlaw" -> EntityResult(bossType = BossType.NETHER_MAGE_OUTLAW)
- entity.name == "DukeBarb " && entity.getLorenzVec()
- .distanceToPlayer() < 30 -> EntityResult(bossType = BossType.NETHER_BARBARIAN_DUKE)
+ private fun tryAddEntityOtherPlayerMP(entity: EntityLivingBase) = when {
+ entity.name == "Mage Outlaw" -> EntityResult(bossType = BossType.NETHER_MAGE_OUTLAW)
+ entity.name == "DukeBarb " && entity.getLorenzVec()
+ .distanceToPlayer() < 30 -> EntityResult(bossType = BossType.NETHER_BARBARIAN_DUKE)
- entity.name == "Minos Inquisitor" -> EntityResult(bossType = BossType.MINOS_INQUISITOR)
- entity.name == "Minos Champion" -> EntityResult(bossType = BossType.MINOS_CHAMPION)
- entity.name == "Minotaur " -> EntityResult(bossType = BossType.MINOTAUR)
- else -> null
- }
- }
+ entity.name == "Minos Inquisitor" -> EntityResult(bossType = BossType.MINOS_INQUISITOR)
+ entity.name == "Minos Champion" -> EntityResult(bossType = BossType.MINOS_CHAMPION)
+ entity.name == "Minotaur " -> EntityResult(bossType = BossType.MINOTAUR)
- private fun tryAddEntityWither(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(4, "§8[§7Lv100§8] §c§5Vanquisher§r ") -> {
- EntityResult(bossType = BossType.NETHER_VANQUISHER)
- }
+ else -> null
+ }
- else -> null
+ private fun tryAddEntityWither(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(4, "§8[§7Lv100§8] §c§5Vanquisher§r ") -> {
+ EntityResult(bossType = BossType.NETHER_VANQUISHER)
}
+
+ else -> null
}
private fun tryAddEntityEnderman(entity: EntityLivingBase): EntityResult? {
- if (entity.hasNameTagWith(3, "§c☠ §bVoidgloom Seraph ")) {
- when {
- entity.hasMaxHealth(300_000, true) -> return EntityResult(bossType = BossType.SLAYER_ENDERMAN_1)
- entity.hasMaxHealth(12_000_000, true) -> return EntityResult(bossType = BossType.SLAYER_ENDERMAN_2)
- entity.hasMaxHealth(50_000_000, true) -> return EntityResult(bossType = BossType.SLAYER_ENDERMAN_3)
- entity.hasMaxHealth(210_000_000, true) -> return EntityResult(bossType = BossType.SLAYER_ENDERMAN_4)
- }
- }
- return null
- }
+ if (!entity.hasNameTagWith(3, "§c☠ §bVoidgloom Seraph ")) return null
- private fun tryAddEntityDragon(entity: EntityLivingBase): EntityResult? {
- //TODO testing and use sidebar data
return when {
- IslandType.THE_END.isInIsland() -> EntityResult(bossType = BossType.END_ENDER_DRAGON)
- IslandType.WINTER.isInIsland() -> EntityResult(bossType = BossType.WINTER_REINDRAKE)
+ entity.hasMaxHealth(300_000, true) -> EntityResult(bossType = BossType.SLAYER_ENDERMAN_1)
+ entity.hasMaxHealth(12_000_000, true) -> EntityResult(bossType = BossType.SLAYER_ENDERMAN_2)
+ entity.hasMaxHealth(50_000_000, true) -> EntityResult(bossType = BossType.SLAYER_ENDERMAN_3)
+ entity.hasMaxHealth(210_000_000, true) -> EntityResult(bossType = BossType.SLAYER_ENDERMAN_4)
else -> null
}
}
- private fun tryAddEntityIronGolem(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(3, "§e﴾ §8[§7Lv100§8] §lEndstone Protector§r ") -> {
- EntityResult(bossType = BossType.END_ENDSTONE_PROTECTOR)
- }
+ //TODO testing and use sidebar data
+ private fun tryAddEntityDragon(entity: EntityLivingBase) = when {
+ IslandType.THE_END.isInIsland() -> EntityResult(bossType = BossType.END_ENDER_DRAGON)
+ IslandType.WINTER.isInIsland() -> EntityResult(bossType = BossType.WINTER_REINDRAKE)
- entity.hasMaxHealth(1_500_000) -> {
- EntityResult(bossType = BossType.GAIA_CONSTURUCT)
- }
+ else -> null
+ }
- entity.hasMaxHealth(100_000_000) -> {
- EntityResult(bossType = BossType.LORD_JAWBUS)
- }
+ private fun tryAddEntityIronGolem(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(3, "§e﴾ §8[§7Lv100§8] §lEndstone Protector§r ") -> {
+ EntityResult(bossType = BossType.END_ENDSTONE_PROTECTOR)
+ }
- else -> null
+ entity.hasMaxHealth(1_500_000) -> {
+ EntityResult(bossType = BossType.GAIA_CONSTURUCT)
}
+
+ entity.hasMaxHealth(100_000_000) -> {
+ EntityResult(bossType = BossType.LORD_JAWBUS)
+ }
+
+ else -> null
}
- private fun tryAddEntityZombie(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(2, "§c☠ §bRevenant Horror") -> {
- when {
- entity.hasMaxHealth(500, true) -> return EntityResult(bossType = BossType.SLAYER_ZOMBIE_1)
- entity.hasMaxHealth(20_000, true) -> return EntityResult(bossType = BossType.SLAYER_ZOMBIE_2)
- entity.hasMaxHealth(400_000, true) -> return EntityResult(bossType = BossType.SLAYER_ZOMBIE_3)
- entity.hasMaxHealth(1_500_000, true) -> return EntityResult(bossType = BossType.SLAYER_ZOMBIE_4)
- else -> null
- }
- }
+ private fun tryAddEntityZombie(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(2, "§c☠ §bRevenant Horror") -> {
+ when {
+ entity.hasMaxHealth(500, true) -> EntityResult(bossType = BossType.SLAYER_ZOMBIE_1)
+ entity.hasMaxHealth(20_000, true) -> EntityResult(bossType = BossType.SLAYER_ZOMBIE_2)
+ entity.hasMaxHealth(400_000, true) -> EntityResult(bossType = BossType.SLAYER_ZOMBIE_3)
+ entity.hasMaxHealth(1_500_000, true) -> EntityResult(bossType = BossType.SLAYER_ZOMBIE_4)
- entity.hasNameTagWith(2, "§c☠ §fAtoned Horror ") && entity.hasMaxHealth(10_000_000, true) -> {
- EntityResult(bossType = BossType.SLAYER_ZOMBIE_5)
+ else -> null
}
-
- else -> null
}
- }
- private fun tryAddEntityLiving(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(2, "Dummy §a10M§c❤") -> EntityResult(bossType = BossType.DUMMY)
- else -> null
+ entity.hasNameTagWith(2, "§c☠ §fAtoned Horror ") && entity.hasMaxHealth(10_000_000, true) -> {
+ EntityResult(bossType = BossType.SLAYER_ZOMBIE_5)
}
+
+ else -> null
}
- private fun tryAddEntityMagmaCube(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(15, "§e﴾ §8[§7Lv500§8] §l§4§lMagma Boss§r ")
- && entity.hasMaxHealth(200_000_000, true) -> {
- EntityResult(bossType = BossType.NETHER_MAGMA_BOSS, ignoreBlocks = true)
- }
+ private fun tryAddEntityLiving(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(2, "Dummy §a10M§c❤") -> EntityResult(bossType = BossType.DUMMY)
- else -> null
- }
+ else -> null
}
- private fun tryAddEntityHorse(entity: EntityLivingBase): EntityResult? {
- return when {
- entity.hasNameTagWith(
- 15,
- "§8[§7Lv100§8] §c§6Headless Horseman§r "
- ) && entity.hasMaxHealth(3_000_000, true) -> {
- EntityResult(bossType = BossType.HUB_HEADLESS_HORSEMAN)
- }
+ private fun tryAddEntityMagmaCube(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(15, "§e﴾ §8[§7Lv500§8] §l§4§lMagma Boss§r ")
+ && entity.hasMaxHealth(200_000_000, true) -> {
+ EntityResult(bossType = BossType.NETHER_MAGMA_BOSS, ignoreBlocks = true)
+ }
- else -> null
+ else -> null
+ }
+
+ private fun tryAddEntityHorse(entity: EntityLivingBase) = when {
+ entity.hasNameTagWith(15, "§8[§7Lv100§8] §c§6Headless Horseman§r ") &&
+ entity.hasMaxHealth(3_000_000, true) -> {
+ EntityResult(bossType = BossType.HUB_HEADLESS_HORSEMAN)
}
+
+ else -> null
}
- private fun tryAddEntityPigZombie(entity: EntityLivingBase): EntityResult? {
- return if (entity.hasNameTagWith(2, "§c☠ §6ⓉⓎⓅⒽⓄⒺⓊⓈ ")) {
+ private fun tryAddEntityPigZombie(entity: EntityLivingBase) =
+ if (entity.hasNameTagWith(2, "§c☠ §6ⓉⓎⓅⒽⓄⒺⓊⓈ ")) {
when {
entity.hasBossHealth(10_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_TYPHOEUS_4)
entity.hasBossHealth(5_000_000) -> EntityResult(bossType = BossType.SLAYER_BLAZE_TYPHOEUS_3)
@@ -402,7 +384,6 @@ class MobFinder {
else -> null
}
} else null
- }
private fun tryAddEntitySpider(entity: EntityLivingBase): EntityResult? {
if (entity.hasNameTagWith(1, "§5☠ §4Tarantula Broodfather ")) {
@@ -437,8 +418,8 @@ class MobFinder {
return null
}
- private fun tryAddEntityWolf(entity: EntityLivingBase): EntityResult? {
- return if (entity.hasNameTagWith(1, "§c☠ §fSven Packmaster ")) {
+ private fun tryAddEntityWolf(entity: EntityLivingBase) =
+ if (entity.hasNameTagWith(1, "§c☠ §fSven Packmaster ")) {
when {
entity.hasMaxHealth(2_000, true) -> EntityResult(bossType = BossType.SLAYER_WOLF_1)
entity.hasMaxHealth(40_000, true) -> EntityResult(bossType = BossType.SLAYER_WOLF_2)
@@ -447,13 +428,10 @@ class MobFinder {
else -> null
}
} else null
- }
- private fun tryAddEntityGuardian(entity: EntityLivingBase): EntityResult? {
- return if (entity.hasMaxHealth(35_000_000)) {
- EntityResult(bossType = BossType.THUNDER)
- } else null
- }
+ private fun tryAddEntityGuardian(entity: EntityLivingBase) = if (entity.hasMaxHealth(35_000_000)) {
+ EntityResult(bossType = BossType.THUNDER)
+ } else null
private fun checkExtraF6GiantsDelay(entity: EntityGiantZombie): Long {
val uuid = entity.uniqueID
@@ -495,109 +473,106 @@ class MobFinder {
}
fun handleChat(message: String) {
- if (LorenzUtils.inDungeons) {
- when (message) {
- //F1
- "§c[BOSS] Bonzo§r§f: Gratz for making it this far, but I’m basically unbeatable." -> {
- floor1bonzo1 = true
- floor1bonzo1SpawnTime = System.currentTimeMillis() + 11_250
- }
-
- "§c[BOSS] Bonzo§r§f: Oh noes, you got me.. what ever will I do?!" -> {
- floor1bonzo1 = false
- }
-
- "§c[BOSS] Bonzo§r§f: Oh I'm dead!" -> {
- floor1bonzo2 = true
- floor1bonzo2SpawnTime = System.currentTimeMillis() + 4_200
- }
+ if (!LorenzUtils.inDungeons) return
+ when (message) {
+ //F1
+ "§c[BOSS] Bonzo§r§f: Gratz for making it this far, but I’m basically unbeatable." -> {
+ floor1bonzo1 = true
+ floor1bonzo1SpawnTime = System.currentTimeMillis() + 11_250
+ }
- "§c[BOSS] Bonzo§r§f: Alright, maybe I'm just weak after all.." -> {
- floor1bonzo2 = false
- }
+ "§c[BOSS] Bonzo§r§f: Oh noes, you got me.. what ever will I do?!" -> {
+ floor1bonzo1 = false
+ }
- //F2
- "§c[BOSS] Scarf§r§f: ARISE, MY CREATIONS!" -> {
- floor2summons1 = true
- floor2summons1SpawnTime = System.currentTimeMillis() + 3_500
- }
+ "§c[BOSS] Bonzo§r§f: Oh I'm dead!" -> {
+ floor1bonzo2 = true
+ floor1bonzo2SpawnTime = System.currentTimeMillis() + 4_200
+ }
- "§c[BOSS] Scarf§r§f: Those toys are not strong enough I see." -> {
- floor2summons1 = false
- }
+ "§c[BOSS] Bonzo§r§f: Alright, maybe I'm just weak after all.." -> {
+ floor1bonzo2 = false
+ }
- "§c[BOSS] Scarf§r§f: Don't get too excited though." -> {
- floor2secondPhase = true
- floor2secondPhaseSpawnTime = System.currentTimeMillis() + 6_300
- }
+ //F2
+ "§c[BOSS] Scarf§r§f: ARISE, MY CREATIONS!" -> {
+ floor2summons1 = true
+ floor2summons1SpawnTime = System.currentTimeMillis() + 3_500
+ }
- "§c[BOSS] Scarf§r§f: Whatever..." -> {
- floor2secondPhase = false
- }
+ "§c[BOSS] Scarf§r§f: Those toys are not strong enough I see." -> {
+ floor2summons1 = false
+ }
- //F3
- "§c[BOSS] The Professor§r§f: I was burdened with terrible news recently..." -> {
- floor3GuardianShield = true
- floor3GuardianShieldSpawnTime = System.currentTimeMillis() + 16_400
- }
+ "§c[BOSS] Scarf§r§f: Don't get too excited though." -> {
+ floor2secondPhase = true
+ floor2secondPhaseSpawnTime = System.currentTimeMillis() + 6_300
+ }
- "§c[BOSS] The Professor§r§f: Even if you took my barrier down, I can still fight." -> {
- floor3GuardianShield = false
- }
+ "§c[BOSS] Scarf§r§f: Whatever..." -> {
+ floor2secondPhase = false
+ }
- "§c[BOSS] The Professor§r§f: Oh? You found my Guardians' one weakness?" -> {
- floor3Professor = true
- floor3ProfessorSpawnTime = System.currentTimeMillis() + 10_300
- }
+ //F3
+ "§c[BOSS] The Professor§r§f: I was burdened with terrible news recently..." -> {
+ floor3GuardianShield = true
+ floor3GuardianShieldSpawnTime = System.currentTimeMillis() + 16_400
+ }
- "§c[BOSS] The Professor§r§f: I see. You have forced me to use my ultimate technique." -> {
- floor3Professor = false
+ "§c[BOSS] The Professor§r§f: Even if you took my barrier down, I can still fight." -> {
+ floor3GuardianShield = false
+ }
- floor3ProfessorGuardianPrepare = true
- floor3ProfessorGuardianPrepareSpawnTime = System.currentTimeMillis() + 10_500
- }
+ "§c[BOSS] The Professor§r§f: Oh? You found my Guardians' one weakness?" -> {
+ floor3Professor = true
+ floor3ProfessorSpawnTime = System.currentTimeMillis() + 10_300
+ }
- "§c[BOSS] The Professor§r§f: The process is irreversible, but I'll be stronger than a Wither now!" -> {
- floor3ProfessorGuardian = true
- }
+ "§c[BOSS] The Professor§r§f: I see. You have forced me to use my ultimate technique." -> {
+ floor3Professor = false
- "§c[BOSS] The Professor§r§f: What?! My Guardian power is unbeatable!" -> {
- floor3ProfessorGuardian = false
- }
+ floor3ProfessorGuardianPrepare = true
+ floor3ProfessorGuardianPrepareSpawnTime = System.currentTimeMillis() + 10_500
+ }
+ "§c[BOSS] The Professor§r§f: The process is irreversible, but I'll be stronger than a Wither now!" -> {
+ floor3ProfessorGuardian = true
+ }
- //F5
- "§c[BOSS] Livid§r§f: This Orb you see, is Thorn, or what is left of him." -> {
- floor5lividEntity = DungeonLividFinder.lividEntity
- floor5lividEntitySpawnTime = System.currentTimeMillis() + 13_000
- }
+ "§c[BOSS] The Professor§r§f: What?! My Guardian power is unbeatable!" -> {
+ floor3ProfessorGuardian = false
+ }
- //F6
- "§c[BOSS] Sadan§r§f: ENOUGH!" -> {
- floor6Giants = true
- floor6GiantsSpawnTime = System.currentTimeMillis() + 7_400
- }
+ //F5
+ "§c[BOSS] Livid§r§f: This Orb you see, is Thorn, or what is left of him." -> {
+ floor5lividEntity = DungeonLividFinder.lividEntity
+ floor5lividEntitySpawnTime = System.currentTimeMillis() + 13_000
+ }
- "§c[BOSS] Sadan§r§f: You did it. I understand now, you have earned my respect." -> {
- floor6Giants = false
- floor6Sadan = true
- floor6SadanSpawnTime = System.currentTimeMillis() + 32_500
- }
+ //F6
+ "§c[BOSS] Sadan§r§f: ENOUGH!" -> {
+ floor6Giants = true
+ floor6GiantsSpawnTime = System.currentTimeMillis() + 7_400
+ }
- "§c[BOSS] Sadan§r§f: NOOOOOOOOO!!! THIS IS IMPOSSIBLE!!" -> {
- floor6Sadan = false
- }
+ "§c[BOSS] Sadan§r§f: You did it. I understand now, you have earned my respect." -> {
+ floor6Giants = false
+ floor6Sadan = true
+ floor6SadanSpawnTime = System.currentTimeMillis() + 32_500
}
- if (message.matchRegex("§c\\[BOSS] (.*) Livid§r§f: Impossible! How did you figure out which one I was\\?!")) {
- floor5lividEntity = null
+ "§c[BOSS] Sadan§r§f: NOOOOOOOOO!!! THIS IS IMPOSSIBLE!!" -> {
+ floor6Sadan = false
}
}
+
+ if (message.matchRegex("§c\\[BOSS] (.*) Livid§r§f: Impossible! How did you figure out which one I was\\?!")) {
+ floor5lividEntity = null
+ }
}
fun handleNewEntity(entity: Entity) {
if (LorenzUtils.inDungeons && floor3ProfessorGuardian && entity is EntityGuardian && floor3ProfessorGuardianEntity == null) {
-
floor3ProfessorGuardianEntity = entity
floor3ProfessorGuardianPrepare = false