Compare commits

...

2 Commits
test ... master

@ -7,7 +7,8 @@ public class Constants {
public static boolean DISABLE_MODULO = false, public static boolean DISABLE_MODULO = false,
ENABLE_FRINGE_LAND = false, ENABLE_FRINGE_LAND = false,
FLOAT_PERLIN_GENERATOR = false, FLOAT_PERLIN_GENERATOR = false,
COMPILE_CHUNK_ASYNC = false; COMPILE_CHUNK_ASYNC = false,
DISABLE_ENTITY_UPDATE = false;
@Deprecated(/* forRemoval = true */) @Deprecated(/* forRemoval = true */)
public static boolean USE_64BIT_PERLIN_GENERATOR = false; public static boolean USE_64BIT_PERLIN_GENERATOR = false;
@ -25,12 +26,12 @@ public class Constants {
try { try {
for(Field f : cls.getDeclaredFields()) { for(Field f : cls.getDeclaredFields()) {
// unsafe.putBoolean(cls, unsafe.fieldOffset(f), Boolean.getBoolean(cls.getName() + "." + f.getName())); // unsafe.putBoolean(cls, unsafe.fieldOffset(f), Boolean.getBoolean(cls.getName() + "." + f.getName()));
f.setBoolean(null, Boolean.getBoolean(cls.getName() + "." + f.getName())); f.setBoolean(null, Boolean.getBoolean("net.minecraft.src.Constants." + f.getName()));
} }
} catch(Throwable t) { } catch(Throwable t) {
throw new RuntimeException(t); throw new RuntimeException(t);
} }
if(System.getProperty(cls.getName() + ".USE_64BIT_PERLIN_GENERATOR") != null) { if(System.getProperty("net.minecraft.src.Constants.USE_64BIT_PERLIN_GENERATOR") != null) {
System.err.println("USE_64BIT_PERLIN_GENERATOR is deprecated and will remove in future, Please consider use -Dnet.minecraft.src.NoiseGeneratorOctaves.noiseType=" + (USE_64BIT_PERLIN_GENERATOR ? "long" : "int") + "Type"); System.err.println("USE_64BIT_PERLIN_GENERATOR is deprecated and will remove in future, Please consider use -Dnet.minecraft.src.NoiseGeneratorOctaves.noiseType=" + (USE_64BIT_PERLIN_GENERATOR ? "long" : "int") + "Type");
} }
} }

@ -3,6 +3,8 @@ package net.minecraft.src;
public abstract class NoiseGenerator public abstract class NoiseGenerator
{ {
public void populateNoiseArray(double[] par1ArrayOfDouble, double par2, double par4, double par6, int par8, int par9, int par10, double par11, double par13, double par15, double par17) { public void populateNoiseArray(double[] par1ArrayOfDouble, double par2, double par4, double par6, int par8, int par9, int par10, double par11, double par13, double par15, double par17) {
if (this instanceof NoiseGeneratorPerlin) {
((NoiseGeneratorPerlin) this).populateNoiseArray(par1ArrayOfDouble, par2, par4, par6, par8, par9, par10, par11, par13, par15, par17);
} else throw new Error("Fucked by MCP™");
} }
} }

@ -295,8 +295,9 @@ public abstract class World implements IBlockAccess
*/ */
public boolean doChunksNearChunkExist(BigInteger par1, int par2, BigInteger par3, int par4) public boolean doChunksNearChunkExist(BigInteger par1, int par2, BigInteger par3, int par4)
{ {
return true; // return true;
// return this.checkChunksExist(par1 - par4, par2 - par4, par3 - par4, par1 + par4, par2 + par4, par3 + par4); BigInteger dist = BigInteger.valueOf(par4);
return this.checkChunksExist(par1.subtract(par3), par2 - par4, par3.subtract(dist), par1.add(dist), par2 + par4, par3.add(dist));
} }
/** /**
@ -1759,6 +1760,7 @@ public abstract class World implements IBlockAccess
for (var1 = 0; var1 < this.loadedEntityList.size(); ++var1) for (var1 = 0; var1 < this.loadedEntityList.size(); ++var1)
{ {
var2 = (Entity)this.loadedEntityList.get(var1); var2 = (Entity)this.loadedEntityList.get(var1);
if (!(var2 instanceof EntityPlayer) && Constants.DISABLE_ENTITY_UPDATE) continue;
if (var2.ridingEntity != null) if (var2.ridingEntity != null)
{ {

Loading…
Cancel
Save