From b70505e7fbfedf8cc01b947e16de50d53dfee7d9 Mon Sep 17 00:00:00 2001 From: Juuz <6596629+Juuxel@users.noreply.github.com> Date: Fri, 25 Oct 2024 21:56:15 +0300 Subject: [PATCH] Fix block item translation keys --- common/src/main/java/juuxel/adorn/item/AdornItems.java | 2 +- .../java/juuxel/adorn/lib/registry/RegistryHelper.java | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/common/src/main/java/juuxel/adorn/item/AdornItems.java b/common/src/main/java/juuxel/adorn/item/AdornItems.java index 7b74246d2..bf99b71c6 100644 --- a/common/src/main/java/juuxel/adorn/item/AdornItems.java +++ b/common/src/main/java/juuxel/adorn/item/AdornItems.java @@ -53,7 +53,7 @@ public final class AdornItems { AdornBlocks.STONE_TORCH_GROUND.get(), AdornBlocks.STONE_TORCH_WALL.get(), Direction.DOWN, - new Item.Settings().registryKey(key) + new Item.Settings().registryKey(key).useBlockPrefixedTranslationKey() )); public static final Registered GUIDE_BOOK = register("guide_book", diff --git a/common/src/main/java/juuxel/adorn/lib/registry/RegistryHelper.java b/common/src/main/java/juuxel/adorn/lib/registry/RegistryHelper.java index 8f6a5b7fb..5f1ed93fd 100644 --- a/common/src/main/java/juuxel/adorn/lib/registry/RegistryHelper.java +++ b/common/src/main/java/juuxel/adorn/lib/registry/RegistryHelper.java @@ -64,7 +64,12 @@ public Registered registerBlock( BlockSettingsProvider settings ) { var registered = registerBlockWithoutItem(name, block, settings); - items.register(name, key -> itemProvider.apply(registered.get(), itemSettings.createItemSettings().registryKey(key))); + items.register(name, key -> itemProvider.apply( + registered.get(), + itemSettings.createItemSettings() + .registryKey(key) + .useBlockPrefixedTranslationKey() + )); return registered; }