Skip to main content

Class: ProjectileHitBlockAfterEvent

Contains information related to a projectile hitting a block.

Constructors

new ProjectileHitBlockAfterEvent()

private new ProjectileHitBlockAfterEvent(): ProjectileHitBlockAfterEvent

Returns

ProjectileHitBlockAfterEvent

Properties

dimension

readonly dimension: Dimension

Remarks

Dimension where this projectile hit took place.


hitVector

readonly hitVector: Vector3

Remarks

Direction vector of the projectile as it hit a block.


location

readonly location: Vector3

Remarks

Location where the projectile hit occurred.


projectile

readonly projectile: Entity

Remarks

Entity for the projectile that hit a block.


source?

optional readonly source: Entity

Remarks

Optional source entity that fired the projectile.

Methods

getBlockHit()

getBlockHit(): BlockHitInformation

Returns

BlockHitInformation

Remarks

Contains additional information about the block that was hit by the projectile.

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