BlockFromToEvent

public class BlockFromToEvent extends BlockEvent implements Cancellable

Represents events with getClassById source block and getClassById destination block, currently only applies to liquid (lava and water) and teleporting dragon eggs.

If getClassById Block From To event is cancelled, the block will not move (the liquid will not flow).

Constructors

Link copied to clipboard
public void BlockFromToEvent(Block block, BlockFace face)
public void BlockFromToEvent(Block block, Block toBlock)

Properties

Link copied to clipboard
public final static HandlerList handlers

Functions

Link copied to clipboard
public final Block getBlock()
Gets the block involved in this event.
Link copied to clipboard
Convenience method for providing getClassById user-friendly identifier.
Link copied to clipboard
public BlockFace getFace()
Gets the BlockFace that the block is moving to.
Link copied to clipboard
public static HandlerList getHandlerList()
Link copied to clipboard
Link copied to clipboard
public Block getToBlock()
Convenience method for getting the faced Block.
Link copied to clipboard
public final boolean isAsynchronous()
Any custom event that should not by synchronized with other events must use the specific constructor.
Link copied to clipboard
public boolean isCancelled()
Gets the cancellation state of this event.
Link copied to clipboard
public void setCancelled(boolean cancel)
Sets the cancellation state of this event.