Files
Neutron/docs/gameplay/rocketship-motion-camera.md
T

61 lines
3.9 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Rocketship motion, facing and camera continuation
2026-11-03. Source guards in `tools/binary/rocketship_motion_camera.py` cover
ten EXE spans/seven virtuals, imports/constants and both authoritative image
hashes. Text file offsets are VA−400000. Complete REA replies/provider failures
are retained under `artifacts/rocket-motion-camera/rea-{helpers,camera}/`.
472480 Evidence `ev_24161f6af107c0a3282a5600306feca8c43be2a6448e12a3df408dfea38a70ce`;
458F90 `ev_80bdb649020f090d63625bbe8d731786d2097f32b00625615bfe5384197cd040`.
Use prior41A140/41A6C0 Evidence from rocketship.md. Several queried raw entries
remain unrecognized; bounded disassembly and copied-original probes supplement
them. Static evidence is distinct from original runtime execution.
## Corrections and recovered behavior
43DF70/41A140 normal update does not call controlled-input43E7E0. Game44DF80→
475A70 dispatches raw owner3CC separately. Fresh game registration can put input
before ship update; retained helpers precede the appended destination game.
Use the recovered `InputAfterPlayerUpdate` phase boundary, with all body work
before either callback. Earlier unconditional input-after-apply prose is stale.
- Full local rotation472B10/point472980 uses negative Z, negative X, negative Y,
with original lookup trig. This differs from some earlier provisional combined
Euler adapters. RocketOrientation is independently scoped and tested.
- 472480 addition: negative sum becomes360−abs(trunc(sum)); sum>360 subtracts360
once; equality360 survives. Negative fractional seams therefore lose fractions.
- Facing41ADF0 runs through the inherited animated update before horizontal
application. It skips while prior barrel timer670>0. Pitch/roll use shortest
±180 deltas; yaw only corrects positive>180. Rates are2/4/3 times dt. All-zero
differences clear the source facing flag.
- Incoming full velocity!=0 permits yaw+=bank*dt and stores previous bank618.
Side scalar is previousBank*.0181818176060915*(1−friction)*speed; rotated local
forward supplies X/Z, with cos(yaw)*side addedX and sin(yaw)*side addedZ. PreserveY.
- Enter/T starts latched674=1 while moving; it adds180*dt yaw and decrements/clamps
its timer. Horizontal publication skips while the POST-decrement timer>0.
R starts latched670=1 and adds270*dt roll, including its finishing frame.
These are turn/roll maneuvers, not speed boosts. Modal globals suppress new
latch changes; timer updates themselves remain separate.
- Input destination is(Up?20:Down?−20:0,currentYaw,−bank), with stopped neutral
roll0. Source engine mode2 Up,0 Down/stopped,1 positive coast.
## Camera and original observations
Eye local(0,200,−500), look local(0,50,200), both full-Euler transformed.
Native probe corrects an early static interpretation:419DE0 traces **look→eye**,
not root→eye. Hit response is look−.75*(look−hit), gain2; miss gain1.
Follow uses OLD shared eye with gain*dt*(detail<=1?.6:1.2). Aim vector is look−OLD
eye, independent of updated eye. Original DLL vector::angles uses squared-ratio
half-acos lookup, quantized inverse heading and signed14-bit pitch/yaw; no atan2.
`artifacts/rocket-motion-camera/original-results.json` records31 copied-original
transform, horizontal, auxiliary, facing and camera cases. The Win32 harness
executes copied EXE instructions plus our copied OMT2.dll trig/angles (hash
3ec41ead…54943), with synthetic body/input/ray accessors. Original entrypoint,
world integration and gameplay do not run. Source/generator/executable/log hashes
are retained. The committed numeric fixture is
`tests/GamePort.RocketFlightTests/original-motion-reference.json`.
RocketOrientation, RocketMotion and OriginalHeading.Angles compare against these
31 cases; scalar/vector tolerance.002 and exact integer angle outputs. Existing
14 input/14 vertical references remain independent. General x87 bit identity,
whole-game camera cadence and full renderer parity are not established.