Class FabricRegistriesHelper

java.lang.Object
net.tearpelato.craftcorelib.platform.FabricRegistriesHelper
All Implemented Interfaces:
IRegistriesHelper

public class FabricRegistriesHelper extends Object implements IRegistriesHelper
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <T extends net.minecraft.world.level.block.entity.BlockEntity>
    net.minecraft.world.level.block.entity.BlockEntityType<T>
    createBlockEntity(BiFunction<net.minecraft.core.BlockPos, net.minecraft.world.level.block.state.BlockState, T> factory, Supplier<net.minecraft.world.level.block.Block[]> blocks)
     
    <T extends net.minecraft.world.inventory.AbstractContainerMenu>
    net.minecraft.world.inventory.MenuType<T>
    createMenu(BiFunction<Integer, net.minecraft.world.entity.player.Inventory, T> function)
     
    <T extends net.minecraft.world.inventory.AbstractContainerMenu>
    net.minecraft.world.inventory.MenuType<T>
    createMenuData(org.apache.commons.lang3.function.TriFunction<Integer, net.minecraft.world.entity.player.Inventory, net.minecraft.network.FriendlyByteBuf, T> function)
     
    net.minecraft.core.Registry<?>
     
    void
    openMenuData(net.minecraft.server.level.ServerPlayer player, net.minecraft.world.MenuProvider provider, net.minecraft.core.BlockPos pos)
     
    <T> void
    registerEntityDataSerializer(net.minecraft.resources.Identifier id, net.minecraft.network.syncher.EntityDataSerializer<T> serializer)
     

    Methods inherited from class Object

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

    • FabricRegistriesHelper

      public FabricRegistriesHelper()
  • Method Details

    • createBlockEntity

      public <T extends net.minecraft.world.level.block.entity.BlockEntity> net.minecraft.world.level.block.entity.BlockEntityType<T> createBlockEntity(BiFunction<net.minecraft.core.BlockPos, net.minecraft.world.level.block.state.BlockState, T> factory, Supplier<net.minecraft.world.level.block.Block[]> blocks)
      Specified by:
      createBlockEntity in interface IRegistriesHelper
    • createMenu

      public <T extends net.minecraft.world.inventory.AbstractContainerMenu> net.minecraft.world.inventory.MenuType<T> createMenu(BiFunction<Integer, net.minecraft.world.entity.player.Inventory, T> function)
      Specified by:
      createMenu in interface IRegistriesHelper
    • createMenuData

      public <T extends net.minecraft.world.inventory.AbstractContainerMenu> net.minecraft.world.inventory.MenuType<T> createMenuData(org.apache.commons.lang3.function.TriFunction<Integer, net.minecraft.world.entity.player.Inventory, net.minecraft.network.FriendlyByteBuf, T> function)
      Specified by:
      createMenuData in interface IRegistriesHelper
    • registerEntityDataSerializer

      public <T> void registerEntityDataSerializer(net.minecraft.resources.Identifier id, net.minecraft.network.syncher.EntityDataSerializer<T> serializer)
      Specified by:
      registerEntityDataSerializer in interface IRegistriesHelper
    • entityDataSerializerRegistry

      public net.minecraft.core.Registry<?> entityDataSerializerRegistry()
      Specified by:
      entityDataSerializerRegistry in interface IRegistriesHelper
    • openMenuData

      public void openMenuData(net.minecraft.server.level.ServerPlayer player, net.minecraft.world.MenuProvider provider, net.minecraft.core.BlockPos pos)
      Specified by:
      openMenuData in interface IRegistriesHelper