Schema Changes for 0.3.0#5
Merged
Merged
Conversation
Implement the previously skipped MetafileType.Special chain so plot manifests and story thread files are discovered, typed, and validated. - New projects PG.StarWarsGame.LSP.Story (+ .Tests): StoryChainScanner walks campaignfiles.xml -> campaigns (*_Story_Name) -> plot manifests -> threads, recursing into tactical refs (STORY_LAND/SPACE_TACTICAL Event_Param1, LINK_TACTICAL Reward_Param7), behind a resolver shared by WorkspaceIndexer and BaselineBuilder - Type manifests as new StoryPlotManifest, threads as StoryParser, activating the dormant story param validation/completion; new tags/StoryPlotManifest.yaml provides manifest tag validation - Strict chain diagnostics on the referencing line (code "story-chain"): unresolved story names/plot entries/tactical refs, malformed manifests; warning for vanilla-shipped sources, error otherwise - Feature flag features.story.discovery (server default on, client setting default off, restart-based) with flag-off regression test - BaselineBuilder scans the game repository (MEG-aware) into FileTypeMap BREAKING CHANGE: SerializedBaseline.SchemaVersion is bumped 1 -> 2. Existing v1 baselines (downloaded or locally cached .aet files) no longer load and are discarded cleanly; baseline-backed validation is degraded until a regenerated v2 baseline is published. Regenerate with the BaselineBuilder against a game install. Closes #82
Dialog .txt scripts become a third language, scoped by the new pgproj directories.storyDialog node. - pgproj: directories.storyDialog in the canonical schema, loader, resolver, WorkspaceConfiguration/ProjectLayer StoryDialogRoots - schema: enums/StoryDialogCommand.yaml (17 commands, typed args, references); new machine-readable "untested" flag on enum values - Story project: line-based StoryDialogParser ([CHAPTER n], # comments, WAIT SPEECH normalization), schema-driven fact producer + dispatcher handlers (unknown command, arity, arg types, untested warning, localisation/speech/movie/SFX references), .txt diagnostics publisher (code "story-dialog"), scope-gated document sync for **/*.txt - XML cross-checks: Story_Dialog outside the storyDialog scope warns on the event; Story_Chapter pointing at an undefined chapter errors - Feature flag features.dialog.diagnostics (server default on, client setting default off, restart-based) gating everything through IStoryDialogScope.Enabled, with flag-off regression tests - 3289 unit tests green; 2 new E2E smoke tests (one catches the real vanilla typo "TEXTCOLOR255" in Dialog_tutorial_07.txt) Closes #89
…nostics (#83)
From-scratch story model with the campaign-wide graph and executable
evaluator that validation, filtering, and the future simulator share.
- StoryThreadParser: single StoryEvent class (prereq OR-of-AND groups,
positional params, column-accurate ranges incl. prereq tokens,
document-order tag list for the future canonical writer)
- StoryGraphBuilder: schema-driven typed edges (prereq/control/tactical/
flag) via the new ParamDefinition.ReferenceTypeName, AND/OR junctions
and portals with deterministic ids, campaign-global TRIGGER_EVENT
resolution with ambiguity tracking
- StoryEvaluator + immutable StoryRuntimeState: lifecycle, OR-of-ANDs
truth semantics, fixpoint reachability with control-edge rescue,
Tarjan prereq-cycle detection
- StoryModelService: lazy per-campaign models (chain associations from
the discovery scanner), validate-on-access invalidation by GameIndex
document versions, open-buffer-first reads, layer-aware resolution
- Graph diagnostics (code "story-graph", opt-in via
features.story.graphDiagnostics): dangling/cyclic prereqs, duplicate
and ambiguous event names, unreachable events, suspended plots nothing
activates, documented tag order, 31-char flag limit
- YAML: referenceType StoryEventName/StoryFlag/StoryPlotFile/StoryBranch
on StoryEventType/StoryRewardType params
Closes #83
Story event names, flags, and AI-notification ids become indexed
symbols across XML story threads and Lua scripts.
- XML (StoryDocumentSymbolCollector, schema-driven): <Event Name>
defines StoryEvent, SET_FLAG param 1 defines StoryFlag; prereq tokens
and reference-typed params emit column-accurate references
- Lua (LuaStorySymbolCollector): StoryModeEvents keys reference their
XML events; Story_Event("X") defines the StoryNotification id;
Check_Story_Flag references flags via the @xmlref schema data
- Hover/definition/references ride the existing generic handlers:
go-to-definition works from a Prereq token to its event and from a
STORY_AI_NOTIFICATION id to the Lua call that fires it
- Story references are campaign-scoped: index-wide duplicate and
unresolved-reference checks exempt them (the story graph diagnostics
own that); StoryParamReferenceHandler falls back to the raw
referenceType, activating the previously inert planet/unit/faction
existence checks in story params
- features.story.symbols (server default on, client setting default
off); flag state folds into the snapshot fingerprint so cached
parses invalidate on a flip
3382 unit tests green; E2E 71/74 (known pre-existing failure only)
incl. two new cross-language go-to-definition smoke tests.
Requires the eaw-schema counterpart (StoryEventType.yaml
StoryNotification + lua/api.d.lua typed @xmlref annotations).
Closes #84
…ions
Adds the executable story (gated by features.tools.storySimulator):
StorySimulator runs deterministic simulation over the campaign graph —
virtual clock for STORY_ELAPSED, control-edge trigger cascades
(TRIGGER_EVENT and friends; DISABLE_* rewards disable), flag table
feeding STORY_FLAGS, STORY_ELEMENT thread activation — with manual
intervention points for everything the model cannot decide: trigger
satisfaction, Lua Story_Event notifications (catalogue collected from
the campaign's indexed scripts), and tactical outcomes via the armed
victory/defeat events. Sessions live per campaign behind
aet/storySim{Start,Stop,GetState,SatisfyTrigger,SetFlag,AdvanceClock,
LuaNotify} plus an aet/storySimChanged push; the graph panel gains a
Simulate toolbar, live lifecycle colouring without re-layout, a flag
inspector, an intervention queue, and a step log. No game process, no
DAP, no file writes.
Closes #90
Closes #73 Closes #63
Adds tags that were added by recent patch
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.