Repository navigation
API Interface EngineOptions
Defined in: src/engine/core/Engine.ts:24
Myco Engine core API (ADR 0135): what the public myco module (src/myco.ts) re-exports, alongside
the first-party plugins' runtime halves. three.js and Rapier are never part of this surface
(ADR 0010).
assets?: AssetSource | AssetSource[];Defined in: src/engine/core/Engine.ts:31
Asset sources, e.g. Assets.fromGlob(import.meta.glob("./**/*.png", { eager: true, import: "default" })).
Registered while the Engine lives; dispose() removes them (ADR 0319).
bootstrap?:
| BootstrapSetting
| Bootstrap;Defined in: src/engine/core/Engine.ts:63
Which Worlds to create (ADR 0032): a declarative config or a code bootstrap. Default: the
project's bootstrap setting, else the default bootstrap (one World).
container?: HTMLElement;Defined in: src/engine/core/Engine.ts:33
Element the canvas is placed in. Omit (or pass headless: true) to run without rendering.
headless?: boolean;Defined in: src/engine/core/Engine.ts:34
kind?: WorldKind;Defined in: src/engine/core/Engine.ts:52
"runtime" for games (default); "editor" for the scene editor's Editor World (ADR 0016, 0022).
Without a bootstrap option, an editor (or server) Engine gets that one World and ignores the
project's bootstrap.
loadScript?: (path) => Promise<Bootstrap>;Defined in: src/engine/core/Engine.ts:69
Imports a code bootstrap's script ("bootstrap": "scripts/Bootstrap.ts") and returns its
bootstrap export. The editor passes its script loader (ADR 0030); games import the function
and pass it as bootstrap instead.
string
Promise<Bootstrap>
project?: ProjectSettingsInput;Defined in: src/engine/core/Engine.ts:26
Project settings (usually the game's project.json).
quality?: "player" | "keep";Defined in: src/engine/core/Engine.ts:58
Graphics quality (ADR 0050, 0055): "player" (default) activates the player's saved tier, or
detects one when the project allows it; "keep" leaves the active tier alone (the editor's
Play mode, so its previewed tier stays).
storage?: StorageBackend;Defined in: src/engine/core/Engine.ts:46
Storage backend for saves/settings (ADR 0024). Defaults to files under Tauri, IndexedDB in browsers, memory when headless.
This wiki is generated from docs/wiki/ and the myco module's source on every push to master. Change pages there in a pull request: edits made here are not kept.
Basics
Gameplay
Rendering
Audio
- Playing sound
- Why is there no sound?
- Playlists
- Interactive music
- Sound generators
- Spatial audio
- Audio mixer
- Live mixing
- Loudness
- Audio profiler
- Audio takes
Reference