Fix possible crash when inserting/extracting from slave connected to AE2 storage bus

This commit is contained in:
Justin Aquadro committed 2016-11-15 19:05:49 -05:00
1 parent de2ed53193
commit f4db8d6db3
2 files changed
+5 -3

No files matched your search

+1 -1
View File
@@ -17,7 +17,7 @@ buildscript {
apply plugin: 'forge'
version = "1.7.10-1.10.5"
version = "1.7.10-1.10.6"
group= "com.jaquadro.minecraft.storagedrawers" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
archivesBaseName = "StorageDrawers"
@@ -15,6 +15,8 @@ import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.Constants;
import java.util.ArrayList;
public class TileEntitySlave extends TileEntity implements IDrawerGroup, IPriorityGroup, ISmartGroup, ISidedInventory
{
private BlockCoord controllerCoord;
@@ -261,7 +263,7 @@ public class TileEntitySlave extends TileEntity implements IDrawerGroup, IPriori
public Iterable<Integer> enumerateDrawersForInsertion (ItemStack stack, boolean strict) {
TileEntityController controller = getController();
if (controller == null || !controller.isValidSlave(selfCoord))
return null;
return new ArrayList<Integer>();
return controller.enumerateDrawersForInsertion(stack, strict);
}
@@ -270,7 +272,7 @@ public class TileEntitySlave extends TileEntity implements IDrawerGroup, IPriori
public Iterable<Integer> enumerateDrawersForExtraction (ItemStack stack, boolean strict) {
TileEntityController controller = getController();
if (controller == null || !controller.isValidSlave(selfCoord))
return null;
return new ArrayList<Integer>();
return controller.enumerateDrawersForExtraction(stack, strict);
}