Fixed packets being sent client side, attempted to fix a multiblock connection issue with turbines

This commit is contained in:
Robert S 2014-06-09 08:37:32 -04:00
parent 6c67feb482
commit bd6aa3453e
2 changed files with 7 additions and 4 deletions

View file

@ -56,10 +56,13 @@ public abstract class TileMechanical extends TileBase implements INodeProvider,
{ {
super.updateEntity(); super.updateEntity();
mechanicalNode.update(); mechanicalNode.update();
if (mechanicalNode.markRotationUpdate && ticks % 10 == 0) if (!this.getWorldObj().isRemote)
{ {
sendRotationPacket(); if (mechanicalNode.markRotationUpdate && ticks % 10 == 0)
mechanicalNode.markRotationUpdate = false; {
sendRotationPacket();
mechanicalNode.markRotationUpdate = false;
}
} }
} }

View file

@ -22,7 +22,7 @@ public class TurbineNode extends MechanicalNode
@Override @Override
public boolean canConnect(ForgeDirection from, Object source) public boolean canConnect(ForgeDirection from, Object source)
{ {
return source instanceof MechanicalNode && !(source instanceof TurbineNode) && from == turbine().getDirection().getOpposite(); return turbine().getMultiBlock().isPrimary() && source instanceof MechanicalNode && !(source instanceof TurbineNode) && from == turbine().getDirection().getOpposite();
} }
@Override @Override