Support target-scoped trauma mechanics
This commit is contained in:
+21
-3
@@ -398,7 +398,10 @@ normalized events are `shot_fired`, `weapon_hit`, `skill_deployed`,
|
||||
`movement_snapshot`, `proximity_snapshot`, `firing_started`, `firing_stopped`,
|
||||
`reload_started`, `reload_completed`, `weapon_swapped`, and `tick`. Event
|
||||
details such as target, distance, critical state, source, movement, and nearby
|
||||
counts travel as typed event values.
|
||||
counts travel as typed event values. The event registry publishes authoritative
|
||||
field metadata where branches need a bounded contract. For example,
|
||||
`weapon_hit.values.headshot` is a boolean that distinguishes headshots from
|
||||
body shots.
|
||||
|
||||
The optional Action Family catalog provides authoring recipes for common
|
||||
mechanics. Applying a recipe copies its typed scenario inputs, state pools, and
|
||||
@@ -408,6 +411,12 @@ dependency. Adding another recipe appends branches. Replacing a program with a
|
||||
recipe requires confirmation because replacement discards the current branch
|
||||
graph.
|
||||
|
||||
A Talent may save an empty `captured_only` program while an author records its
|
||||
name, category, image, and source description. The registry marks that Talent
|
||||
`CONFIG REQUIRED`, and calculations exclude it. Changing readiness to `ready`
|
||||
or `requires_assumptions` restores strict branch, numbered-outcome, and
|
||||
description-placeholder validation.
|
||||
|
||||
The program graph uses three child tables:
|
||||
|
||||
- `conditional_effect_state_pools` defines agent- or target-scoped flags,
|
||||
@@ -418,14 +427,16 @@ The program graph uses three child tables:
|
||||
state mutations, and optional recipe provenance. Reducers convert event
|
||||
streams into counts, distinct or consecutive matches, sliding windows,
|
||||
durations, intervals, or derived values. Mutations can set, add, consume,
|
||||
clear, derive, or transfer state.
|
||||
clear, derive, or transfer state. A mutation may bind a target-scoped pool to
|
||||
the current event target, event actor, or another typed entity selector. Each
|
||||
target owns an independent value and expiry timer.
|
||||
- `conditional_effect_outcomes` applies Attribute modifiers, direct damage,
|
||||
restoration, resource costs, or markers. Each outcome names its target scope,
|
||||
value basis, optional resource or Attribute, combat timing, optional state
|
||||
band, and phase: `on_event`, `after_event`, `on_enter`, `on_exit`, or
|
||||
`while_active`. One typed value or expression exists for every variant
|
||||
required by the owning source. The common value models are static values,
|
||||
live Attribute percentages, event-field values, reducer output,
|
||||
live Attribute values, percentage-normalized Attribute values, event-field values, reducer output,
|
||||
source-defined scenario values, and OS Protocol upgrade scaling. Restoration
|
||||
outcomes may deliver their total immediately or continuously over an explicit
|
||||
duration.
|
||||
@@ -436,6 +447,13 @@ convert event streams into activations or derived values. The runtime applies
|
||||
state mutations, enforces pool bounds and expiry, emits outcomes in phase order,
|
||||
and records telemetry for each activation.
|
||||
|
||||
Each write to an expiring pool refreshes its timer. When a pool expires,
|
||||
`on_exit` outcomes evaluate stack thresholds and per-stack expressions against
|
||||
the final value before reset. The runtime records the bound target on emitted
|
||||
outcomes. A one-second target debuff with a one-second damage cadence can
|
||||
therefore resolve once at its refreshed shared expiry without inventing
|
||||
intermediate ticks.
|
||||
|
||||
Live Attribute references use a stable Attribute ID and read the authoritative
|
||||
loadout total that the builder captures for the evaluation pass. Percentage
|
||||
Attributes retain their displayed units, so an expression that applies a
|
||||
|
||||
Reference in New Issue
Block a user