Fixed a bug where Buy shop signs would display how much there was to

sell as the amount, instead of how much space is available.
This commit is contained in:
sigonasr2 2016-07-31 20:53:24 -05:00
parent febc66b16a
commit e8b6d1c109
2 changed files with 1 additions and 1 deletions

Binary file not shown.

View File

@ -2400,7 +2400,7 @@ public class TwosideKeeper extends JavaPlugin implements Listener {
int shopID = TwosideShops.GetShopID(s);
WorldShop shop = TwosideShops.LoadWorldShopData(shopID);
Chest c = (Chest)chest.getState();
shop.UpdateAmount(GenericFunctions.CountItems(c.getInventory(), shop.GetItem()));
shop.UpdateAmount(GenericFunctions.CountEmptySpace(c.getInventory(), shop.GetItem()));
TwosideShops.UpdateSign(shop, shop.getID(),s,shop.isPurchaseShopSign(s));
TwosideShops.SaveWorldShopData(shop);
Location newloc = ev.getClickedBlock().getLocation().add(-ev.getBlockFace().getModX()+0.5, -ev.getBlockFace().getModY()+1.5, -ev.getBlockFace().getModZ()+0.5);