Browse Source

resource merchant work

lakebane-master
FatBoy-DOTC 9 months ago
parent
commit
8c022596a7
  1. 20
      src/engine/server/world/WorldServer.java

20
src/engine/server/world/WorldServer.java

@ -657,19 +657,19 @@ public class WorldServer {
resourceMerchant.building = sdrHut; resourceMerchant.building = sdrHut;
NPCManager.slotCharacterInBuilding(resourceMerchant); NPCManager.slotCharacterInBuilding(resourceMerchant);
resourceMerchant.setLoc(resourceMerchant.bindLoc); resourceMerchant.setLoc(resourceMerchant.bindLoc);
resourceMerchant.contract.getSellInventory().clear(); //resourceMerchant.contract.getSellInventory().clear();
for(int resourceID : Warehouse.getMaxResources().keySet()) { //for(int resourceID : Warehouse.getMaxResources().keySet()) {
if (resourceID == 7 || resourceID == 1580021) // if (resourceID == 7 || resourceID == 1580021)
continue; // continue;
//MobLoot resource = new MobLoot(resourceMerchant, ItemBase.getItemBase(resourceID), 1, true); //MobLoot resource = new MobLoot(resourceMerchant, ItemBase.getItemBase(resourceID), 1, true);
//resource.setValue(Warehouse.getCostForResource(resourceID)); //resource.setValue(Warehouse.getCostForResource(resourceID));
//resourceMerchant.getCharItemManager().addItemToInventory(resource); //resourceMerchant.getCharItemManager().addItemToInventory(resource);
MobEquipment resource = new MobEquipment(ItemBase.getItemBase(resourceID),0,0); // MobEquipment resource = new MobEquipment(ItemBase.getItemBase(resourceID),0,0);
resourceMerchant.contract.getSellInventory().add(resource); // resourceMerchant.contract.getSellInventory().add(resource);
} //}
for (MobEquipment item : resourceMerchant.contract.getSellInventory()) { //for (MobEquipment item : resourceMerchant.contract.getSellInventory()) {
item.magicValue = Warehouse.getCostForResource(item.getItemBase().getUUID()); // item.magicValue = Warehouse.getCostForResource(item.getItemBase().getUUID());
} //}
} }
} }
catch(Exception e){ catch(Exception e){

Loading…
Cancel
Save