Skip to content

API reference / @jsprismarine/prismarine / entity/data/eyeOfEnderSignals / EyeOfEnderSignals

Class: EyeOfEnderSignals ​

Defined in: packages/prismarine/src/entity/data/eyeOfEnderSignals.ts:226

The eyes of ender of one runtime, and the system that flies each of them once a tick.

Constructors ​

Constructor ​

new EyeOfEnderSignals(host): EyeOfEnderSignals

Defined in: packages/prismarine/src/entity/data/eyeOfEnderSignals.ts:227

Parameters ​

host ​

EyeOfEnderSignalsHost

Returns ​

EyeOfEnderSignals

Methods ​

isValid() ​

isValid(entity): boolean

Defined in: packages/prismarine/src/entity/data/eyeOfEnderSignals.ts:258

Whether an entity is either no eye or one with a flight, so it may enter the world.

Parameters ​

entity ​

DataEntity

Returns ​

boolean


launch() ​

launch(from, target, stack): DataEntity | undefined

Defined in: packages/prismarine/src/entity/data/eyeOfEnderSignals.ts:236

Throws an eye from a point toward a stronghold, with the shatter rolled now, as Java rolls it.

Parameters ​

from ​

EntityPosition

Where the eye starts, in the middle of the thrower's body.

target ​

EntityPosition

Where the stronghold starts, in blocks.

stack ​

StoredItemStack

The stack that drops when the eye survives, which is the eye thrown.

Returns ​

DataEntity | undefined

The eye, or undefined when the content declares no eye of ender.


update() ​

update(entity): void

Defined in: packages/prismarine/src/entity/data/eyeOfEnderSignals.ts:269

One tick of flight, Java's EyeOfEnder.tick in its order: the move by the velocity the eye had, the next velocity from where it now is, and once life passes the lifetime the break sound, the discard, and the drop or the burst.

Parameters ​

entity ​

DataEntity

Returns ​

void

Java Source ​

EyeOfEnder.tick