Expand description
AppInfo: who a game is, the same on every target: the name players
see, a reverse-DNS id, its version and build, its publisher, the name
its saves are kept under (ADR-0059), and its window’s icon
(WindowIcon, ADR-0061).
A game writes it once, in its shuyi.ron’s app part, and
shuyi app-info writes it as a Rust constant (pub const APP: AppInfo) its binary compiles. A game that keeps its own builds it
here in a const item:
use shuyi_platform::AppInfo;
const APP: AppInfo = AppInfo::new("Moon Garden", "com.example.moon-garden", "0.1.0")
.with_storage("moon_garden")
.with_publisher("Moon Garden's makers");
assert_eq!((APP.storage, APP.build), ("moon_garden", 1));Structs§
- AppInfo
- Who a game is. Build it with
AppInfo::newand thewith_setters: a struct literal doesn’t compile outside this crate, so a new field never breaks a game (ADR-0039). - Window
Icon - A window’s icon: PNG files of 16, 32 and 64 pixels square, which
shuyi app-infodownscales from the game’s one icon (ADR-0061). Build it withWindowIcon::new.