@moku-labs/game 0.15.104 → 0.15.106
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-CYXJyv3w.d.mts → commands-wfLkpPZC.d.mts} +5 -5
- package/dist/control.d.mts +4 -4
- package/dist/{define-Cq8Df0_C.d.mts → define--35FWvH9.d.mts} +2 -2
- package/dist/{headless-DRiVyv9T.d.mts → headless-CWa3MHQi.d.mts} +1 -1
- package/dist/{index-BIofySGI.d.mts → index-CFq7H9zQ.d.mts} +9 -7
- package/dist/index.d.mts +4 -4
- 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-DuAOUZ-z.d.mts → runtime-CIpfTDsz.d.mts} +1 -1
- package/dist/{src-BJBCs69P.mjs → src-BLbBo_Ih.mjs} +504 -226
- package/dist/testing.d.mts +4 -4
- package/dist/testing.mjs +1 -1
- package/dist/{types-BlXBiM8d.d.mts → types-B7maCx9u.d.mts} +1 -1
- package/dist/{types-C1-VCBhy.d.mts → types-BTR9r8se.d.mts} +5 -3
- package/dist/{types-BT8kKhan.d.mts → types-BXfauLJW.d.mts} +4 -4
- package/dist/{types-Ca90Yo7d.d.mts → types-CThqFAwa.d.mts} +2 -2
- package/dist/{types-CayM8xne.d.mts → types-DQWTawIz.d.mts} +94 -16
- package/dist/{visual-B_3sVlRK.d.mts → visual-D62TNaW-.d.mts} +6 -6
- package/dist/visual.d.mts +1 -1
- package/package.json +1 -1
package/dist/testing.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Fr as ClockSource, Jn as NodeFx, Lr as FakeClock, Nn as AnyFlow, Un as Descriptor, Ur as Json, jn as FeaturePlugin, qn as Hint, zn as NodeTable } from "./types-
|
|
2
|
-
import { t as createApp } from "./index-
|
|
3
|
-
import { b as memory, x as saveOf, y as WithGameState } 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 { Fr as ClockSource, Jn as NodeFx, Lr as FakeClock, Nn as AnyFlow, Un as Descriptor, Ur as Json, jn as FeaturePlugin, qn as Hint, zn as NodeTable } from "./types-DQWTawIz.mjs";
|
|
2
|
+
import { t as createApp } from "./index-CFq7H9zQ.mjs";
|
|
3
|
+
import { b as memory, x as saveOf, y as WithGameState } from "./types-BXfauLJW.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-CWa3MHQi.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 { dn as refuseStart, gn as type, pn as exit, t as createApp, w as flattenFeatures } from "./src-
|
|
1
|
+
import { dn as refuseStart, gn as type, pn as exit, t as createApp, w as flattenFeatures } from "./src-BLbBo_Ih.mjs";
|
|
2
2
|
import { n as saveOf, t as memory } from "./memory-DeD9wis6.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,4 +1,4 @@
|
|
|
1
|
-
import { J as TransformValue, Or as TagType, Pr as Api$5, Qn as ChangeHook, Un as Descriptor, Ur as Json, Xn as Answered, Z as Api$3, Zn as AnchorTarget, _r as ComponentType, ar as ProjectionMotion, dr as ViewHandle, er as Ease, et as PixiContainer, fr as AnyComponent, ir as NumericFields, kr as Api$2, li as Api, mr as AnyComponentValue, nr as MotionCause, pn as Api$1, pr as AnyComponentType, qn as Hint, rr as MotionHandle, rt as PixiModule, s as Events$1, sr as ReducedMotion, t as Api$4, tr as Motion, vt as ViewportSize, yi as Require, yr as Entity } from "./types-
|
|
1
|
+
import { J as TransformValue, Or as TagType, Pr as Api$5, Qn as ChangeHook, Un as Descriptor, Ur as Json, Xn as Answered, Z as Api$3, Zn as AnchorTarget, _r as ComponentType, ar as ProjectionMotion, dr as ViewHandle, er as Ease, et as PixiContainer, fr as AnyComponent, ir as NumericFields, kr as Api$2, li as Api, mr as AnyComponentValue, nr as MotionCause, pn as Api$1, pr as AnyComponentType, qn as Hint, rr as MotionHandle, rt as PixiModule, s as Events$1, sr as ReducedMotion, t as Api$4, tr as Motion, vt as ViewportSize, yi as Require, yr as Entity } from "./types-DQWTawIz.mjs";
|
|
2
2
|
import { Log } from "@moku-labs/common/browser";
|
|
3
3
|
import { PluginCtx } from "@moku-labs/core";
|
|
4
4
|
import { Node, Yoga } from "yoga-layout/load";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as FilterSlotQuad, Br as Api$6, Hn as TypeTag, Hr as Events$3, O as FilterSlot, Un as Descriptor, Ur as Json, Z as Api$4, Zn as AnchorTarget, _r as ComponentType, _t as Point, ai as Events$5, at as PixiTexture, b as Events$4, er as Ease, fr as AnyComponent, hr as ComponentHandle, ir as NumericFields, it as PixiSprite, j as SyncApi, k as FilterSlotInputs, kr as Api$3, li as Api$1, lr as TrackOptions, mr as AnyComponentValue, nt as PixiGpuProgram, ot as PixiUniformGroup, pn as Api$2, rr as MotionHandle, rt as PixiModule, s as Events$1, sr as ReducedMotion, t as Api$5, tt as PixiFilter, ur as TrackSegment, vi as Events$2, yi as Require, yr as Entity, yt as FilterCache } from "./types-
|
|
2
|
-
import { R as InputApi, T as TextApi, U as I18nApi, c as UiNode, i as Finding, l as LayoutState, n as ElementChange, o as JsxState, r as ElementMotion, tt as StylesState } from "./types-
|
|
1
|
+
import { A as FilterSlotQuad, Br as Api$6, Hn as TypeTag, Hr as Events$3, O as FilterSlot, Un as Descriptor, Ur as Json, Z as Api$4, Zn as AnchorTarget, _r as ComponentType, _t as Point, ai as Events$5, at as PixiTexture, b as Events$4, er as Ease, fr as AnyComponent, hr as ComponentHandle, ir as NumericFields, it as PixiSprite, j as SyncApi, k as FilterSlotInputs, kr as Api$3, li as Api$1, lr as TrackOptions, mr as AnyComponentValue, nt as PixiGpuProgram, ot as PixiUniformGroup, pn as Api$2, rr as MotionHandle, rt as PixiModule, s as Events$1, sr as ReducedMotion, t as Api$5, tt as PixiFilter, ur as TrackSegment, vi as Events$2, yi as Require, yr as Entity, yt as FilterCache } from "./types-DQWTawIz.mjs";
|
|
2
|
+
import { R as InputApi, T as TextApi, U as I18nApi, c as UiNode, i as Finding, l as LayoutState, n as ElementChange, o as JsxState, r as ElementMotion, tt as StylesState } from "./types-B7maCx9u.mjs";
|
|
3
3
|
import { Log } from "@moku-labs/common/browser";
|
|
4
4
|
import { PluginCtx } from "@moku-labs/core";
|
|
5
5
|
|
|
@@ -1541,7 +1541,9 @@ type FilterDefinition = {
|
|
|
1541
1541
|
readonly glsl: string;
|
|
1542
1542
|
/**
|
|
1543
1543
|
* The quad program: the same body on a mesh, in the pass that draws the canvas (renderer README, "Kept pictures").
|
|
1544
|
-
*
|
|
1544
|
+
* A definition with inputs has one too: each input starts from the view's own input, and the mesh binds its held
|
|
1545
|
+
* chain result (`Bloom` rides it while its `strength` moves). `undefined` for a backdrop, an input from `"back"`, or
|
|
1546
|
+
* a body the rewrite does not fit.
|
|
1545
1547
|
*/
|
|
1546
1548
|
readonly quadSource: string | undefined;
|
|
1547
1549
|
readonly uniforms: readonly UniformSpec[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { $r as SnapshotOf, Fr as ClockSource, Hn as TypeTag, Jr as PlayerStateProvider, Lr as FakeClock, Nn as AnyFlow, Q as Config$2, Ur as Json, Vr as Config, Xr as SaveDoc, Yr as ProviderCall, a as Config$3, d as Manifest, gt as Orientation, hn as Config$1, jn as FeaturePlugin, n as AssetsIo, rt as PixiModule } from "./types-
|
|
2
|
-
import { o as AudioContextLike, s as Config$4 } from "./types-
|
|
3
|
-
import { J as StringTable, U as I18nApi, Y as TextKey } from "./types-
|
|
4
|
-
import { Et as PlatformProvider, It as audioPlugin, Nt as effectsPlugin, i as screen, t as createApp, wt as platformPlugin } from "./index-
|
|
1
|
+
import { $r as SnapshotOf, Fr as ClockSource, Hn as TypeTag, Jr as PlayerStateProvider, Lr as FakeClock, Nn as AnyFlow, Q as Config$2, Ur as Json, Vr as Config, Xr as SaveDoc, Yr as ProviderCall, a as Config$3, d as Manifest, gt as Orientation, hn as Config$1, jn as FeaturePlugin, n as AssetsIo, rt as PixiModule } from "./types-DQWTawIz.mjs";
|
|
2
|
+
import { o as AudioContextLike, s as Config$4 } from "./types-BTR9r8se.mjs";
|
|
3
|
+
import { J as StringTable, U as I18nApi, Y as TextKey } from "./types-B7maCx9u.mjs";
|
|
4
|
+
import { Et as PlatformProvider, It as audioPlugin, Nt as effectsPlugin, i as screen, t as createApp, wt as platformPlugin } from "./index-CFq7H9zQ.mjs";
|
|
5
5
|
import { AnyPluginInstance } from "@moku-labs/core";
|
|
6
6
|
|
|
7
7
|
//#region src/plugins/model/store/providers/memory.d.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Qr as Snapshot, Ur as Json } from "./types-
|
|
2
|
-
import { t as HeadlessApp } from "./headless-
|
|
1
|
+
import { Qr as Snapshot, Ur as Json } from "./types-DQWTawIz.mjs";
|
|
2
|
+
import { t as HeadlessApp } from "./headless-CWa3MHQi.mjs";
|
|
3
3
|
import { Log } from "@moku-labs/common/browser";
|
|
4
4
|
|
|
5
5
|
//#region src/plugins/flow/doors/types.d.ts
|
|
@@ -3746,28 +3746,51 @@ type AnyProjectionMotion = {
|
|
|
3746
3746
|
};
|
|
3747
3747
|
/**
|
|
3748
3748
|
* One pair of `ProjectionSpec.initialOnly`: a component and the fields of it that `view` gives a
|
|
3749
|
-
* view once, when it is born. The field names are checked against the component's own value.
|
|
3749
|
+
* view once, when it is born. The field names are checked against the component's own value. A
|
|
3750
|
+
* third element, `when`, covers only the views whose item answers true at their birth; `Item` is
|
|
3751
|
+
* the item `from` gives, so `when` reads its fields checked. The answer is fixed for the life of
|
|
3752
|
+
* the view. Without `when` the pair covers every view.
|
|
3750
3753
|
*
|
|
3751
3754
|
* @example
|
|
3752
3755
|
* ```ts
|
|
3756
|
+
* // The arc of every ring is the system's.
|
|
3753
3757
|
* const arc: InitialOnlyPair<ShapeValue> = [Shape, ["sweep"]];
|
|
3758
|
+
* // Only the hand of the stopwatch turns with the clock; its bolt keeps the rotation `view` gives.
|
|
3759
|
+
* type Part = { id: string; role: "bolt" | "restHand" };
|
|
3760
|
+
* const hand: InitialOnlyPair<TransformValue, Part> = [Transform, ["rotation"], part => part.role === "restHand"];
|
|
3761
|
+
* hand[2]?.({ id: "hand", role: "restHand" }); // true
|
|
3762
|
+
* hand[2]?.({ id: "bolt", role: "bolt" }); // false
|
|
3754
3763
|
* ```
|
|
3755
3764
|
*/
|
|
3756
|
-
type InitialOnlyPair<Value extends object> = readonly [ComponentHandle<Value>, readonly (keyof Value & string)[]];
|
|
3765
|
+
type InitialOnlyPair<Value extends object, Item = unknown> = readonly [ComponentHandle<Value>, readonly (keyof Value & string)[]] | readonly [ComponentHandle<Value>, readonly (keyof Value & string)[], (item: NoInfer<Item>) => boolean];
|
|
3757
3766
|
/**
|
|
3758
3767
|
* The `initialOnly` list of a projection: one pair for each value type of `Values`, each pair
|
|
3759
|
-
* checked against its own component
|
|
3760
|
-
* `[[Shape, ["swep"]]]`
|
|
3768
|
+
* checked against its own component, and each `when` typed with the item `Item` of `from`.
|
|
3769
|
+
* `projection()` infers `Values` from the list and `Item` from `from`, so `[[Shape, ["swep"]]]`
|
|
3770
|
+
* and a `when` that reads a field the item lacks are type errors.
|
|
3761
3771
|
*
|
|
3762
3772
|
* @example
|
|
3763
3773
|
* ```ts
|
|
3764
|
-
*
|
|
3774
|
+
* type Part = { id: string; role: "bolt" | "restHand" };
|
|
3775
|
+
* const fields: InitialOnly<[ShapeValue, TransformValue], Part> = [
|
|
3765
3776
|
* [Shape, ["sweep", "alpha"]],
|
|
3766
|
-
* [Transform, ["rotation"]]
|
|
3777
|
+
* [Transform, ["rotation"], part => part.role === "restHand"]
|
|
3767
3778
|
* ];
|
|
3768
3779
|
* ```
|
|
3769
3780
|
*/
|
|
3770
|
-
type InitialOnly<Values extends readonly object[]> = { readonly [Index in keyof Values]: InitialOnlyPair<Values[Index]> };
|
|
3781
|
+
type InitialOnly<Values extends readonly object[], Item = unknown> = { readonly [Index in keyof Values]: InitialOnlyPair<Values[Index], Item> };
|
|
3782
|
+
/**
|
|
3783
|
+
* The `when` of an `initialOnly` pair with the item type erased, as the world stores it. A method
|
|
3784
|
+
* signature, so a `when` typed for a game's item still reaches the erased spec.
|
|
3785
|
+
*/
|
|
3786
|
+
type AnyWhen = {
|
|
3787
|
+
bivariant(item: unknown): boolean;
|
|
3788
|
+
}["bivariant"];
|
|
3789
|
+
/**
|
|
3790
|
+
* One `initialOnly` pair of an erased spec: the component, its field names no longer tied to it,
|
|
3791
|
+
* and the `when` if any.
|
|
3792
|
+
*/
|
|
3793
|
+
type AnyInitialOnlyPair = readonly [ComponentHandle<object>, readonly string[], AnyWhen?];
|
|
3771
3794
|
/**
|
|
3772
3795
|
* A scene switch, as a plugin hands it to a projection with `projection.feed`: the scene left, the scene entered, and
|
|
3773
3796
|
* the share of the switch's bundles loaded, 0 to 1. The projection's `from` reads it as its third argument. `scenes`
|
|
@@ -3844,6 +3867,13 @@ type ProjectionSpec<Item, LayerName extends string, LiftName extends string, Pla
|
|
|
3844
3867
|
* rules of `mute()`, for every view of the projection and for its whole life. A `mute()` on the
|
|
3845
3868
|
* view adds to them, and its release keeps them. Left out, the projection writes every field.
|
|
3846
3869
|
*
|
|
3870
|
+
* A third element, `when(item)`, covers only some views: it is asked once, at the birth of a
|
|
3871
|
+
* view (for a view a warm window builds, on the warm item), and the answer holds for the life of
|
|
3872
|
+
* the view. A `when` that throws is a failed birth, `world:projection-failed`, as a `view` that
|
|
3873
|
+
* throws. A dev build warns `world:initial-only-changed` once per view when a later item would
|
|
3874
|
+
* answer otherwise; nothing changes in the view. `replace` asks the new spec's `when` on the item
|
|
3875
|
+
* each live view shows.
|
|
3876
|
+
*
|
|
3847
3877
|
* @example
|
|
3848
3878
|
* ```ts
|
|
3849
3879
|
* // The timer ring of a chest: born full, then the system `board.rings` draws its arc from `Now`.
|
|
@@ -3863,8 +3893,23 @@ type ProjectionSpec<Item, LayerName extends string, LiftName extends string, Pla
|
|
|
3863
3893
|
* });
|
|
3864
3894
|
* // The fade ends with the 0.42 the system wrote: no full ring, no `world:view-corrected`.
|
|
3865
3895
|
* ```
|
|
3896
|
+
* @example
|
|
3897
|
+
* ```ts
|
|
3898
|
+
* // The stopwatch: its bolt tweens home with the enter motion, its hand turns with `Now`.
|
|
3899
|
+
* export const stopwatch = projection({
|
|
3900
|
+
* name: "board.stopwatch",
|
|
3901
|
+
* layer: "marks",
|
|
3902
|
+
* from: (player: Player) => player.board.stopwatch.parts,
|
|
3903
|
+
* key: part => part.id,
|
|
3904
|
+
* view: part => [Transform({ x: part.x, y: part.y, rotation: part.rotation })],
|
|
3905
|
+
* motion: { enter: view => view.toRest(Transform, { ms: 300 }) },
|
|
3906
|
+
* initialOnly: [[Transform, ["rotation"], part => part.role === "restHand"]]
|
|
3907
|
+
* });
|
|
3908
|
+
* // The hand keeps the angle `board.hand` writes through the enter, a lift and the way home;
|
|
3909
|
+
* // the bolt still ends at its rest rotation.
|
|
3910
|
+
* ```
|
|
3866
3911
|
*/
|
|
3867
|
-
readonly initialOnly?: InitialOnly<Values>;
|
|
3912
|
+
readonly initialOnly?: InitialOnly<Values, Item>;
|
|
3868
3913
|
/**
|
|
3869
3914
|
* The item a closed window of this projection is kept built for, so it opens in the frame after the tap. While
|
|
3870
3915
|
* `from` does not show its key (`key(item)`, or the name of the projection without `key`), the engine builds its
|
|
@@ -3921,8 +3966,8 @@ type AnyProjectionSpec = {
|
|
|
3921
3966
|
from(player: Json, session: Json, sw: SceneSwitch | undefined): unknown;
|
|
3922
3967
|
key?(item: unknown): string;
|
|
3923
3968
|
view(item: unknown): ViewOutput;
|
|
3924
|
-
readonly motion?: AnyProjectionMotion; /** The `initialOnly` pairs, their field names no longer tied to the component. */
|
|
3925
|
-
readonly initialOnly?: readonly
|
|
3969
|
+
readonly motion?: AnyProjectionMotion; /** The `initialOnly` pairs, their field names no longer tied to the component, each with its `when` if any. */
|
|
3970
|
+
readonly initialOnly?: readonly AnyInitialOnlyPair[]; /** The item a closed window is kept built for, its type erased as `from`'s. */
|
|
3926
3971
|
warm?(player: Json, session: Json): unknown;
|
|
3927
3972
|
};
|
|
3928
3973
|
/**
|
|
@@ -3962,6 +4007,13 @@ type View$1 = {
|
|
|
3962
4007
|
loopOwed: boolean;
|
|
3963
4008
|
exiting: boolean; /** How the view came, then how it leaves. */
|
|
3964
4009
|
cause: MotionCause;
|
|
4010
|
+
/**
|
|
4011
|
+
* The `initialOnly` seed the view was born with, the table of its answers: what the release of a
|
|
4012
|
+
* `mute()` keeps. `undefined` for a view no pair covers. A `replace` moves it to the new spec's.
|
|
4013
|
+
*/
|
|
4014
|
+
seed: MuteTable | undefined; /** The answers of the `when`s at the birth (or the last `replace`): bit i for the i-th pair with a `when`. */
|
|
4015
|
+
mask: number; /** A dev build warned `world:initial-only-changed` for this view: it warns once. */
|
|
4016
|
+
maskWarned: boolean;
|
|
3965
4017
|
};
|
|
3966
4018
|
/**
|
|
3967
4019
|
* One mounted projection: its owner, the live views by key, the despawn queue, the items of the
|
|
@@ -4071,6 +4123,16 @@ type Dirty = {
|
|
|
4071
4123
|
* it, and `mute()` copies it before it adds a field.
|
|
4072
4124
|
*/
|
|
4073
4125
|
type MuteTable = ReadonlyMap<string, ReadonlySet<string>>;
|
|
4126
|
+
/**
|
|
4127
|
+
* The `initialOnly` of one spec, checked: its pairs, where the pairs with a `when` are, and the
|
|
4128
|
+
* frozen seed of every answer mask a view was born with so far. Views with the same answers share
|
|
4129
|
+
* one seed. A mask that covers no pair has `undefined`: no seed.
|
|
4130
|
+
*/
|
|
4131
|
+
type SeedBook = {
|
|
4132
|
+
/** The spec's `initialOnly` pairs, checked at `register` or `replace`: every one has a field, every `when` is a function. */readonly pairs: readonly AnyInitialOnlyPair[]; /** The indices in `pairs` of the pairs with a `when`, in order: the i-th is bit i of a mask. */
|
|
4133
|
+
readonly asks: readonly number[]; /** Answer mask to its frozen seed, filled the first time a view is born with that mask; `undefined` covers no pair. */
|
|
4134
|
+
readonly seeds: Map<number, MuteTable | undefined>;
|
|
4135
|
+
};
|
|
4074
4136
|
/**
|
|
4075
4137
|
* A mute's fields joined with a type's owned fields, and the owned set they were joined with.
|
|
4076
4138
|
*/
|
|
@@ -4106,8 +4168,8 @@ type ProjectionState = {
|
|
|
4106
4168
|
* the shared `initialOnly` seed a view of such a projection is born with. A view a listener of
|
|
4107
4169
|
* its spawn muted keeps that table, and the seed joins it.
|
|
4108
4170
|
*/
|
|
4109
|
-
mutes: Map<Entity, MuteTable>; /** The `initialOnly` seed of each registered spec that has
|
|
4110
|
-
initialOnly: WeakMap<AnyProjectionSpec,
|
|
4171
|
+
mutes: Map<Entity, MuteTable>; /** The `initialOnly` seed book of each registered spec that has the option, checked at `register` and `replace`. */
|
|
4172
|
+
initialOnly: WeakMap<AnyProjectionSpec, SeedBook>; /** The owned fields of each component type as a set, by the type's frozen `owned` list: made once. */
|
|
4111
4173
|
ownedSets: WeakMap<readonly string[], ReadonlySet<string>>; /** The muted and the owned fields joined, by the mute's field set: dropped when `mute()` or its release changes it. */
|
|
4112
4174
|
joinedMutes: WeakMap<ReadonlySet<string>, JoinedFields>; /** The `onConverged` listeners: the owners of elements, told after a restore or a load. */
|
|
4113
4175
|
converged: Array<() => void>;
|
|
@@ -4246,11 +4308,14 @@ type ProjectionApi = {
|
|
|
4246
4308
|
/**
|
|
4247
4309
|
* Swaps the stored spec of a registered projection. A mounted one has its layers checked against
|
|
4248
4310
|
* the current scene and runs the new `view` for every item on the next frame, directly. An
|
|
4249
|
-
* unmounted one is only stored; its next `mount` uses it.
|
|
4311
|
+
* unmounted one is only stored; its next `mount` uses it. The new spec's `initialOnly` `when`s
|
|
4312
|
+
* are asked on the item each live view shows now, before any view moves to the fields of its new
|
|
4313
|
+
* answers. Nothing changes when the call throws, also when a `when` throws.
|
|
4250
4314
|
*
|
|
4251
4315
|
* @param spec - The new projection, under the name it was registered with.
|
|
4252
|
-
* @throws {Error} When no projection of that name is registered,
|
|
4253
|
-
* `layer` or `lift` the scene does not declare
|
|
4316
|
+
* @throws {Error} When no projection of that name is registered, when a mounted one names a
|
|
4317
|
+
* `layer` or `lift` the scene does not declare, when its `initialOnly` is refused, or what a
|
|
4318
|
+
* `when` throws.
|
|
4254
4319
|
* @example
|
|
4255
4320
|
* ```ts
|
|
4256
4321
|
* // The dev hot swap in `ui`: the saved `view.ts` exports a new `boardItems`.
|
|
@@ -9003,7 +9068,13 @@ type KeptRecord = {
|
|
|
9003
9068
|
s1Version: number;
|
|
9004
9069
|
s2InputsVersion: number;
|
|
9005
9070
|
s2PictureVersion: number; /** The inputs the held results were drawn by; another first filter with inputs redoes stage 2. */
|
|
9006
|
-
s2Of: FilterSlotInputs | undefined;
|
|
9071
|
+
s2Of: FilterSlotInputs | undefined;
|
|
9072
|
+
/**
|
|
9073
|
+
* Stage 3 drew over the held results last (F126 stage 4): the filter's apply then wrote each input's scale and clamp for
|
|
9074
|
+
* them into the instance's numbers, which its mesh reads as they stand. False from the record's making, after stage 2
|
|
9075
|
+
* and after its results are released.
|
|
9076
|
+
*/
|
|
9077
|
+
heldPlaced: boolean; /** Dirty flags set by collect (P10.3) and by the key compare of the flush. */
|
|
9007
9078
|
dirtyS1: boolean;
|
|
9008
9079
|
dirtyS2: boolean;
|
|
9009
9080
|
dirtyS3: boolean; /** Keys of the last take and of the last drawn frame (P2.6), indices `KEY`. */
|
|
@@ -11731,11 +11802,18 @@ type FilterSlot = {
|
|
|
11731
11802
|
* const quad: FilterSlotQuad = { program: tintProgram, fu: tintOfRow.group };
|
|
11732
11803
|
* ctx.require(rendererPlugin).sync.filters.set(row, [{ filter: tintOfRow.filter, passes: 1, cache: "local", quad }]);
|
|
11733
11804
|
* quad.program.vertex?.entryPoint; // "mainVertex"
|
|
11805
|
+
* // A Bloom on a tile reads one input, `bright`: the mesh binds its held result under two names.
|
|
11806
|
+
* bloomOfTile.quad?.inputNames; // ["brightTexture", "brightSampler"]
|
|
11734
11807
|
* ```
|
|
11735
11808
|
*/
|
|
11736
11809
|
type FilterSlotQuad = {
|
|
11737
11810
|
/** The filter's body behind Pixi's mesh groups; `GpuProgram.from` of the text effects assembles and checks. */readonly program: PixiGpuProgram; /** The uniform group of the filter's instance; `undefined` for a filter that binds none. */
|
|
11738
11811
|
readonly fu: PixiUniformGroup | undefined;
|
|
11812
|
+
/**
|
|
11813
|
+
* The resource names of each input of the filter, its texture then its sampler, in declaration order: the mesh binds
|
|
11814
|
+
* the held chain results there. Empty or left out for a filter with no inputs; a game's own slot leaves it out.
|
|
11815
|
+
*/
|
|
11816
|
+
readonly inputNames?: readonly string[];
|
|
11739
11817
|
};
|
|
11740
11818
|
/**
|
|
11741
11819
|
* The stages of a filter's inputs and the seam of the kept-picture cache, on the filter's slot. `effects` fills it;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Br as Api$2, Pr as Api$4, Z as Api, kr as Api$1, ri as Api$3 } from "./types-
|
|
2
|
-
import { W as AnimApi, r as UiApi } from "./types-
|
|
3
|
-
import { R as InputApi } from "./types-
|
|
4
|
-
import { r as Repro } from "./headless-
|
|
5
|
-
import { i as ControlApp, o as InputOf } from "./types-
|
|
6
|
-
import { t as commands } from "./commands-
|
|
1
|
+
import { Br as Api$2, Pr as Api$4, Z as Api, kr as Api$1, ri as Api$3 } from "./types-DQWTawIz.mjs";
|
|
2
|
+
import { W as AnimApi, r as UiApi } from "./types-BTR9r8se.mjs";
|
|
3
|
+
import { R as InputApi } from "./types-B7maCx9u.mjs";
|
|
4
|
+
import { r as Repro } from "./headless-CWa3MHQi.mjs";
|
|
5
|
+
import { i as ControlApp, o as InputOf } from "./types-CThqFAwa.mjs";
|
|
6
|
+
import { t as commands } from "./commands-wfLkpPZC.mjs";
|
|
7
7
|
|
|
8
8
|
//#region src/visual/types.d.ts
|
|
9
9
|
/** The base commands of the `/control` door, keyed by their short names. */
|
package/dist/visual.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as VisualApp, c as VisualRenderer, d as VisualStart, f as VisualStep, h as VisualTolerance, i as CheckpointResult, l as VisualReport, m as VisualTestResult, n as runVisualTests, o as VisualOptions, p as VisualTest, r as defineVisualTest, s as VisualPage, t as parseVisualArgv, u as VisualSetup } from "./visual-
|
|
1
|
+
import { a as VisualApp, c as VisualRenderer, d as VisualStart, f as VisualStep, h as VisualTolerance, i as CheckpointResult, l as VisualReport, m as VisualTestResult, n as runVisualTests, o as VisualOptions, p as VisualTest, r as defineVisualTest, s as VisualPage, t as parseVisualArgv, u as VisualSetup } from "./visual-D62TNaW-.mjs";
|
|
2
2
|
export { type CheckpointResult, type VisualApp, type VisualOptions, type VisualPage, type VisualRenderer, type VisualReport, type VisualSetup, type VisualStart, type VisualStep, type VisualTest, type VisualTestResult, type VisualTolerance, defineVisualTest, parseVisualArgv, runVisualTests };
|