Log inGet started
Package

wld.toolbox

Newest version

This package holds more than this page lists. See all of its files in its world.

README.md

wld.play

Enters play mode and leaves the gameplay simulation running. It flips engine.mode to "play" when the engine is elsewhere, and resumes the standing gameplay pause when the engine is already in play; a pause another caller holds is theirs to settle, so the call refuses and names them rather than lifting it. The flip rebuilds the scene for play over the frames after it, and the call returns once that rebuild has ended. The calling agent takes part in the play session from then on, so its /source writes land on the play shadow with the session's, to be settled when leaving play (see wld.edit).

Returns { mode, paused, resumed, settled, timings }: the run state the call produced, and whether the simulation it met was stopped and is now running. timings says where the call's time went, in whole milliseconds: totalMs for the call, writeMs for the mode write, rebuildMs for the wait on the scene rebuild, and the frames the call spanned; a call that waited on a rebuild also carries its phases (drain, teardown, load, respawn, settle, review) and its loads (each scene load's name, the ms the rebuild spent in its call, its instantiate, its records and whether it has settled), and layers.lastRebuild() reports that rebuild in full.