package micdoodle8.mods.galacticraft.core.blocks; import micdoodle8.mods.galacticraft.core.entities.EntitySkeletonBoss; import micdoodle8.mods.galacticraft.core.tile.TileEntityDungeonSpawner; import net.minecraft.block.Block; import net.minecraft.block.ITileEntityProvider; import net.minecraft.block.material.Material; import net.minecraft.block.state.IBlockState; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Blocks; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.tileentity.TileEntity; import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import java.util.Random; public class BlockBossSpawner extends Block implements ITileEntityProvider { public BlockBossSpawner(String assetName) { super(Material.rock); this.blockHardness = 1000000.0F; this.blockResistance = 1000000.0F; this.setUnlocalizedName(assetName); } @Override public AxisAlignedBB getSelectedBoundingBox(World worldIn, BlockPos pos) { return new AxisAlignedBB(pos.getX(), pos.getY(), pos.getZ(), pos.getX(), pos.getY(), pos.getZ()); } @Override public int getRenderType() { return -1; } @Override public boolean shouldSideBeRendered(IBlockAccess worldIn, BlockPos pos, EnumFacing side) { return false; } @Override public Item getItemDropped(IBlockState state, Random rand, int fortune) { return Item.getItemFromBlock(Blocks.air); } @Override public int quantityDropped(IBlockState state, int fortune, Random random) { return 0; } @Override public TileEntity createNewTileEntity(World worldIn, int meta) { return new TileEntityDungeonSpawner(EntitySkeletonBoss.class); } @Override public ItemStack getPickBlock(MovingObjectPosition target, World world, BlockPos pos, EntityPlayer player) { return null; } @Override public boolean isOpaqueCube() { return false; } @Override public AxisAlignedBB getCollisionBoundingBox(World worldIn, BlockPos pos, IBlockState state) { return null; } @Override public boolean isCollidable() { return false; } @Override public boolean isFullCube() { return false; } }