diff options
| author | Alkalus <draknyte1@hotmail.com> | 2020-04-13 23:50:26 +0000 |
|---|---|---|
| committer | Alkalus <draknyte1@hotmail.com> | 2020-04-13 23:50:26 +0000 |
| commit | e724a728061ec4a78cff73a4a2dd46eea4af4521 (patch) | |
| tree | fee3354917be32870ec349b605990a091ace9e62 /src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java | |
| parent | 24b1356471191a10fde6e4f1baf58ae74e87cfba (diff) | |
| parent | 87ab3c0ab5f1b682295e2a010cc88cf4ae7db51c (diff) | |
| download | GT5-Unofficial-e724a728061ec4a78cff73a4a2dd46eea4af4521.tar.gz GT5-Unofficial-e724a728061ec4a78cff73a4a2dd46eea4af4521.tar.bz2 GT5-Unofficial-e724a728061ec4a78cff73a4a2dd46eea4af4521.zip | |
Merged in MillingRecipes (pull request #7)
Milling Recipes & many other misc fixes
Diffstat (limited to 'src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java')
| -rw-r--r-- | src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java b/src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java new file mode 100644 index 0000000000..c942db14cf --- /dev/null +++ b/src/Java/gtPlusPlus/xmod/bop/blocks/pine/LeavesPineTree.java @@ -0,0 +1,36 @@ +package gtPlusPlus.xmod.bop.blocks.pine; + +import java.util.Random; + +import gtPlusPlus.api.objects.Logger; +import gtPlusPlus.core.item.chemistry.AgriculturalChem; +import gtPlusPlus.core.util.math.MathUtils; +import gtPlusPlus.core.util.minecraft.ItemUtils; +import gtPlusPlus.xmod.bop.blocks.BOP_Block_Registrator; +import gtPlusPlus.xmod.bop.blocks.base.LeavesBase; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.world.World; + +public class LeavesPineTree extends LeavesBase { + + public LeavesPineTree(){ + super("Pine", "pine", new ItemStack[]{}); + this.treeType = new String[] {"pine"}; + this.leafType = new String[][] {{"pine"},{"pine_opaque"}}; + } + + @Override + public Item getItemDropped(int p_149650_1_, Random p_149650_2_, int p_149650_3_){ + return Item.getItemFromBlock(BOP_Block_Registrator.sapling_Pine); + } + + @Override//Drops when Leaf is broken + protected void func_150124_c(World world, int x, int y, int z, int meta, int randomChance){ + Logger.INFO("Dropping Bonus Drops"); + if (MathUtils.randInt(0, 10) >= 9) { + this.dropBlockAsItem(world, x, y, z, ItemUtils.getSimpleStack(AgriculturalChem.mPinecone, MathUtils.randInt(1, 4))); + } + } + +}
\ No newline at end of file |
