Unique name of the scene.
Map of entities by name.
Whether updates and drawing are paused.
Registers a one-time listener for the specified event.
The listener is automatically removed after the first invocation.
Event name
This emitter for chaining
Emits an event, invoking all registered listeners with the provided arguments.
If the event is "error" and no listeners are registered, the first argument (the error)
will be thrown.
Event name
true if any listeners were invoked, false otherwise
Removes all listeners for the specified event, or all listeners if no event is provided.
Event name
Optionalevent: KOptional event name to clear listeners for
This emitter for chaining
Returns the number of listeners registered for the specified event.
Event name
The event to count listeners for
The number of registered listeners
Updates all non-paused entities in the scene.
Time since last update in seconds
Draws all entities in z-order (higher z = drawn later).
The 2D rendering context
Removes an entity from the scene by name.
The entity to remove
Retrieves an entity by name.
The name of the entity
The entity, or undefined if not found
Container for a collection of entities, handling update/draw loops and z-order sorting.