mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-25 14:34:22 +00:00
Fix 32-bit crapness in TankLayerScan.
This commit is contained in:
1 parent
a3a8ba0158
commit
1b2dda8316
1 file changed
+3
-1
@@ -10,6 +10,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagIntArray;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import scala.compat.Platform$;
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.library.util.CoordTuple;
|
||||
import tconstruct.library.util.CoordTupleSort;
|
||||
@@ -37,7 +38,7 @@ public class TankLayerScan extends LogicComponent
|
||||
protected CoordTuple returnStone;
|
||||
|
||||
private static boolean debug = false;
|
||||
private static final int MAX_LAYER_RECURSION_DEPTH = 3500;
|
||||
private static int MAX_LAYER_RECURSION_DEPTH = System.getProperty("os.arch").equals("amd64") ? 4000 : 2000; // Recursion causes overflows on 32-bit, so reduce if not 64-bit
|
||||
|
||||
public TankLayerScan(TileEntity te, Block... ids)
|
||||
{
|
||||
@@ -50,6 +51,7 @@ public class TankLayerScan extends LogicComponent
|
||||
validAirCoords.add(new int[] { -1, 0 });
|
||||
validAirCoords.add(new int[] { 0, 1 });
|
||||
validAirCoords.add(new int[] { 0, -1 });
|
||||
//TConstruct.logger.info("Using recursion size " + MAX_LAYER_RECURSION_DEPTH + " on JVM arch " + System.getProperty("os.arch"));
|
||||
}
|
||||
|
||||
public void checkValidStructure ()
|
||||
|
||||
Reference in new issue
Block a user