Merge branch 'gate-triggers-plugs' of https://github.com/Prototik/BuildCraft into Prototik-gate-triggers-plugs

This commit is contained in:
SpaceToad 2014-05-05 14:37:51 +02:00
commit f02dda793d
2 changed files with 7 additions and 5 deletions

View file

@ -322,7 +322,7 @@ public final class Gate {
if (trigger instanceof ITileTrigger) {
for (ForgeDirection o : ForgeDirection.VALID_DIRECTIONS) {
TileEntity tile = pipe.container.getTile(o);
if (tile != null && !(tile instanceof TileGenericPipe)) {
if (tile != null && !(tile instanceof TileGenericPipe) && pipe.hasGate(o)) {
if (((ITileTrigger) trigger).isTriggerActive(o.getOpposite(), tile, parameter)) {
return true;
}

View file

@ -95,10 +95,12 @@ public class ContainerGateInterface extends BuildCraftContainer {
}
for (ForgeDirection o : ForgeDirection.VALID_DIRECTIONS) {
TileEntity tile = pipe.container.getTile(o);
Block block = pipe.container.getBlock(o);
potentialTriggers.addAll(ActionManager.getNeighborTriggers(block, tile));
potentialActions.addAll(ActionManager.getNeighborActions(block, tile));
if (pipe.hasGate(o)) {
TileEntity tile = pipe.container.getTile(o);
Block block = pipe.container.getBlock(o);
potentialTriggers.addAll(ActionManager.getNeighborTriggers(block, tile));
potentialActions.addAll(ActionManager.getNeighborActions(block, tile));
}
}
if (!pipe.gate.material.hasParameterSlot) {