Class NeoForgeRegistryCallbacks.BlockCallbacks
java.lang.Object
net.neoforged.neoforge.registries.NeoForgeRegistryCallbacks.BlockCallbacks
- All Implemented Interfaces:
AddCallback<Block>,BakeCallback<Block>,ClearCallback<Block>,RegistryCallback<Block>
- Enclosing class:
NeoForgeRegistryCallbacks
static class NeoForgeRegistryCallbacks.BlockCallbacks
extends Object
implements AddCallback<Block>, ClearCallback<Block>, BakeCallback<Block>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final NeoForgeRegistryCallbacks.BlockCallbacks.ClearableObjectIntIdentityMap<BlockState> (package private) static final NeoForgeRegistryCallbacks.BlockCallbacks -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCalled when an entry is added to the registry.voidCalled when the registry is frozen, and all registration is finished.voidCalled when the registry is cleared before anything is done to the registry.
-
Field Details
-
INSTANCE
-
BLOCKSTATE_TO_ID_MAP
static final NeoForgeRegistryCallbacks.BlockCallbacks.ClearableObjectIntIdentityMap<BlockState> BLOCKSTATE_TO_ID_MAP -
addedBlocks
-
-
Constructor Details
-
BlockCallbacks
BlockCallbacks()
-
-
Method Details
-
onAdd
Description copied from interface:AddCallbackCalled when an entry is added to the registry.- Specified by:
onAddin interfaceAddCallback<Block>- Parameters:
registry- the registryid- the integer ID assigned to the entrykey- the resource key for the entryvalue- the entry's value
-
onClear
Description copied from interface:ClearCallbackCalled when the registry is cleared before anything is done to the registry.- Specified by:
onClearin interfaceClearCallback<Block>- Parameters:
registry- the registryfull- iftrue, all entries in the registry will be cleared. iffalse, only integer IDs in the registry will be cleared.
-
onBake
Description copied from interface:BakeCallbackCalled when the registry is frozen, and all registration is finished.- Specified by:
onBakein interfaceBakeCallback<Block>- Parameters:
registry- the registry
-