api.module
This package holds more than this page lists. See all of its files in its world.
README.md
api
campaignKit's front door. Campaign.start(config) gives a level-based game its whole shell from one config table, on the player's own machine: menusKit title, a level-select map (map.style: storybook, parchment, lanterns or list), a dialogueKit story beat before and after each level, the level itself (platformer3dKit by default, or your own runner), results with Next / Retry / map, a finale hook, credits, per-player pause and settings, per-level music and jump / land / checkpoint / death sounds. Call it in play from any script (a component's update is fine: a running config is left alone).
Also: Campaign.status(), Campaign.on(evt, fn) ("state", "level", "finish", "unlock"), Campaign.go(screen, levelId), Campaign.restart(), Campaign.finished(levelId, result) for custom runners, Campaign.setMapStyle(style), Campaign.setSoundSet(set), Campaign.sting(name), Campaign.best(id), Campaign.isUnlocked(id), Campaign.catalogue(). The config's fields are listed in the package README.