From c86fafe811f7471dd08cc2174549f9ab9b8ded7a Mon Sep 17 00:00:00 2001 From: TheMode Date: Fri, 30 Apr 2021 23:15:34 +0200 Subject: [PATCH] Demo server cleanup --- src/test/java/demo/PlayerInit.java | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/test/java/demo/PlayerInit.java b/src/test/java/demo/PlayerInit.java index 34984b591..6ac680612 100644 --- a/src/test/java/demo/PlayerInit.java +++ b/src/test/java/demo/PlayerInit.java @@ -55,11 +55,9 @@ public class PlayerInit { ChunkGeneratorDemo chunkGeneratorDemo = new ChunkGeneratorDemo(); NoiseTestGenerator noiseTestGenerator = new NoiseTestGenerator(); - for (int i = 0; i < 4; i++) { - InstanceContainer instanceContainer = instanceManager.createInstanceContainer(DimensionType.OVERWORLD); - instanceContainer.enableAutoChunkLoad(true); - instanceContainer.setChunkGenerator(chunkGeneratorDemo); - } + InstanceContainer instanceContainer = instanceManager.createInstanceContainer(DimensionType.OVERWORLD); + instanceContainer.enableAutoChunkLoad(true); + instanceContainer.setChunkGenerator(chunkGeneratorDemo); inventory = new Inventory(InventoryType.CHEST_1_ROW, Component.text("Test inventory")); /*inventory.addInventoryCondition((p, slot, clickType, inventoryConditionResult) -> { @@ -293,7 +291,7 @@ public class PlayerInit { // Unload the chunk (save memory) if it has no remaining viewer if (chunk.getViewers().isEmpty()) { - player.getInstance().unloadChunk(chunk); + //player.getInstance().unloadChunk(chunk); } }); }