mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-17 10:55:17 +00:00
Fix incorrect corporea result message. Closes #2424
This commit is contained in:
1 parent
21a5f20018
commit
3d01311604
2 files changed
+7
-3
No files matched your search
@@ -23,8 +23,8 @@ public class WrappedIInventory extends WrappedInventoryBase{
|
||||
private final InvWithLocation inv;
|
||||
|
||||
private WrappedIInventory(InvWithLocation inv, ICorporeaSpark spark) {
|
||||
super(spark);
|
||||
this.inv = inv;
|
||||
this.spark = spark;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -51,6 +51,7 @@ public class WrappedIInventory extends WrappedInventoryBase{
|
||||
// IWrappedInventory - keep it synch
|
||||
if(isMatchingItemStack(request.matcher, request.checkNBT, stackAt)) {
|
||||
int rem = Math.min(stackAt.getCount(), request.count == -1 ? stackAt.getCount() : request.count);
|
||||
request.foundItems += stackAt.getCount();
|
||||
|
||||
if(rem > 0) {
|
||||
stacks.add(inv.handler.extractItem(i, rem, !doit));
|
||||
@@ -58,7 +59,6 @@ public class WrappedIInventory extends WrappedInventoryBase{
|
||||
spark.onItemExtracted(stackAt);
|
||||
}
|
||||
|
||||
request.foundItems += stackAt.getCount();
|
||||
request.extractedItems += rem;
|
||||
|
||||
if(request.count != -1)
|
||||
|
||||
@@ -20,7 +20,11 @@ import java.util.List;
|
||||
|
||||
public abstract class WrappedInventoryBase implements IWrappedInventory {
|
||||
|
||||
protected ICorporeaSpark spark;
|
||||
protected final ICorporeaSpark spark;
|
||||
|
||||
public WrappedInventoryBase(ICorporeaSpark spark) {
|
||||
this.spark = spark;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ICorporeaSpark getSpark() {
|
||||
|
||||
Reference in new issue
Block a user