package common.item;

import common.block.Block;
import common.init.ToolMaterial;
import common.material.Material;

public class ItemSpade extends ItemTool
{
//    private static final Set<Block> EFFECTIVE_ON = Sets.newHashSet(new Block[] {
//    		Blocks.clay, Blocks.dirt, Blocks.farmland, Blocks.grass, Blocks.gravel, Blocks.mycelium, Blocks.sand, Blocks.snow, Blocks.snow_layer, Blocks.soul_sand
//    });

    public ItemSpade(ToolMaterial material)
    {
        super(1, material);
    }

    public boolean canUseOn(ItemStack stack, Block state)
    {
        return state.canShovelHarvest();
    }
    
    public boolean canHarvestBlock(Block blockIn)
    {
//        return blockIn == Blocks.snow_layer ? true : blockIn == Blocks.snow;
        return blockIn.getMaterial() == Material.snow ? true : blockIn.getMaterial() == Material.craftedSnow;
    }
}
