From 5ae837f1f8a32041739cd1eb1426ed12df8e8cba Mon Sep 17 00:00:00 2001 From: mckuhei Date: Sun, 7 May 2023 01:10:03 +0800 Subject: [PATCH] Add deprecated information. --- src/minecraft/net/minecraft/src/Constants.java | 7 ++++++- src/minecraft/net/minecraft/src/RenderGlobal.java | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/minecraft/net/minecraft/src/Constants.java b/src/minecraft/net/minecraft/src/Constants.java index 6764f33..7e6ec65 100644 --- a/src/minecraft/net/minecraft/src/Constants.java +++ b/src/minecraft/net/minecraft/src/Constants.java @@ -5,11 +5,13 @@ import sun.misc.Unsafe; public class Constants { public static boolean DISABLE_MODULO = false, - USE_64BIT_PERLIN_GENERATOR = false, ENABLE_FRINGE_LAND = false, FLOAT_PERLIN_GENERATOR = false, COMPILE_CHUNK_ASYNC = false; + @Deprecated(/* forRemoval = true */) + public static boolean USE_64BIT_PERLIN_GENERATOR = false; + static { Unsafe unsafe; try { @@ -28,5 +30,8 @@ public class Constants { } catch(Throwable t) { throw new RuntimeException(t); } + if(System.getProperty(cls.getName() + ".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"); + } } } diff --git a/src/minecraft/net/minecraft/src/RenderGlobal.java b/src/minecraft/net/minecraft/src/RenderGlobal.java index 3df24e7..03abf38 100644 --- a/src/minecraft/net/minecraft/src/RenderGlobal.java +++ b/src/minecraft/net/minecraft/src/RenderGlobal.java @@ -1406,7 +1406,7 @@ public class RenderGlobal implements IWorldAccess { if(Constants.COMPILE_CHUNK_ASYNC) { this.worldRenderersToUpdate.set(var9, (Object)null); - if(!var10.addedToQueue) { + if(!var10.addedToQueue && chunksToUpdate.size() <= 100) { chunksToUpdate.add(var10); var10.addedToQueue = true; }