Hello everyone.
I have been working on an ore which is supposed to have a chance of dropping additional items with varying amount.
I found a method wich seams to be depricated and does not work any more.
@Deprecated
public ArrayList<ItemStack> onBlockDestroyedByPlayer(World world, int x, int y, int z, int metadata, int fortune){
ArrayList<ItemStack> drops = new ArrayList<ItemStack>();
drops.add(new ItemStack(Items.COAL, world.rand.nextInt(100) + 1));
drops.add(new ItemStack(Items.APPLE, world.rand.nextInt(10) + 1));
if (world.rand.nextFloat() < 0.5F)
drops.add(new ItemStack(Items.DIAMOND));
return drops;
}
Are there any similar methods or did I make some stupid mistake?
Thank you in advance.