public class FruitProviderPod extends FruitProviderNone
| Modifier and Type | Class and Description |
|---|---|
static class |
FruitProviderPod.EnumPodType |
ripeningPeriod| Constructor and Description |
|---|
FruitProviderPod(java.lang.String unlocalizedDescription,
IFruitFamily family,
FruitProviderPod.EnumPodType type,
net.minecraft.item.ItemStack... dropOnMature) |
| Modifier and Type | Method and Description |
|---|---|
net.minecraft.util.ResourceLocation |
getDecorativeSprite()
return the ResourceLocation to display on decorative leaves
|
net.minecraft.util.NonNullList<net.minecraft.item.ItemStack> |
getFruits(ITreeGenome genome,
net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos,
int ripeningTime)
Returns all drops of this block if you harvest it.
|
java.lang.String |
getModelName() |
java.util.Map<net.minecraft.item.ItemStack,java.lang.Float> |
getProducts()
A unmodifiable map that contains all products and their associated drop chances.
|
net.minecraft.util.ResourceLocation |
getSprite(ITreeGenome genome,
net.minecraft.world.IBlockAccess world,
net.minecraft.util.math.BlockPos pos,
int ripeningTime) |
void |
registerSprites()
Can be used to register the sprite/s that can be returned with
IFruitProvider.getSprite(ITreeGenome, IBlockAccess, BlockPos, int). |
boolean |
requiresFruitBlocks() |
boolean |
trySpawnFruitBlock(ITreeGenome genome,
net.minecraft.world.World world,
java.util.Random rand,
net.minecraft.util.math.BlockPos pos)
Tries to spawn a fruit block at the potential position when the tree generates.
|
getColour, getDecorativeColor, getDescription, getFamily, getModID, getRipeningPeriod, getSpecialty, isFruitLeaf, setOverlayclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetFruitChancepublic FruitProviderPod(java.lang.String unlocalizedDescription,
IFruitFamily family,
FruitProviderPod.EnumPodType type,
net.minecraft.item.ItemStack... dropOnMature)
public boolean requiresFruitBlocks()
requiresFruitBlocks in interface IFruitProviderrequiresFruitBlocks in class FruitProviderNonepublic net.minecraft.util.NonNullList<net.minecraft.item.ItemStack> getFruits(@Nullable
ITreeGenome genome,
net.minecraft.world.World world,
net.minecraft.util.math.BlockPos pos,
int ripeningTime)
IFruitProvidergetFruits in interface IFruitProvidergetFruits in class FruitProviderNonegenome - The genome of the tree of the leaves / pod.ripeningTime - The repining time of the block. From 0 to IFruitProvider.getRipeningPeriod().public boolean trySpawnFruitBlock(ITreeGenome genome, net.minecraft.world.World world, java.util.Random rand, net.minecraft.util.math.BlockPos pos)
IFruitProviderITreeGenome.getSappiness()trySpawnFruitBlock in interface IFruitProvidertrySpawnFruitBlock in class FruitProviderNonepublic net.minecraft.util.ResourceLocation getSprite(ITreeGenome genome, net.minecraft.world.IBlockAccess world, net.minecraft.util.math.BlockPos pos, int ripeningTime)
getSprite in interface IFruitProvidergetSprite in class FruitProviderNoneripeningTime - Elapsed ripening time for the fruit.public net.minecraft.util.ResourceLocation getDecorativeSprite()
IFruitProvidergetDecorativeSprite in interface IFruitProvidergetDecorativeSprite in class FruitProviderNonepublic java.util.Map<net.minecraft.item.ItemStack,java.lang.Float> getProducts()
IFruitProvidergetProducts in interface IFruitProvidergetProducts in class FruitProviderNonepublic void registerSprites()
IFruitProviderIFruitProvider.getSprite(ITreeGenome, IBlockAccess, BlockPos, int).registerSprites in interface IFruitProviderregisterSprites in class FruitProviderNonepublic java.lang.String getModelName()
getModelName in interface IFruitProvidergetModelName in class FruitProviderNone