Skip to content

recordGame beta ​

Function of @v12-engine/engine

ts
export declare function recordGame(world: World, options: RecordOptions): ReplayRecorder;

Records a game played in the page (RecordOptions): as its start and its players' commands (kind: 'commands', the default: recordCommands), or as an observer from player's side sees it, what changed sendRate times a second (kind: 'frames'). Frames are answered at once, as by a watcher who missed nothing, so what is kept is what changed and not the whole world again