diff options
author | makamys <makamys@outlook.com> | 2022-06-27 17:11:10 +0200 |
---|---|---|
committer | makamys <makamys@outlook.com> | 2022-06-27 18:30:52 +0200 |
commit | 3d0bc63e8bf9d817ccdcb27fdbcde5d995ce9307 (patch) | |
tree | ff2ad545b01b74b782be09ec64bbf47b48582aea /src/main/java/makamys/neodymium/renderer/NeoRenderer.java | |
parent | da152e5a796a0369127ad4fb2b81715a0ec9cbd7 (diff) | |
download | Neodymium-3d0bc63e8bf9d817ccdcb27fdbcde5d995ce9307.tar.gz Neodymium-3d0bc63e8bf9d817ccdcb27fdbcde5d995ce9307.tar.bz2 Neodymium-3d0bc63e8bf9d817ccdcb27fdbcde5d995ce9307.zip |
Fix crash when joining a server
Diffstat (limited to 'src/main/java/makamys/neodymium/renderer/NeoRenderer.java')
-rw-r--r-- | src/main/java/makamys/neodymium/renderer/NeoRenderer.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/main/java/makamys/neodymium/renderer/NeoRenderer.java b/src/main/java/makamys/neodymium/renderer/NeoRenderer.java index c6f72da..413e1a0 100644 --- a/src/main/java/makamys/neodymium/renderer/NeoRenderer.java +++ b/src/main/java/makamys/neodymium/renderer/NeoRenderer.java @@ -185,7 +185,7 @@ public class NeoRenderer { NeoRegion v = kv.getValue(); if(v.shouldDelete()) { - v.destroy(getSaveDir()); + v.destroy(); it.remove(); } else { v.tick(); @@ -488,7 +488,7 @@ public class NeoRenderer { ChunkCoordIntPair key = new ChunkCoordIntPair(Math.floorDiv(chunkX , 32), Math.floorDiv(chunkZ, 32)); NeoRegion region = loadedRegionsMap.get(key); if(region == null) { - region = NeoRegion.load(getSaveDir(), Math.floorDiv(chunkX , 32), Math.floorDiv(chunkZ , 32)); + region = NeoRegion.load(Math.floorDiv(chunkX , 32), Math.floorDiv(chunkZ , 32)); loadedRegionsMap.put(key, region); } return region; @@ -564,10 +564,6 @@ public class NeoRenderer { return text; } - private Path getSaveDir(){ - return Minecraft.getMinecraft().mcDataDir.toPath().resolve("neodymium").resolve(Minecraft.getMinecraft().getIntegratedServer().getFolderName()); - } - private boolean shouldRenderInWorld(World world) { return world != null; } |