Minor patch
Fixed a glitch in inventory when storing items. Fixed leaked test code throwing issues in merchant's buy action.
This commit is contained in:
@@ -139,6 +139,8 @@ public class StorageProcessor {
|
|||||||
c.announce(MaplePacketCreator.enableActions());
|
c.announce(MaplePacketCreator.enableActions());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
item = item.copy(); // thanks Robin Schulz & BHB88 for noticing a inventory glitch when storing items
|
||||||
} finally {
|
} finally {
|
||||||
inv.unlockInventory();
|
inv.unlockInventory();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -238,8 +238,7 @@ public class MapleHiredMerchant extends AbstractMapleMapObject {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean canBuy(MapleClient c, Item newItem) {
|
private static boolean canBuy(MapleClient c, Item newItem) { // thanks xiaokelvin for noticing a leaked test code here
|
||||||
System.out.println(newItem.getPet().getName());
|
|
||||||
return MapleInventoryManipulator.checkSpace(c, newItem.getItemId(), newItem.getQuantity(), newItem.getOwner()) && MapleInventoryManipulator.addFromDrop(c, newItem, false);
|
return MapleInventoryManipulator.checkSpace(c, newItem.getItemId(), newItem.getQuantity(), newItem.getOwner()) && MapleInventoryManipulator.addFromDrop(c, newItem, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user