public class FarmableSapling extends java.lang.Object implements IFarmable
| Modifier and Type | Field and Description |
|---|---|
protected net.minecraft.item.ItemStack |
germling |
protected boolean |
ignoreMetadata |
protected net.minecraft.block.Block |
saplingBlock |
protected net.minecraft.item.ItemStack[] |
windfall |
| Constructor and Description |
|---|
FarmableSapling(net.minecraft.item.ItemStack germling,
net.minecraft.item.ItemStack[] windfall) |
FarmableSapling(net.minecraft.item.ItemStack germling,
net.minecraft.item.ItemStack[] windfall,
boolean addSubItems) |
| Modifier and Type | Method and Description |
|---|---|
void |
addInformation(IFarmableInfo info) |
ICrop |
getCropAt(net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos,
net.minecraft.block.state.IBlockState blockState) |
boolean |
isGermling(net.minecraft.item.ItemStack itemstack) |
boolean |
isSaplingAt(net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos,
net.minecraft.block.state.IBlockState blockState) |
boolean |
isWindfall(net.minecraft.item.ItemStack itemstack) |
boolean |
plantSaplingAt(net.minecraft.entity.player.EntityPlayer player,
net.minecraft.item.ItemStack germling,
net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos)
Plants a sapling by manipulating the world.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisSaplingAtprotected final net.minecraft.item.ItemStack germling
protected final boolean ignoreMetadata
protected final net.minecraft.block.Block saplingBlock
protected final net.minecraft.item.ItemStack[] windfall
public FarmableSapling(net.minecraft.item.ItemStack germling,
net.minecraft.item.ItemStack[] windfall)
public FarmableSapling(net.minecraft.item.ItemStack germling,
net.minecraft.item.ItemStack[] windfall,
boolean addSubItems)
public boolean plantSaplingAt(net.minecraft.entity.player.EntityPlayer player,
net.minecraft.item.ItemStack germling,
net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos)
IFarmableIFarmLogic should have verified the given location as valid. Called by the IFarmHousing
which handles resources.plantSaplingAt in interface IFarmablepublic boolean isSaplingAt(net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos,
net.minecraft.block.state.IBlockState blockState)
isSaplingAt in interface IFarmablepublic ICrop getCropAt(net.minecraft.world.World world, net.minecraft.util.math.BlockPos pos, net.minecraft.block.state.IBlockState blockState)
public boolean isGermling(net.minecraft.item.ItemStack itemstack)
isGermling in interface IFarmablepublic void addInformation(IFarmableInfo info)
addInformation in interface IFarmablepublic boolean isWindfall(net.minecraft.item.ItemStack itemstack)
isWindfall in interface IFarmable