    001    package net.minecraft.block;
    002
    003    import java.util.Random;
    004    import net.minecraft.block.material.Material;
    005    import net.minecraft.creativetab.CreativeTabs;
    006    import net.minecraft.item.Item;
    007    import net.minecraft.util.MathHelper;
    008
    009    public class BlockGlowStone extends Block
    010    {
    011        public BlockGlowStone(int par1, int par2, Material par3Material)
    012        {
    013            super(par1, par2, par3Material);
    014            this.setCreativeTab(CreativeTabs.tabBlock);
    015        }
    016
    017        /**
    018         * Returns the usual quantity dropped by the block plus a bonus of 1 to 'i' (inclusive).
    019         */
    020        public int quantityDroppedWithBonus(int par1, Random par2Random)
    021        {
    022            return MathHelper.clamp_int(this.quantityDropped(par2Random) + par2Random.nextInt(par1 + 1), 1, 4);
    023        }
    024
    025        /**
    026         * Returns the quantity of items to drop on block destruction.
    027         */
    028        public int quantityDropped(Random par1Random)
    029        {
    030            return 2 + par1Random.nextInt(3);
    031        }
    032
    033        /**
    034         * Returns the ID of the items to drop on destruction.
    035         */
    036        public int idDropped(int par1, Random par2Random, int par3)
    037        {
    038            return Item.lightStoneDust.shiftedIndex;
    039        }
    040    }