[API reference](https://jsprismarine.dev/api/index.md) / [@jsprismarine/prismarine](https://jsprismarine.dev/api/@jsprismarine/prismarine/index.md) / [entity/data/live](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/live/index.md) / LiveEntityRuntime

# Class: LiveEntityRuntime

Defined in: [packages/prismarine/src/entity/data/live.ts:830](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L830)

One dimension's entity runtime over a running server, shown to its clients through store actors.

## Constructors

### Constructor

> **new LiveEntityRuntime**(`options`, `players?`): `LiveEntityRuntime`

Defined in: [packages/prismarine/src/entity/data/live.ts:858](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L858)

#### Parameters

##### options

[`LiveEntityOptions`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/live/index.md#liveentityoptions)

##### players?

[`StorePlayers`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storePlayers/classes/StorePlayers.md) = `...`

The server's store players, whose actors show them as players and whose
  inventories answer the host's meal and armor facts.

#### Returns

`LiveEntityRuntime`

## Properties

### actors

> `readonly` **actors**: [`StoreActors`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActors.md)

Defined in: [packages/prismarine/src/entity/data/live.ts:839](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L839)

Each entity as the clients are shown it and the rest of the server reaches it, read from
the store: an [ItemActor](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/itemActor/classes/ItemActor.md) for a dropped stack and an [InertActor](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/InertActor.md) for a saved
actor no pack declares.

***

### runtime

> `readonly` **runtime**: [`EntityRuntime`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/EntityRuntime/classes/EntityRuntime.md)

Defined in: [packages/prismarine/src/entity/data/live.ts:832](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L832)

The entities themselves, for the content adapter's three groups and for tests.

## Accessors

### droppedItems

#### Get Signature

> **get** **droppedItems**(): [`DroppedItems`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/droppedItems/classes/DroppedItems.md)

Defined in: [packages/prismarine/src/entity/data/live.ts:1176](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1176)

The dropped stacks of this dimension.

##### Returns

[`DroppedItems`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/droppedItems/classes/DroppedItems.md)

## Methods

### adoptItem()

> **adoptItem**(`arrived`, `at`, `portalCooldown`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1208](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1208)

Takes in a stack that left another dimension's store through a portal, with the state it
left with, at where it arrives.

#### Parameters

##### arrived

[`ItemActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/itemActor/classes/ItemActor.md)

The stack's actor in the store it left.

##### at

[`EntityPosition`](https://jsprismarine.dev/api/@jsprismarine/entities/index.md#entityposition)

Where it arrives, which it reports itself at.

##### portalCooldown

`number`

The cooldown it arrives with.

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when the actor held no stack.

***

### attach()

> **attach**(`adapter`): `void`

Defined in: [packages/prismarine/src/entity/data/live.ts:1147](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1147)

Takes the assembled adapter for this dimension, which is where the spawn
rules read the world from.

Separate from the constructor because the adapter holds groups projected
out of this runtime, so the runtime exists first. The spawn world is
`src/content/world/views.ts`'s projection rather than another one written
here, so a spawn rule and a block behavior read the same world.

#### Parameters

##### adapter

[`ServerWorldAdapter`](https://jsprismarine.dev/api/@jsprismarine/prismarine/content/world/adapter/index.md#serverworldadapter)

#### Returns

`void`

***

### attachLead()

> **attachLead**(`holderId`, `targetId`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1273](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1273)

Attaches a live entity or player as holder of a data-driven entity's leash.

#### Parameters

##### holderId

`number`

##### targetId

`number`

#### Returns

`boolean`

***

### canDyeEntity()

> **canDyeEntity**(`target`, `color`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1322](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1322)

Whether this live body is a data-driven entity that accepts the requested dye.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The entity, a store entity through its actor.

##### color

`string`

The dye color name.

#### Returns

`boolean`

Whether the runtime entity accepts the dye.

***

### canNameEntity()

> **canNameEntity**(`target`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1298](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1298)

Whether this live body is a data-driven entity that accepts a name tag.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The entity, a store entity through its actor.

#### Returns

`boolean`

Whether its runtime entity accepts name tags.

***

### damageEntity()

> **damageEntity**(`target`, `amount`, `source`, `route`): `boolean` \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1082](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1082)

Hurts a data-driven entity through the store's damage pipeline, for a caller that describes
the blow with a legacy [DamageSource](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/DamageSource/classes/DamageSource.md), such as a player's swing or a legacy blast.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The entity, a store entity through its actor.

##### amount

`number`

##### source

[`DamageSource`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/DamageSource/classes/DamageSource.md)

##### route

[`DamageRoute`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/damagePipeline/index.md#damageroute)

Which path the blow came by.

#### Returns

`boolean` \| `undefined`

Whether it took health off the entity, or undefined when it is not a store entity
  and the caller still owns the blow.

***

### dropItem()

> **dropItem**(`lying`, `start`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1185](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1185)

Puts a stack on the ground as a store entity.

#### Parameters

##### lying

[`ContentPosition`](https://jsprismarine.dev/api/@jsprismarine/prismarine/content/world/adapter/index.md#contentposition)

Where it lies; it reports itself a little above.

##### start

[`ItemStart`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/droppedItems/index.md#itemstart)

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when the stack is empty or the content declares no item.

***

### dyeEntity()

> **dyeEntity**(`target`, `color`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1334](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1334)

Applies a supported dye through the live data-driven entity runtime.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The entity, a store entity through its actor.

##### color

`string`

The dye color name.

#### Returns

`boolean`

Whether the runtime changed the color.

***

### igniteEntity()

> **igniteEntity**(`target`, `seconds`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1101](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1101)

Sets a store entity on fire for some seconds, as Java's `Entity.igniteForSeconds` does,
never shortening a fire already burning longer.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

##### seconds

`number`

#### Returns

`boolean`

Whether it is a store entity.

#### Java Source

Entity.igniteForTicks

***

### interactWithItem()

> **interactWithItem**(`target`, `player`, `itemIdentifier`, `heldItem?`): [`EntityItemInteraction`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/itemInteraction/index.md#entityiteminteraction)

Defined in: [packages/prismarine/src/entity/data/live.ts:1389](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1389)

Applies a held item to a data-driven entity and carries out its world, item, and animation effects.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

##### player

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

##### itemIdentifier

`string`

##### heldItem?

[`ItemDrop`](https://jsprismarine.dev/api/@jsprismarine/block-behaviors/index.md#itemdrop)

#### Returns

[`EntityItemInteraction`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/itemInteraction/index.md#entityiteminteraction)

***

### isInRide()

> **isInRide**(`id`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1286](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1286)

Whether an entity rides something or carries a rider.

Bedrock sends nothing with passengers through a portal (MCPE-47288), and the only riding
the server models is the data-driven `minecraft:rideable` index, so a player on a mob
answers through the mob's side and a written entity never rides.

#### Parameters

##### id

`number`

The entity's runtime id.

#### Returns

`boolean`

***

### killEntity()

> **killEntity**(`target`, `source`, `route`): `boolean` \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1114](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1114)

Kills a data-driven entity through the store's damage pipeline, with a blow of its whole
health that ignores armor and the grace period, which is what `/kill` deals.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

##### source

[`DamageSource`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/DamageSource/classes/DamageSource.md)

##### route

[`DamageRoute`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/damagePipeline/index.md#damageroute)

#### Returns

`boolean` \| `undefined`

Whether it died, or undefined when it is not a store entity.

***

### launchProjectile()

> **launchProjectile**(`action`, `shooter`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1247](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1247)

Launches an item projectile from its live source through the data-driven runtime.

A player's position is already at eye height; other entity positions are at their feet.
The entity definition supplies flight and hit behavior through `minecraft:projectile`.

#### Parameters

##### action

[`LaunchProjectileAction`](https://jsprismarine.dev/api/@jsprismarine/item-behaviors/index.md#launchprojectileaction)

The item behavior's projectile identifier, speed, spread, and payload.

##### shooter

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The live entity that used the item.

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The spawned projectile, or undefined when its loaded definition is not a projectile.

#### Java See

Projectile.shootFromRotation

***

### nameEntity()

> **nameEntity**(`target`, `name`): `boolean`

Defined in: [packages/prismarine/src/entity/data/live.ts:1310](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1310)

Names a live body through its data-driven runtime entity.

#### Parameters

##### target

[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md)

The entity, a store entity through its actor.

##### name

`string`

The custom name being assigned.

#### Returns

`boolean`

Whether the runtime accepted the name tag.

***

### onEntityRemoved()

> **onEntityRemoved**(`listener`): () => `void`

Defined in: [packages/prismarine/src/entity/data/live.ts:1133](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1133)

Hears about every entity the runtime removes, after the body is gone.

The End's dragon fight learns of its dragon's death through this rather than through a
field on the runtime, so the runtime stays ignorant of who is watching. The reason is the
removal reason the runtime recorded: `death` and `death_behavior` are deaths,
`chunk unload` means the entity still exists in the save.

#### Parameters

##### listener

(`entity`, `reason`) => `void`

#### Returns

A function that unsubscribes the listener.

() => `void`

***

### persist()

> **persist**(): `void`

Defined in: [packages/prismarine/src/entity/data/live.ts:1464](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1464)

Writes every entity's record into its actor's tags, ready for a save. A dropped stack's
actor record is the item's own tags, which `EntitySerializer.toNBT` writes, and an inert
actor keeps the tags it was loaded with, so neither is given a record.

Called by `World.saveChunks` before it writes anything, rather than once a tick: the
record is a snapshot of state that changes every tick, and nothing reads it until a chunk
is written. The chunk serializer reads it from the actor with every other tag it carries.

#### Returns

`void`

***

### restore()

> **restore**(`record`, `stored`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1514](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1514)

Brings one saved entity back into the runtime.

The store entity is what enters the world, shown through its actor.
Everything the file carried that this server does not model, the actor's
`UniqueID` first among them, moves onto the actor, so the next save
addresses the same actor rather than writing a second one.

#### Parameters

##### record

[`DataEntityRecord`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/persistence/index.md#dataentityrecord)

##### stored

[`StoredActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/EntitySerializer/index.md#storedactor)

What `EntitySerializer` read from the actor NBT.

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when no loaded pack declares its type.

***

### restoreExisting()

> **restoreExisting**(`stored`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1556](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1556)

Migrates a saved actor without runtime state when its pack type is available.

This covers entities saved by an older class-based runtime as well as actors rebuilt from a
provider's lightweight entity snapshot. The type's spawn event initializes current
components, goals, and physics, while the original actor tags stay on the actor for fields
the runtime does not model yet.

#### Parameters

##### stored

[`StoredActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/EntitySerializer/index.md#storedactor)

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

***

### restoreInert()

> **restoreInert**(`stored`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1603](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1603)

Brings back a saved actor that no loaded pack declares, or whose type would not spawn, as
an inert store entity: it keeps its identifier, its position, its tags, its portal
cooldown, a TNT's fuse and every actor record tag, a data entity record among them, is
shown to clients as itself and runs nothing. The next save writes it back as it was loaded, so a world loaded once without the
pack that declares its mobs still has them when the pack comes back.

#### Parameters

##### stored

[`StoredActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/EntitySerializer/index.md#storedactor)

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when the content has no inert type either.

***

### restoreItem()

> **restoreItem**(`stored`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1194](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1194)

Brings a saved dropped stack back as a store entity, from the actor record a chunk carried.

#### Parameters

##### stored

[`StoredActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/EntitySerializer/index.md#storedactor)

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when the record holds no stack.

***

### restoreRecord()

> **restoreRecord**(`record`, `at`, `kept`): [`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

Defined in: [packages/prismarine/src/entity/data/live.ts:1527](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1527)

Brings one entity back into the runtime from its record, at a position, with what the
record does not hold: the actor record tags to carry forward, and the name tag, tags and
status effects the actor record held apart from it.

#### Parameters

##### record

[`DataEntityRecord`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/persistence/index.md#dataentityrecord)

##### at

[`EntityPosition`](https://jsprismarine.dev/api/@jsprismarine/entities/index.md#entityposition)

##### kept

[`KeptActorState`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/live/index.md#keptactorstate)

#### Returns

[`DataEntity`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/DataEntity/classes/DataEntity.md) \| `undefined`

The entity, or undefined when no loaded pack declares its type.

***

### savedRecords()

> **savedRecords**(): `ReadonlyMap`\<[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md), [`DataEntityRecord`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/persistence/index.md#dataentityrecord)\>

Defined in: [packages/prismarine/src/entity/data/live.ts:1477](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1477)

The record [LiveEntityRuntime.persist](#persist) would write for each entity that persists, by
actor, without writing it, so a replay digest can hash what a save holds and change nothing.

#### Returns

`ReadonlyMap`\<[`StoreActor`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/storeActors/classes/StoreActor.md), [`DataEntityRecord`](https://jsprismarine.dev/api/@jsprismarine/prismarine/entity/data/persistence/index.md#dataentityrecord)\>

The records, each keyed by a store actor.

***

### tick()

> **tick**(`tick`, `shouldTick?`): `void`

Defined in: [packages/prismarine/src/entity/data/live.ts:1164](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/prismarine/src/entity/data/live.ts#L1164)

Runs one server tick for eligible entities. Clients are shown what it changed from the
change log, after the world's tick seals.

The spawn loop starts on the first tick because it reads the loaded spawn rules.

#### Parameters

##### tick

`number`

The world's tick counter, which the pools' cadences use.

##### shouldTick?

(`position`) => `boolean`

Optional chunk eligibility rule; omitted callers tick every entity.

#### Returns

`void`
