Class NeoForgeRegister.Blocks
java.lang.Object
net.xun.lib.common.api.registries.Register<net.minecraft.world.level.block.Block>
net.xun.lib.common.api.registries.Register.Blocks
net.xun.lib.neoforge.api.registries.NeoForgeRegister.Blocks
- All Implemented Interfaces:
Iterable<net.minecraft.world.level.block.Block>
- Enclosing class:
NeoForgeRegister<T>
-
Nested Class Summary
Nested classes/interfaces inherited from class net.xun.lib.common.api.registries.Register
Register.Blocks, Register.Items -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidregister()Performs final registration by binding all holders to the actual registry.<B extends net.minecraft.world.level.block.Block>
RegistryBlock<B> Registers a new block.Methods inherited from class net.xun.lib.common.api.registries.Register.Blocks
bind, createHolderMethods inherited from class net.xun.lib.common.api.registries.Register
create, create, createBlocks, createItems, getEntries, getNamespace, getRegistryKey, iteratorMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
Blocks
-
-
Method Details
-
register
public <B extends net.minecraft.world.level.block.Block> RegistryBlock<B> register(String name, Supplier<B> supplier) Description copied from class:Register.BlocksRegisters a new block.- Overrides:
registerin classRegister.Blocks- Type Parameters:
B- The concrete block type- Parameters:
name- The name of the block (without namespace)supplier- Supplier providing the block instance- Returns:
- A specialized block registry holder
-
register
public void register()Description copied from class:RegisterPerforms final registration by binding all holders to the actual registry.This should be called during mod initialization after the registry is available. Note: Certain registry types are bound immediately and skip this step.
-