Files
MagicBees/thaumicbees_src/thaumicbees/bees/FlowerProviderBookshelf.java
T
MysteriousAges 5a2f360e50 Another FC build.
*Heavily refactored bee code. Much cleaner now I think.
*Temporal bee branch complete, now with more Doctor Who!
2013-02-09 14:12:43 -08:00

52 lines
1.2 KiB
Java

package thaumicbees.bees;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import forestry.api.apiculture.IBeeGenome;
import forestry.api.apiculture.IFlowerProvider;
import forestry.api.genetics.IPollinatable;
public class FlowerProviderBookshelf implements IFlowerProvider
{
public boolean isAcceptedFlower(World world, IBeeGenome genome, int x, int i, int j)
{
boolean flag = false;
if (world.getBlockId(x, i, j) == Block.bookShelf.blockID)
{
flag = true;
}
return flag;
}
public boolean growFlower(World world, IBeeGenome genome, int x, int i, int j)
{
// Always return true so the system thinks we grew a flower.
// Bees can't grow bookshelves! Are you crazy?!
return true;
}
public ItemStack[] affectProducts(World world, IBeeGenome genome, int x, int i, int j, ItemStack products[])
{
return products;
}
public ItemStack[] getItemStacks()
{
return new ItemStack[] { new ItemStack(Block.bookShelf) };
}
//@Override
public boolean isAcceptedPollinatable(World world, IPollinatable pollinatable)
{
// No idea what this is supposed to do.
return false;
}
public String getDescription()
{
return "Books";
}
}