Fixed crash when configuring an Exporter, fixes #1413

This commit is contained in:
raoulvdberge
2017-08-09 23:44:20 +02:00
parent 1f6f18770a
commit 4d48953e3f
2 changed files with 11 additions and 6 deletions

View File

@@ -2,6 +2,7 @@
### 1.5.16
- Fixed crash when placing a Controller (raoulvdberge)
- Fixed crash when configuring an Exporter (raoulvdberge)
### 1.5.15
- Updated Forge to 2444 (MC 1.12.1) (raoulvdberge)

View File

@@ -150,6 +150,7 @@ public class NetworkNodeExporter extends NetworkNode implements IComparable, ITy
if (took != null && ItemHandlerHelper.insertItem(handler, took, true).isEmpty()) {
took = network.extractItem(slot, 1, compare, false);
if (took != null) {
ItemHandlerHelper.insertItem(handler, took, false);
craftOnlyToExtract[i]--;
@@ -159,6 +160,7 @@ public class NetworkNodeExporter extends NetworkNode implements IComparable, ITy
craftOnlyTask[i] = null;
}
}
}
} else if (!network.getCraftingManager().getTasks().contains(craftOnlyTask[i])) {
craftOnlyTask[i] = null;
}
@@ -188,10 +190,12 @@ public class NetworkNodeExporter extends NetworkNode implements IComparable, ITy
} else if (ItemHandlerHelper.insertItem(handler, took, true).isEmpty()) {
took = network.extractItem(slot, upgrades.getItemInteractCount(), compare, false);
if (took != null) {
ItemHandlerHelper.insertItem(handler, took, false);
}
}
}
}
@Override
public int getCompare() {