Documentation

FurnaceBurnEvent extends BlockEvent
in package
implements Cancellable Uses CancellableTrait

Called when a furnace is about to consume a new fuel item.

Interfaces, Classes, Traits and Enums

Cancellable
This interface is implemented by an Event subclass if and only if it can be cancelled.

Table of Contents

MAX_EVENT_CALL_DEPTH  = 50
$block  : Block
$eventName  : string|null
$burning  : bool
$burnTime  : int
$eventCallDepth  : int
$fuel  : Item
$furnace  : Furnace
$isCancelled  : bool
__construct()  : mixed
call()  : void
Calls event handlers registered for this event.
cancel()  : void
getBlock()  : Block
getBurnTime()  : int
Returns the number of ticks that the furnace will be powered for.
getEventName()  : string
getFuel()  : Item
getFurnace()  : Furnace
isBurning()  : bool
Returns whether the fuel item will be consumed.
isCancelled()  : bool
setBurning()  : void
Sets whether the fuel will be consumed. If false, the furnace will smelt as if it consumed fuel, but no fuel will be deducted.
setBurnTime()  : void
Sets the number of ticks that the given fuel will power the furnace for.
uncancel()  : void

Constants

MAX_EVENT_CALL_DEPTH

private mixed MAX_EVENT_CALL_DEPTH = 50

Properties

$eventName

protected string|null $eventName = null

$eventCallDepth

private static int $eventCallDepth = 1

Methods

call()

Calls event handlers registered for this event.

public call() : void
Tags
throws
RuntimeException

if event call recursion reaches the max depth limit

Return values
void

getBurnTime()

Returns the number of ticks that the furnace will be powered for.

public getBurnTime() : int
Return values
int

getEventName()

public final getEventName() : string
Return values
string

isBurning()

Returns whether the fuel item will be consumed.

public isBurning() : bool
Return values
bool

setBurning()

Sets whether the fuel will be consumed. If false, the furnace will smelt as if it consumed fuel, but no fuel will be deducted.

public setBurning(bool $burning) : void
Parameters
$burning : bool
Return values
void

setBurnTime()

Sets the number of ticks that the given fuel will power the furnace for.

public setBurnTime(int $burnTime) : void
Parameters
$burnTime : int
Return values
void

Search results