aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal002@users.noreply.github.com>2024-08-25 23:50:04 +0200
committerGitHub <noreply@github.com>2024-08-25 23:50:04 +0200
commit17be307d56bab4f50006bb5487e4bf513ef8ee08 (patch)
treec84338903982d9a7f63fc0ace113e9d074fffa0f /src/main/java/at/hannibal2
parent90e6983f8589d6d2725dcc77bfdd13be92cfc131 (diff)
downloadskyhanni-17be307d56bab4f50006bb5487e4bf513ef8ee08.tar.gz
skyhanni-17be307d56bab4f50006bb5487e4bf513ef8ee08.tar.bz2
skyhanni-17be307d56bab4f50006bb5487e4bf513ef8ee08.zip
Fix: Hoppity Requirement (#2398)
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
Diffstat (limited to 'src/main/java/at/hannibal2')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt
index e9a8bb687..f4d98e782 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt
@@ -134,11 +134,13 @@ object HoppityCollectionStats {
@SubscribeEvent
fun onInventoryOpen(event: InventoryFullyOpenedEvent) {
- if (!isEnabled()) return
+ if (!(LorenzUtils.inSkyBlock)) return
if (!pagePattern.matches(event.inventoryName)) return
inInventory = true
- display = buildDisplay(event)
+ if (config.hoppityCollectionStats) {
+ display = buildDisplay(event)
+ }
}
@SubscribeEvent
@@ -150,6 +152,7 @@ object HoppityCollectionStats {
@SubscribeEvent
fun onBackgroundDraw(event: GuiRenderEvent.ChestGuiOverlayRenderEvent) {
if (!inInventory) return
+ if (!config.hoppityCollectionStats) return
config.hoppityStatsPosition.renderRenderables(
display,
@@ -367,8 +370,6 @@ object HoppityCollectionStats {
fun hasFoundRabbit(rabbit: String): Boolean = loggedRabbits.containsKey(rabbit)
- private fun isEnabled() = LorenzUtils.inSkyBlock && config.hoppityCollectionStats
-
enum class RabbitCollectionRarity(
val displayName: String,
val item: NEUInternalName,