A load of fixes to the power net, should be better, but needs testing

This commit is contained in:
modmuss50 2016-03-20 15:32:22 +00:00
parent 5460f2f9a2
commit 8f3811c9d8
2 changed files with 33 additions and 4 deletions

View file

@ -159,6 +159,9 @@ public abstract class CableMultipart extends Multipart implements INormallyOcclu
public void onNeighborBlockChange(Block block) {
super.onNeighborBlockChange(block);
nearByChange();
if(network != null){
network.buildEndpoint();
}
findAndJoinNetwork(getWorld(), getPos());
}
@ -174,7 +177,7 @@ public abstract class CableMultipart extends Multipart implements INormallyOcclu
}
}
public CableMultipart getPartFromWorld(World world, BlockPos pos, EnumFacing side) {
public static CableMultipart getPartFromWorld(World world, BlockPos pos, EnumFacing side) {
if(world == null || pos == null){
return null;
}