Skip to content

Commit

Permalink
Fixes #118, skip chance check if fortune > 3
Browse files Browse the repository at this point in the history
  • Loading branch information
Qowyn committed Sep 6, 2014
1 parent 53e0018 commit 8f1a97d
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/main/java/mods/natura/blocks/trees/NLeavesNocolor.java
Expand Up @@ -81,8 +81,16 @@ public Item getItemDropped (int meta, Random random, int fortune)
public ArrayList<ItemStack> getDrops (World world, int x, int y, int z, int metadata, int fortune)
{
ArrayList<ItemStack> ret = super.getDrops(world, x, y, z, metadata, fortune);
if (metadata % 4 == 2 && Natura.random.nextInt(40 - fortune * 10) == 0)
ret.add(new ItemStack(Items.redstone));

if (metadata % 4 == 2)
{
if (fortune > 3 || Natura.random.nextInt(40 - fortune * 10) == 0)
{
ret.add(new ItemStack(Items.redstone));
}

}

return ret;
}

Expand Down

0 comments on commit 8f1a97d

Please sign in to comment.