package com.r3944realms.leashedplayer.content.blocks.entity;

import com.r3944realms.leashedplayer.LeashedPlayer;
import com.r3944realms.leashedplayer.content.blocks.ModBlocksRegister;
import net.minecraft.core.registries.Registries;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.neoforged.bus.api.IEventBus;
import net.neoforged.neoforge.registries.DeferredHolder;
import net.neoforged.neoforge.registries.DeferredRegister;

import java.util.Set;
public class ModBlockEntityRegister {
    public static DeferredRegister<BlockEntityType<?>> BLOCK_ENTITY = DeferredRegister.create(Registries.BLOCK_ENTITY_TYPE, LeashedPlayer.MOD_ID);
    public static DeferredHolder<BlockEntityType<?>, BlockEntityType<ItemMemoryBlockEntity>> ITEM_MEMORY_BLOCK =
            BLOCK_ENTITY.register(
                    "item_memory_block_entity",
                    () -> new BlockEntityType<>(
                            ItemMemoryBlockEntity::new,
                            Set.of(ModBlocksRegister.TEST_BLOCK.get())
                    )
            );
    public static void register(IEventBus eventBus) {
        BLOCK_ENTITY.register(eventBus);
    }

}
