From 399f681abc0bc738e01d659f2a6ae73e5fc64f71 Mon Sep 17 00:00:00 2001 From: syeyoung Date: Tue, 7 Feb 2023 15:25:44 +0900 Subject: - loading and unloading Signed-off-by: syeyoung --- .../main/java/kr/syeyoung/dungeonsguide/mod/DungeonsGuide.java | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'mod/src/main/java/kr/syeyoung/dungeonsguide') diff --git a/mod/src/main/java/kr/syeyoung/dungeonsguide/mod/DungeonsGuide.java b/mod/src/main/java/kr/syeyoung/dungeonsguide/mod/DungeonsGuide.java index f3622b22..303caea8 100755 --- a/mod/src/main/java/kr/syeyoung/dungeonsguide/mod/DungeonsGuide.java +++ b/mod/src/main/java/kr/syeyoung/dungeonsguide/mod/DungeonsGuide.java @@ -381,6 +381,14 @@ public class DungeonsGuide implements DGInterface { ReflectionHelper.setPrivateValue(ThreadDownloadImageData.class,(ThreadDownloadImageData) value, null, "imageBuffer", "field_110563_c", "k"); } } + Set toRemove = new HashSet<>(); + for (Map.Entry resourceLocationITextureObjectEntry : mapTextureObjects.entrySet()) { + if (resourceLocationITextureObjectEntry.getKey().getResourceDomain().equalsIgnoreCase("dungeonsguide")) + toRemove.add(resourceLocationITextureObjectEntry.getKey()); + } + for (ResourceLocation resourceLocation : toRemove) { + ITextureObject textureObject = mapTextureObjects.remove(resourceLocation); + } -- cgit