From c7463ccbbe3f6a7ff91ed38f0bcafe82dd1a843c Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Fri, 23 Jun 2023 00:27:08 +0200 Subject: Added Leech Supreme to Damage Indicator --- .../at/hannibal2/skyhanni/config/Features.java | 2 +- .../skyhanni/config/features/DamageIndicator.java | 90 --------------------- .../config/features/DamageIndicatorConfig.java | 91 ++++++++++++++++++++++ .../skyhanni/features/damageindicator/BossType.kt | 3 + .../skyhanni/features/damageindicator/MobFinder.kt | 7 ++ 5 files changed, 102 insertions(+), 91 deletions(-) delete mode 100644 src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicator.java create mode 100644 src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicatorConfig.java (limited to 'src/main/java/at/hannibal2/skyhanni') diff --git a/src/main/java/at/hannibal2/skyhanni/config/Features.java b/src/main/java/at/hannibal2/skyhanni/config/Features.java index 02c4f9a80..8adf851ce 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/Features.java +++ b/src/main/java/at/hannibal2/skyhanni/config/Features.java @@ -85,7 +85,7 @@ public class Features extends Config { @Expose @Category(name = "Damage Indicator", desc = "Better damage overview in combat with bosses of all sorts.") - public DamageIndicator damageIndicator = new DamageIndicator(); + public DamageIndicatorConfig damageIndicator = new DamageIndicatorConfig(); @Expose @Category(name = "Slayer", desc = "Slayer features.") diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicator.java b/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicator.java deleted file mode 100644 index f558b638d..000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicator.java +++ /dev/null @@ -1,90 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class DamageIndicator { - - @Expose - @ConfigOption(name = "Damage Indicator Enabled", desc = "Show the boss' remaining health.") - @ConfigEditorBoolean - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Healing Chat Message", desc = "Sends a chat message when a boss heals themself.") - @ConfigEditorBoolean - public boolean healingMessage = false; - - @Expose - @ConfigOption( - name = "Boss Name", - desc = "Change how the boss name should be displayed.") - @ConfigEditorDropdown(values = {"Disabled", "Full Name", "Short Name"}) - public int bossName = 1; - - @Expose - @ConfigOption( - name = "Select Boss", - desc = "Change what type of boss you want the damage indicator be enabled for." - ) - @ConfigEditorDraggableList( - exampleText = { - "§bDungeon All", - "§bNether Mini Bosses", - "§bVanquisher", - "§bEndstone Protector (not tested)", - "§bEnder Dragon (not finished)", - "§bRevenant Horror", - "§bTarantula Broodfather", - "§bSven Packmaster", - "§bVoidgloom Seraph", - "§bInferno Demonlord (only tier 1 yet)", - "§bHeadless Horseman (bugged)", - "§bDungeon Floor 1", - "§bDungeon Floor 2", - "§bDungeon Floor 3", - "§bDungeon Floor 4", - "§bDungeon Floor 5", - "§bDungeon Floor 6", - "§bDungeon Floor 7", - "§bDiana Mobs", - "§bSea Creatures", - "Dummy", - "§bArachne" - } - ) - //TODO only show currently working and tested features - public List bossesToShow = new ArrayList<>(Arrays.asList(0, 1, 2, 5, 6, 7, 8, 9, 18, 19, 21)); - - @Expose - @ConfigOption(name = "Hide Damage Splash", desc = "Hiding damage splashes near the damage indicator.") - @ConfigEditorBoolean - public boolean hideDamageSplash = false; - - @Expose - @ConfigOption(name = "Damage Over Time", desc = "Show damage and health over time below the damage indicator.") - @ConfigEditorBoolean - public boolean showDamageOverTime = false; - - @Expose - @ConfigOption(name = "Health During Laser", desc = "Show the health of Voidgloom Seraph 4 during the laser phase.") - @ConfigEditorBoolean - public boolean showHealthDuringLaser = false; - - @Expose - @ConfigOption(name = "Hide Nametag", desc = "Hide the vanilla nametag of damage indicator bosses.") - @ConfigEditorBoolean - public boolean hideVanillaNametag = false; - - @Expose - @ConfigOption(name = "Time to Kill", desc = "Show the time it takes to kill the slayer boss.") - @ConfigEditorBoolean - public boolean timeToKillSlayer = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicatorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicatorConfig.java new file mode 100644 index 000000000..141b5e5ed --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/DamageIndicatorConfig.java @@ -0,0 +1,91 @@ +package at.hannibal2.skyhanni.config.features; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +public class DamageIndicatorConfig { + + @Expose + @ConfigOption(name = "Damage Indicator Enabled", desc = "Show the boss' remaining health.") + @ConfigEditorBoolean + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Healing Chat Message", desc = "Sends a chat message when a boss heals themself.") + @ConfigEditorBoolean + public boolean healingMessage = false; + + @Expose + @ConfigOption( + name = "Boss Name", + desc = "Change how the boss name should be displayed.") + @ConfigEditorDropdown(values = {"Disabled", "Full Name", "Short Name"}) + public int bossName = 1; + + @Expose + @ConfigOption( + name = "Select Boss", + desc = "Change what type of boss you want the damage indicator be enabled for." + ) + @ConfigEditorDraggableList( + exampleText = { + "§bDungeon All", + "§bNether Mini Bosses", + "§bVanquisher", + "§bEndstone Protector (not tested)", + "§bEnder Dragon (not finished)", + "§bRevenant Horror", + "§bTarantula Broodfather", + "§bSven Packmaster", + "§bVoidgloom Seraph", + "§bInferno Demonlord (only tier 1 yet)", + "§bHeadless Horseman (bugged)", + "§bDungeon Floor 1", + "§bDungeon Floor 2", + "§bDungeon Floor 3", + "§bDungeon Floor 4", + "§bDungeon Floor 5", + "§bDungeon Floor 6", + "§bDungeon Floor 7", + "§bDiana Mobs", + "§bSea Creatures", + "Dummy", + "§bArachne", + "§bThe Rift Bosses" + } + ) + //TODO only show currently working and tested features + public List bossesToShow = new ArrayList<>(Arrays.asList(0, 1, 2, 5, 6, 7, 8, 9, 18, 19, 21, 22)); + + @Expose + @ConfigOption(name = "Hide Damage Splash", desc = "Hiding damage splashes near the damage indicator.") + @ConfigEditorBoolean + public boolean hideDamageSplash = false; + + @Expose + @ConfigOption(name = "Damage Over Time", desc = "Show damage and health over time below the damage indicator.") + @ConfigEditorBoolean + public boolean showDamageOverTime = false; + + @Expose + @ConfigOption(name = "Health During Laser", desc = "Show the health of Voidgloom Seraph 4 during the laser phase.") + @ConfigEditorBoolean + public boolean showHealthDuringLaser = false; + + @Expose + @ConfigOption(name = "Hide Nametag", desc = "Hide the vanilla nametag of damage indicator bosses.") + @ConfigEditorBoolean + public boolean hideVanillaNametag = false; + + @Expose + @ConfigOption(name = "Time to Kill", desc = "Show the time it takes to kill the slayer boss.") + @ConfigEditorBoolean + public boolean timeToKillSlayer = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/features/damageindicator/BossType.kt b/src/main/java/at/hannibal2/skyhanni/features/damageindicator/BossType.kt index 0b8563937..9abed088a 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/damageindicator/BossType.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/damageindicator/BossType.kt @@ -74,6 +74,9 @@ enum class BossType(val fullName: String, val bossTypeToggle: Int, val shortName ARACHNE_SMALL("§cSmall Arachne", 21), ARACHNE_BIG("§4Big Arachne", 21), + // The Rift + LEECH_SUPREME("§cLeech Supreme", 22), + //TODO arachne //TODO corelone diff --git a/src/main/java/at/hannibal2/skyhanni/features/damageindicator/MobFinder.kt b/src/main/java/at/hannibal2/skyhanni/features/damageindicator/MobFinder.kt index 373d20c22..4316c895c 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/damageindicator/MobFinder.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/damageindicator/MobFinder.kt @@ -3,6 +3,7 @@ package at.hannibal2.skyhanni.features.damageindicator import at.hannibal2.skyhanni.SkyHanniMod import at.hannibal2.skyhanni.events.withAlpha import at.hannibal2.skyhanni.features.dungeon.DungeonData +import at.hannibal2.skyhanni.features.rift.RiftAPI import at.hannibal2.skyhanni.mixins.hooks.RenderLivingEntityHelper import at.hannibal2.skyhanni.utils.EntityUtils.hasBossHealth import at.hannibal2.skyhanni.utils.EntityUtils.hasMaxHealth @@ -192,6 +193,12 @@ class MobFinder { } } } + } else if (RiftAPI.inRift()) { + if (entity is EntityOtherPlayerMP) { + if (entity.name == "Leech Supreme") { + return EntityResult(bossType = BossType.LEECH_SUPREME) + } + } } else { if (entity is EntityBlaze) { if (entity.name != "Dinnerbone") { -- cgit