package minestrapteam.mods.minestrappolation.block.ore;
import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.Entity;
import net.minecraft.item.Item;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.BlockPos;
import net.minecraft.util.EnumFacing;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.EnumPlantType;
import net.minecraftforge.common.IPlantable;
public class BlockSoulOre extends MBlockOre
{
public BlockSoulOre(Material materialIn, MapColor mapColorIn, Item itemDrop, int meta, int expMin, int expMax, int dropAmount, int bonusAmount, String tool, int level, boolean silkHarvest)
{
super(materialIn, mapColorIn, itemDrop, meta, expMin, expMax, dropAmount, bonusAmount, tool, level,
silkHarvest);
}
@Override
public AxisAlignedBB getCollisionBoundingBox(World worldIn, BlockPos pos, IBlockState state)
{
return new AxisAlignedBB(pos.getX(), pos.getY(), pos.getZ(), (double) pos.getX() + 1,
(double) pos.getY() + 0.875F, (double) pos.getZ() + 1);
}
@Override
public void onEntityCollidedWithBlock(World world, BlockPos pos, Entity entity)
{
entity.motionX *= 0.4D;
entity.motionZ *= 0.4D;
}
@Override
public boolean canSustainPlant(IBlockAccess world, BlockPos pos, EnumFacing direction, IPlantable plantable)
{
return plantable.getPlantType(world, pos) == EnumPlantType.Nether;
}
}