mirror of
https://github.com/2006-Scape/2006Scape.git
synced 2026-07-02 16:49:03 +00:00
Recalculate Weight When Buying/Selling Items (#632)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.rs2.game.shops;
|
||||
|
||||
import com.rs2.Constants;
|
||||
import com.rs2.game.items.Weight;
|
||||
import org.apollo.cache.def.ItemDefinition;
|
||||
|
||||
import com.rs2.game.bots.BotHandler;
|
||||
@@ -450,6 +451,7 @@ public class ShopAssistant {
|
||||
// Add item to the shop
|
||||
addShopItem(unNotedItemID, amount);
|
||||
player.getItemAssistant().resetItems(3823);
|
||||
Weight.updateWeight(player);
|
||||
resetShop(player.shopId);
|
||||
updatePlayerShop();
|
||||
return true;
|
||||
@@ -611,6 +613,7 @@ public class ShopAssistant {
|
||||
GameLogger.writeLog(player.playerName, "shopbuying", player.playerName + " bought " + amount + " " + itemName + " for " + totalValue + " " + currencyName + " from store " + shopID + ".");
|
||||
}
|
||||
player.getItemAssistant().resetItems(3823);
|
||||
Weight.updateWeight(player);
|
||||
resetShop(player.shopId);
|
||||
updatePlayerShop();
|
||||
return true; //return TRUE / FALSE Update = shop&Inventory / Doesnt Update
|
||||
|
||||
Reference in New Issue
Block a user