More refactoring. Adding to bazaar now works for selling and seeking by gil.

This commit is contained in:
Filip Maj 2017-11-11 17:05:07 -05:00
parent bbac4b0fce
commit e8c9904e1d
9 changed files with 109 additions and 75 deletions

View file

@ -61,7 +61,7 @@ namespace FFXIVClassic_Map_Server.Actors
//Inventory
protected Dictionary<ushort, Inventory> itemPackages = new Dictionary<ushort, Inventory>();
private Equipment equipment;
protected Equipment equipment;
public Character(uint actorID) : base(actorID)
{
@ -157,7 +157,7 @@ namespace FFXIVClassic_Map_Server.Actors
{
if (itemPackages.ContainsKey(itemPackage))
{
itemPackages[itemPackage].AddItemSpecial(slot, item);
itemPackages[itemPackage].SetItem(slot, item);
}
}
@ -254,6 +254,14 @@ namespace FFXIVClassic_Map_Server.Actors
return null;
}
public Inventory GetItemPackage(ushort package)
{
if (itemPackages.ContainsKey(package))
return itemPackages[package];
else
return null;
}
public ushort GetPackageForItem(uint catalogID)
{
ItemData data = Server.GetItemGamedata(catalogID);