Furnace and Path models fix

This commit is contained in:
Aleksey 2021-05-27 20:05:34 +03:00
parent e8996b8aa6
commit 2986556c97
3 changed files with 3 additions and 1 deletions

View file

@ -57,6 +57,7 @@ public class BaseFurnaceBlock extends FurnaceBlock implements BlockModelProvider
public @Nullable BlockModel getBlockModel(ResourceLocation blockId, BlockState blockState) {
String blockName = blockId.getPath();
Map<String, String> textures = Maps.newHashMap();
textures.put("%modid%", blockId.getNamespace());
textures.put("%top%", blockName + "_top");
textures.put("%side%", blockName + "_side");
Optional<String> pattern;

View file

@ -68,6 +68,7 @@ public class BasePathBlock extends BaseBlockNotFull {
public @Nullable BlockModel getBlockModel(ResourceLocation resourceLocation, BlockState blockState) {
String name = resourceLocation.getPath();
Map<String, String> textures = Maps.newHashMap();
textures.put("%modid%", resourceLocation.getNamespace());
textures.put("%top%", name + "_top");
textures.put("%side%", name.replace("_path", "") + "_side");
Optional<String> pattern = PatternsHelper.createJson(BasePatterns.BLOCK_PATH, textures);