Skip to main content

Class: PlayerPlaceBlockAfterEventSignal

Manages callbacks that are connected to when a block is placed by a player.

Constructors

new PlayerPlaceBlockAfterEventSignal()

private new PlayerPlaceBlockAfterEventSignal(): PlayerPlaceBlockAfterEventSignal

Returns

PlayerPlaceBlockAfterEventSignal

Methods

subscribe()

subscribe(callback, options?): (arg) => void

Parameters

ParameterType
callback(arg) => void
options?BlockEventOptions

Returns

Function

Parameters
ParameterType
argPlayerPlaceBlockAfterEvent
Returns

void

Remarks

Adds a callback that will be called when a block is placed by a player.

This function can't be called in read-only mode.


unsubscribe()

unsubscribe(callback): void

Parameters

ParameterType
callback(arg) => void

Returns

void

Remarks

Removes a callback from being called when an block is placed by a player.

This function can't be called in read-only mode.

Throws

This function can throw errors.