@moku-labs/game 0.15.55 → 0.15.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/page.d.mts +1 -1
- package/dist/app/system.d.mts +3 -3
- package/dist/app.d.mts +3 -3
- package/dist/app.mjs +1 -1
- package/dist/assets.d.mts +1 -1
- package/dist/{commands-C7qVsYsu.d.mts → commands-B208rrQE.d.mts} +5 -5
- package/dist/control.d.mts +4 -4
- package/dist/{define-BeFMCdMd.d.mts → define-U9QpSza7.d.mts} +2 -2
- package/dist/{headless-C4YDmZv1.d.mts → headless-7IBMNGda.d.mts} +1 -1
- package/dist/{index-BgJZZmqB.d.mts → index-m2g9-8_E.d.mts} +24 -11
- package/dist/index.d.mts +5 -5
- package/dist/index.mjs +1 -1
- package/dist/inspect.d.mts +6 -6
- package/dist/jsx-dev-runtime.d.mts +1 -1
- package/dist/jsx-runtime.d.mts +1 -1
- package/dist/{runtime-DAid26Eo.d.mts → runtime-DLCg0viS.d.mts} +1 -1
- package/dist/{src-9Oy89OMt.mjs → src-CJtaTza4.mjs} +1163 -280
- package/dist/testing.d.mts +4 -4
- package/dist/testing.mjs +1 -1
- package/dist/{types-BdwZpZce.d.mts → types-BEW2Y3au.d.mts} +2 -2
- package/dist/{types-VWk999Gp.d.mts → types-C0As3dEe.d.mts} +2 -2
- package/dist/{types-D9YSrw2Z.d.mts → types-C6PML3Il.d.mts} +310 -40
- package/dist/{types-Dj8OQDCY.d.mts → types-DuqbyY_j.d.mts} +4 -4
- package/dist/{types-CGofZbu2.d.mts → types-FtzEwwWY.d.mts} +1 -1
- package/dist/{visual-CugfNrMB.d.mts → visual-CpTnNnas.d.mts} +6 -6
- package/dist/visual.d.mts +1 -1
- package/llms.txt +4 -3
- package/package.json +1 -1
package/dist/testing.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as createApp } from "./index-
|
|
3
|
-
import { b as saveOf, v as WithGameState, y as memory } from "./types-
|
|
4
|
-
import { a as createHeadless, i as ReproResult, n as HeadlessGame, o as runRepro, r as Repro, s as stepFrames, t as HeadlessApp } from "./headless-
|
|
1
|
+
import { Ar as Json, Dn as NodeTable, Fn as Hint, In as NodeFx, Sr as ClockSource, jn as Descriptor, wr as FakeClock, xn as AnyFlow, yn as FeaturePlugin } from "./types-C6PML3Il.mjs";
|
|
2
|
+
import { t as createApp } from "./index-m2g9-8_E.mjs";
|
|
3
|
+
import { b as saveOf, v as WithGameState, y as memory } from "./types-DuqbyY_j.mjs";
|
|
4
|
+
import { a as createHeadless, i as ReproResult, n as HeadlessGame, o as runRepro, r as Repro, s as stepFrames, t as HeadlessApp } from "./headless-7IBMNGda.mjs";
|
|
5
5
|
import { AnyPluginInstance } from "@moku-labs/core";
|
|
6
6
|
|
|
7
7
|
//#region src/plugins/clock/fake.d.ts
|
package/dist/testing.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { an as type, en as refuseStart, m as flattenFeatures, nn as exit, t as createApp } from "./src-
|
|
1
|
+
import { an as type, en as refuseStart, m as flattenFeatures, nn as exit, t as createApp } from "./src-CJtaTza4.mjs";
|
|
2
2
|
import { n as saveOf, t as memory } from "./memory-CWlqhS7l.mjs";
|
|
3
3
|
import { n as fakeClock } from "./fake-hnJcJeYf.mjs";
|
|
4
4
|
import { i as stepFrames, r as runRepro, t as createHeadless } from "./headless-CCiUwvlp.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as HeadlessApp } from "./headless-
|
|
1
|
+
import { Ar as Json, zr as Snapshot } from "./types-C6PML3Il.mjs";
|
|
2
|
+
import { t as HeadlessApp } from "./headless-7IBMNGda.mjs";
|
|
3
3
|
import { Log } from "@moku-labs/common/browser";
|
|
4
4
|
|
|
5
5
|
//#region src/plugins/flow/doors/types.d.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { $ as PixiModule, A as SyncApi, An as TypeTag,
|
|
2
|
-
import { N as InputApi, R as I18nApi, X as StylesState, c as UiNode, i as Finding, l as LayoutState, n as ElementChange, o as JsxState, r as ElementMotion, w as TextApi } from "./types-
|
|
1
|
+
import { $ as PixiModule, $n as AnyComponent, A as SyncApi, An as TypeTag, Ar as Json, Dr as Api$6, Gn as NumericFields, Jn as ReducedMotion, Kr as Events$5, O as FilterSlot, Q as PixiFilter, Rn as AnchorTarget, Vn as Ease, Wn as MotionHandle, Xn as TrackOptions, Xr as Api$1, Y as Api$4, Zn as TrackSegment, ai as Events$2, b as Events$4, et as PixiSprite, ft as FilterCache, gr as Api$3, ir as ComponentType, jn as Descriptor, k as FilterSlotInputs, kr as Events$3, nn as Api$2, nr as ComponentHandle, oi as Require, or as Entity, s as Events$1, t as Api$5, tr as AnyComponentValue, tt as PixiTexture, ut as Point } from "./types-C6PML3Il.mjs";
|
|
2
|
+
import { N as InputApi, R as I18nApi, X as StylesState, c as UiNode, i as Finding, l as LayoutState, n as ElementChange, o as JsxState, r as ElementMotion, w as TextApi } from "./types-FtzEwwWY.mjs";
|
|
3
3
|
import { Log } from "@moku-labs/common/browser";
|
|
4
4
|
import { PluginCtx } from "@moku-labs/core";
|
|
5
5
|
|
|
@@ -1912,7 +1912,7 @@ type SystemTiming = {
|
|
|
1912
1912
|
ms: Float64Array;
|
|
1913
1913
|
};
|
|
1914
1914
|
declare namespace types_d_exports$4 {
|
|
1915
|
-
export { AnyComponentType, AnyComponentValue, AnyProjectionSpec, AnySystem, Api$3 as Api, Cause, ChangeHook, ComponentHandle, ComponentSchema, ComponentType, ComponentValue, Config$4 as Config, Deps$4 as Deps, DescriptionNode, Ease, EcsApi, EcsModule, Entity, EntityDiff, EntitySnapshot, Events$4 as Events, Explained, FrameDiff, GameSystemDefinition, InitialOnly, InitialOnlyPair, KernelSlice$4 as KernelSlice, LayerSort, LayerSpec, ModelCommitted, Motion, MotionCause, MotionHandle, Mut, Narrowed, NumericFields, Owner, ProjectionApi, ProjectionKey, ProjectionModule, ProjectionMotion, ProjectionSpec, QueryTerm, QueryTuple, ReducedMotion, ResourceType, RestOptions, State$4 as State, SystemContext, SystemContextOf, SystemDefinition, SystemFor, SystemTiming, TagType, TrackOptions, TrackSegment, TweenDriver, TweenOptions, ViewHandle, ViewOutput, WorldCtx, WorldMode, WorldPhase, WorldSnapshot };
|
|
1915
|
+
export { AnyComponentType, AnyComponentValue, AnyProjectionSpec, AnySystem, Api$3 as Api, Cause, ChangeHook, ComponentHandle, ComponentSchema, ComponentType, ComponentValue, Config$4 as Config, Deps$4 as Deps, DescriptionNode, Ease, EcsApi, EcsModule, Entity, EntityDiff, EntitySnapshot, Events$4 as Events, Explained, FrameDiff, GameSystemDefinition, InitialOnly, InitialOnlyPair, KernelSlice$4 as KernelSlice, LayerSort, LayerSpec, ModelCommitted, Motion, MotionCause, MotionHandle, Mut, Narrowed, NumericFields, Owner, ProjectionApi, ProjectionKey, ProjectionModule, ProjectionMotion, ProjectionSpec, QueryTerm, QueryTuple, ReducedMotion, ResourceType, RestOptions, SceneSwitch, State$4 as State, SystemContext, SystemContextOf, SystemDefinition, SystemFor, SystemTiming, TagType, TrackOptions, TrackSegment, TweenDriver, TweenOptions, ViewHandle, ViewOutput, WorldCtx, WorldMode, WorldPhase, WorldSnapshot };
|
|
1916
1916
|
}
|
|
1917
1917
|
/**
|
|
1918
1918
|
* world plugin events.
|
|
@@ -3729,6 +3729,22 @@ type InitialOnlyPair<Value extends object> = readonly [ComponentHandle<Value>, r
|
|
|
3729
3729
|
* ```
|
|
3730
3730
|
*/
|
|
3731
3731
|
type InitialOnly<Values extends readonly object[]> = { readonly [Index in keyof Values]: InitialOnlyPair<Values[Index]> };
|
|
3732
|
+
/**
|
|
3733
|
+
* A scene switch, as a plugin hands it to a projection with `projection.feed`: the scene left, the scene entered, and
|
|
3734
|
+
* the share of the switch's bundles loaded, 0 to 1. The projection's `from` reads it as its third argument. `scenes`
|
|
3735
|
+
* feeds its leave loader one: `{ from: current, to: current, progress: 0 }` while the scene stands, then the switch.
|
|
3736
|
+
*
|
|
3737
|
+
* @example
|
|
3738
|
+
* ```ts
|
|
3739
|
+
* // 300 ms into the ward → board switch, half of the board's bundles are loaded.
|
|
3740
|
+
* const sw: SceneSwitch = { from: "ward", to: "board", progress: 0.5 };
|
|
3741
|
+
* ```
|
|
3742
|
+
*/
|
|
3743
|
+
type SceneSwitch = {
|
|
3744
|
+
readonly from: string;
|
|
3745
|
+
readonly to: string;
|
|
3746
|
+
readonly progress: number;
|
|
3747
|
+
};
|
|
3732
3748
|
/**
|
|
3733
3749
|
* One projection: keyed items of the model turned into entities. `Item` is inferred from the
|
|
3734
3750
|
* return of `from`; `layer` and `lift` keep their literal types so a scene can check them.
|
|
@@ -3751,7 +3767,33 @@ type ProjectionSpec<Item, LayerName extends string, LiftName extends string, Pla
|
|
|
3751
3767
|
readonly name: string;
|
|
3752
3768
|
readonly layer: LayerName;
|
|
3753
3769
|
readonly lift?: LiftName;
|
|
3754
|
-
|
|
3770
|
+
/**
|
|
3771
|
+
* The items of the projection, read from the committed state: a list, keyed by `key`, or one plain object, a screen
|
|
3772
|
+
* drawn under the name of the projection; `undefined` or `null` shows nothing. The third argument is the switch
|
|
3773
|
+
* another plugin last handed this projection with `projection.feed`, `undefined` for a projection never fed: the
|
|
3774
|
+
* leave loader of a scene reads where the switch goes and how far it loaded. A `from` with two parameters reads the
|
|
3775
|
+
* state alone, as before.
|
|
3776
|
+
*
|
|
3777
|
+
* @param player - The `player` root of the committed state.
|
|
3778
|
+
* @param session - The `session` root of the committed state.
|
|
3779
|
+
* @param sw - The switch last fed, or `undefined`.
|
|
3780
|
+
* @returns The items, or the one item of a screen.
|
|
3781
|
+
* @example
|
|
3782
|
+
* ```ts
|
|
3783
|
+
* // The leave loader of a game: where the switch goes and its progress.
|
|
3784
|
+
* export const loading = projection({
|
|
3785
|
+
* name: "screens.loading",
|
|
3786
|
+
* layer: "veil",
|
|
3787
|
+
* from: (_player: Player, _session: Session, sw: SceneSwitch | undefined) => ({
|
|
3788
|
+
* to: sw?.to ?? "",
|
|
3789
|
+
* progress: sw?.progress ?? 0
|
|
3790
|
+
* }),
|
|
3791
|
+
* view: loader => loaderView(loader)
|
|
3792
|
+
* });
|
|
3793
|
+
* // `scenes` fed it { from: "ward", to: "board", progress: 0.5 }: the item is { to: "board", progress: 0.5 }.
|
|
3794
|
+
* ```
|
|
3795
|
+
*/
|
|
3796
|
+
from(player: Player, session: Session, sw: SceneSwitch | undefined): readonly Item[] | Item; /** Omitted when `from` returns one plain object: the key is then the name of the projection. */
|
|
3755
3797
|
key?(item: Item): string;
|
|
3756
3798
|
view(item: Item): ViewOutput;
|
|
3757
3799
|
readonly motion?: ProjectionMotion<Item>;
|
|
@@ -3836,8 +3878,8 @@ type ProjectionSpec<Item, LayerName extends string, LiftName extends string, Pla
|
|
|
3836
3878
|
type AnyProjectionSpec = {
|
|
3837
3879
|
readonly name: string;
|
|
3838
3880
|
readonly layer: string;
|
|
3839
|
-
readonly lift?: string;
|
|
3840
|
-
from(player: Json, session: Json): unknown;
|
|
3881
|
+
readonly lift?: string; /** The items of `ProjectionSpec.from`, their type erased; the third argument is the switch last fed. */
|
|
3882
|
+
from(player: Json, session: Json, sw: SceneSwitch | undefined): unknown;
|
|
3841
3883
|
key?(item: unknown): string;
|
|
3842
3884
|
view(item: unknown): ViewOutput;
|
|
3843
3885
|
readonly motion?: AnyProjectionMotion; /** The `initialOnly` pairs, their field names no longer tied to the component. */
|
|
@@ -4054,7 +4096,7 @@ type ProjectionState = {
|
|
|
4054
4096
|
* The game clock at the start of this frame (world's `input` phase), or at the start of a scene build in its own
|
|
4055
4097
|
* frame: what `left()` counts from, for a scene build and a warm window alike.
|
|
4056
4098
|
*/
|
|
4057
|
-
frameStart: number; /** The warm record of every mounted projection that declares `warm
|
|
4099
|
+
frameStart: number; /** The warm record of every mounted projection that declares `warm` or is held, by projection name. */
|
|
4058
4100
|
warm: Map<string, WarmRecord>; /** The same records in mounted order: the order the warm step takes them in. */
|
|
4059
4101
|
warmList: WarmRecord[];
|
|
4060
4102
|
/**
|
|
@@ -4070,6 +4112,27 @@ type ProjectionState = {
|
|
|
4070
4112
|
*/
|
|
4071
4113
|
warmStale: boolean; /** Milliseconds per frame the building of a warm view may take, read from the frame rate when the work starts. */
|
|
4072
4114
|
warmBudgetMs: number;
|
|
4115
|
+
/**
|
|
4116
|
+
* The projections `hold` mounted and `show` has not released: a reconcile shows none of their items, and their
|
|
4117
|
+
* record keeps `from`'s first item built and hidden. `unmount`, the clear and `onStop` forget a name.
|
|
4118
|
+
*/
|
|
4119
|
+
held: Set<string>;
|
|
4120
|
+
/**
|
|
4121
|
+
* The names `show` released, and the shown ones `feed` changed, since the last reconcile: the next reconcile
|
|
4122
|
+
* reconciles them by name. A name is on it once.
|
|
4123
|
+
*/
|
|
4124
|
+
showing: string[];
|
|
4125
|
+
/**
|
|
4126
|
+
* The switch `feed` last handed each projection, by name: what `from` reads as its third argument. The public
|
|
4127
|
+
* `unmount`, the clear and `onStop` forget it; a `hold` or a `mount` that places a mounted name again keeps it.
|
|
4128
|
+
*/
|
|
4129
|
+
fed: Map<string, SceneSwitch>;
|
|
4130
|
+
/**
|
|
4131
|
+
* The switch a held projection's warm step reads `from` with, by name: set by the first `feed` after `hold`, so a
|
|
4132
|
+
* later feed never makes the held item differ; dropped by `hold`, `show` and every unmount. Without one the warm step
|
|
4133
|
+
* reads `fed`, the value stored when `hold` ran.
|
|
4134
|
+
*/
|
|
4135
|
+
heldFed: Map<string, SceneSwitch>;
|
|
4073
4136
|
};
|
|
4074
4137
|
/**
|
|
4075
4138
|
* Where a warm record stands: nothing held (`"cold"`), its view held and still built by ui and the renderer
|
|
@@ -4077,8 +4140,9 @@ type ProjectionState = {
|
|
|
4077
4140
|
*/
|
|
4078
4141
|
type WarmPhase = "cold" | "building" | "ready" | "shown";
|
|
4079
4142
|
/**
|
|
4080
|
-
* The warm window of one mounted projection: the item `warm` gave,
|
|
4081
|
-
* its key. A record lives while its projection is mounted; its view
|
|
4143
|
+
* The warm window of one mounted projection: the item `warm` gave, or `from`'s first item while the projection is held,
|
|
4144
|
+
* and the view of it held hidden until `from` shows its key. A record lives while its projection is mounted; its view
|
|
4145
|
+
* is spawned, patched and dropped in place.
|
|
4082
4146
|
*/
|
|
4083
4147
|
type WarmRecord = {
|
|
4084
4148
|
/** The projection. */name: string; /** The key of the held item; absent while nothing is held. */
|
|
@@ -4092,8 +4156,8 @@ type WarmRecord = {
|
|
|
4092
4156
|
entities: Set<Entity>;
|
|
4093
4157
|
phase: WarmPhase;
|
|
4094
4158
|
/**
|
|
4095
|
-
* The state
|
|
4096
|
-
* threw, so a throw is logged once per commit and not every frame.
|
|
4159
|
+
* The state the item was last read against: the step reads it again only after a commit, a `hold` or a `show`.
|
|
4160
|
+
* Kept when `warm`, `from` or `view` threw, so a throw is logged once per commit and not every frame.
|
|
4097
4161
|
*/
|
|
4098
4162
|
seen?: Snapshot;
|
|
4099
4163
|
};
|
|
@@ -4230,6 +4294,79 @@ type ProjectionApi = {
|
|
|
4230
4294
|
* ```
|
|
4231
4295
|
*/
|
|
4232
4296
|
unmount(names: readonly string[]): void;
|
|
4297
|
+
/**
|
|
4298
|
+
* Mounts projections held: the checks and the places of `mount`, but a held projection shows none of its items, and
|
|
4299
|
+
* every name is reconciled at once, direct, so one that showed views drops them. Its `from`'s first item (keyed by
|
|
4300
|
+
* `key`, or by the name of the projection) is kept built and hidden instead, as a warm window keeps its item: in the
|
|
4301
|
+
* idle time of frames, under the warm budget, never drawn, never hit; `isBuilding` answers true for its view and for
|
|
4302
|
+
* what `adopt` marks, `entityOf` and `entitiesOf` nothing. A commit writes into the held view as into a warm one; a
|
|
4303
|
+
* restore, a load, a forced rerun and the start of a scene build drop it as they drop a warm one, to be built again.
|
|
4304
|
+
* It stays held until `show` or `unmount`. A projection that declares `warm` holds `from`'s item while it is held,
|
|
4305
|
+
* and warms its own item again once shown and closed. Only a drawing renderer and a live world build it, as for a
|
|
4306
|
+
* warm window; elsewhere nothing is built and `show` spawns the view. Nothing is held when the call throws.
|
|
4307
|
+
*
|
|
4308
|
+
* @param names - Names of the projections to hold.
|
|
4309
|
+
* @param owner - Who owns the entities of these projections.
|
|
4310
|
+
* @throws {Error} For an unknown name, or a `layer` or `lift` the scene does not declare.
|
|
4311
|
+
* @example
|
|
4312
|
+
* ```ts
|
|
4313
|
+
* // `scenes`: the ward stands; its leave loader `loading` is built ahead for the next switch, hidden.
|
|
4314
|
+
* const world = ctx.require(worldPlugin);
|
|
4315
|
+
* world.projection.hold(["loading"], { kind: "plugin", name: "scenes" });
|
|
4316
|
+
* world.projection.entitiesOf("loading"); // []: nothing shows over the ward
|
|
4317
|
+
* world.projection.isBuilding(1_048_620); // true a frame later: the loader's root, built in idle frames
|
|
4318
|
+
* ```
|
|
4319
|
+
*/
|
|
4320
|
+
hold(names: readonly string[], owner: Owner): void;
|
|
4321
|
+
/**
|
|
4322
|
+
* Shows a held projection: it is held no more, and the next reconcile (the `input` phase of the next frame) shows its
|
|
4323
|
+
* `from`'s item, also while a scene is built aside. The held view is adopted: the same entity, no spawn. An item with
|
|
4324
|
+
* the content of the held one runs no `view` and writes nothing; another one has the difference written directly,
|
|
4325
|
+
* with no `change` hook. The `enter` and `loop` hooks play as for a new view; a world that is not live shows it
|
|
4326
|
+
* direct. A held view still in work is shown as it stands, and ui builds the rest of its root in one block. With no
|
|
4327
|
+
* held view (a headless app, a paused world) the reconcile spawns it as a mount does. A name that is not held:
|
|
4328
|
+
* nothing.
|
|
4329
|
+
*
|
|
4330
|
+
* @param name - The held projection.
|
|
4331
|
+
* @example
|
|
4332
|
+
* ```ts
|
|
4333
|
+
* // `scenes`, in the renderer's `due` of a switch that took 400 ms: the loader built while the ward stood is shown.
|
|
4334
|
+
* const world = ctx.require(worldPlugin);
|
|
4335
|
+
* world.projection.show("loading");
|
|
4336
|
+
* world.projection.entityOf("loading", "loading"); // undefined until the next frame's reconcile
|
|
4337
|
+
* world.projection.entityOf("loading", "loading"); // 1_048_620 the next frame: the same root, no spawn
|
|
4338
|
+
* world.projection.show("hud"); // nothing: the HUD is not held
|
|
4339
|
+
* ```
|
|
4340
|
+
*/
|
|
4341
|
+
show(name: string): void;
|
|
4342
|
+
/**
|
|
4343
|
+
* Hands a projection the scene switch its `from` reads as its third argument (`scenes` feeds its leave loader).
|
|
4344
|
+
* A value equal field by field to the one stored (`from`, `to` and `progress`, each with `===`) changes nothing and
|
|
4345
|
+
* allocates nothing. Any other value is stored as it is, not copied: feed a new object for a new value, never one
|
|
4346
|
+
* changed in place (its fields are read-only). Then what happens depends on the projection:
|
|
4347
|
+
* - Held (`hold`): nothing more. The held view keeps the value of the first feed after `hold` (or the one stored
|
|
4348
|
+
* when `hold` ran), also through a commit, so a feed never builds it again; `show` reads the latest value and
|
|
4349
|
+
* writes the difference into the held view once.
|
|
4350
|
+
* - Mounted and shown: the next reconcile (the `input` phase of the next frame) reads its `from` again by name, with
|
|
4351
|
+
* no commit. A changed item is a change of a live view under the rules of any commit: an `enter` that still plays
|
|
4352
|
+
* is cancelled, a `change` hook runs. It costs one reconcile of that projection.
|
|
4353
|
+
* - Not mounted, or unknown: only stored; a later `mount` or `hold` reads it.
|
|
4354
|
+
*
|
|
4355
|
+
* `unmount` forgets the value of its names, and so do the clear and `onStop`; a `hold` or a `mount` that places a
|
|
4356
|
+
* mounted name again keeps it.
|
|
4357
|
+
*
|
|
4358
|
+
* @param name - The projection.
|
|
4359
|
+
* @param sw - The switch: the scene left, the scene entered and the share of its bundles loaded.
|
|
4360
|
+
* @example
|
|
4361
|
+
* ```ts
|
|
4362
|
+
* // `scenes`, 300 ms into the ward → board switch: the shown loader gets half of the board's bundles loaded.
|
|
4363
|
+
* ctx.require(worldPlugin).projection.feed("screens.loading", { from: "ward", to: "board", progress: 0.5 });
|
|
4364
|
+
* // The next frame's reconcile calls the loader's from(player, session, { from: "ward", to: "board", progress: 0.5 }).
|
|
4365
|
+
* ctx.require(worldPlugin).projection.feed("screens.loading", { from: "ward", to: "board", progress: 0.5 });
|
|
4366
|
+
* // An equal value: no reconcile, 0 B.
|
|
4367
|
+
* ```
|
|
4368
|
+
*/
|
|
4369
|
+
feed(name: string, sw: SceneSwitch): void;
|
|
4233
4370
|
/**
|
|
4234
4371
|
* A drop with no commit: cancels the view's motions and plays settle for every loose component.
|
|
4235
4372
|
* A view that loops comes home too, and its loop runs on. In mode `paused` or `fast` the rest
|
|
@@ -4917,8 +5054,10 @@ type Hint = {
|
|
|
4917
5054
|
* Options of a guide: the `guide` descriptor a node awaits, and what the `guide` of a node returns.
|
|
4918
5055
|
* `allow` is the one answer the gate lets through. `ui` dims the screen with a veil and cuts a
|
|
4919
5056
|
* window over `target` (one target, or the union of the shown ones of a list), grown by `pad`; a
|
|
4920
|
-
* press outside the window reaches no view and answers `blocked` when it is set.
|
|
4921
|
-
* the
|
|
5057
|
+
* press outside the window reaches no view and answers `blocked` when it is set. A press inside the
|
|
5058
|
+
* window that the narrow drops answers `blocked` too: another intent, or the allowed intent with
|
|
5059
|
+
* another payload (a drop on the wrong cell). Without a target the veil covers the whole screen and
|
|
5060
|
+
* every press is outside.
|
|
4922
5061
|
*
|
|
4923
5062
|
* @example
|
|
4924
5063
|
* ```ts
|
|
@@ -4977,16 +5116,25 @@ type GuideOptions = {
|
|
|
4977
5116
|
alpha?: number;
|
|
4978
5117
|
} | false;
|
|
4979
5118
|
/**
|
|
4980
|
-
* The answer a press outside the window gives, with its payload, instead of reaching nothing.
|
|
4981
|
-
*
|
|
5119
|
+
* The answer a press outside the window gives, with its payload, instead of reaching nothing. A
|
|
5120
|
+
* press inside the window that the narrow drops gives it too: another intent, or the allowed
|
|
5121
|
+
* intent with another payload (a drop on the wrong cell). A press at a closed gate is held as it
|
|
5122
|
+
* is, never turned into `blocked`. The gate takes it beside `allow`, so it must be an outcome of
|
|
5123
|
+
* the node that waits.
|
|
4982
5124
|
*
|
|
4983
5125
|
* @example
|
|
4984
5126
|
* ```ts
|
|
4985
5127
|
* const strict: GuideOptions = {
|
|
4986
|
-
* allow: { intent: "
|
|
4987
|
-
* target:
|
|
4988
|
-
*
|
|
4989
|
-
*
|
|
5128
|
+
* allow: { intent: "merge", payload: { from: "c2", to: "c3" } },
|
|
5129
|
+
* target: [
|
|
5130
|
+
* { projection: "board.items", key: "c2" },
|
|
5131
|
+
* { projection: "board.items", key: "c3" },
|
|
5132
|
+
* { projection: "board.items", key: "c4" }
|
|
5133
|
+
* ],
|
|
5134
|
+
* blocked: { intent: "tutorialBlocked", payload: { step: 2 } }
|
|
5135
|
+
* };
|
|
5136
|
+
* // a press on the shop button outside the window, or a drop of c2 onto c4 inside it, answers
|
|
5137
|
+
* // { intent: "tutorialBlocked", payload: { step: 2 } }: the node shows the hand again
|
|
4990
5138
|
* ```
|
|
4991
5139
|
*/
|
|
4992
5140
|
blocked?: Allow;
|
|
@@ -6207,6 +6355,12 @@ type NodeGuideHost = {
|
|
|
6207
6355
|
[key: string]: Json;
|
|
6208
6356
|
} | undefined; /** Derives the guide again from the committed state; a `guide` that throws fails the node. */
|
|
6209
6357
|
refresh: () => void;
|
|
6358
|
+
/**
|
|
6359
|
+
* Shows the last result again through the `guide` handler, with the narrow it already set. Called
|
|
6360
|
+
* when the fx mode goes from fast back to live: in fast mode the handler of `ui` did not run.
|
|
6361
|
+
* Shows nothing once the node was left, or while it guides nothing.
|
|
6362
|
+
*/
|
|
6363
|
+
reshow: () => void;
|
|
6210
6364
|
};
|
|
6211
6365
|
/**
|
|
6212
6366
|
* The last `flow.state()` and the fields it was built from. `state()` hands the same frozen
|
|
@@ -6300,7 +6454,8 @@ type RunnerApi = {
|
|
|
6300
6454
|
* entered through the same check as `restore`, with the same fallback. A rest node is entered
|
|
6301
6455
|
* before the switch to fast mode: its stages see the mode of the caller. A transit node is
|
|
6302
6456
|
* entered after the switch and without the wait `restore` adds for it: its popup is not shown,
|
|
6303
|
-
* the route answers it. The mode of the caller is put back afterwards
|
|
6457
|
+
* the route answers it. The mode of the caller is put back afterwards; when it is live, the guide
|
|
6458
|
+
* of the node the walk ends at is shown, its lock and veil as on a live entry.
|
|
6304
6459
|
*
|
|
6305
6460
|
* @param route - The player's answers and substituted sub-flow results, in order.
|
|
6306
6461
|
* @param options - Walk options.
|
|
@@ -11335,7 +11490,7 @@ type LeaveCover = {
|
|
|
11335
11490
|
* The loader of a scene being left, drawn above the veil when the switch is not done `afterMs` after its start, until
|
|
11336
11491
|
* the swap: a game texture turning at the centre (`texture`), a layer of the scene drawn above the veil (`due`, which
|
|
11337
11492
|
* makes what the loader draws only once it is due and answers its layer: `scenes` mounts a loader projection there),
|
|
11338
|
-
* or, with neither, a white ring the engine draws.
|
|
11493
|
+
* or, with neither, a white ring the engine draws. A layer that shows at the swap fades out with the veil.
|
|
11339
11494
|
*
|
|
11340
11495
|
* @example
|
|
11341
11496
|
* ```ts
|
|
@@ -11351,8 +11506,10 @@ type LeaveLoader = {
|
|
|
11351
11506
|
/**
|
|
11352
11507
|
* Called once, in the first frame the loader is due and before it is drawn, never for a switch done sooner: it
|
|
11353
11508
|
* makes what the loader draws and answers the layer of the scene that holds it, whose container is drawn above the
|
|
11354
|
-
* veil from then
|
|
11355
|
-
*
|
|
11509
|
+
* veil from then on. After the swap it stays there and fades out with the veil, its alpha the veil's level; once the
|
|
11510
|
+
* veil is gone it waits there at alpha 0 until no view hangs in it (the switch unmounts the loader), then goes back
|
|
11511
|
+
* under the root at alpha 1. A drop puts it back at once. `undefined`, or a throw, draws the ring; a layer the scene
|
|
11512
|
+
* does not declare draws nothing.
|
|
11356
11513
|
*
|
|
11357
11514
|
* @returns The layer, or `undefined` for the ring.
|
|
11358
11515
|
*/
|
|
@@ -11403,8 +11560,9 @@ type LeaveApi = {
|
|
|
11403
11560
|
*/
|
|
11404
11561
|
show(look: LeaveLook): void;
|
|
11405
11562
|
/**
|
|
11406
|
-
* The switch swapped the next scene in: the
|
|
11407
|
-
*
|
|
11563
|
+
* The switch swapped the next scene in: the veil fades out over its `outMs` from where it stands and is taken off the
|
|
11564
|
+
* stage. A ring or a texture loader goes at once; a layer loader that shows stays above the veil and fades out with
|
|
11565
|
+
* it, and its layer goes back under the root once the loader's views left it. Nothing runs: nothing happens.
|
|
11408
11566
|
*
|
|
11409
11567
|
* @example
|
|
11410
11568
|
* ```ts
|
|
@@ -11451,21 +11609,37 @@ type LeaveRun = {
|
|
|
11451
11609
|
startedAt: number;
|
|
11452
11610
|
steppedAt: number;
|
|
11453
11611
|
level: number;
|
|
11454
|
-
landed: boolean;
|
|
11612
|
+
landed: boolean; /** The veil's level at the swap: a layer loader fades from whole to nothing over the rest of it. 1 before the swap. */
|
|
11613
|
+
landedLevel: number;
|
|
11455
11614
|
loader: LoaderKind; /** The texture of a `"texture"` loader, resolved at `show`. */
|
|
11456
11615
|
texture?: PixiTexture; /** A `"layer"` loader's `due` was called: once, the first frame it was due. */
|
|
11457
11616
|
asked: boolean; /** The layer a `"layer"` loader's `due` answered; absent before. */
|
|
11458
|
-
layer?: string; /** The layer container a `"layer"` loader drew above the veil; absent while none
|
|
11459
|
-
lifted?: PixiContainer; /** The loader is shown: past its `afterMs`, before the swap. */
|
|
11617
|
+
layer?: string; /** The layer container a `"layer"` loader drew above the veil, kept through the fade-out; absent while none is. */
|
|
11618
|
+
lifted?: PixiContainer; /** The loader is shown: past its `afterMs`, before the swap; after it, a layer loader that showed, while it fades. */
|
|
11460
11619
|
shown: boolean;
|
|
11461
11620
|
};
|
|
11462
11621
|
/**
|
|
11463
|
-
*
|
|
11464
|
-
*
|
|
11622
|
+
* A loader layer that faded out with the veil and waits above it, at alpha 0, until the loader's views left it: under
|
|
11623
|
+
* the root it would draw them whole. Not public.
|
|
11624
|
+
*/
|
|
11625
|
+
type LeaveParked = {
|
|
11626
|
+
container: PixiContainer; /** The layer, whose place in the layer list it goes back to. */
|
|
11627
|
+
layer: string | undefined;
|
|
11628
|
+
/**
|
|
11629
|
+
* Frames it waits at most: views another owner draws in the layer (the scene that stands, a loader the game mounted)
|
|
11630
|
+
* never leave it, and the layer goes back whole then.
|
|
11631
|
+
*/
|
|
11632
|
+
framesLeft: number;
|
|
11633
|
+
};
|
|
11634
|
+
/**
|
|
11635
|
+
* The picture of a scene being left (spec 33, slice A2): the running look, absent while none runs; the engine's
|
|
11636
|
+
* objects, absent until the first look needs them and after the application that held them was lost; and the loader
|
|
11637
|
+
* layer that waits for its views to leave, absent while none does. Not public.
|
|
11465
11638
|
*/
|
|
11466
11639
|
type LeaveState = {
|
|
11467
11640
|
run?: LeaveRun;
|
|
11468
11641
|
objects?: LeaveObjects;
|
|
11642
|
+
parked?: LeaveParked;
|
|
11469
11643
|
};
|
|
11470
11644
|
/**
|
|
11471
11645
|
* sync module API, `app.renderer.sync`. The one owner of every display object: it builds them
|
|
@@ -12213,7 +12387,7 @@ type PassCount = {
|
|
|
12213
12387
|
enabled: boolean[];
|
|
12214
12388
|
};
|
|
12215
12389
|
declare namespace types_d_exports$1 {
|
|
12216
|
-
export { AnySceneProjection, CheckedProjections, Config$1 as Config, DefineScene, Deps$1 as Deps, Events$1 as Events, FullCover, FullLeave, FullLoader, KernelSlice$1 as KernelSlice, LayerMap, Leaving, RunContext, SceneBuild, SceneCover, SceneDefinition, SceneLayer, SceneLeave, SceneLoader, SceneOwner, SceneProjection, SceneSpec, SceneState, ScenesApi, ScenesCtx, SortRule, State$1 as State, UiLayer };
|
|
12390
|
+
export { AnySceneProjection, BundleProgress, BundleShare, CheckedProjections, Config$1 as Config, DefineScene, Deps$1 as Deps, Events$1 as Events, FadingLoader, FullCover, FullLeave, FullLoader, HeldLoader, KernelSlice$1 as KernelSlice, LayerMap, Leaving, LoaderFeed, RunContext, SceneBuild, SceneCover, SceneDefinition, SceneEnter, SceneLayer, SceneLeave, SceneLoader, SceneOwner, SceneProjection, SceneSpec, SceneState, ScenesApi, ScenesCtx, SortRule, State$1 as State, UiLayer };
|
|
12217
12391
|
}
|
|
12218
12392
|
/**
|
|
12219
12393
|
* How a layer orders what is drawn in it. The scene's name for the rule `world` stores.
|
|
@@ -12317,7 +12491,7 @@ type CheckedProjections<Layer extends string, List> = { readonly [Index in keyof
|
|
|
12317
12491
|
* The veil a live switch lays over the scene being left, from the switch start: a full-screen rect the engine draws
|
|
12318
12492
|
* above every layer, fading from 0 to `alpha` over `inMs`; after the swap the next scene is under it and it fades out
|
|
12319
12493
|
* over `outMs`. It takes no tap. A field left out keeps the one of the level below: the scene's over the config's over
|
|
12320
|
-
* the engine's.
|
|
12494
|
+
* the engine's. The scene being entered has the last word on its `color` and `alpha` (`enter.cover`).
|
|
12321
12495
|
*
|
|
12322
12496
|
* @example
|
|
12323
12497
|
* ```ts
|
|
@@ -12336,8 +12510,9 @@ type SceneCover = {
|
|
|
12336
12510
|
* texture turning at the centre (`texture`), a projection of the game drawn above the veil (`projection`), or, with
|
|
12337
12511
|
* neither, a white ring the engine draws. `texture` and `projection` are one choice: a level that names either replaces
|
|
12338
12512
|
* both of the level below, and with both named `projection` is drawn. A projection loader draws in a layer of its own
|
|
12339
|
-
* that the scene being left declares
|
|
12340
|
-
* while the
|
|
12513
|
+
* that the scene being left declares: kept built and hidden while that scene stands, shown once the loader is due (the
|
|
12514
|
+
* whole layer is drawn above the veil while it shows), and faded out with the veil after the swap. `scenes` hands its
|
|
12515
|
+
* `from` the switch (`SceneSwitch`): where it goes and how far its bundles loaded.
|
|
12341
12516
|
*
|
|
12342
12517
|
* @example
|
|
12343
12518
|
* ```ts
|
|
@@ -12349,15 +12524,21 @@ type SceneCover = {
|
|
|
12349
12524
|
*/
|
|
12350
12525
|
type SceneLoader<Asset extends string = string> = {
|
|
12351
12526
|
/** Milliseconds after the switch start the loader waits for. Default 400. */afterMs?: number; /** An asset key of the game: the texture turns at the centre of the frame. */
|
|
12352
|
-
texture?: Asset;
|
|
12527
|
+
texture?: Asset;
|
|
12528
|
+
/**
|
|
12529
|
+
* The name of a registered projection: kept built and hidden while the scene stands, shown once the loader is due,
|
|
12530
|
+
* its layer drawn above the veil; it fades out with the veil after the swap. Its `from(player, session, sw)` reads the
|
|
12531
|
+
* switch as its third argument: `{ from: "ward", to: "ward", progress: 0 }` while the ward stands, then `{ from:
|
|
12532
|
+
* "ward", to: "board", progress }`, the share of the board's bundles loaded, in steps of 0.01 up to 1.
|
|
12533
|
+
*/
|
|
12353
12534
|
projection?: string;
|
|
12354
12535
|
};
|
|
12355
12536
|
/**
|
|
12356
12537
|
* What a live switch shows over the scene being left: the veil and the loader. The scene being left decides: its
|
|
12357
12538
|
* `leave` is merged field by field over `config.leave`, which is merged over the engine's default (`{ cover: { color:
|
|
12358
12539
|
* 0x000000, alpha: 0.45, inMs: 50, outMs: 150 }, loader: { afterMs: 400 } }`). `false` turns a part or the whole off;
|
|
12359
|
-
* a part written over `false` starts from the engine's default.
|
|
12360
|
-
* show nothing.
|
|
12540
|
+
* a part written over `false` starts from the engine's default. The scene being entered may set the veil's `color` and
|
|
12541
|
+
* `alpha` on top (`enter.cover`). Fast mode, a headless app and the first scene of a run show nothing.
|
|
12361
12542
|
*
|
|
12362
12543
|
* @example
|
|
12363
12544
|
* ```ts
|
|
@@ -12372,6 +12553,22 @@ type SceneLeave<Asset extends string = string> = {
|
|
|
12372
12553
|
cover?: SceneCover | false;
|
|
12373
12554
|
loader?: SceneLoader<Asset> | false;
|
|
12374
12555
|
} | false;
|
|
12556
|
+
/**
|
|
12557
|
+
* What a live switch to this scene shows over the scene being left: the veil takes this scene's `color` and `alpha`,
|
|
12558
|
+
* each over what the scene being left resolved (its `leave` over `config.leave` over the engine's). Only the look of
|
|
12559
|
+
* the veil: `inMs` and `outMs` stay the left scene's, and a veil the scene being left turned off (`cover: false`)
|
|
12560
|
+
* stays off, as `enter` never turns one on. Absent: the scene being left decides alone.
|
|
12561
|
+
*
|
|
12562
|
+
* @example
|
|
12563
|
+
* ```ts
|
|
12564
|
+
* // Every way into the night scene dims the scene being left in navy at 70 %: ward → night shows the veil
|
|
12565
|
+
* // { color: 0x0b1020, alpha: 0.7, inMs: 50, outMs: 150 } over a ward that leaves with the engine's.
|
|
12566
|
+
* const enter: SceneEnter = { cover: { color: 0x0b1020, alpha: 0.7 } };
|
|
12567
|
+
* ```
|
|
12568
|
+
*/
|
|
12569
|
+
type SceneEnter = {
|
|
12570
|
+
/** The `color` and the `alpha` of the veil of a switch to this scene. */cover?: Pick<SceneCover, "color" | "alpha">;
|
|
12571
|
+
};
|
|
12375
12572
|
/**
|
|
12376
12573
|
* What the author passes to `defineScene`. The layer names come from the keys of `layers` plus
|
|
12377
12574
|
* the appended `ui`; `NoInfer` keeps `projections` out of that inference, so a wrong name is
|
|
@@ -12404,7 +12601,8 @@ type SceneSpec<Layers extends LayerMap, Projections extends readonly AnyScenePro
|
|
|
12404
12601
|
layers: Layers;
|
|
12405
12602
|
projections: Projections & NoInfer<CheckedProjections<SceneLayer<Layers>, Projections>>;
|
|
12406
12603
|
music?: Asset; /** What a live switch shows over this scene when it is left: merged field by field over `config.leave`. */
|
|
12407
|
-
leave?: SceneLeave<Asset>;
|
|
12604
|
+
leave?: SceneLeave<Asset>; /** What a live switch to this scene shows: the `color` and `alpha` of the veil over the scene being left. */
|
|
12605
|
+
enter?: SceneEnter;
|
|
12408
12606
|
};
|
|
12409
12607
|
/**
|
|
12410
12608
|
* The signature of `defineScene` bound to the asset and bundle keys and to the `Player` and
|
|
@@ -12440,7 +12638,8 @@ type SceneDefinition = {
|
|
|
12440
12638
|
* @returns The bundle names the scene needs on top of `bundle`.
|
|
12441
12639
|
*/
|
|
12442
12640
|
bundles?(state: SceneState): readonly string[]; /** What `defineScene` was given as `leave`; absent when the scene takes the config's. */
|
|
12443
|
-
readonly leave?: SceneLeave;
|
|
12641
|
+
readonly leave?: SceneLeave; /** What `defineScene` was given as `enter`; absent when the scene being left decides the veil alone. */
|
|
12642
|
+
readonly enter?: SceneEnter;
|
|
12444
12643
|
};
|
|
12445
12644
|
/**
|
|
12446
12645
|
* The committed state a scene's `bundles` reads: the frozen `player` and `session` of `model.store.snapshot()`, never a
|
|
@@ -12560,6 +12759,35 @@ type State$1 = {
|
|
|
12560
12759
|
* one. Absent otherwise: deleted, never written as `undefined`.
|
|
12561
12760
|
*/
|
|
12562
12761
|
leaving?: Leaving;
|
|
12762
|
+
/**
|
|
12763
|
+
* The leave loader projection scenes holds for the next switch of the scene that stands (F103): `world` keeps it
|
|
12764
|
+
* built and hidden, and the loader's `due` only shows it. Absent while it holds none: deleted, never written as
|
|
12765
|
+
* `undefined`.
|
|
12766
|
+
*/
|
|
12767
|
+
held?: HeldLoader;
|
|
12768
|
+
/**
|
|
12769
|
+
* The loader projection the last switch showed, fading out with the veil after its swap (F107 part 3), until the
|
|
12770
|
+
* veil's `outMs` passed. Absent otherwise: deleted, never written as `undefined`.
|
|
12771
|
+
*/
|
|
12772
|
+
fading?: FadingLoader;
|
|
12773
|
+
};
|
|
12774
|
+
/**
|
|
12775
|
+
* A leave loader projection scenes holds while a scene stands (F103): its name and the layer its spec names, which the
|
|
12776
|
+
* renderer draws above the veil once the loader is due.
|
|
12777
|
+
*/
|
|
12778
|
+
type HeldLoader = {
|
|
12779
|
+
/** The projection. */name: string; /** The `layer` of its spec: the view a `show` brings has no `Layer` before the next frame's reconcile. */
|
|
12780
|
+
layer: string;
|
|
12781
|
+
};
|
|
12782
|
+
/**
|
|
12783
|
+
* A loader projection fading out with the veil after the swap of its switch (F107 part 3): unmounted once the veil's
|
|
12784
|
+
* `outMs` passed, or held again for the next switch when the scene that stands leaves with the same loader.
|
|
12785
|
+
*/
|
|
12786
|
+
type FadingLoader = {
|
|
12787
|
+
/** The projection. */name: string; /** Milliseconds of the fade still to run, counted down by the frames since the swap. */
|
|
12788
|
+
leftMs: number; /** The loader the scene that stands holds once the fade is over: this projection again. Absent: it is unmounted. */
|
|
12789
|
+
rehold?: HeldLoader; /** Removes the frame callback of the fade. */
|
|
12790
|
+
off: () => void;
|
|
12563
12791
|
};
|
|
12564
12792
|
/**
|
|
12565
12793
|
* The veil and the loader a switch showed over the scene being left (spec 33, slices A2 and A3): the node that started
|
|
@@ -12577,10 +12805,50 @@ type Leaving = {
|
|
|
12577
12805
|
* resolved against it.
|
|
12578
12806
|
*/
|
|
12579
12807
|
to: string; /** Landed or dropped: a second end does nothing. */
|
|
12580
|
-
done: boolean;
|
|
12581
|
-
|
|
12808
|
+
done: boolean;
|
|
12809
|
+
/**
|
|
12810
|
+
* The loader projection the switch mounted or showed once its loader was due: unmounted at once at a drop, faded out
|
|
12811
|
+
* with the veil after a land. Absent while it mounted and showed none.
|
|
12812
|
+
*/
|
|
12813
|
+
projection?: string; /** Milliseconds the veil fades out over after the swap, 0 without a veil: a loader shown goes with it. */
|
|
12814
|
+
outMs: number;
|
|
12815
|
+
/**
|
|
12816
|
+
* The loader projection the switch feeds its `SceneSwitch` (F107 part 1), from its start to its swap or drop. Absent
|
|
12817
|
+
* when it feeds none: a ring, a texture, a loader turned off, or a projection another owner shows.
|
|
12818
|
+
*/
|
|
12819
|
+
feeding?: LoaderFeed; /** Removes the abort listener of the switch's node. */
|
|
12582
12820
|
off: () => void;
|
|
12583
12821
|
};
|
|
12822
|
+
/**
|
|
12823
|
+
* One bundle of a switch and how much of it is loaded, in thousandths: 1000 once it is loaded.
|
|
12824
|
+
*/
|
|
12825
|
+
type BundleShare = {
|
|
12826
|
+
/** The bundle. */readonly bundle: string; /** The share of its files settled, in thousandths: 0 to 1000. */
|
|
12827
|
+
share: number;
|
|
12828
|
+
};
|
|
12829
|
+
/**
|
|
12830
|
+
* What a switch feeds its loader projection (F107 part 1): the name, both scenes, the table of its bundles made at the
|
|
12831
|
+
* start, the progress last fed and the one `feed` call of the switch. The hook of `assets:bundle-progress` and the
|
|
12832
|
+
* scene stage, once its loads are in, write the table and feed a new `SceneSwitch` only once the progress grew by 0.01
|
|
12833
|
+
* or reached 1.
|
|
12834
|
+
*/
|
|
12835
|
+
type LoaderFeed = {
|
|
12836
|
+
/** The loader projection. */readonly name: string; /** The scene being left: `from` of every switch fed. */
|
|
12837
|
+
readonly from: string; /** The scene being switched to: `to` of every switch fed. */
|
|
12838
|
+
readonly to: string; /** The bundles the scene being switched to names, one row each, in the order it names them. */
|
|
12839
|
+
readonly bundles: readonly BundleShare[]; /** The progress last fed, in thousandths: the mean of the shares, floored; 1000 with no bundle. */
|
|
12840
|
+
fed: number;
|
|
12841
|
+
/**
|
|
12842
|
+
* Feeds the loader a switch: `world.projection.feed` bound to the name, made once per switch.
|
|
12843
|
+
*
|
|
12844
|
+
* @param sw - The switch, a new object for each new value.
|
|
12845
|
+
*/
|
|
12846
|
+
readonly feed: (sw: SceneSwitch) => void;
|
|
12847
|
+
};
|
|
12848
|
+
/**
|
|
12849
|
+
* The payload of the `assets:bundle-progress` hook: one more file of a running load settled.
|
|
12850
|
+
*/
|
|
12851
|
+
type BundleProgress = Events["assets:bundle-progress"];
|
|
12584
12852
|
/**
|
|
12585
12853
|
* A veil with every field: what a level of `leave` resolves to.
|
|
12586
12854
|
*/
|
|
@@ -13388,6 +13656,8 @@ type Events = {
|
|
|
13388
13656
|
* One more file of a running load settled. `loaded` counts the settled files (a font once, with
|
|
13389
13657
|
* its pages), `total` is the file count of the bundle; the last one of a load has
|
|
13390
13658
|
* `loaded === total` and comes before `assets:bundle-loaded`. An aborted load sends none.
|
|
13659
|
+
* `scenes` listens during a live switch: the share of the switch's bundles loaded is what its
|
|
13660
|
+
* leave loader projection reads as `progress`.
|
|
13391
13661
|
*/
|
|
13392
13662
|
"assets:bundle-progress": {
|
|
13393
13663
|
bundle: string;
|
|
@@ -13710,4 +13980,4 @@ type BundleCompanion = {
|
|
|
13710
13980
|
unload(bundle: string): void;
|
|
13711
13981
|
};
|
|
13712
13982
|
//#endregion
|
|
13713
|
-
export { PixiModule as $,
|
|
13983
|
+
export { PixiModule as $, AnyComponent as $n, RateChange as $r, ShaderWhat as $t, SyncApi as A, TypeTag as An, Json as Ar, PerfChange as At, ShapeValue as B, DescriptionNode as Bn, SnapshotOf as Br, PerfLongFrameLine as Bt, SceneSpec as C, DefineNode as Cn, Config$5 as Cr, PERF_CAUSES as Ct, DebugSwitches as D, NodeTable as Dn, Api$5 as Dr, PassKind as Dt, types_d_exports$1 as E, JournalEntry as En, types_d_exports$5 as Er, PROBLEM_RULES as Et, NineSliceValue as F, Hint as Fn, PlayerStateProvider as Fr, PerfEventLine as Ft, Transform as G, NumericFields as Gn, Config$7 as Gr, PerfStartupLine as Gt, SpriteBlend as H, Motion as Hn, RngApi as Hr, PerfMeasured as Ht, Overlay as I, NodeFx as In, ProviderCall as Ir, PerfEventName as It, AdaptiveScale as J, ReducedMotion as Jn, State$7 as Jr, PoolTrimDetail as Jt, TransformValue as K, ProjectionMotion as Kn, Events$6 as Kr, PerfTelemetryLine as Kt, OverlayValue as L, Answer as Ln, SaveDoc as Lr, PerfGapLine as Lt, HudPart as M, Effect as Mn, State$6 as Mr, PerfCollectorLine as Mt, HudPartValue as N, EffectOptions as Nn, types_d_exports$6 as Nr, PerfCounts as Nt, FilterSlot as O, RouteStep as On, Config$6 as Or, PassRecord as Ot, NineSlice$1 as P, GuideOptions as Pn, Patch as Pr, PerfDisplay as Pt, PixiFilter as Q, ViewHandle as Qn, FrameRate as Qr, ShaderEventDetail as Qt, Parent as R, AnchorTarget as Rn, SaveUnreadableError as Rr, PerfHeaderLine as Rt, SceneDefinition as S, Bookmark as Sn, ClockSource as Sr, OverlayWhat as St, State$1 as T, FlowState as Tn, State$5 as Tr, PERF_LOG_VERSION as Tt, SpriteOptions as U, MotionCause as Un, RngState as Ur, PerfSampleLine as Ut, Sprite as V, Ease as Vn, StoreApi as Vr, PerfMarkLine as Vt, SpriteValue as W, MotionHandle as Wn, Api$6 as Wr, PerfSpikeLine as Wt, Config$2 as X, TrackOptions as Xn, Api$7 as Xr, ProblemRule as Xt, Api$1 as Y, SceneSwitch as Yn, types_d_exports$7 as Yr, ProblemEventDetail as Yt, MonitorConfig as Z, TrackSegment as Zn, Config$8 as Zr, SHADER_WHATS as Zt, AnySceneProjection as _, type as _n, Config$4 as _r, FrameRing as _t, Config as a, Events$8 as ai, EmitterIdOf as an, ComponentValue as ar, types_d_exports$2 as at, Events$1 as b, FeatureTree as bn, types_d_exports$4 as br, MonitorSections as bt, LoadBundles as c, Position as cn, FrameDiff as cr, RenderStats as ct, Manifest as d, types_d_exports$3 as dn, QueryTerm as dr, ViewportSize as dt, State$8 as ei, WarmDetail as en, AnyComponentType as er, PixiSprite as et, ReadyBundles as f, contribution as fn, ResourceType as fr, FilterCache as ft, types_d_exports as g, to as gn, Api$3 as gr, FrameRecord as gt, Usage as h, slot as hn, TagType as hr, FrameReadout as ht, BundleSpec as i, Config$9 as ii, Config$3 as in, ComponentType as ir, Under as it, Display as j, Descriptor as jn, Root as jr, PerfChangeEntry as jt, FilterSlotInputs as k, SceneIdOf as kn, Events$5 as kr, PerfCause as kt, LoadReason as l, State$3 as ln, Mut as lr, Orientation as lt, Tier as m, exit as mn, SystemFor as mr, FrameReadResult as mt, AssetsIo as n, Time as ni, Api$2 as nn, ComponentHandle as nr, PoolTrim as nt, DefineBundles as o, Require as oi, GameTypes as on, Entity as or, Captured as ot, State as p, defineFlow as pn, SystemDefinition as pr, FrameColumns as pt, sprite as q, ProjectionSpec as qn, PauseReason as qr, PerfThermalLine as qt, BundleMap as r, types_d_exports$8 as ri, BundlesOf as rn, ComponentSchema as rr, State$2 as rt, Events as s, HudKeysOf as sn, EntitySnapshot as sr, MonitorCounts as st, Api as t, ThermalReading as ti, DEMAND_REASONS as tn, AnyComponentValue as tr, PixiTexture as tt, LoadResult as u, TextStylesOf as un, Narrowed as ur, Point as ut, Config$1 as v, FeatureDescription as vn, Explained as vr, LongFrameEntry as vt, ScenesApi as w, FlowGraph as wn, FakeClock as wr, PERF_GAP_BUCKETS as wt, LayerMap as x, AnyFlow as xn, Api$4 as xr, OverlayEventDetail as xt, DefineScene as y, FeaturePlugin as yn, State$4 as yr, MONITOR_SECTIONS as yt, Shape as z, ChangeHook as zn, Snapshot as zr, PerfLogLine as zt };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { $ as PixiModule, An as TypeTag,
|
|
2
|
-
import { o as AudioContextLike, s as Config$4 } from "./types-
|
|
3
|
-
import { R as I18nApi, U as StringTable, W as TextKey } from "./types-
|
|
4
|
-
import { St as effectsPlugin, Tt as audioPlugin, ht as PlatformProvider, i as screen, pt as platformPlugin, t as createApp } from "./index-
|
|
1
|
+
import { $ as PixiModule, An as TypeTag, Ar as Json, Br as SnapshotOf, Fr as PlayerStateProvider, Ir as ProviderCall, Lr as SaveDoc, Or as Config, Sr as ClockSource, X as Config$2, a as Config$3, d as Manifest, in as Config$1, lt as Orientation, n as AssetsIo, wr as FakeClock, xn as AnyFlow, yn as FeaturePlugin } from "./types-C6PML3Il.mjs";
|
|
2
|
+
import { o as AudioContextLike, s as Config$4 } from "./types-C0As3dEe.mjs";
|
|
3
|
+
import { R as I18nApi, U as StringTable, W as TextKey } from "./types-FtzEwwWY.mjs";
|
|
4
|
+
import { St as effectsPlugin, Tt as audioPlugin, ht as PlatformProvider, i as screen, pt as platformPlugin, t as createApp } from "./index-m2g9-8_E.mjs";
|
|
5
5
|
import { AnyPluginInstance } from "@moku-labs/core";
|
|
6
6
|
|
|
7
7
|
//#region src/plugins/model/store/providers/memory.d.ts
|