aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt1
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/Misc.java67
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasureTracker.kt33
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasures.kt14
4 files changed, 115 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
index 4fbf8a619..082ff7f7c 100644
--- a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
+++ b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt
@@ -296,6 +296,7 @@ class SkyHanniMod {
loadModule(RestorePieceOfWizardPortalLore())
loadModule(QuickModMenuSwitch)
loadModule(ShowItemUuid())
+ loadModule(FrozenTreasureTracker())
init()
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java b/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java
index 258bc517a..f5a08521d 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/Misc.java
@@ -6,6 +6,10 @@ import io.github.moulberry.moulconfig.annotations.*;
import io.github.moulberry.moulconfig.observer.Property;
import org.lwjgl.input.Keyboard;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
public class Misc {
@Expose
@@ -479,6 +483,69 @@ public class Misc {
}
@Expose
+ @ConfigOption(name = "Frozen Treasure Tracker", desc = "")
+ @Accordion
+ public Misc.FrozenTreasureTracker frozenTreasureTracker = new Misc.FrozenTreasureTracker();
+
+ public static class FrozenTreasureTracker {
+
+ @Expose
+ @ConfigOption(
+ name = "Enabled",
+ desc = "Tracks all of your drops from frozen treasure in the Glacial Caves\n" +
+ "§eIce calculations are an estimate but are relatively accurate"
+ )
+ @ConfigEditorBoolean
+ public boolean enabled = true;
+
+ @Expose
+ @ConfigOption(
+ name = "Text Format",
+ desc = "Drag text to change the appearance of the overlay."
+ )
+ @ConfigEditorDraggableList(
+ exampleText = { // todo change colours
+ "§e§lFrozen Treasure Tracker",
+ "§e1,636 Treasures Mined",
+ "§e3.2 Total Ice",
+ "§e342,192 Ice/hr",
+ "§e31,002 Compact Procs",
+ " ",
+ "§b182 §fWhite Gift",
+ "§b94 §aGreen Gift",
+ "§b17 §9§cRed Gift",
+ "§b328 §fPacked Ice",
+ "§b80 §aEnchanted Ice",
+ "§b4 §9Enchanted Packed Ice",
+ "§b182 §aIce Bait",
+ "§b3 §aGlowy Chum Bait",
+ "§b36 §5Glacial Fragment",
+ "§b6 §fGlacial Talisman",
+ " ",
+ }
+ )
+ public List<Integer> textFormat = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 14, 15));
+
+ @Expose
+ @ConfigOption(name = "Count Compact", desc = "Adds compact drops from your pickaxe to the ice total.")
+ @ConfigEditorBoolean
+ public boolean countCompact = true;
+
+ @Expose
+ @ConfigOption(name = "Only in Glacial Cave", desc = "Only shows the overlay while in the Glacial Cave.")
+ @ConfigEditorBoolean
+ public boolean onlyInCave = true;
+
+ @Expose
+ @ConfigOption(name = "Hide Chat messages", desc = "Hides the chat messages from frozen treasures.")
+ @ConfigEditorBoolean
+ public boolean hideMessages = false;
+
+ @Expose
+ public Position glacialDropPos = new Position(10, 80, false, true);
+ }
+
+ @Expose
@ConfigOption(name = "Exp Bottles", desc = "Hides all the experience orbs lying on the ground.")
@ConfigEditorBoolean
public boolean hideExpBottles = false;
diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasureTracker.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasureTracker.kt
new file mode 100644
index 000000000..fa947b022
--- /dev/null
+++ b/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasureTracker.kt
@@ -0,0 +1,33 @@
+package at.hannibal2.skyhanni.features.misc
+
+import at.hannibal2.skyhanni.SkyHanniMod
+import at.hannibal2.skyhanni.events.PreProfileSwitchEvent
+import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
+
+class FrozenTreasureTracker {
+ private val config get() = SkyHanniMod.feature.misc.frozenTreasureTracker
+ private var display = listOf<List<Any>>()
+ private var treasureMined = 0
+ private var compactProcs = 0
+ private var estimatedIce = 0
+ private var icePerHour = 0
+
+ private var treasureCount = mapOf<FrozenTreasures, Int>()
+
+ private fun formatDisplay(map: List<List<Any>>): List<List<Any>> {
+ val newList = mutableListOf<List<Any>>()
+ for (index in config.textFormat) {
+ newList.add(map[index])
+ }
+ return newList
+ }
+
+ @SubscribeEvent
+ fun onPreProfileSwitch(event: PreProfileSwitchEvent) {
+ display = emptyList()
+ }
+
+
+ //FROZEN TREASURE! You found Enchanted Ice!
+
+} \ No newline at end of file
diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasures.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasures.kt
new file mode 100644
index 000000000..b2ede31d7
--- /dev/null
+++ b/src/main/java/at/hannibal2/skyhanni/features/misc/FrozenTreasures.kt
@@ -0,0 +1,14 @@
+package at.hannibal2.skyhanni.features.misc
+
+enum class FrozenTreasures (val internalName: String, val displayName: String, val defaultAmount: Int, val iceMultiplier: Int = 0){
+ WHITE_GIFT("WHITE_GIFT", "§fWhite Gift", 1),
+ GREEN_GIFT("GREEN_GIFT", "§aGreen Gift",1),
+ RED_GIFT("RED_GIFT","§9§cRed Gift", 1),
+ PACKED_ICE("PACKED_ICE","§fPacked Ice", 32, 9),
+ ENCHANTED_ICE("ENCHANTED_ICE","§aEnchanted Ice", 16, 160),
+ ENCHANTED_PACKED_ICE("ENCHANTED_PACKED_ICE", "§9Enchanted Packed Ice",1, 25600),
+ ICE_BAIT("ICE_BAIT","§aIce Bait", 16),
+ GLOWY_CHUM_BAIT("GLOWY_CHUM_BAIT", "§aGlowy Chum Bait",16),
+ GLACIAL_FRAGMENT("GLACIAL_FRAGMENT","§5Glacial Fragment", 1),
+ GLACIAL_TALISMAN("GLACIAL_TALISMAN", "§fGlacial Talisman",1)
+} \ No newline at end of file