diff options
| author | HiZe_ <superhize@hotmail.com> | 2023-07-19 20:57:05 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-19 20:57:05 +0200 |
| commit | 58d20fe9c2f09790b6e7f1865769b3ebc7ad121c (patch) | |
| tree | 908b4129a0391b3b0395cfc31797b6605dbaa285 /src/main/java/at/hannibal2/skyhanni/config | |
| parent | 3eb97a2a74833760c2d1fa4b053eff49d94f12ad (diff) | |
| download | skyhanni-58d20fe9c2f09790b6e7f1865769b3ebc7ad121c.tar.gz skyhanni-58d20fe9c2f09790b6e7f1865769b3ebc7ad121c.tar.bz2 skyhanni-58d20fe9c2f09790b6e7f1865769b3ebc7ad121c.zip | |
Merge pull request #293
* moved formatting stuff into its own class
* started splitting into multiple files
* renamed Formatting file to GhostFormatting
* formatting
* Fixed error when killcombo is over 1000
* save
* added total money made
* fixed detection of bestiary levelup message
* Merge branch 'beta' into ghostcounter_update
* Merge commit 'refs/pull/293/head' of https://github.com/hannibal002/s…
* changed things for money made
* save
* hopefully fixed an error
* Merge branch 'beta' into ghostcounter_update
* fixed error in new command
* fixed error when trying to get combat level
* Merge branch 'hannibal002:beta' into ghostcounter_update
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/config')
3 files changed, 21 insertions, 12 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/Storage.java b/src/main/java/at/hannibal2/skyhanni/config/Storage.java index 21979ffef..a53cb13bc 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/Storage.java +++ b/src/main/java/at/hannibal2/skyhanni/config/Storage.java @@ -7,12 +7,12 @@ import at.hannibal2.skyhanni.features.garden.CropType; import at.hannibal2.skyhanni.features.garden.fortuneguide.FarmingItems; import at.hannibal2.skyhanni.features.garden.visitor.VisitorReward; import at.hannibal2.skyhanni.features.misc.FrozenTreasure; -import at.hannibal2.skyhanni.features.misc.GhostCounter.Option; +import at.hannibal2.skyhanni.features.misc.ghostcounter.GhostCounter; +import at.hannibal2.skyhanni.features.misc.ghostcounter.GhostData; import at.hannibal2.skyhanni.features.rift.area.westvillage.KloonTerminal; import at.hannibal2.skyhanni.utils.LorenzVec; import com.google.gson.annotations.Expose; import net.minecraft.item.ItemStack; - import java.util.*; public class Storage { @@ -219,7 +219,7 @@ public class Storage { public static class GhostCounter { @Expose - public Map<Option, Double> data = new HashMap<>(); + public Map<GhostData.Option, Double> data = new HashMap<>(); @Expose public boolean ctDataImported = false; 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 237b0afe3..e5c46cb00 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt @@ -20,9 +20,9 @@ import at.hannibal2.skyhanni.features.garden.fortuneguide.FFGuideGUI import at.hannibal2.skyhanni.features.minion.MinionFeatures import at.hannibal2.skyhanni.features.misc.CityProjectFeatures import at.hannibal2.skyhanni.features.misc.CollectionCounter -import at.hannibal2.skyhanni.features.misc.GhostCounter import at.hannibal2.skyhanni.features.misc.MarkedPlayerManager import at.hannibal2.skyhanni.features.misc.discordrpc.DiscordRPCManager +import at.hannibal2.skyhanni.features.misc.ghostcounter.GhostUtil import at.hannibal2.skyhanni.features.slayer.SlayerItemProfitTracker import at.hannibal2.skyhanni.test.PacketTest import at.hannibal2.skyhanni.test.SkyHanniTestCommand @@ -126,12 +126,12 @@ object Commands { registerCommand( "shimportghostcounterdata", "Manually importing the ghost counter data from GhostCounterV3" - ) { GhostCounter.importCTGhostCounterData() } + ) { GhostUtil.importCTGhostCounterData() } registerCommand( "shclearfarmingitems", "Clear farming items saved for the Farming Fortune Guide" ) { clearFarmingItems() } - registerCommand("shresetghostcounter", "Resets the ghost counter stats") { GhostCounter.reset() } + registerCommand("shresetghostcounter", "Resets the ghost counter stats") { GhostUtil.reset() } } private fun usersBugFix() { diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/GhostCounter.java b/src/main/java/at/hannibal2/skyhanni/config/features/GhostCounter.java index 84b6e99d3..5b2a91f7b 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/GhostCounter.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/GhostCounter.java @@ -1,6 +1,8 @@ package at.hannibal2.skyhanni.config.features; import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.features.misc.ghostcounter.GhostFormatting; +import at.hannibal2.skyhanni.features.misc.ghostcounter.GhostUtil; import com.google.gson.annotations.Expose; import io.github.moulberry.moulconfig.annotations.*; @@ -40,7 +42,8 @@ public class GhostCounter { " §bXP/h: 810,410", " §bKills/h: 420", " §bETA: 14d", - " §bMoney/h: 13,420,069" + " §bMoney/h: 13,420,069", + " §bMoney made: 14B" } ) public List<Integer> ghostDisplayText = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 9, 10, 11, 12)); @@ -61,15 +64,15 @@ public class GhostCounter { @ConfigOption(name = "Reset Formatting", desc = "Reset formatting to default text.") @ConfigEditorButton(buttonText = "Reset") - public Runnable resetFormatting = at.hannibal2.skyhanni.features.misc.GhostCounter.INSTANCE::resetFormatting; + public Runnable resetFormatting = GhostFormatting.INSTANCE::reset; @ConfigOption(name = "Export Formatting", desc = "Export current formatting to clipboard.") @ConfigEditorButton(buttonText = "Export") - public Runnable exportFormatting = at.hannibal2.skyhanni.features.misc.GhostCounter.INSTANCE::exportFormatting; + public Runnable exportFormatting = GhostFormatting.INSTANCE::export; @ConfigOption(name = "Import Formatting", desc = "Import formatting from clipboard.") @ConfigEditorButton(buttonText = "Import") - public Runnable importFormatting = at.hannibal2.skyhanni.features.misc.GhostCounter.INSTANCE::importFormatting; + public Runnable importFormatting = GhostFormatting.INSTANCE::importFormat; @Expose @ConfigOption(name = "Title", desc = "Title Line.") @@ -294,6 +297,13 @@ public class GhostCounter { "Calculated with your kill per hour and your average magic find.") @ConfigEditorText public String moneyHourFormat = " &6$/h: &b%value%"; + + @Expose + @ConfigOption(name = "Money made", desc = "Calculate the money you made.\nInclude §eSorrow§7, §ePlasma§7, §eVolta§7, §e1M coins drop\n" + + "§eGhostly Boots§7, §eScavenger coins.\n" + + "§cUsing current Sell Offer value.") + @ConfigEditorText + public String moneyMadeFormat = " &6Money made: &b%value%"; } @Expose @@ -325,9 +335,8 @@ public class GhostCounter { @ConfigOption(name = "Reset", desc = "Reset the counter.") @ConfigEditorButton(buttonText = "Reset") - public Runnable resetCounter = at.hannibal2.skyhanni.features.misc.GhostCounter.INSTANCE::reset; + public Runnable resetCounter = GhostUtil.INSTANCE::reset; @Expose public Position position = new Position(50, 50, false, true); - } |
