summaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/config/commands
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/config/commands')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt13
1 files changed, 13 insertions, 0 deletions
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 59b850784..b91bf4252 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt
+++ b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt
@@ -5,6 +5,7 @@ import at.hannibal2.skyhanni.config.ConfigGuiManager
import at.hannibal2.skyhanni.config.commands.SimpleCommand.ProcessCommandRunnable
import at.hannibal2.skyhanni.data.ApiDataLoader
import at.hannibal2.skyhanni.data.GuiEditManager
+import at.hannibal2.skyhanni.data.ProfileStorageData
import at.hannibal2.skyhanni.features.bingo.BingoCardDisplay
import at.hannibal2.skyhanni.features.bingo.BingoNextStepHelper
import at.hannibal2.skyhanni.features.event.diana.BurrowWarpHelper
@@ -86,6 +87,7 @@ object Commands {
registerCommand("shtestcomposter") { ComposterOverlay.onCommand(it) }
registerCommand("shtestinquisitor") { InquisitorWaypointShare.test() }
registerCommand("shshowcropmoneycalculation") { CropMoneyDisplay.toggleShowCalculation() }
+ registerCommand("shstoprepowarnings") { stopRepoWarnings()}
// for developers - coding help
registerCommand("shreloadlocalrepo") { SkyHanniMod.repo.reloadLocalRepo() }
@@ -113,6 +115,17 @@ object Commands {
}
}
+ private fun stopRepoWarnings() {
+ val hidden = ProfileStorageData.playerSpecific?.lastRepoIssueVersion
+ if (hidden == SkyHanniMod.version) {
+ ProfileStorageData.playerSpecific?.lastRepoIssueVersion = ""
+ LorenzUtils.chat("§e[SkyHanni] Re-enabled repo warnings.")
+ } else {
+ ProfileStorageData.playerSpecific?.lastRepoIssueVersion = SkyHanniMod.version
+ LorenzUtils.chat("§e[SkyHanni] Disabled repo warnings until next update.")
+ }
+ }
+
private fun clearFarmingItems() {
val config = GardenAPI.config?.fortune ?: return
LorenzUtils.chat("§e[SkyHanni] clearing farming items")