API reference
API reference
The public types of the MicroEngine SDK 0.6.0-alpha.1, one page per namespace and per type: signatures, parameters, default
values and the descriptions written in the engine’s source. It covers the four engine packages (MicroEngine,
MicroEngine.Sdl, MicroEngine.Raylib, MicroEngine.Desktop); the microengine tool is documented in
The microengine tool.
This reference says what each member is. How the pieces work together, with examples, is in the engine manual; every page here links to its chapter under “Guide”. New to MicroEngine? Start with the tutorial.
| Namespace | Contains | Guide |
|---|---|---|
| MicroEngine.Achievements | Achievements as an optional engine module: the module that registers the tracker as a service of the engine and writes its progress. | Achievements |
| MicroEngine.Audio.Retro | Retro sound in code: sound effects described by parameters (in the spirit of sfxr), the synthesizer that renders them, instruments and waveforms, and the tiny step sequencer behind Song. |
Synthesized sound effects |
| MicroEngine.Audio | Sound effects and music: the one mixer every backend plays through (voices with handles and priorities, buses, music streams, exact-frame scheduling), the sound bank and music games play through, the audio device contract, offline rendering for tests, WAV and OGG decoding, synthesis. | Audio |
| MicroEngine.Content | Content: the asset store under Game.Assets (typed handles, scopes that share and release, the loader registry, the reserved import step) and content sources beyond folders (zip archives, files a host lists). | Assets |
| MicroEngine.Core | The game and its loop: Game, settings, runners and sessions, launchers and platform composition, scripted input, saves, content files, achievements, application identity, the headless platform. |
Game lifecycle and time |
| MicroEngine.Desktop | The desktop launcher with the official desktop platforms (SDL 3, raylib, SDL software, headless). | Backends and platforms |
| MicroEngine.Graphics.Devices | The graphics device contract every backend implements: capabilities and the typed capability error, textures, render targets, samplers, buffers, pipelines, command lists with passes, readback and the surface target; the core validation backends inherit and the CPU reference device. | The graphics device |
| MicroEngine.Graphics | Drawing: the renderer contract, images in code and from PNG, sprites and atlases, animation, camera, parallax, particles, light, the pixel font. | Graphics |
| MicroEngine.Hosting | Hosting: the launcher model every host shares (launch requests and their rules, platform selection, the host environment) and the composition a game configures once with its Configure entry point. | Composing a game for every platform |
| MicroEngine.Input | Input: device events with ids (keys, text, pointers and touches, wheel, gamepads), players and device pairing, input layers, and actions over them: bindings and their persistence, analog values, on-screen controls, prompts, custom sources. | Input |
| MicroEngine.Kernel | The kernel: engine composition (builder, services, modules, capabilities), the frame schedule and its phases, loop-owned time, engine events, logging and generational handles. | Modules and the frame schedule |
| MicroEngine.Physics.Tiles | The tile backend of the physics contract: tile grids as static geometry, the exact swept mover, one-way platforms and moving solids that push and carry bodies. | Physics worlds |
| MicroEngine.Physics | The 2D physics contract: worlds of bodies owned by entities, box shapes with collision layers, collide-and-slide moves with their contacts, ray and overlap queries, sensors with buffered events, declared capabilities and the typed capability error, and the module that steps worlds and writes body poses to transforms. | Physics worlds |
| MicroEngine.Platform | The platform contracts: the host (clock, event pump, main surface, capabilities, whether it may block), the surface, display pacing and precise waits, storage for saves and content sources. | The platform host |
| MicroEngine.Raylib | The raylib platform for desktops (in the published SDK, also the browser platform). | Backends and platforms |
| MicroEngine.Saves | Saves as an optional engine module: the module that registers a save store as a service of the engine. | Persistence |
| MicroEngine.Scenes | The scene stack (scenes, transitions, coroutines and tweens) and the scene world: entity ids, transforms with a hierarchy, typed attachments, interpolation for drawing and world clocks. | Scenes |
| MicroEngine.Sdl | The SDL 3 platform: Windows, Linux, macOS, Android, iOS and browsers (WebAssembly), with the browser launcher and the browser page it reads. | Backends and platforms |
| MicroEngine.UI | Widgets: labels, buttons, panels, stacks, text fields, dialogue boxes, menus, typewriter text, toasts, themes, focus and the UI input layer. | UI widgets |
| MicroEngine.World | Tile layers, collision grids, swept movement against tiles (TileMotion), autotiling and drawing tiles. |
Tile maps and collision |
| MicroEngine | Basic value types: colours, rectangles, maths and easing helpers. | Graphics |
Reading a page
- Signatures are C#. Optional parameters show their default value (
float fadeSeconds = 0.4);?marks a value that may be null. - Records (
GameSettings,SfxParams,TouchLayout…) are configured with object initialisers and copied withwith:new GameSettings("My Game") { Background = Color.Hex("1a1c2c") }. - Examples on type pages are short fragments that name your own classes (
TitleScene,player); complete programs that compile and run are in the focused examples and the tutorial. - Platform types (
SdlPlatform,RaylibPlatform,HeadlessPlatform) implement the sameIPlatformcontract; a game never names them, its launcher does (Backends and platforms). - The SDK is in Alpha: these APIs may change between 0.x versions, and every such change is listed in the migration notes.