Class FullPotsAccessorDemo.DioriteFlowerPotBlock

    • Constructor Detail

      • DioriteFlowerPotBlock

        public DioriteFlowerPotBlock()
    • Method Detail

      • hasTileEntity

        public boolean hasTileEntity​(BlockState state)
        Description copied from interface: IForgeBlock
        Called throughout the code as a replacement for block instanceof BlockContainer Moving this to the Block base class allows for mods that wish to extend vanilla blocks, and also want to have a tile entity on that block, may. Return true from this function to specify this block has a tile entity.
        Parameters:
        state - State of the current block
        Returns:
        True if block has a tile entity, false otherwise
      • createTileEntity

        public TileEntity createTileEntity​(BlockState state,
                                           IBlockReader world)
        Description copied from interface: IForgeBlock
        Called throughout the code as a replacement for ITileEntityProvider.createNewTileEntity Return the same thing you would from that function. This will fall back to ITileEntityProvider.createNewTileEntity(World) if this block is a ITileEntityProvider
        Parameters:
        state - The state of the current block
        world - The world to create the TE in
        Returns:
        A instance of a class extending TileEntity