From 425e1a954ca32d8c575ec4e79d0e981c414b34dd Mon Sep 17 00:00:00 2001 From: ceikry Date: Sun, 1 Aug 2021 23:39:20 -0500 Subject: [PATCH] Force rune shop to buy chaos runes at 13ea and death runes at 27ea until formula is corrected --- Server/data/configs/item_configs.json | 2 ++ Server/src/main/java/core/game/content/global/shop/Shop.java | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Server/data/configs/item_configs.json b/Server/data/configs/item_configs.json index 2fc325c31..b8cd15e3d 100644 --- a/Server/data/configs/item_configs.json +++ b/Server/data/configs/item_configs.json @@ -5625,6 +5625,7 @@ "examine": "Used for medium missile spells.", "grand_exchange_price": "320", "durability": null, + "tokkul_price": "270", "name": "Death rune", "tradeable": "true", "low_alchemy": "41", @@ -5651,6 +5652,7 @@ "examine": "Used for small missile spells.", "grand_exchange_price": "140", "durability": null, + "tokkul_price": "135", "name": "Chaos rune", "tradeable": "true", "low_alchemy": "18", diff --git a/Server/src/main/java/core/game/content/global/shop/Shop.java b/Server/src/main/java/core/game/content/global/shop/Shop.java index 080cfca8a..5b44cfc1c 100644 --- a/Server/src/main/java/core/game/content/global/shop/Shop.java +++ b/Server/src/main/java/core/game/content/global/shop/Shop.java @@ -639,7 +639,10 @@ public class Shop { } double mod = (maxMod + minMod) / 2; SystemLogger.logInfo("" + item.getDefinition().getAlchemyValue(highAlch) + " " + mod + " " + item.getAmount()); - int value = (int) (item.getDefinition().getAlchemyValue(highAlch) * mod * item.getAmount()); + int baseValue = item.getDefinition().getAlchemyValue(highAlch); + int value = (int) (baseValue * mod * item.getAmount()); + if(getCurrency() == Items.TOKKUL_6529 && item.getId() == Items.CHAOS_RUNE_562) value = 13; + if(getCurrency() == Items.TOKKUL_6529 && item.getId() == Items.DEATH_RUNE_560) value = 27; if(item.getId() == 12183){ value = 25 * item.getAmount(); }