diff --git a/src/engine/objects/Contract.java b/src/engine/objects/Contract.java index 076e8525..3132d155 100644 --- a/src/engine/objects/Contract.java +++ b/src/engine/objects/Contract.java @@ -30,7 +30,7 @@ public class Contract extends AbstractGameObject { public int inventorySet = 0; private int vendorID; private boolean isTrainer; - private VendorDialog vendorDialog; + public VendorDialog vendorDialog; private ArrayList npcMenuOptions = new ArrayList<>(); private ArrayList npcModTypeTable = new ArrayList<>(); private ArrayList npcModSuffixTable = new ArrayList<>(); diff --git a/src/engine/server/world/WorldServer.java b/src/engine/server/world/WorldServer.java index f3adfb62..7bdfdc39 100644 --- a/src/engine/server/world/WorldServer.java +++ b/src/engine/server/world/WorldServer.java @@ -647,17 +647,20 @@ public class WorldServer { Logger.error("FAILED TO ADD RUNE MERCHANT"); } try { - NPC resourceMerchant = NPC.createNPC("Resources", 960124, Vector3fImmutable.ZERO, Guild.getGuild(6), ZoneManager.getZoneByUUID(656), (short) 70, null); + + NPC resourceMerchant = NPC.createNPC("Resource Merchant", 960124, Vector3fImmutable.ZERO, Guild.getGuild(6), ZoneManager.getZoneByUUID(656), (short) 70, null); resourceMerchant.sellPercent = 0; + resourceMerchant.contract.vendorDialog = VendorDialog.getVendorDialog(623); Building sdrHut = BuildingManager.getBuilding(27984); resourceMerchant.buildingUUID = sdrHut.getObjectUUID(); resourceMerchant.building = sdrHut; NPCManager.slotCharacterInBuilding(resourceMerchant); resourceMerchant.setLoc(resourceMerchant.bindLoc); - //for(MobEquipment item : resourceMerchant.contract.getSellInventory()){ - // item.magicValue = 10000000; - //} - //resourceMerchant.contract.getSellInventory() + resourceMerchant.contract.getSellInventory().clear(); + for(int resourceID : Warehouse.getMaxResources().keySet()){ + MobEquipment me = new MobEquipment(ItemBase.getItemBase(resourceID), 0, 0); + resourceMerchant.contract.getSellInventory().add(me); + } } catch(Exception e){ Logger.error("FAILED TO ADD RUNE MERCHANT");