aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2024-04-07 09:05:20 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2024-04-07 09:05:20 +0200
commitd0587a449ca47ad13788672bb9d014a6d9289d15 (patch)
treeece1f670c19e6b5876e89f69fd8747585fdc5e08 /src/main
parent9b2b9732939449ad5324c0169e0db23e0313bd3f (diff)
downloadskyhanni-d0587a449ca47ad13788672bb9d014a6d9289d15.tar.gz
skyhanni-d0587a449ca47ad13788672bb9d014a6d9289d15.tar.bz2
skyhanni-d0587a449ca47ad13788672bb9d014a6d9289d15.zip
extract DungeonFloor into own class
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/storage/ProfileSpecificStorage.java4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonAPI.kt16
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt2
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFloor.kt17
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/dungeon/TerracottaPhase.kt2
5 files changed, 21 insertions, 20 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/storage/ProfileSpecificStorage.java b/src/main/java/at/hannibal2/skyhanni/config/storage/ProfileSpecificStorage.java
index 68761ef3a..fd1d87206 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/storage/ProfileSpecificStorage.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/storage/ProfileSpecificStorage.java
@@ -6,7 +6,7 @@ import at.hannibal2.skyhanni.data.model.ComposterUpgrade;
import at.hannibal2.skyhanni.features.combat.endernodetracker.EnderNodeTracker;
import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostData;
import at.hannibal2.skyhanni.features.dungeon.CroesusChestTracker;
-import at.hannibal2.skyhanni.features.dungeon.DungeonAPI;
+import at.hannibal2.skyhanni.features.dungeon.DungeonFloor;
import at.hannibal2.skyhanni.features.event.diana.DianaProfitTracker;
import at.hannibal2.skyhanni.features.event.diana.MythologicalCreatureTracker;
import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasureTracker;
@@ -409,7 +409,7 @@ public class ProfileSpecificStorage {
public static class DungeonStorage {
@Expose
- public Map<DungeonAPI.DungeonFloor, Integer> bosses = new HashMap<>();
+ public Map<DungeonFloor, Integer> bosses = new HashMap<>();
@Expose
public List<DungeonStorage.DungeonRunInfo> runs = Stream.generate(DungeonStorage.DungeonRunInfo::new)
diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonAPI.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonAPI.kt
index 1543aaf01..47f742ded 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonAPI.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonAPI.kt
@@ -259,22 +259,6 @@ object DungeonAPI {
}
}
- enum class DungeonFloor(private val bossName: String) {
- ENTRANCE("The Watcher"),
- F1("Bonzo"),
- F2("Scarf"),
- F3("The Professor"),
- F4("Thorn"),
- F5("Livid"),
- F6("Sadan"),
- F7("Necron");
-
- companion object {
-
- fun byBossName(bossName: String) = DungeonFloor.entries.firstOrNull { it.bossName == bossName }
- }
- }
-
enum class DungeonClass(val scoreboardName: String) {
ARCHER("Archer"),
BERSERK("Berserk"),
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 80d4a48d2..60574b1c6 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonCopilot.kt
@@ -75,7 +75,7 @@ class DungeonCopilot {
if (message == "§c[BOSS] The Watcher§r§f: That will be enough for now.") changeNextStep("Clear Blood Room")
if (message == "§c[BOSS] The Watcher§r§f: You have proven yourself. You may pass.") {
- if (DungeonAPI.getCurrentBoss() == DungeonAPI.DungeonFloor.ENTRANCE) {
+ if (DungeonAPI.getCurrentBoss() == DungeonFloor.ENTRANCE) {
changeNextStep("")
} else {
changeNextStep("Enter Boss Room")
diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFloor.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFloor.kt
new file mode 100644
index 000000000..5bb2ae0c2
--- /dev/null
+++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFloor.kt
@@ -0,0 +1,17 @@
+package at.hannibal2.skyhanni.features.dungeon
+
+enum class DungeonFloor(private val bossName: String) {
+ ENTRANCE("The Watcher"),
+ F1("Bonzo"),
+ F2("Scarf"),
+ F3("The Professor"),
+ F4("Thorn"),
+ F5("Livid"),
+ F6("Sadan"),
+ F7("Necron");
+
+ companion object {
+
+ fun byBossName(bossName: String) = DungeonFloor.entries.firstOrNull { it.bossName == bossName }
+ }
+}
diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/TerracottaPhase.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/TerracottaPhase.kt
index 7b47adfda..a0e923820 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/TerracottaPhase.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/TerracottaPhase.kt
@@ -46,5 +46,5 @@ class TerracottaPhase {
private fun isActive() = isEnabled() && inTerracottaPhase
private fun isEnabled() =
- LorenzUtils.inDungeons && DungeonAPI.inBossRoom && DungeonAPI.getCurrentBoss() == DungeonAPI.DungeonFloor.F6
+ LorenzUtils.inDungeons && DungeonAPI.inBossRoom && DungeonAPI.getCurrentBoss() == DungeonFloor.F6
}