Entities · function
createWorldSnapshot
An empty slot, to be filled by World.saveInto and reused for the life of a rewind ring.
Explained in Entities.
function createWorldSnapshot(): WorldSnapshotimport { createWorldSnapshot } from '@driftengine/entities';In depth
Its arrays are zero-length and grow to the world's shape on the first save, so a ring of eight costs eight small objects up front and allocates nothing on the ticks that matter.