9
0
mirror of https://github.com/BX-Team/DivineMC.git synced 2025-12-22 16:29:23 +00:00

rename chunk algorithms

This commit is contained in:
NONPLAYT
2025-03-03 19:39:45 +03:00
parent 0b19b8f13d
commit fc0922d105
2 changed files with 7 additions and 3 deletions

View File

@@ -170,7 +170,7 @@ public class DivineConfig {
public static long chunkDataCacheSoftLimit = 8192L; public static long chunkDataCacheSoftLimit = 8192L;
public static long chunkDataCacheLimit = 32678L; public static long chunkDataCacheLimit = 32678L;
public static int maxViewDistance = 32; public static int maxViewDistance = 32;
public static ChunkSystemAlgorithms chunkWorkerAlgorithm = ChunkSystemAlgorithms.C2ME; public static ChunkSystemAlgorithms chunkWorkerAlgorithm = ChunkSystemAlgorithms.MOONRISE;
public static int threadPoolPriority = Thread.NORM_PRIORITY + 1; public static int threadPoolPriority = Thread.NORM_PRIORITY + 1;
public static boolean enableSecureSeed = false; public static boolean enableSecureSeed = false;
public static boolean smoothBedrockLayer = false; public static boolean smoothBedrockLayer = false;
@@ -197,7 +197,11 @@ public class DivineConfig {
"Changes the maximum view distance for the server, allowing clients to have render distances higher than 32"); "Changes the maximum view distance for the server, allowing clients to have render distances higher than 32");
chunkWorkerAlgorithm = ChunkSystemAlgorithms.valueOf(getString("settings.chunk-generation.chunk-worker-algorithm", chunkWorkerAlgorithm.name(), chunkWorkerAlgorithm = ChunkSystemAlgorithms.valueOf(getString("settings.chunk-generation.chunk-worker-algorithm", chunkWorkerAlgorithm.name(),
"Modifies what algorithm the chunk system will use to define thread counts. values: MOONRISE, C2ME, C2ME_AGGRESSIVE")); "Modifies what algorithm the chunk system will use to define thread counts.",
"Valid values:",
" - MOONRISE: Default algorithm, used by default in Paper",
" - C2ME: Algorithm used by C2ME (old)",
" - C2ME_NEW: Modern algorithm used by C2ME"));
threadPoolPriority = getInt("settings.chunk-generation.thread-pool-priority", threadPoolPriority, threadPoolPriority = getInt("settings.chunk-generation.thread-pool-priority", threadPoolPriority,
"Sets the priority of the thread pool used for chunk generation"); "Sets the priority of the thread pool used for chunk generation");

View File

@@ -26,7 +26,7 @@ public enum ChunkSystemAlgorithms {
final int ioThreads = Math.max(1, configIoThreads); final int ioThreads = Math.max(1, configIoThreads);
return new Pair<>(workerThreads, ioThreads); return new Pair<>(workerThreads, ioThreads);
}), }),
C2ME_AGGRESSIVE((configWorkerThreads, configIoThreads) -> { C2ME_NEW((configWorkerThreads, configIoThreads) -> {
String expression = """ String expression = """
max( max(