diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-04-21 00:53:47 +0200 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-04-21 00:53:47 +0200 |
commit | 9dcb17f1d853796620817e036c53a67ae4635125 (patch) | |
tree | 19cc0b7df1a11226a443a3e52e8390036b789ee1 /src/main/java/at | |
parent | 43575ec3781bc617975f853df85294575875cfab (diff) | |
download | skyhanni-9dcb17f1d853796620817e036c53a67ae4635125.tar.gz skyhanni-9dcb17f1d853796620817e036c53a67ae4635125.tar.bz2 skyhanni-9dcb17f1d853796620817e036c53a67ae4635125.zip |
Added option to choose between "buy order" and "instant buy" price for the composter
Diffstat (limited to 'src/main/java/at')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/features/Garden.java | 6 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/garden/composter/ComposterOverlay.kt | 3 |
2 files changed, 8 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Garden.java b/src/main/java/at/hannibal2/skyhanni/config/features/Garden.java index fe3905e4a..d7bae165f 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/Garden.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/Garden.java @@ -790,6 +790,12 @@ public class Garden { public boolean composterOverlay = true; @Expose + @ConfigOption(name = "Overlay Price", desc = "Toggle for bazaar 'buy order' vs 'instant buy' price in composter overlay.") + @ConfigEditorDropdown(values = {"Instant Buy", "Buy Order"}) + @ConfigAccordionId(id = 17) + public int composterOverlayPriceType = 0; + + @Expose public Position composterOverlayOrganicMatterPos = new Position(140, 152, false, true); @Expose diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/composter/ComposterOverlay.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/composter/ComposterOverlay.kt index dc88c14df..10e62c394 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/composter/ComposterOverlay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/composter/ComposterOverlay.kt @@ -386,7 +386,8 @@ class ComposterOverlay { } private fun getPrice(internalName: String): Double { - val price = NEUItems.getPrice(internalName) + val useSellPrice = config.composterOverlayPriceType == 1 + val price = NEUItems.getPrice(internalName, useSellPrice) if (internalName == "BIOFUEL" && price > 20_000) return 20_000.0 return price |