Class NeoForgeRegistration

java.lang.Object
net.nikdo53.tinymultiblocklib.platform.NeoForgeRegistration
All Implemented Interfaces:
IRegistrationUtils

public class NeoForgeRegistration extends Object implements IRegistrationUtils
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final net.neoforged.neoforge.registries.DeferredRegister<net.minecraft.world.level.block.entity.BlockEntityType<?>>
     
    static final net.neoforged.neoforge.registries.DeferredRegister.Blocks
     
     
    static final net.neoforged.neoforge.registries.DeferredRegister.Items
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <T extends net.minecraft.world.level.block.entity.BlockEntity>
    void
    addSupportedBEBlock(Supplier<net.minecraft.world.level.block.entity.BlockEntityType<T>> blockEntityType, net.minecraft.world.level.block.Block block)
     
    <T extends net.minecraft.world.level.block.entity.BlockEntity>
    Supplier<net.minecraft.world.level.block.entity.BlockEntityType<T>>
    registerBlockEntity(String name, BiFunction<net.minecraft.core.BlockPos, net.minecraft.world.level.block.state.BlockState, T> function, Set<net.minecraft.world.level.block.Block> blocks)
     
    <T extends net.minecraft.world.level.block.Block>
    Supplier<net.minecraft.world.item.Item>
     
    <T extends net.minecraft.world.level.block.Block>
    Supplier<T>
    registerBlockWithItem(String name, Function<net.minecraft.world.level.block.state.BlockBehaviour.Properties, ? extends T> func, Supplier<net.minecraft.world.level.block.state.BlockBehaviour.Properties> properties)
     

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • INSTANCE

      public static final NeoForgeRegistration INSTANCE
    • ITEMS

      public static final net.neoforged.neoforge.registries.DeferredRegister.Items ITEMS
    • BLOCK_ENTITIES

      public static final net.neoforged.neoforge.registries.DeferredRegister<net.minecraft.world.level.block.entity.BlockEntityType<?>> BLOCK_ENTITIES
    • BLOCKS

      public static final net.neoforged.neoforge.registries.DeferredRegister.Blocks BLOCKS
  • Constructor Details

    • NeoForgeRegistration

      public NeoForgeRegistration()
  • Method Details

    • registerBlockEntity

      public <T extends net.minecraft.world.level.block.entity.BlockEntity> Supplier<net.minecraft.world.level.block.entity.BlockEntityType<T>> registerBlockEntity(String name, BiFunction<net.minecraft.core.BlockPos, net.minecraft.world.level.block.state.BlockState, T> function, Set<net.minecraft.world.level.block.Block> blocks)
      Specified by:
      registerBlockEntity in interface IRegistrationUtils
    • registerBlockWithItem

      public <T extends net.minecraft.world.level.block.Block> Supplier<T> registerBlockWithItem(String name, Function<net.minecraft.world.level.block.state.BlockBehaviour.Properties, ? extends T> func, Supplier<net.minecraft.world.level.block.state.BlockBehaviour.Properties> properties)
      Specified by:
      registerBlockWithItem in interface IRegistrationUtils
    • registerBlockItem

      public <T extends net.minecraft.world.level.block.Block> Supplier<net.minecraft.world.item.Item> registerBlockItem(String name, Supplier<T> block)
      Specified by:
      registerBlockItem in interface IRegistrationUtils
    • addSupportedBEBlock

      public <T extends net.minecraft.world.level.block.entity.BlockEntity> void addSupportedBEBlock(Supplier<net.minecraft.world.level.block.entity.BlockEntityType<T>> blockEntityType, net.minecraft.world.level.block.Block block)
      Specified by:
      addSupportedBEBlock in interface IRegistrationUtils