aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal002@users.noreply.github.com>2024-05-01 05:26:08 +0200
committerGitHub <noreply@github.com>2024-05-01 13:26:08 +1000
commit1259d8a657829a9343e3024c031f7bf94f6897b9 (patch)
tree038892e42260739286f601094ac22ed436fae9a4
parent7df31da39359712dd6ec39c8186ad80908ac0a58 (diff)
downloadskyhanni-1259d8a657829a9343e3024c031f7bf94f6897b9.tar.gz
skyhanni-1259d8a657829a9343e3024c031f7bf94f6897b9.tar.bz2
skyhanni-1259d8a657829a9343e3024c031f7bf94f6897b9.zip
Merge pull request #1599
* doing big moves * Merge branch 'refs/heads/beta' into splitting-factory-and-hoppity-in-… * 43 -> 44
-rw-r--r--src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt26
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt2
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/event/HoppityEggsConfig.java6
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChocolateFactoryConfig.java (renamed from src/main/java/at/hannibal2/skyhanni/config/features/event/ChocolateFactoryConfig.java)40
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityCollectionStats.kt)4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggLocator.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggLocator.kt)6
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggType.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggType.kt)2
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsManager.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsManager.kt)18
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsShared.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsShared.kt)8
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityNpc.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityNpc.kt)5
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateAmount.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateAmount.kt)5
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryAPI.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryAPI.kt)37
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryBarnManager.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryBarnManager.kt)4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryInventory.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryInventory.kt)4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryShortcut.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryShortcut.kt)2
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryStats.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryStats.kt)4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTimeTowerManager.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTimeTowerManager.kt)3
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltip.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltip.kt)5
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltipCompact.kt (renamed from src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltipCompact.kt)3
21 files changed, 106 insertions, 86 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
index 143ac7dd9..b59e6bd9f 100644
--- a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
+++ b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
@@ -125,19 +125,6 @@ import at.hannibal2.skyhanni.features.dungeon.DungeonTeammateOutlines
import at.hannibal2.skyhanni.features.dungeon.HighlightDungeonDeathmite
import at.hannibal2.skyhanni.features.dungeon.TerracottaPhase
import at.hannibal2.skyhanni.features.event.UniqueGiftingOpportunitiesFeatures
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryBarnManager
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryShortcut
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityCollectionStats
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggLocator
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggsManager
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggsShared
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityNpc
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryInventory
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryStats
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryTimeTowerManager
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryTooltip
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryTooltipCompact
import at.hannibal2.skyhanni.features.event.diana.AllBurrowsList
import at.hannibal2.skyhanni.features.event.diana.BurrowWarpHelper
import at.hannibal2.skyhanni.features.event.diana.DianaProfitTracker
@@ -148,6 +135,11 @@ import at.hannibal2.skyhanni.features.event.diana.HighlightInquisitors
import at.hannibal2.skyhanni.features.event.diana.InquisitorWaypointShare
import at.hannibal2.skyhanni.features.event.diana.MythologicalCreatureTracker
import at.hannibal2.skyhanni.features.event.diana.SoopyGuessBurrow
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityCollectionStats
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggLocator
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggsManager
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggsShared
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityNpc
import at.hannibal2.skyhanni.features.event.jerry.HighlightJerries
import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasureTracker
import at.hannibal2.skyhanni.features.event.lobby.waypoints.christmas.PresentWaypoints
@@ -276,6 +268,14 @@ import at.hannibal2.skyhanni.features.inventory.bazaar.BazaarCancelledBuyOrderCl
import at.hannibal2.skyhanni.features.inventory.bazaar.BazaarOpenPriceWebsite
import at.hannibal2.skyhanni.features.inventory.bazaar.BazaarOrderHelper
import at.hannibal2.skyhanni.features.inventory.bazaar.CraftMaterialsFromBazaar
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryBarnManager
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryInventory
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryShortcut
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryStats
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryTimeTowerManager
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryTooltip
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryTooltipCompact
import at.hannibal2.skyhanni.features.inventory.tiarelay.TiaRelayHelper
import at.hannibal2.skyhanni.features.inventory.tiarelay.TiaRelayWaypoints
import at.hannibal2.skyhanni.features.itemabilities.ChickenHeadTimer
diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt
index faeab5a00..6fa027640 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt
+++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt
@@ -12,7 +12,7 @@ import com.google.gson.JsonPrimitive
object ConfigUpdaterMigrator {
val logger = LorenzLogger("ConfigMigration")
- const val CONFIG_VERSION = 43
+ const val CONFIG_VERSION = 44
fun JsonElement.at(chain: List<String>, init: Boolean): JsonElement? {
if (chain.isEmpty()) return this
if (this !is JsonObject) return null
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java
index b68664d79..b50c67ea6 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java
@@ -24,8 +24,8 @@ public class EventConfig {
public WinterConfig winter = new WinterConfig();
@Expose
- @Category(name = "Hoppity", desc = "Features for the Hoppity event and the chocolate factory.")
- public ChocolateFactoryConfig chocolateFactory = new ChocolateFactoryConfig();
+ @Category(name = "Hoppity Eggs", desc = "Features for the Hoppity event.")
+ public HoppityEggsConfig hoppityEggs = new HoppityEggsConfig();
@ConfigOption(name = "City Project", desc = "")
@Accordion
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/HoppityEggsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/HoppityEggsConfig.java
index 133323926..5306cf967 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/event/HoppityEggsConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/HoppityEggsConfig.java
@@ -36,4 +36,10 @@ public class HoppityEggsConfig {
@Expose
@ConfigLink(owner = HoppityEggsConfig.class, field = "showClaimedEggs")
public Position position = new Position(33, 72, false, true);
+
+ @Expose
+ @ConfigOption(name = "Highlight Hoppity Shop", desc = "Highlight items that haven't been bought from the Hoppity shop yet.")
+ @ConfigEditorBoolean
+ @FeatureToggle
+ public boolean highlightHoppityShop = true;
}
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/ChocolateFactoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChocolateFactoryConfig.java
index d725c2974..7692d28c6 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/event/ChocolateFactoryConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChocolateFactoryConfig.java
@@ -1,10 +1,9 @@
-package at.hannibal2.skyhanni.config.features.event;
+package at.hannibal2.skyhanni.config.features.inventory;
import at.hannibal2.skyhanni.config.FeatureToggle;
import at.hannibal2.skyhanni.config.core.config.Position;
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryStats.ChocolateFactoryStat;
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryStats.ChocolateFactoryStat;
import com.google.gson.annotations.Expose;
-import io.github.notenoughupdates.moulconfig.annotations.Accordion;
import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorBoolean;
import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorDraggableList;
import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorSlider;
@@ -18,11 +17,6 @@ import java.util.List;
public class ChocolateFactoryConfig {
@Expose
- @ConfigOption(name = "Hoppity Eggs", desc = "")
- @Accordion
- public HoppityEggsConfig hoppityEggs = new HoppityEggsConfig();
-
- @Expose
@ConfigOption(name = "Chocolate Factory Features", desc = "Global toggle for all chocolate factory features.")
@ConfigEditorBoolean
@FeatureToggle
@@ -93,12 +87,6 @@ public class ChocolateFactoryConfig {
public boolean extraTooltipStats = true;
@Expose
- @ConfigOption(name = "Hoppity Collection Stats", desc = "Shows info about your hoppity rabbit collection.")
- @ConfigEditorBoolean
- @FeatureToggle
- public boolean hoppityCollectionStats = true;
-
- @Expose
@ConfigOption(name = "Time Tower Warning", desc = "Notification when you have a new time tower usage available and " +
"continuously warn when your time tower is full.")
@ConfigEditorBoolean
@@ -106,20 +94,10 @@ public class ChocolateFactoryConfig {
public boolean timeTowerWarning = false;
@Expose
- @ConfigOption(name = "Hoppity Menu Shortcut", desc = "Add a Chocolate Factory button in the SkyBlock Menu that runs /chocolatefactory on click.")
- @ConfigEditorBoolean
- @FeatureToggle
- public boolean hoppityMenuShortcut = true;
-
- @Expose
@ConfigLink(owner = ChocolateFactoryConfig.class, field = "statsDisplay")
public Position position = new Position(163, 160, false, true);
@Expose
- @ConfigLink(owner = ChocolateFactoryConfig.class, field = "hoppityCollectionStats")
- public Position hoppityStatsPosition = new Position(163, 160, false, true);
-
- @Expose
@ConfigOption(name = "Compact On Click", desc = "Compact the item toolip when clicking on the chocolate.")
@ConfigEditorBoolean
@FeatureToggle
@@ -141,8 +119,18 @@ public class ChocolateFactoryConfig {
public Position tooltipMovePosition = new Position(-380, 150, false, true);
@Expose
- @ConfigOption(name = "Highlight Hoppity Shop", desc = "Highlight items that haven't been bought from the Hoppity shop yet.")
+ @ConfigOption(name = "Hoppity Collection Stats", desc = "Shows info about your hoppity rabbit collection.")
@ConfigEditorBoolean
@FeatureToggle
- public boolean highlightHoppityShop = true;
+ public boolean hoppityCollectionStats = true;
+
+ @Expose
+ @ConfigLink(owner = ChocolateFactoryConfig.class, field = "hoppityCollectionStats")
+ public Position hoppityStatsPosition = new Position(163, 160, false, true);
+
+ @Expose
+ @ConfigOption(name = "Hoppity Menu Shortcut", desc = "Add a Chocolate Factory button in the SkyBlock Menu that runs /chocolatefactory on click.")
+ @ConfigEditorBoolean
+ @FeatureToggle
+ public boolean hoppityMenuShortcut = true;
}
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java
index 518730117..f28aac82e 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java
@@ -49,6 +49,10 @@ public class InventoryConfig {
public ItemAbilityConfig itemAbilities = new ItemAbilityConfig();
@Expose
+ @Category(name = "Chocolate Factory", desc = "The chocolate factory")
+ public ChocolateFactoryConfig chocolateFactory = new ChocolateFactoryConfig();
+
+ @Expose
@ConfigOption(name = "Not Clickable Items", desc = "")
@Accordion
public HideNotClickableConfig hideNotClickable = new HideNotClickableConfig();
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityCollectionStats.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt
index 09091532a..6f835b760 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityCollectionStats.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityCollectionStats.kt
@@ -1,10 +1,10 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
import at.hannibal2.skyhanni.events.GuiRenderEvent
import at.hannibal2.skyhanni.events.InventoryCloseEvent
import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent
import at.hannibal2.skyhanni.events.ProfileJoinEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.utils.DisplayTableEntry
import at.hannibal2.skyhanni.utils.ItemUtils.getLore
import at.hannibal2.skyhanni.utils.LorenzUtils
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggLocator.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggLocator.kt
index b6767f7b8..9a6a8799d 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggLocator.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggLocator.kt
@@ -1,4 +1,4 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
import at.hannibal2.skyhanni.data.IslandType
import at.hannibal2.skyhanni.events.DebugDataCollectEvent
@@ -6,7 +6,7 @@ import at.hannibal2.skyhanni.events.LorenzRenderWorldEvent
import at.hannibal2.skyhanni.events.LorenzTickEvent
import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent
import at.hannibal2.skyhanni.events.ReceiveParticleEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.test.GriffinUtils.drawWaypointFilled
import at.hannibal2.skyhanni.utils.InventoryUtils
import at.hannibal2.skyhanni.utils.ItemUtils.getInternalName
@@ -26,7 +26,7 @@ import kotlin.time.Duration.Companion.seconds
object HoppityEggLocator {
- private val config get() = ChocolateFactoryAPI.config.hoppityEggs
+ private val config get() = HoppityEggsManager.config
private val locatorItem = "EGGLOCATOR".asInternalName()
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggType.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggType.kt
index 295e95d9c..15f463884 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggType.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggType.kt
@@ -1,4 +1,4 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
import io.github.moulberry.notenoughupdates.util.SkyBlockTime
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsManager.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsManager.kt
index f7dfaf99e..8b3d81c44 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsManager.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsManager.kt
@@ -1,11 +1,13 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
+import at.hannibal2.skyhanni.SkyHanniMod
+import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator
import at.hannibal2.skyhanni.events.GuiRenderEvent
import at.hannibal2.skyhanni.events.LorenzChatEvent
import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent
import at.hannibal2.skyhanni.events.SecondPassedEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.features.fame.ReminderUtils
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.test.command.ErrorManager
import at.hannibal2.skyhanni.utils.ChatUtils
import at.hannibal2.skyhanni.utils.DelayedRun
@@ -20,7 +22,7 @@ import kotlin.time.Duration.Companion.seconds
object HoppityEggsManager {
- private val config get() = ChocolateFactoryAPI.config.hoppityEggs
+ val config get() = SkyHanniMod.feature.event.hoppityEggs
private val eggFoundPattern by ChocolateFactoryAPI.patternGroup.pattern(
"egg.found",
@@ -115,4 +117,14 @@ object HoppityEggsManager {
fun onSecondPassed(event: SecondPassedEvent) {
HoppityEggType.checkClaimed()
}
+
+ @SubscribeEvent
+ fun onConfigFix(event: ConfigUpdaterMigrator.ConfigFixEvent) {
+ event.move(
+ 44,
+ "event.chocolateFactory.highlightHoppityShop",
+ "event.chocolateFactory.hoppityEggs.highlightHoppityShop"
+ )
+ event.move(44, "event.chocolateFactory.hoppityEggs", "event.hoppityEggs")
+ }
}
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsShared.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsShared.kt
index effd33500..5577db3fd 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityEggsShared.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityEggsShared.kt
@@ -1,8 +1,8 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
import at.hannibal2.skyhanni.events.LorenzChatEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggsManager.getEggType
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggsManager.getEggType
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.utils.ChatUtils
import at.hannibal2.skyhanni.utils.LorenzUtils
import at.hannibal2.skyhanni.utils.LorenzVec
@@ -13,7 +13,7 @@ import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
object HoppityEggsShared {
- private val config get() = ChocolateFactoryAPI.config.hoppityEggs
+ private val config get() = HoppityEggsManager.config
/**
* REGEX-TEST: CalMWolfs: [SkyHanni] Breakfast Chocolate Egg located at x: 142, y: 71, z: -453
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityNpc.kt b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityNpc.kt
index 8e8e137ae..199535279 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/hoppity/HoppityNpc.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/event/hoppity/HoppityNpc.kt
@@ -1,11 +1,10 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity
+package at.hannibal2.skyhanni.features.event.hoppity
import at.hannibal2.skyhanni.events.GuiContainerEvent
import at.hannibal2.skyhanni.events.InventoryCloseEvent
import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent
import at.hannibal2.skyhanni.events.InventoryUpdatedEvent
import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.utils.InventoryUtils
import at.hannibal2.skyhanni.utils.ItemUtils.getLore
import at.hannibal2.skyhanni.utils.LorenzColor
@@ -15,7 +14,7 @@ import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
object HoppityNpc {
- private val config get() = ChocolateFactoryAPI.config
+ private val config get() = HoppityEggsManager.config
private var slotsToHighlight = mutableSetOf<Int>()
private var inShop = false
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateAmount.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateAmount.kt
index 160023629..cf22746ef 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateAmount.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateAmount.kt
@@ -1,7 +1,6 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI.profileStorage
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI.profileStorage
import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators
import at.hannibal2.skyhanni.utils.SimpleTimeMark
import at.hannibal2.skyhanni.utils.TimeUtils.format
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryAPI.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryAPI.kt
index 377e79072..76fd47489 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryAPI.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryAPI.kt
@@ -1,7 +1,7 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.SkyHanniMod
-import at.hannibal2.skyhanni.config.features.event.ChocolateFactoryConfig
+import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator
import at.hannibal2.skyhanni.config.storage.ProfileSpecificStorage.ChocolateFactoryStorage
import at.hannibal2.skyhanni.data.ProfileStorageData
import at.hannibal2.skyhanni.data.jsonobjects.repo.HoppityEggLocationsJson
@@ -10,11 +10,7 @@ import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent
import at.hannibal2.skyhanni.events.InventoryUpdatedEvent
import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent
import at.hannibal2.skyhanni.events.RepositoryReloadEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggLocator
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateAmount
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryStats
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryTimeTowerManager
-import at.hannibal2.skyhanni.features.event.chocolatefactory.menu.ChocolateFactoryTooltip
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggLocator
import at.hannibal2.skyhanni.utils.CollectionUtils.nextAfter
import at.hannibal2.skyhanni.utils.DelayedRun
import at.hannibal2.skyhanni.utils.InventoryUtils
@@ -39,8 +35,7 @@ import net.minecraft.item.ItemStack
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
object ChocolateFactoryAPI {
-
- val config: ChocolateFactoryConfig get() = SkyHanniMod.feature.event.chocolateFactory
+ val config get() = SkyHanniMod.feature.inventory.chocolateFactory
val profileStorage: ChocolateFactoryStorage? get() = ProfileStorageData.profileSpecific?.chocolateFactory
val patternGroup = RepoPattern.group("misc.chocolatefactory")
@@ -332,6 +327,30 @@ object ChocolateFactoryAPI {
ChocolateFactoryTooltip.updateIgnoredSlots()
}
+ @SubscribeEvent
+ fun onConfigFix(event: ConfigUpdaterMigrator.ConfigFixEvent) {
+ val old = "event.chocolateFactory"
+ val new = "inventory.chocolateFactory"
+ event.move(44, "$old.enabled", "$new.enabled")
+ event.move(44, "$old.statsDisplay", "$new.statsDisplay")
+ event.move(44, "$old.statsDisplayList", "$new.statsDisplayList")
+ event.move(44, "$old.showStackSizes", "$new.showStackSizes")
+ event.move(44, "$old.highlightUpgrades", "$new.highlightUpgrades")
+ event.move(44, "$old.useMiddleClick", "$new.useMiddleClick")
+ event.move(44, "$old.rabbitWarning", "$new.rabbitWarning")
+ event.move(44, "$old.barnCapacityThreshold", "$new.barnCapacityThreshold")
+ event.move(44, "$old.extraTooltipStats", "$new.extraTooltipStats")
+ event.move(44, "$old.timeTowerWarning", "$new.timeTowerWarning")
+ event.move(44, "$old.position", "$new.position")
+ event.move(44, "$old.compactOnClick", "$new.compactOnClick")
+ event.move(44, "$old.compactOnClickAlways", "$new.compactOnClickAlways")
+ event.move(44, "$old.tooltipMove", "$new.tooltipMove")
+ event.move(44, "$old.tooltipMovePosition", "$new.tooltipMovePosition")
+ event.move(44, "$old.hoppityMenuShortcut", "$new.hoppityMenuShortcut")
+ event.move(44, "$old.hoppityCollectionStats", "$new.hoppityCollectionStats")
+ event.move(44, "$old.hoppityStatsPosition", "$new.hoppityStatsPosition")
+ }
+
fun getChocolateUpgradeCost(lore: List<String>): Long? {
val nextLine = lore.nextAfter({ UtilsPatterns.costLinePattern.matches(it) }) ?: return null
return chocolateAmountPattern.matchMatcher(nextLine.removeColor()) {
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryBarnManager.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryBarnManager.kt
index 7b1be9152..7154af4a1 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryBarnManager.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryBarnManager.kt
@@ -1,7 +1,7 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.events.LorenzChatEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.hoppity.HoppityEggsManager
+import at.hannibal2.skyhanni.features.event.hoppity.HoppityEggsManager
import at.hannibal2.skyhanni.utils.ChatUtils
import at.hannibal2.skyhanni.utils.HypixelCommands
import at.hannibal2.skyhanni.utils.LorenzUtils
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryInventory.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryInventory.kt
index add477bb9..0e5caca37 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryInventory.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryInventory.kt
@@ -1,10 +1,8 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.events.GuiContainerEvent
import at.hannibal2.skyhanni.events.GuiRenderItemEvent
import at.hannibal2.skyhanni.events.RenderInventoryItemTipEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryBarnManager
import at.hannibal2.skyhanni.utils.InventoryUtils
import at.hannibal2.skyhanni.utils.ItemUtils.getLore
import at.hannibal2.skyhanni.utils.ItemUtils.name
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryShortcut.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryShortcut.kt
index 6b9fc671e..7053f521d 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/ChocolateFactoryShortcut.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryShortcut.kt
@@ -1,4 +1,4 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.data.IslandType
import at.hannibal2.skyhanni.events.GuiContainerEvent
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryStats.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryStats.kt
index e1b26fed8..cbf38db46 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryStats.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryStats.kt
@@ -1,10 +1,8 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator
import at.hannibal2.skyhanni.events.GuiRenderEvent
import at.hannibal2.skyhanni.events.SecondPassedEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryBarnManager
import at.hannibal2.skyhanni.utils.ClipboardUtils
import at.hannibal2.skyhanni.utils.LorenzUtils
import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTimeTowerManager.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTimeTowerManager.kt
index a1b34a1a4..e83e60e2b 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTimeTowerManager.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTimeTowerManager.kt
@@ -1,8 +1,7 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.events.ProfileJoinEvent
import at.hannibal2.skyhanni.events.SecondPassedEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.features.fame.ReminderUtils
import at.hannibal2.skyhanni.utils.ChatUtils
import at.hannibal2.skyhanni.utils.HypixelCommands
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltip.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltip.kt
index dd09a2402..227ece8d9 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltip.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltip.kt
@@ -1,8 +1,7 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.events.LorenzToolTipEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI.profileStorage
+import at.hannibal2.skyhanni.features.inventory.chocolatefactory.ChocolateFactoryAPI.profileStorage
import at.hannibal2.skyhanni.utils.LorenzUtils.round
import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators
import net.minecraftforge.fml.common.eventhandler.EventPriority
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltipCompact.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltipCompact.kt
index 00d6783ba..212d9c130 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/event/chocolatefactory/menu/ChocolateFactoryTooltipCompact.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/chocolatefactory/ChocolateFactoryTooltipCompact.kt
@@ -1,9 +1,8 @@
-package at.hannibal2.skyhanni.features.event.chocolatefactory.menu
+package at.hannibal2.skyhanni.features.inventory.chocolatefactory
import at.hannibal2.skyhanni.events.GuiContainerEvent
import at.hannibal2.skyhanni.events.GuiRenderEvent
import at.hannibal2.skyhanni.events.LorenzToolTipEvent
-import at.hannibal2.skyhanni.features.event.chocolatefactory.ChocolateFactoryAPI
import at.hannibal2.skyhanni.utils.CollectionUtils.getOrNull
import at.hannibal2.skyhanni.utils.ItemUtils.getLore
import at.hannibal2.skyhanni.utils.ItemUtils.name