Skip to content

API reference / @jsprismarine/prismarine / network/ReplayManifest

network/ReplayManifest ​

Interfaces ​

ReplayDimensionManifest ​

Defined in: prismarine/src/network/ReplayManifest.ts:15

One resolved dimension input needed to identify the initial level setup.

Properties ​

generator ​

readonly generator: string

Defined in: prismarine/src/network/ReplayManifest.ts:21

The effective generator kind used for this stem.

id ​

readonly id: string

Defined in: prismarine/src/network/ReplayManifest.ts:17

The stem id, such as minecraft:overworld.

type ​

readonly type: string

Defined in: prismarine/src/network/ReplayManifest.ts:19

The dimension type id bound to this stem.


ReplayGameRuleManifest ​

Defined in: prismarine/src/network/ReplayManifest.ts:25

One saved game rule in the form used by the level.

Properties ​

editable ​

readonly editable: boolean

Defined in: prismarine/src/network/ReplayManifest.ts:28

name ​

readonly name: string

Defined in: prismarine/src/network/ReplayManifest.ts:26

value ​

readonly value: number | boolean

Defined in: prismarine/src/network/ReplayManifest.ts:27


ReplayInitialStateManifest ​

Defined in: prismarine/src/network/ReplayManifest.ts:48

Versioned metadata and digests captured at the start of a replay run.

Properties ​

activeContentFingerprint ​

readonly activeContentFingerprint: string

Defined in: prismarine/src/network/ReplayManifest.ts:64

A combined fingerprint for the content and world-generation inputs above.

contentFingerprint ​

readonly contentFingerprint: string

Defined in: prismarine/src/network/ReplayManifest.ts:60

The pack definitions and repository-owned data the server content build resolved.

format ​

readonly format: "jsprismarine-replay-initial-state"

Defined in: prismarine/src/network/ReplayManifest.ts:49

level ​

readonly level: object

Defined in: prismarine/src/network/ReplayManifest.ts:51

dimensions ​

readonly dimensions: readonly ReplayDimensionManifest[]

gameRules ​

readonly gameRules: readonly ReplayGameRuleManifest[]

name ​

readonly name: string

seed ​

readonly seed: string

tick ​

readonly tick: number

weather ​

readonly weather: WeatherState

loadedWorldDigests ​

readonly loadedWorldDigests: readonly (readonly [string, string])[]

Defined in: prismarine/src/network/ReplayManifest.ts:68

Digests of ready, loaded worlds. These are verification values, not restorable chunks.

randomState ​

readonly randomState: ServerReplayRandomState

Defined in: prismarine/src/network/ReplayManifest.ts:66

State of the server's stateful random sources at this boundary.

storageBoundary ​

readonly storageBoundary: ReplayStorageBoundary

Defined in: prismarine/src/network/ReplayManifest.ts:70

Explains which provider-backed state this manifest can verify or restore.

version ​

readonly version: 2

Defined in: prismarine/src/network/ReplayManifest.ts:50

worldgenFingerprint ​

readonly worldgenFingerprint: string

Defined in: prismarine/src/network/ReplayManifest.ts:62

The dimension stems, dimension types, and active Java worldgen registry data.


ReplayStorageBoundary ​

Defined in: prismarine/src/network/ReplayManifest.ts:32

The persisted provider state required to recreate this replay's initial save.

Properties ​

captureAtomic ​

readonly captureAtomic: true

Defined in: prismarine/src/network/ReplayManifest.ts:37

The provider reads its logical state as one synchronous snapshot.

includesUnloadedPersistentState ​

readonly includesUnloadedPersistentState: true

Defined in: prismarine/src/network/ReplayManifest.ts:35

kind ​

readonly kind: "provider-snapshot"

Defined in: prismarine/src/network/ReplayManifest.ts:34

provider ​

readonly provider: string

Defined in: prismarine/src/network/ReplayManifest.ts:33

restoreAtomic ​

readonly restoreAtomic: false

Defined in: prismarine/src/network/ReplayManifest.ts:39

False because LevelDB records and its metadata files use separate storage writes.

restoresWorldState ​

readonly restoresWorldState: true

Defined in: prismarine/src/network/ReplayManifest.ts:40

snapshot ​

readonly snapshot: string

Defined in: prismarine/src/network/ReplayManifest.ts:42

Base64-encoded bytes returned by the named provider.

snapshotDigest ​

readonly snapshotDigest: string

Defined in: prismarine/src/network/ReplayManifest.ts:44

SHA-256 of the decoded snapshot bytes.

Functions ​

deserializeReplayInitialStateManifest() ​

deserializeReplayInitialStateManifest(bytes): ReplayInitialStateManifest

Defined in: prismarine/src/network/ReplayManifest.ts:86

Parses a JSON manifest and rejects unsupported versions or incomplete state.

Parameters ​

bytes ​

Uint8Array

Returns ​

ReplayInitialStateManifest


replayInputFingerprint() ​

replayInputFingerprint(value): string

Defined in: prismarine/src/network/ReplayManifest.ts:74

Hashes JSON-shaped runtime inputs while sorting object and map keys.

Parameters ​

value ​

unknown

Returns ​

string


restoreReplayInitialStateSnapshot() ​

restoreReplayInitialStateSnapshot(provider, manifest): Promise<void>

Defined in: prismarine/src/network/ReplayManifest.ts:106

Restores the persisted part of a replay boundary before its provider opens the world.

Parameters ​

provider ​

Provider

A new, disabled provider of the same type that captured the manifest.

manifest ​

ReplayInitialStateManifest

The validated initial-state manifest to restore.

Returns ​

Promise<void>

Throws ​

When the manifest or snapshot digest is invalid.

Throws ​

When the provider differs or does not support replay restoration.


serializeReplayInitialStateManifest() ​

serializeReplayInitialStateManifest(manifest): Buffer

Defined in: prismarine/src/network/ReplayManifest.ts:80

Serializes a manifest as UTF-8 JSON bytes.

Parameters ​

manifest ​

ReplayInitialStateManifest

Returns ​

Buffer