aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal002@users.noreply.github.com>2024-10-09 00:43:16 +0200
committerGitHub <noreply@github.com>2024-10-09 09:43:16 +1100
commit9beb1bb5876d0f3203606e59b16225fbee40e652 (patch)
treea924be23c54baba23e3a8fcddbf7310d67b7e00a /src/main/java/at/hannibal2/skyhanni/features
parent5e71dc9572870b7dc7ab4358ee61718bec014ae1 (diff)
downloadskyhanni-9beb1bb5876d0f3203606e59b16225fbee40e652.tar.gz
skyhanni-9beb1bb5876d0f3203606e59b16225fbee40e652.tar.bz2
skyhanni-9beb1bb5876d0f3203606e59b16225fbee40e652.zip
Improvement: Pocket Sack-in-a-Sack in Estimated Item Value (#2698)
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValueCalculator.kt11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValueCalculator.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValueCalculator.kt
index e2efab05b..5797c50cd 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValueCalculator.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValueCalculator.kt
@@ -29,6 +29,7 @@ import at.hannibal2.skyhanni.utils.NumberUtil.shortFormat
import at.hannibal2.skyhanni.utils.PrimitiveIngredient
import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils
import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils.getAbilityScrolls
+import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils.getAppliedPocketSackInASack
import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils.getArmorDye
import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils.getAttributes
import at.hannibal2.skyhanni.utils.SkyBlockItemModifierUtils.getBookwormBookCount
@@ -98,6 +99,7 @@ object EstimatedItemValueCalculator {
::addManaDisintegrators,
::addPolarvoidBook,
::addBookwormBook,
+ ::addPocketSackInASack,
// cosmetic
::addHelmetSkin,
@@ -393,6 +395,15 @@ object EstimatedItemValueCalculator {
return price
}
+ private fun addPocketSackInASack(stack: ItemStack, list: MutableList<String>): Double {
+ val count = stack.getAppliedPocketSackInASack() ?: return 0.0
+
+ val pocketSackInASack = "POCKET_SACK_IN_A_SACK".asInternalName()
+ val price = pocketSackInASack.getPrice() * count
+ list.add("§7Pocket Sack-in-a-Sack: §e$count§7/§e3 §7(§6" + price.shortFormat() + "§7)")
+ return price
+ }
+
private fun addBookwormBook(stack: ItemStack, list: MutableList<String>): Double {
val count = stack.getBookwormBookCount() ?: return 0.0