Fix broken check

This commit is contained in:
Raoul Van den Berge
2016-09-20 15:55:43 +02:00
parent d7502df445
commit d3d3381620

View File

@@ -132,15 +132,17 @@ public class CraftingTaskProcessing extends CraftingTask {
}
private boolean isTileInUse(ICraftingTask task) {
if (task != this && task instanceof CraftingTaskProcessing) {
if (task != this) {
if (task.getChild() != null) {
return isTileInUse(task.getChild());
}
CraftingTaskProcessing other = (CraftingTaskProcessing) task;
if (task instanceof CraftingTaskProcessing) {
CraftingTaskProcessing other = (CraftingTaskProcessing) task;
if (other.tileInUse != null && other.tileInUse.equals(pattern.getContainer().getFacingTile().getPos()) && !other.pattern.equals(pattern)) {
return true;
if (other.tileInUse != null && other.tileInUse.equals(pattern.getContainer().getFacingTile().getPos()) && !other.pattern.equals(pattern)) {
return true;
}
}
}