Skip to main content

Module platform_facts

Module platform_facts 

Source
Expand description

PlatformFacts: where the game runs, as its screens see it (Ctx::platform). A fact is constant for a run: the platform’s backend says them before the game loads, read from its target’s profile (TargetProfile) or from the system.

A screen asks a fact instead of a cfg!, so a test can run it as any target: offer Quit only where can_quit. The facts are the screens’. A game’s rules never read them, so a replay plays the same on every target.

Structs§

PlatformFacts
Where the game runs: its target’s id, and what that target lets a game do and the player press.

Enums§

Quit
How the player leaves a game on a target.