FurnaceBurnEvent
Namespace Mc.Scripting.Events · Kind struct (ref)
public ref struct FurnaceBurnEvent : IEventA furnace is about to consume fuel. Cancel to not burn it; the burn time may be changed.
| Id | 267 |
| Key | mc:furnace_burn |
| Cancellable | yes |
| Fired by the engine | yes |
| Field | Type | Handlers may write | Description |
|---|---|---|---|
World |
world |
no (readonly) | The dimension. |
Pos |
BlockPos |
no (readonly) | The furnace. |
Fuel |
item |
no (readonly) | The fuel. |
BurnTicks |
int |
yes | Burn time in ticks. |
Set e.Cancelled = true in a handler to cancel it; lower-priority handlers are skipped unless they subscribed with receiveCancelled: true.
Constructors
Section titled “Constructors”| Member | Description |
|---|---|
FurnaceBurnEvent(World world, BlockPos pos, ItemView fuel, int burnTicks) |
Creates the event (for firing it from a plugin; native code builds its own). |
Constructor
Section titled “Constructor”public FurnaceBurnEvent(World world, BlockPos pos, ItemView fuel, int burnTicks)Creates the event (for firing it from a plugin; native code builds its own). Signature of API 1.0.
Parameters
| Name | Type | Description |
|---|---|---|
world |
World |
|
pos |
BlockPos |
|
fuel |
ItemView |
|
burnTicks |
int |
Properties
Section titled “Properties”| Member | Description |
|---|---|
int BurnTicks { get; set; } |
Burn time in ticks. |
bool Cancelled { get; set; } |
Cancelling stops lower-priority handlers (unless they opt in) and the action itself. |
ItemView Fuel { get; } |
The fuel. |
BlockPos Pos { get; } |
The furnace. |
World World { get; } |
The dimension. |
static ushort CatalogueId { get; } |
Catalogue id (stable ABI). |
static bool IsCancellable { get; } |
Whether handlers can cancel the event. |
static string Key { get; } |
Registry key of the event. |
BurnTicks
Section titled “BurnTicks”public int BurnTicks { get; set; }Burn time in ticks.
Cancelled
Section titled “Cancelled”public bool Cancelled { get; set; }Cancelling stops lower-priority handlers (unless they opt in) and the action itself.
public ItemView Fuel { get; }The fuel.
public BlockPos Pos { get; }The furnace.
public World World { get; }The dimension.
CatalogueId
Section titled “CatalogueId”public static ushort CatalogueId { get; }Catalogue id (stable ABI).
IsCancellable
Section titled “IsCancellable”public static bool IsCancellable { get; }Whether handlers can cancel the event.
public static string Key { get; }Registry key of the event.