From 8df8ed4a02819d6d90db0ac69a69dc21d1eb91d1 Mon Sep 17 00:00:00 2001 From: James Seibel Date: Sun, 13 Aug 2023 13:36:47 -0500 Subject: [PATCH] Request a garbage collection after closing the DH world --- .../seibel/distanthorizons/core/api/internal/SharedApi.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/src/main/java/com/seibel/distanthorizons/core/api/internal/SharedApi.java b/core/src/main/java/com/seibel/distanthorizons/core/api/internal/SharedApi.java index a5b785e4e..e00111b6d 100644 --- a/core/src/main/java/com/seibel/distanthorizons/core/api/internal/SharedApi.java +++ b/core/src/main/java/com/seibel/distanthorizons/core/api/internal/SharedApi.java @@ -46,6 +46,9 @@ public class SharedApi ColumnRenderBufferBuilder.shutdownExecutorService(); WorldGenerationQueue.shutdownWorldGenThreadPool(); ChunkToLodBuilder.shutdownExecutorService(); + + // recommend that the garbage collector cleans up any objects from the old world + System.gc(); } }