StartAppOptions
Interface of @v12-engine/client/app
export interface StartAppOptions extends RuntimeOptionsWhat an app of scenes is started with
Members
entries
entries?: readonly SceneEntry[];The list the app starts with: a line for each scene to pick from. With scenes as a list
fullscreenButton
fullscreenButton?: boolean;Whether the app's menus show a button for full screen (StartedApp.fullscreen). On when left out
fullscreenHost
fullscreenHost?: FullscreenHost;A full screen of a shell around the page, in place of the page's: what StartedApp.fullscreen, the menus' button and a game's corner button then ask (a desktop app's, whose web view has no lock of the keys). The page's when left out
game
game?: Game<unknown> | LoadedGame;The game the app is of (createGame): its name over the app (title), and, where scenes is left out, the scenes appScenes makes of it alone (the start screen, the game, the settings, a random map), started on the one the address asks for (sceneAsked) or the start screen
guards
guards?: boolean;Whether the page is kept from behaving like a page while the app is played (campaign plan FS1): no zoom of it (Ctrl and the wheel, Ctrl with + - 0, a pinch), no pull or swipe at its edges, no back swipe, no context menu of the browser (text keeps its own), and on the app's own screens Esc kept from leaving full screen and the pointer kept as the setting keepPointer says. Fetched after the app starts. On when left out
keepPointer
keepPointer?: KeepPointer;When the pointer is kept in the app's own screens until the player chooses (the setting keepPointer): fullscreen when left out
languages
languages?: Languages;The game's languages (GameView.languages, campaign plan LO1), for the app's own screens (its menus, the campaign's, the settings before a game): said in the one the player chose (the setting language), the browser's where the game has it. A game played says things in its view's
navigationWorker
navigationWorker?: NavigationWorkerLike | (() => NavigationWorkerLike);A worker that builds the navigations of its worlds (S37), so that the page does not stand still while a large map is made: a worker of the page's own, whose file calls serveNavigationBuilds() (see navigationWorker). On the page's thread without. What was built is kept either way, and a world made again on the same ground reads it. Given as what makes it (() => new Worker(…)), it is made at the first build: the menu fetches none of it
onGame
onGame?: (client: GameClient) => void | (() => void);Told of each game the app plays, once it is on: its client, a mission's, a free game's, a replay's. What it gives back is called as the game ends (its scene left). What a shell around the page needs of the game playing now: a desktop app that saves it as its window closes
overlays
overlays?: OverlayLooks;What floats over the app's own screens (its menus, its list), as the app draws it: the box of a tooltip, a toast, a dialog, a menu (OverlayLooks). The kit's where one is left out. A game's own are its view's (GameView.hud.overlays)
patience
patience?: number;How many seconds the scene shown is held for one not ready yet, before that comes in as it is, its loading screen and all: a long load says something, and one that hangs does not hold a dead page. 8 when left out
scenes
scenes?: readonly Scene[] | Scenes;The scenes the app can open: a list of them, with the lines of the list it starts with (entries), or scenes made already (createScenes), to add to and look into from code. appScenes({ game }) when left out, with a game
sounds
sounds?: UiSounds;The sounds of the app's own screens as they move, by the addresses of their files (UiSounds: open as a menu comes, hover as the pointer comes onto a button, press as one is pressed), heard through the app's mixer on the interface bus. A game's HUD has its own (GameView.hud.sounds). Silent when left out
start
start?: string;The scene the app starts with, in the place of the list: a game's own menu
target
target: HTMLElement | string;Where on the page the app goes: an element, or a selector of one. The app fills it
title
title?: string;What is over the list. The game's name, or Scenes, when left out
transition
transition?: SceneTransition;How a scene comes in over the one before, once it is ready, unless it says itself (Scene.transition): fade when left out, cut, or a component of the game's own (SceneTransition)
worker
worker?: WorldWorkerLike | (() => WorldWorkerLike);The worker its campaigns' missions run their simulation in (architecture plan C7a), so that a long tick is not a late frame: a worker of the page's own, whose file calls serveCampaign(rules, { missions }) of @v12-engine/client/campaign-worker with the campaign's missions' code. What a mission does on its world runs there, and the page hears back what it won as plain data. Given as what makes it (() => new Worker(…)), it is made as the first mission starts and kept for the app's life, one game at a time. The app's other games (free play, a random map, the editor's Play here) and a campaign that says worker: false are played in the page. In the page when left out