From 952ec69f2231e6ef535b0db33f346e01efa660ad Mon Sep 17 00:00:00 2001 From: Craig Date: Tue, 19 Dec 2023 13:08:21 +0000 Subject: [PATCH] Made ShellPatterns more accessible --- .../tardis_refined/patterns/ShellPatterns.java | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/common/src/main/java/whocraft/tardis_refined/patterns/ShellPatterns.java b/common/src/main/java/whocraft/tardis_refined/patterns/ShellPatterns.java index 3f32838d7..f791a55ef 100644 --- a/common/src/main/java/whocraft/tardis_refined/patterns/ShellPatterns.java +++ b/common/src/main/java/whocraft/tardis_refined/patterns/ShellPatterns.java @@ -103,7 +103,7 @@ public static ShellPattern next(List patterns, ShellPattern curren *
Also assigns the {@link ShellPattern} its parent {@link ShellTheme}'s ID * @implSpec INTERNAL USE ONLY * */ - private static ShellPattern addDefaultPattern(ResourceLocation themeId, ShellPattern datagenPattern) { + public static ShellPattern addDefaultPattern(ResourceLocation themeId, ShellPattern datagenPattern) { List patternList; ShellPattern pattern = (ShellPattern) datagenPattern.setThemeId(themeId); if (DEFAULT_PATTERNS.containsKey(themeId)) { @@ -121,17 +121,25 @@ private static ShellPattern addDefaultPattern(ResourceLocation themeId, ShellPat return pattern; } - private static ShellPattern addDefaultPattern(ResourceLocation themeId, String patternName, boolean hasEmissiveTexture) { + public static ShellPattern addDefaultPattern(ResourceLocation themeId, String patternName, boolean hasEmissiveTexture) { ShellPattern pattern = (ShellPattern) new ShellPattern(patternName, new PatternTexture(exteriorTextureLocation(themeId, patternName), hasEmissiveTexture) , new PatternTexture(interiorTextureLocation(themeId, patternName), hasEmissiveTexture)).setThemeId(themeId); return addDefaultPattern(themeId, pattern); } - private static ResourceLocation exteriorTextureLocation(ResourceLocation themeId, String textureName){ + public static ResourceLocation exteriorTextureLocation(ResourceLocation themeId, String textureName){ return new ResourceLocation(TardisRefined.MODID, "textures/blockentity/shell/" + themeId.getPath() + "/" + textureName + ".png"); } - private static ResourceLocation interiorTextureLocation(ResourceLocation themeId, String textureName){ + public static ResourceLocation exteriorTextureLocation(ResourceLocation themeId, String modid, String textureName){ + return new ResourceLocation(modid, "textures/blockentity/shell/" + themeId.getPath() + "/" + textureName + ".png"); + } + + public static ResourceLocation interiorTextureLocation(ResourceLocation themeId, String modid, String textureName){ + return new ResourceLocation(modid, "textures/blockentity/shell/" + themeId.getPath() + "/" + textureName + "_interior.png"); + } + + public static ResourceLocation interiorTextureLocation(ResourceLocation themeId, String textureName){ return new ResourceLocation(TardisRefined.MODID, "textures/blockentity/shell/" + themeId.getPath() + "/" + textureName + "_interior.png"); }