001package net.minecraftforge.event.entity.player;
002
003import net.minecraft.entity.player.EntityPlayer;
004import net.minecraft.world.World;
005import net.minecraftforge.event.Cancelable;
006import net.minecraftforge.event.Event;
007
008@Cancelable
009@Event.HasResult
010public class BonemealEvent extends PlayerEvent
011{
012    /**
013     * This event is called when a player attempts to use Bonemeal on a block.
014     * It can be canceled to completely prevent any further processing.
015     * 
016     * You can also set the result to ALLOW to mark the event as processed 
017     * and use up a bonemeal from the stack but do no further processing.
018     * 
019     * setResult(ALLOW) is the same as the old setHandeled()
020     */
021
022    public final World world;
023    public final int ID;
024    public final int X;
025    public final int Y;
026    public final int Z;
027    
028    public BonemealEvent(EntityPlayer player, World world, int id, int x, int y, int z)
029    {
030        super(player);
031        this.world = world;
032        this.ID = id;
033        this.X = x;
034        this.Y = y;
035        this.Z = z;
036    }
037}