PPC scramble: animate it as a collapse -> hold-roll+shake -> recover -> lock
Reworks the flat per-row shear into the authentic sync-loss-and-relock
transition the playtesters described, on both render paths (surround
DrawDevSurface + glass ExpandPlaneToBGRA, native + rotated radar):
1. COLLAPSE -- the image squeezes to a thin centred vertical line.
2. HOLD (~0.8s, the window the card held the detuned CRTC) -- the line's
content scrolls WILDLY fast and decelerates, plus a violent per-frame
SHAKE (LCG jitter: vertical row bounce + horizontal scroll jitter).
3. RECOVERY (~0.5s) -- the line broadens back to full while the scroll,
tear and shake settle to zero.
4. LOCK -- clean full display.
Mechanism: FunkyVideo(on, dur) records start+hold; ScrambleParams is a
two-phase envelope (hold: deep collapse + decelerating scroll = integral of
v(t)=rollMax*(1-t/hold); recovery: smoothstep broaden + settle). The read
loops map the source through it -- `scale` sets a black-bordered collapse
band, `rollOff` SCROLLS (wraps) within it, `shear` is a per-row diagonal,
`shakeRow` bounces the source row. The SVGA16 owns the full hold+recovery
clock, so FunkyVideo(False) is a no-op (the card restoring sync is where the
recovery begins) -- the recovery isn't cut off when the 0.8s latch clears.
Tunable by eye (pod-monitor PLL look isn't recoverable from the binary):
BT_SCRAMBLE_COLLAPSE (0.03), _ROLL (9000 px/s), _SHAKE (10 px), _SHEAR (3),
_DUR (hold), _RECOVER (0.5s). BT_SCRAMBLE_TEST loops the transition for
tuning; BT_SCRAMBLE_CYCLE loops it stepping the roll speed.
Verified: Release links clean; surround loops the effect at slowed + true
full speed, all secondaries + radar collapse/roll/shake/recover together,
main view clean, no crash. SHIPPING with these defaults for playtester
feedback.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -16,21 +16,38 @@ secondary CRTs were being degaussed."* Full findings: `context/gauges-hud.md`
|
||||
@0x4a03f3 position (after the cylinder resolve, before the burst loop) — fires
|
||||
`GetGaugeRenderer()->SpecialEffect(scrambleVideo, damageType*0.2f)` once per
|
||||
EnergyDamageType message. `BT_DMG_LOG` prints `[ppc-scramble]`.
|
||||
- **B — visual:** `SVGA16::FunkyVideo` (was the 2007 stub) now arms `scrambleActive`;
|
||||
`SVGA16::ScrambleRowShift` (new) is the per-source-row horizontal shear, read by
|
||||
BOTH `DrawDevSurface` (surround/dock) and `ExpandPlaneToBGRA` (glass windows), so
|
||||
all secondary surfaces + the rotated radar shear together and the main 3D view
|
||||
(a separate timing chain) is untouched. Tunable: `BT_SCRAMBLE_SHEAR` (px/line,
|
||||
default 4), `BT_SCRAMBLE_ROLL` (px/sec, default 220). **`BT_SCRAMBLE_TEST=1`
|
||||
forces it always-on for tuning by eye without waiting for a PPC hit.**
|
||||
- **B — visual (animated recovery):** `SVGA16::FunkyVideo(on, dur)` (was the 2007
|
||||
stub) records the start + hold; `SVGA16::ScrambleParams` (new) is a two-phase
|
||||
envelope read by BOTH `DrawDevSurface` (surround/dock) and `ExpandPlaneToBGRA`
|
||||
(glass windows, native + rotated radar), so all secondary surfaces recover
|
||||
together and the main 3D view (separate timing chain) is untouched. The sequence
|
||||
per hit: **collapse** to a thin centred line → **HOLD** for the ~0.8 s the card
|
||||
held bad sync (content scrolls wildly fast + decelerating, plus a violent
|
||||
**shake**) → **RECOVERY** (~0.5 s: the line broadens back to full while
|
||||
scroll/tear/shake settle) → **LOCK** (clean). The read loops map the source
|
||||
through the envelope: horizontal `scale` sets a black-bordered collapse band,
|
||||
`rollOff` scrolls (wraps) within it, `shear` is a per-row diagonal, and a
|
||||
per-frame LCG `shake` bounces the row + jitters the scroll. Tunables (by eye —
|
||||
the pod-monitor PLL look is not recoverable): `BT_SCRAMBLE_COLLAPSE` (min band
|
||||
fraction, 0.03), `BT_SCRAMBLE_ROLL` (initial scroll px/s, 9000),
|
||||
`BT_SCRAMBLE_SHAKE` (px, 10), `BT_SCRAMBLE_SHEAR` (px/row, 3), `BT_SCRAMBLE_DUR`
|
||||
(hold s), `BT_SCRAMBLE_RECOVER` (recovery s, 0.5). **`BT_SCRAMBLE_TEST=1` loops
|
||||
the whole transition** for tuning without a hit; `BT_SCRAMBLE_CYCLE=1` loops it
|
||||
stepping the roll speed.
|
||||
- **C — non-stacking latch:** `L4GaugeRenderer::SpecialEffect` now ignores the
|
||||
re-arm while `scrambleVideoFlag` is set (matches the binary's `modified` latch);
|
||||
a second PPC during the window no longer extends it.
|
||||
- Verified: Release links clean; surround boots + runs with the effect forced on,
|
||||
every secondary MFD + the radar shear while the out-the-window view stays clean,
|
||||
no crash. **Open:** live PPC-fire confirmation (one arm per hit, non-stacking
|
||||
across two hits) + the by-eye shear tuning belong to the playtesters who filed
|
||||
the report — `k`/`roll` are not recoverable from the binary.
|
||||
a second PPC during the window no longer extends it. NB the SVGA16 animation runs
|
||||
the full hold+recovery on its own clock (`FunkyVideo(False)` is a no-op — the
|
||||
card restoring sync is where the recovery *begins*), so the recovery isn't cut
|
||||
off when the 0.8 s latch clears.
|
||||
- Verified [T2]: Release links clean; surround boots + runs with the effect looped
|
||||
(`BT_SCRAMBLE_TEST`) at both slowed and true full speed — every secondary MFD +
|
||||
the radar collapse/roll/shake/recover together while the out-the-window view
|
||||
stays clean, no crash (screenshots). **SHIPPING with the current defaults for
|
||||
playtester feedback.** Open: live PPC-fire confirmation (one arm per hit,
|
||||
non-stacking across two hits) + by-eye tuning of the envelope constants — none
|
||||
recoverable from the binary, so the testers who filed the report are the ground
|
||||
truth.
|
||||
|
||||
**Good news up front:** the engine half already exists in our tree under the
|
||||
**original VWE names** (`SpecialEffect` / `scrambleVideo` / `FunkyVideo`). Only
|
||||
|
||||
Reference in New Issue
Block a user