logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Namespace Serenity.SequencePlayer.Infrastructure.Editor.Builder

    Classes

    CreateSequencePlayerWindow

    Step-by-step window for creating (or updating) one project's SequencePlayer asset chain — the ordered UnitySequenceDefinition assets and the single UnitySequencePlayerSettings that references them. Mirrors CreateSignalDefinitionWindow's shape: the window only collects input and renders results, SequencePlayerCreator does the actual validation and generation work — this window never mutates an asset itself.

    The only wizard that also touches the open scene. SequencePlayer has no installer (see SequencePlayerCreator's type doc) — the assets this wizard creates are inert until a UnitySequencePlayerService exists somewhere in a loaded scene. The Done step offers an explicit, Undo-registered "Place service in open scene" button rather than doing it automatically: scene mutation is a materially different, less reversible-by-review action than asset creation, and a project may already have a service placed (or intentionally place its own subclass) that this wizard must never duplicate silently.

    SequencePlayerCreator

    Generates (or updates) a SequencePlayer aggregate asset chain: an ordered list of UnitySequenceDefinition assets under <OutputFolderPath>/Sequences/ and one UnitySequencePlayerSettings directly under OutputFolderPath referencing them, in the exact order they were authored. Mirrors Serenity.Wave.Editor.Builder.WaveCreator's multi-asset shape (bottom-up resolve-or-create, then the referencing asset, full rollback on any failure) — sequence definitions are the "leaves", the settings asset is the "root" that references them, exactly like wave configs feeding a wave set.

    SequencePlayer is the only aggregate with no installer. Verified by reading UnitySequencePlayerService: it is a plain scene MonoBehaviour that resolves its own definitions on Awake() in three tiers — (1) an inspector-assigned array, (2) a label-loaded UnitySequencePlayerSettings tagged SEQUENCE_PLAYER, (3) loose label-loaded UnitySequenceDefinition assets carrying the same label — nothing in the composition root ever creates or configures this MonoBehaviour. Creating these assets and tagging them correctly is necessary but not sufficient: a UnitySequencePlayerService must also exist in a loaded scene, or the assets created here are never read by anything. Create(Input)'s result always carries a warning to this effect (SceneServicePlacementWarningMessage) — a wizard window collecting input, rendering results, and offering an explicit "place service in scene" action ships alongside this engine; every asset mutation lives here only.

    Both tiers carry the label. Verified against UnitySequencePlayerService.EnsureDefinitionsLoaded: it first looks for a labelled UnitySequencePlayerSettings and uses its Definitions if any exist; only when no labelled settings asset carries definitions does it fall back to loose labelled UnitySequenceDefinition assets. Since this engine always creates a settings asset referencing every authored definition, the fallback tier never actually triggers for wizard-authored content — but the definitions are retagged SEQUENCE_PLAYER regardless, so they still resolve correctly if a settings asset is later deleted or a definition is reused loose elsewhere.

    Stage Ids are never a resolution key. Verified by reading ExecuteStageAsync(ISequenceStage, CancellationToken) and PlayDefinitionAsync: stages are iterated strictly by list position; a stage's Id is only ever used for a verbose log line. Unlike a definition/settings Id collision (a genuine same-asset data-loss bug), a duplicate or blank stage Id within one definition is cosmetic — Validate(Input) only ever warns about it, never blocks.

    A wizard window collecting input and rendering results ships in a separate file (CreateSequencePlayerWindow); every asset mutation lives here.

    SequencePlayerCreator.DefinitionInput

    One authored sequence, resolved-or-edited by Id within <OutputFolderPath>/Sequences/.

    SequencePlayerCreator.DefinitionPreview

    Read-only summary of what Create(Input) would do for one definition.

    SequencePlayerCreator.DefinitionResult

    Outcome for a single definition within a SequencePlayerCreator.Result.

    SequencePlayerCreator.Input

    Everything needed to create or update one project's SequencePlayer asset chain.

    SequencePlayerCreator.PreviewResult

    Read-only summary of what a Create(Input) call would do. Never mutates the project.

    SequencePlayerCreator.Result

    Outcome of a Create(Input) call.

    SequencePlayerCreator.StageRowInput

    One authored stage row within a definition.

    SequencePlayerWizardPresets

    The Create Sequence wizard's built-in preset catalog. A stage's Kind is a free-form, opaque label — the generic SequencePlayer engine never interprets it, so these presets are illustrative starting shapes only, not an exhaustive catalog of "real" kinds. Every preset uses either an empty kind (a plain, unclassified stage) or "Custom" (a stage a UnitySequencePlayerService subclass is expected to handle). The "Custom" label is case-sensitive and deliberately matches the value produced by legacy-asset migration and by the cutscene stage mapping, so a subclass that dispatches on stage.Kind == "Custom" handles preset-authored and migrated stages alike.

    Structs

    SequencePlayerWizardPresets.DefinitionPreset

    One authored definition within a preset.

    SequencePlayerWizardPresets.Preset

    One full preset: display copy, the Settings Id it seeds, and every definition it authors.

    SequencePlayerWizardPresets.StageRowPreset

    One authored stage row within a preset definition.

    In this article
    © 2026 Serenity. All Rights Reserved