summaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/config
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/config')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt3
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/Storage.java4
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt9
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/event/diana/AllBurrowsListConfig.java18
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java5
5 files changed, 36 insertions, 3 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt
index 125d395f8..647cb7ec1 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt
+++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt
@@ -67,8 +67,7 @@ class ConfigManager {
}
override fun read(reader: JsonReader): LorenzVec {
- val (x, y, z) = reader.nextString().split(":").map { it.toDouble() }
- return LorenzVec(x, y, z)
+ return LorenzVec.decodeFromString(reader.nextString())
}
}.nullSafe())
.registerTypeAdapter(TrophyRarity::class.java, object : TypeAdapter<TrophyRarity>() {
diff --git a/src/main/java/at/hannibal2/skyhanni/config/Storage.java b/src/main/java/at/hannibal2/skyhanni/config/Storage.java
index 56a11626a..77b92131b 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/Storage.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/Storage.java
@@ -66,6 +66,9 @@ public class Storage {
public Map<String, SkyHanniTracker.DisplayMode> trackerDisplayModes = new HashMap<>();
@Expose
+ public List<LorenzVec> foundDianaBurrowLocations = new ArrayList<>();
+
+ @Expose
public Map<UUID, PlayerSpecific> players = new HashMap<>();
public static class PlayerSpecific {
@@ -467,7 +470,6 @@ public class Storage {
@Expose
// TODO renmae
public MythologicalCreatureTracker.Data mythologicalMobTracker = new MythologicalCreatureTracker.Data();
-
}
}
}
diff --git a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt
index b196bb634..680834317 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt
+++ b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt
@@ -14,6 +14,7 @@ import at.hannibal2.skyhanni.features.chat.Translator
import at.hannibal2.skyhanni.features.combat.endernodetracker.EnderNodeTracker
import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostUtil
import at.hannibal2.skyhanni.features.commands.PartyCommands
+import at.hannibal2.skyhanni.features.event.diana.AllBurrowsList
import at.hannibal2.skyhanni.features.event.diana.BurrowWarpHelper
import at.hannibal2.skyhanni.features.event.diana.DianaProfitTracker
import at.hannibal2.skyhanni.features.event.diana.GriffinBurrowHelper
@@ -421,6 +422,14 @@ object Commands {
"readcropmilestonefromclipboard",
"Read crop milestone from clipboard. This helps fixing wrong crop milestone data"
) { GardenCropMilestonesCommunityFix.readDataFromClipboard() }
+ registerCommand(
+ "shcopyfoundburrowlocations",
+ "Copy all ever found burrow locations to clipboard"
+ ) { AllBurrowsList.copyToClipboard() }
+ registerCommand(
+ "shaddfoundburrowlocationsfromclipboard",
+ "Add all ever found burrow locations from clipboard"
+ ) { AllBurrowsList.addFromClipboard() }
}
private fun internalCommands() {
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/AllBurrowsListConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/AllBurrowsListConfig.java
new file mode 100644
index 000000000..3dce0f375
--- /dev/null
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/AllBurrowsListConfig.java
@@ -0,0 +1,18 @@
+package at.hannibal2.skyhanni.config.features.event.diana;
+
+import com.google.gson.annotations.Expose;
+import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean;
+import io.github.moulberry.moulconfig.annotations.ConfigOption;
+
+public class AllBurrowsListConfig {
+
+ @Expose
+ @ConfigOption(name = "Save Found Burrows", desc = "Save the location of every found burrow in a locally stored list.")
+ @ConfigEditorBoolean
+ public boolean save = true;
+
+ @Expose
+ @ConfigOption(name = "Show All Burrows", desc = "Show the list of all ever found burrows in the world.")
+ @ConfigEditorBoolean
+ public boolean showAll = false;
+}
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java
index 4867c0bcd..fb992ab5f 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java
@@ -74,4 +74,9 @@ public class DianaConfig {
@Accordion
// TODO renmae
public MythologicalMobTrackerConfig mythologicalMobtracker = new MythologicalMobTrackerConfig();
+
+ @Expose
+ @ConfigOption(name = "All Burrows List", desc = "")
+ @Accordion
+ public AllBurrowsListConfig allBurrowsList = new AllBurrowsListConfig();
}