Permalink
Browse files

Fixed an issue where the wrong inventory was specified for minecart d…

…epositer
  • Loading branch information...
me4502 committed Sep 23, 2017
1 parent 9baf7bf commit 05e574b8771e5fdb48a3a8d333388580213f71be
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/main/java/com/sk89q/craftbook/mechanics/minecart/blocks/CartDeposit.java
@@ -156,7 +156,7 @@ public void onVehicleImpact(CartBlockImpactEvent event) {
if (inf.a.getData() < 0 || inf.a.getData() == item.getDurability()) {
if(inf.b < 0) {
transferitems.add(item.clone());
cartinventory.remove(item);
containerinventory.remove(item);
} else {
ItemStack stack = item.clone();
if(item.getAmount() > inf.b) {
@@ -168,7 +168,7 @@ public void onVehicleImpact(CartBlockImpactEvent event) {
items.add(new Tuple2<>(inf.a, inf.b - stack.getAmount()));
}
transferitems.add(stack.clone());
cartinventory.removeItem(stack);
containerinventory.removeItem(stack);
}
}
}

0 comments on commit 05e574b

Please sign in to comment.