mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-22 04:52:25 +00:00
Prevent race condition causing #4487 & add sanity check for the only other place the fields are updated.
This commit is contained in:
1 parent
c1e0cf8288
commit
2c4c997e02
1 file changed
+9
-2
@@ -62,8 +62,8 @@ public class BlockTransmitter extends Block implements ITileEntityProvider
|
||||
public static AxisAlignedBB[] smallSides = new AxisAlignedBB[7];
|
||||
public static AxisAlignedBB[] largeSides = new AxisAlignedBB[7];
|
||||
|
||||
public static AxisAlignedBB smallDefault = smallSides[6];
|
||||
public static AxisAlignedBB largeDefault = largeSides[6];
|
||||
public static AxisAlignedBB smallDefault;
|
||||
public static AxisAlignedBB largeDefault;
|
||||
|
||||
static
|
||||
{
|
||||
@@ -82,6 +82,9 @@ public class BlockTransmitter extends Block implements ITileEntityProvider
|
||||
largeSides[4] = new AxisAlignedBB(0.0, 0.25, 0.25, 0.25, 0.75, 0.75);
|
||||
largeSides[5] = new AxisAlignedBB(0.75, 0.25, 0.25, 1.0, 0.75, 0.75);
|
||||
largeSides[6] = new AxisAlignedBB(0.25, 0.25, 0.25, 0.75, 0.75, 0.75);
|
||||
|
||||
smallDefault = smallSides[6];
|
||||
largeDefault = largeSides[6];
|
||||
}
|
||||
|
||||
public BlockTransmitter()
|
||||
@@ -400,6 +403,10 @@ public class BlockTransmitter extends Block implements ITileEntityProvider
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (box == null){
|
||||
throw new IllegalStateException("box should not be null");
|
||||
}
|
||||
|
||||
if(tile.getTransmitterType().getSize() == Size.SMALL)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user