mini_arcade_core.engine.game¶
Engine core module defining the Engine class and configuration.
Classes¶
Runtime dependencies required by the Engine. |
|
Core engine object responsible for the main loop and active scene. |
Module Contents¶
- class mini_arcade_core.engine.game.EngineDependencies¶
Runtime dependencies required by the Engine.
- Variables:
backend – Backend implementation used by the runtime.
scene_registry – Scene registry available to the scene adapter.
gameplay_settings – Optional gameplay settings payload.
- backend: mini_arcade_core.backend.Backend¶
- scene_registry: mini_arcade_core.scenes.registry.SceneRegistry¶
- gameplay_settings: mini_arcade_core.engine.gameplay_settings.GamePlaySettings | dict[str, Any] | None = None¶
- class mini_arcade_core.engine.game.Engine(config: mini_arcade_core.engine.engine_config.EngineConfig, dependencies: EngineDependencies)¶
Core engine object responsible for the main loop and active scene.
- config¶
- backend¶
- managers¶
- services¶
- property running: bool¶
Check if the game is currently running.
- quit()¶
Request that the main loop stops.
- run(initial_scene: str | None = None)¶
Run the main loop starting with the given scene.
This is intentionally left abstract so you can plug pygame, pyglet, or another backend.
- Parameters:
initial_scene (str | None) – Optional scene id to start with.
- resolve_world() object | None¶
Resolve and return the current gameplay world.
- Returns:
The current gameplay world, or None if not found.
- Return type:
object | None