Skip to content

@minecraft/server


@minecraft/server / ItemComponentUseOnEvent

Class: ItemComponentUseOnEvent ​

Defined in: @minecraft/server/index.d.ts:13894

Contains information regarding the use of an item on a block via a component.

Extends ​

Properties ​

block ​

readonly block: Block

Defined in: @minecraft/server/index.d.ts:15355

Remarks ​

The block impacted by this event.

Inherited from ​

ItemUseOnEvent.block


blockFace ​

readonly blockFace: Direction

Defined in: @minecraft/server/index.d.ts:15361

Remarks ​

The face of the block that the item was used on.

Inherited from ​

ItemUseOnEvent.blockFace


faceLocation ​

readonly faceLocation: Vector3

Defined in: @minecraft/server/index.d.ts:15368

Remarks ​

Location relative to the bottom north-west corner of the block that the item was used on.

Inherited from ​

ItemUseOnEvent.faceLocation


itemStack ​

readonly itemStack: ItemStack

Defined in: @minecraft/server/index.d.ts:15374

Remarks ​

The item stack used on the block.

Inherited from ​

ItemUseOnEvent.itemStack


source ​

readonly source: Entity

Defined in: @minecraft/server/index.d.ts:13901

Remarks ​

The entity that used the item on the block.


usedOnBlockPermutation ​

readonly usedOnBlockPermutation: BlockPermutation

Defined in: @minecraft/server/index.d.ts:13907

Remarks ​

The block permutation that the item was used on.