Registry helpers help you register things.
Usually, you would create a new RegistryHelper<T> by passing in a Registry<T> and your mod id, or you could use one of the specialized classes (ItemRegistryHelper, BlockRegistryHelper, etc.).
Example Usage
TODO
Items
java
public static final ItemRegistryHelper REGISTRY = new ItemRegistryHelper(ExampleMod.MODID);
public static final ResourceKey<Item> TEST_ITEM_ID = REGISTRY.createId("test_item");
public static final ResourceKey<Item> TEST_SHOVEL_ITEM_ID = REGISTRY.createId("test_shovel_item");
public static final Item TEST_ITEM = REGISTRY.addItem(TEST_ITEM_ID, new Item.Properties());
public static final Item TEST_SHOVEL_ITEM = REGISTRY.addItem(TEST_SHOVEL_ITEM_ID, p -> new ShovelItem(ToolMaterial.NETHERITE, 100, 100, p), new Item.Properties().fireResistant());
public static void register() {
REGISTRY.register();
}1
2
3
4
5
6
7
8
9
10
11
2
3
4
5
6
7
8
9
10
11
Blocks
TODO