Implement timed Invisible gadget and shared energy warnings
This commit is contained in:
1 parent
3527d33810
commit
1897dd2b90
44 files changed
+2466
-39
No files matched your search
@@ -0,0 +1,171 @@
|
||||
# Bubble gadget source contract
|
||||
|
||||
2026-11-01. Recovered static contract for the next gadget; **no Bubble runtime
|
||||
implementation or original-game execution is claimed by this investigation**.
|
||||
Original EXE SHA-256
|
||||
`f5281076e1a2492f2d61f87aae3f4544b6d0f535ebe33f9fbb6f78710fe1aea8`.
|
||||
Preferred VAs below map to file offsets VA−400000 in the supplied text section;
|
||||
`tools/binary/bubble.py` independently PE-maps and exports every retained site.
|
||||
Output is `artifacts/bubble/source-contract.json`:12 bounded span hashes,37
|
||||
instruction sites and6 virtual bindings. Originals were read only.
|
||||
|
||||
## REA evidence and scope
|
||||
|
||||
Two local REA/Ghidra sessions inspected the generated
|
||||
`artifacts/uncontrolled-phases/rea/Neutron.exe` copy, exported complete Evidence
|
||||
and closed/snapshotted under `artifacts/bubble/`.
|
||||
|
||||
| Procedure | Evidence / saved reply |
|
||||
| --- | --- |
|
||||
| Bubble constructor410840 | `ev_a0c9ee6d5757a741190f3dfcc093bdc7d7b802bcdcd2cbc029422550d34e7cb2`, `rea-effect/00.json` |
|
||||
| Start410CA0 | `ev_097f43eb24a762785dd495220c26a8995d541c69de3e9a88d4c195e24a04b1ce`, `rea-effect/02.json` |
|
||||
| Stop410D00 | `ev_d88f2e5a0b0b2ea4f47758084f3c2a6c605f18a1b8c7c4aa3b7cff0e9465b2e7`, `rea-effect/03.json` |
|
||||
|
||||
427FF0,4299B0,429A30 (`rea-core/`) and410AE0 (`rea-effect/01.json`) were not
|
||||
recognized as procedures by the native profile. Numeric VA queries fell back to
|
||||
unmapped file-offset errors; the complete diagnostics remain on disk. These are
|
||||
not successful decompilations. Contracts below use reviewed fixed instruction
|
||||
ranges/virtual bindings, supported by the successful constructor/start/stop
|
||||
Evidence. No unchanged failed query was repeated. Supplementary objdump output
|
||||
is retained as `equip.asm`, `cleanup.asm`, `class.asm`, `position.asm` and
|
||||
`exe.asm`; source hashes and mapping keep this independently reviewable.
|
||||
|
||||
## Owners and layout — recovered
|
||||
|
||||
The [group0 menu](gadget-controls.md) names item0 **BUBBLE** and maps its practice
|
||||
to VR01. Global signed WORD4F0588 is equipped raw mode; source movement mode is
|
||||
a separate WORD at Jimmy complete7C4/interface704. The Bubble is owned at Jimmy
|
||||
completeA14/interface954. Constructor42232C calls410840, stores the result42233C
|
||||
and initially hides it at42236E. It is not a free-moving projectile or Jimmy's
|
||||
physical body.
|
||||
|
||||
Bubble complete vtable492970; game interface is complete+C8 with table49250C.
|
||||
Game slot3C4 binds410AE0 update; generic1C binds464130. Constructor4108F7 registers
|
||||
FourCC `3BUB`; class name is `C3DBUBBLE`. Constructor4352F0 supplies the sprite
|
||||
base. Own body integration/triangle collision is disabled through471030(0) and
|
||||
4710C0(0); Jimmy's body instead changes radius/factor when equipped.
|
||||
|
||||
| Bubble complete field | Purpose established here |
|
||||
| --- | --- |
|
||||
|90..9C|RGBA sprite color; expanding/collapsing writes all four components|
|
||||
|AC/B0|Sprite width/height; initially200/200 via4645F0(200)|
|
||||
|B4/B8|Source/destination blend enums6 /1 or7|
|
||||
|57C|Integer base pulse size240, initialized410935|
|
||||
|584|Copied archive name `RetainedSprites.omt`|
|
||||
|5E8|Loaded original canvas resource; constructor477890(archive,1)|
|
||||
|600|Float visual timer, incremented each effect update|
|
||||
|604|Float pulse `sin(timer*10)*30` while active|
|
||||
|610|Float fade scalar|
|
||||
|614/615/616|Active / expanding / collapsing flags respectively|
|
||||
|
||||
The retained resource is Canv1 of RetainedSprites.omt, not an ASE sphere. Exact
|
||||
archive/pixels/tutorial inventory is independently documented by the asset
|
||||
investigator. The sprite's full camera-facing transform remains a rendering
|
||||
adapter dependency; the ellipse/pulse does not justify inventing sphere geometry.
|
||||
|
||||
## Equip and cleanup — recovered
|
||||
|
||||
Complete Jimmy174→428D50 dispatches item0 to428F61. The common menu caller closes
|
||||
and invokes cleanup178 first; arbitrary calls to174 without that caller are not
|
||||
equivalent. Bubble branch order:
|
||||
|
||||
1. Require the owned Bubble pointer. If absent, return without a new effect.
|
||||
2. If runtime Practice state(0,9)==2, reset that state and load `vr01.gam` at
|
||||
428FCA using existing return strings. This precedes energy and visual-state tests.
|
||||
3. At428FDA require energy4F83D4>0 or Jimmy complete9F8 nonzero. The latter is
|
||||
retained here as an unnamed exemption flag; its complete ownership is open.
|
||||
Failure writes raw mode−1 at428FFA and returns.
|
||||
4. Reject Bubble active614, collapsing616 or expanding615 before starting another
|
||||
transition. These flags are not a generic cooldown invented by the port.
|
||||
5. At429049/429058 invoke game110/100 for **radius160/factor0.415**; write raw mode0
|
||||
at429065, movement mode2 at429072 and max controller speed1350 at42907B.
|
||||
6. Call410CA0 at429085. Start sets expanding615, timer600=0, unhides the sprite
|
||||
if necessary and chooses blend6/1 (additive) or6/7 (conventional alpha) from
|
||||
graphics flag509A13. It does not clear other transition flags itself.
|
||||
7. Start loop SFX2 at429093..4290A1 only if Jimmy completeA40 handle is−1, then
|
||||
animation refresh148. Source animation selection also depends on movement/body.
|
||||
|
||||
Cleanup178→427FF0 dispatches raw mode0 to428037. With the owned Bubble it sets
|
||||
Jimmy A20=0.5, movement mode0, **max controller speed650**, calls410D00 to begin
|
||||
collapse, then **separately clears expanding615** at42806B. It stops the A40 loop
|
||||
and resets handle−1; invokes radius60/factor1.265; writes raw mode−1 at4280BB.
|
||||
The source's explicit650 cleanup value must not silently be replaced by the
|
||||
constructor's600 or by generic authored-state restoration. The A20 consumer is
|
||||
not closed here. Missing-pointer cleanup falls to the shared raw−1 tail without
|
||||
these body/effect changes. Cleanup also restores selected-device HUD3 via the
|
||||
common prelude. It does not directly transfer raw controlled-pointer ownership.
|
||||
|
||||
## Active input, movement and interactions — recovered boundary
|
||||
|
||||
426030's input callback retains its existing global/game/control predicates.
|
||||
Within it426264 tests **movement mode2**, not raw mode0, then426272..426280 calls
|
||||
42A920 with `−0.5*dt`. The common energy helper owns VR exemption, clamp and warning
|
||||
sounds; no duplicate exemption is implied by the Bubble branch. After adjustment,
|
||||
426285..42629F invokes cleanup178 if energy<=0. Consequently controlled Bubble
|
||||
input drains0.5 energy/second outside exempt tutorial handling. Loss of input
|
||||
ownership can stop this branch while the independently registered effect still
|
||||
updates. This is not permission to pause every clock on raw-control loss.
|
||||
|
||||
The same branch positions the sprite using current camera eye509A50+44..4C:
|
||||
`direction=normalize(JimmyRoot+(0,100,0)−eye)`;
|
||||
`BubbleRoot=JimmyRoot+(0,50,0)−direction*80` (4262A5..4263DA).
|
||||
This is camera-relative and differs from simply drawing a sphere centered at
|
||||
JimmyRoot. Zero-length normalization/imported-vector rounding remains open.
|
||||
|
||||
Generic input438B1E..438B98 maps movement modes1 **and2** to shared439900, while
|
||||
mode0 maps438BC0 and3 maps43A120. The prior air-steering recovery of439900 is useful,
|
||||
but does not close Bubble's complete jumping/body/mode transition behavior.
|
||||
Supported Jimmy wrapper4246A9..4246E3 explicitly restores live radius160/raw mode0
|
||||
or60 otherwise, before the later movement/fire phases. A live Bubble integration
|
||||
must preserve source authored/live radii and movementmode2, including support.
|
||||
|
||||
Ordinary primary fire4266AC rejects raw mode0 before controller-speed-zero,
|
||||
SHOOT and the ray scan. Jetpack dispatch also skips raw mode0 at4260D3. Bubble
|
||||
must not keep the ordinary beam or powered-jump path active merely because item3
|
||||
is owned. Other generic movement/jump paths still need caller-complete recovery.
|
||||
Source callbacks42A870 and42A8D0 return early for raw mode0 before their energy/
|
||||
score/flash effects, and42AB0E skips an additional SFX190. Their complete callers/
|
||||
meaning are not traced here; this establishes specific bypasses, **not** universal
|
||||
invulnerability against every hazard, actor or script.
|
||||
|
||||
## Sprite transitions — recovered, with numeric projection limits
|
||||
|
||||
410AE0 first increments float timer600 bydt, then processes flags in priority
|
||||
order active614, expanding615, collapsing616:
|
||||
|
||||
- **Active:** pulse=sin(timer*10)*30; width=(float)integer57C=240 and height=240+pulse.
|
||||
If509A13 is true, RGBA becomes(1,1,1,0.5); otherwise existing RGBA is retained.
|
||||
This does not geometrically scale Jimmy or the sprite during fade.
|
||||
- **Expanding:** scalar610=timer; strictly `timer>double1` clamps scalar1, sets
|
||||
active614 and clears expanding615. RGBA=(scalar,scalar,scalar,scalar).
|
||||
At exactly1 it remains expanding until a later update.
|
||||
- **Collapsing:** scalar610=1−timer; strictly scalar<0 clamps0, clears collapsing616
|
||||
and hides the sprite. RGBA=(scalar,scalar,scalar,scalar). Exactly0 retains collapse
|
||||
until a later update. Stop410D00 sets collapsing616, clears active614 and timer0;
|
||||
Jimmy cleanup must additionally clear expanding615 or expansion retains priority.
|
||||
|
||||
The Python projection retains these state/strict-boundary distinctions and
|
||||
single-precision stored values. It does not claim x87 intermediate/fsin bit parity
|
||||
or original runtime observations. Blending both RGB and alpha during fade can
|
||||
change perceived brightness; replacing it with alpha-only is a behavior change.
|
||||
|
||||
## Validation, current implementation and next action
|
||||
|
||||
Six Python source-contract groups pass in `artifacts/bubble/tests.log`: original
|
||||
identity/span/site/virtual guards and offsets, equip order/flags, movement2 drain,
|
||||
strict expand boundary/color without size scaling, active pulse/graphics alpha,
|
||||
and cleanup priority/strict-negative collapse. This is static/source-projection
|
||||
validation, not native Bubble gameplay or an original game capture.
|
||||
|
||||
The port's group0 selection/practice already exposes Bubble, but **this agent made
|
||||
no runtime changes**. Raw mode0 radius160 is a named future case; the existing
|
||||
ordinary static Jimmy body subset must not be advertised as complete Bubble
|
||||
physics. Recommended next coherent implementation: retain an owned sprite with
|
||||
original Canv1, source transition flags and camera-relative placement; integrate
|
||||
source radius/factor/maxspeed/movement2/ordinary-fire cancellation together,
|
||||
including source cleanup650, controlled−0.5dt and independent visual clock.
|
||||
First recover the generic mode2 jump/body transitions and actual VR01 support/
|
||||
collision class coverage, then test equip→expand→move/jump→empty/Tab cleanup→fade
|
||||
and tutorial/RETURN persistence. Full hazard/AI immunity and renderer orientation
|
||||
remain explicit gates. Invisible is the primary's selected next playable slice;
|
||||
this Bubble contract is ready for that later chunk without speculative physics.
|
||||
@@ -0,0 +1,175 @@
|
||||
# Bubble / Invisible resource and tutorial follow-up
|
||||
|
||||
2026-11-01. Original asset parsing, decoded-pixel inspection and local REA static
|
||||
analysis. Originals remain untouched. This report does not establish original
|
||||
gameplay execution, enemy detection, tutorial completion or native Windows runtime.
|
||||
Primary selected Invisible as the next bounded gameplay implementation; Bubble
|
||||
resource observations are retained for the later effect.
|
||||
|
||||
## Evidence and reusable output
|
||||
|
||||
`tools/extractors/gadget_followup_assets.py` inventories exact original resources,
|
||||
seven current Jimmy clips and both authored tutorials. It retains archive/payload
|
||||
hashes, resource byte offsets, GAM property offsets/raw bytes and duplicate tags.
|
||||
It also guards the source image identities and eight bounded meter code spans.
|
||||
No game code is executed by this utility. Generated report and inspected images:
|
||||
`artifacts/gadget-followup-assets/resources.json`, `orangebubble.png`,
|
||||
`controls_109.png`, `controls_111.png`, `canvas_21.png`, `canvas_22.png`.
|
||||
|
||||
```bash
|
||||
python3 tools/extractors/gadget_followup_assets.py ../Original \
|
||||
--output artifacts/gadget-followup-assets/resources.json \
|
||||
--meter-output artifacts/extracted/invisible-meter
|
||||
python3 -m unittest discover -s tests -p test_gadget_followup_assets.py -v
|
||||
```
|
||||
|
||||
`export_meter(original, output)` writes `meter.json` schema1, reference640×480,
|
||||
exactly two texture records and original decoded RGBA/PNG files. Records contain
|
||||
id/name/width/height/path/png/sourceOffset/sourceBytes/sourceSha256/rgbaSha256.
|
||||
Both names/dimensions are checked before any files are written. Original root,
|
||||
its subtrees and ancestor outputs are rejected. Pixel files are neither recolored
|
||||
nor resized; state/tint/geometry belong to the caller. Six checks pass in
|
||||
`artifacts/gadget-followup-assets/tests.log`: exact assets, tutorial source offsets,
|
||||
duplicate identity, output protection, pixel export and guarded meter spans.
|
||||
|
||||
## Invisible uses the existing Jimmy family — asset facts
|
||||
|
||||
`png/jimycarl.png` is256×256; all65,536 texels have alpha255. The existing
|
||||
prepared Jimmy atlas therefore has no translucent source pixels to replace for
|
||||
this effect. Source `jimstop.ASE` has426 vertices/814 faces, two samples at10fps,
|
||||
480 ticks/frame, and supplies3,551 UV entries/814 UV faces. `jimrun`,
|
||||
`jimbackpedal`, `jimjump`, `jimfall`, `jimfly` and `jimshoot` have the same
|
||||
vertex/face counts and no UV tables; existing preparation uses the standing UV
|
||||
topology. This report verifies counts and resource identity, not every morph's
|
||||
original interpolation phase.
|
||||
|
||||
No additional ASE or PNG is required for the recovered Invisible material path.
|
||||
[Invisible source](invisible.md) owns the activation/timer/state interpretation;
|
||||
[material report](gadget-blending.md) already traces complete slot114→40E4A0
|
||||
positive RGBA/material alpha and source blend enums. Existing port fragment
|
||||
cutout occurs before multiplying material opacity, so alpha0.7 does not discard
|
||||
this fully opaque source atlas. Original fixed-function alpha-test interaction
|
||||
and full material-state parity remain separate renderer questions.
|
||||
|
||||
The original control strip Canv111 `BmenuLInvisible` visibly labels primary mouse
|
||||
and Ctrl as INVISIBLE. Bubble strip109 separately labels mouse movement/forward,
|
||||
jump and Ctrl/Insert keyboard equivalents. These inspected pixels corroborate
|
||||
the input descriptions; they do not establish a held/edge policy, timers or
|
||||
power consumption. Menu/HUD resources already exported for both items are in
|
||||
[gadget assets](gadget-assets.md); no invented icons are needed.
|
||||
|
||||
## Recharge-meter resources and source chain
|
||||
|
||||
Original `screens.omt` SHA256:
|
||||
`e8e95231f5d302b41f4fbf33df1c5a08ce4645370f9f519527ff1727b73b7a5e`.
|
||||
|
||||
| Canvas | Source offset / bytes | Exact decoded dimensions |
|
||||
| --- | --- | --- |
|
||||
|21 `meter` |0x88E18 /8118 |30×110, border/backplate |
|
||||
|22 `metercolor` |0x8C5D8 /9138 |30×110, original multicolor fill |
|
||||
|
||||
REA inspected private hashed copies. EXE identity is
|
||||
`f5281076e1a2492f2d61f87aae3f4544b6d0f535ebe33f9fbb6f78710fe1aea8`;
|
||||
DLL identity is `3ec41ead011adf56387a6dbd4580e5b5a9721b5f8020c8a56420f42824354943`.
|
||||
Complete replies, exports and closed snapshots are in
|
||||
`artifacts/gadget-followup-assets/rea-meter/` and `rea-meter-dll/`.
|
||||
The renderer/alignment follow-up is exported/closed in `rea-meter-surface/`.
|
||||
|
||||
| Source function | REA Evidence |
|
||||
| --- | --- |
|
||||
|401430 menu construction |`ev_e7355ffccf1c4066e58d93e229e4a89662e01045e555d178cb2c11b1ddb5b42b` |
|
||||
|402D70 canvas placement |`ev_37b8296fe0ea52d6b1d36ba096c60700a7dca3986cb7966b8d6d2884253bf4f0` |
|
||||
|4037F0 meter percent |`ev_525ca303ce70c16f524063053ebdd9fecd82054cf480d8f2f30f1ec0d7e08333` |
|
||||
|DLL10029430 canvas render |`ev_f133d0c29cd7b2969814c4b89df37e369776d954543980c93dc69bc3ccb7e579` |
|
||||
|DLL10029180 canvas construction |`ev_856445a19d924cf5ec157575da27686731caca9a1a611895a98d269fe31c4b03` |
|
||||
|DLL10037AC0 draw_surface |`ev_143b978a715b32486294f27aa987c926c0cf8f52e09a2116b81ec34803d9962b` |
|
||||
|DLL10029870 update_logic |`ev_5021f9ff80b9087cafdf449976e363921d6159833f003efe15870f24932d8343` |
|
||||
|DLL10029890 compute_auto_align |`ev_b963c3e443054b1425af94a27efd37cc157f6dd2070d2d87cbb2a78f72dc083e` |
|
||||
|DLL10029930 get_canv_wordsize |`ev_d766e30f3466351eaea497f58546f564563849cf9fdc269c42b131c01ac542a5` |
|
||||
|
||||
Constructor401430 opens `omt/screens.omt` and binds global4F7CB0 to canvas21 at
|
||||
4017CB, global4F8028 to canvas22 at401865 through402D70→menu454/402E30. Literal
|
||||
coordinate arguments are(320,7) and(322,4). Constructor sets sprite source blend6,
|
||||
destination1 or7 according to graphics509A13; RGBA initiallywhite. Runtime
|
||||
menu484/488 show/hide both;48C/490 change fill tint to red(1,.2,.2,1)/white.
|
||||
Those latter caller/state branches are guarded by [Invisible](invisible.md).
|
||||
|
||||
4037F0 (raw0x37F0) clamps only negative percent to0, writes fill width
|
||||
`screenWidth/640*27`, and height `screenHeight/480*percent*1.04`. Global4F6560 is
|
||||
screen width,4F655E height. The multiplier at48D908/raw8D908 is a stored double
|
||||
**1.04**, not0.01. At100 percent the logical height is104. Width/height are fields
|
||||
AC/B0; source sprite placement44/48 stays separate. No forced100 clamp is proven
|
||||
in this leaf. Caller supplies the actual timer/recharge conversion.
|
||||
|
||||
Texture resize is **full-image stretch**, not percentage UV cropping. Canvas
|
||||
render10029430 obtains custom AC/B0 dimensions when flagC4 bit0 is set, then
|
||||
forwards the original canvas, cached offsets, dimensions and RGBA90 to renderer
|
||||
slotB0.402D70 sets flagC4 to1. DX draw_surface10037AC0 builds a rectangle using
|
||||
the supplied width/height, with source UV0..0.9999 for the single-texture path;
|
||||
the tiled path distributes the complete source canvas across those dimensions.
|
||||
Percentage does not enter UV selection. The modern texture uses0..1 over the
|
||||
exact decoded image; legacy edge epsilon/texture padding remain renderer details.
|
||||
The tint multiplies this original gradient once; no replacement solid fill or
|
||||
partial-source gradient crop is evidenced. Source48C/490 tint leaves are already
|
||||
in the guarded192-byte meter_tint span0x3730..37F0.
|
||||
|
||||
Modern layout policy: interpret the source coordinates using a640×480 logical
|
||||
viewport with uniform widescreen scale, background rectangle(320,7,30,110),
|
||||
fill width27 and bottom114/top `114−1.04*percent`. This preserves source initial
|
||||
bottom placement while changing height. It is explicitly not a fully closed
|
||||
original pixel-position recovery:402D70 writes alignment modesBC/C0=3;
|
||||
constructor initializes cached offsetsA0/A4=0, while engine update_logic10029870
|
||||
can recompute−half-size offsets through10029890. Canvas render forwards cached
|
||||
offsets and dimensions. Whether these menu sprites enter that engine logic pass,
|
||||
and the exact frame of recomputation, remain unresolved. Pseudocode for402D70
|
||||
has incorrectly recovered parameters; its arguments/formulas above are checked
|
||||
against the guarded instructions, not copied from its prototype.
|
||||
|
||||
## Original tutorial fixtures
|
||||
|
||||
| Data | VR01 Bubble | VR03 Invisible |
|
||||
| --- | --- | --- |
|
||||
|GAM SHA256 |`7938214fb62784fcb34245491342a5f33e3615bdc178e4883a9e285e6869904f` |`8acc4d3b8c416c41c1900ac0b1f895ab5819781e5dd87d19a1f177414660d5b2` |
|
||||
|Entity count |16 |67 |
|
||||
|Scene shape |`VRRoom`,60 vertices/80 triangles |`Box01`,280 vertices/424 triangles |
|
||||
|PHONEBOOTH STRT offset |0x45C |0x406 |
|
||||
|Authored root |(−2678.0381,87.3322,−2783.4011) |(−292.9982,160.3451,−2467.5544) |
|
||||
|Yaw |290 |290 |
|
||||
|Intro |`bu`,3MCA0xA61 |`inv`,3MCA0x8EEE |
|
||||
|Voicepractice IDs |24/23/22 |21/20/37 |
|
||||
|Return LOAD offsets |0x83C radius400;0x1631 radius300 |0x94DE radius300 |
|
||||
|
||||
Both intros serialize PlayerControlled=NULL and NextTrigger=default. VR01 has
|
||||
DeactivateInv=1; VR03 omits that property. Absence is not evidence forfalse;
|
||||
the constructor/default binding is documented separately by the Invisible
|
||||
investigator. VR03 source SoundIndex0/1/2 properties occur at0x90F7/0x9176/0x91F5.
|
||||
The voice bank also contains invisibility4/ID38, but this intro does not use it.
|
||||
|
||||
VR03 contains eight actual3SOL at source offsets0x7BA,14B0,1EB7,342B,4828,4D2F,
|
||||
5736,633B. All share ObjectTag `C3DYOKIANSOLDIER`; keep actor identity by instance/
|
||||
source offset, never collapse them into one dictionary/tag lookup. Each serializes
|
||||
AIState2, VisibleRange2500,FOV359,TargetNameJIM1. These data values do not recover
|
||||
the target-detection algorithm or prove combat/AI is implemented.
|
||||
Literal patrol links contain two missing names: yok3→`tok4`, and soldier0x5736
|
||||
starts at `fyoy1`; supplied patrols contain `yok4`/`fyok1`. Preserve these original
|
||||
strings rather than silently repairing them. VR01 contains no3SOL.
|
||||
|
||||
A meaningful bounded Invisible fixture can load actualVR03/PHONEBOOTH, skip or
|
||||
complete its source intro, and exercise equipped/ready/activation/expiry/recharge/
|
||||
cleanup against the current player, atlas and meter. It must establish item2
|
||||
availability through the existing inventory/PostLoad contract. No fake enemy or
|
||||
invented vision/combat response is needed to verify this first effect. Tutorial
|
||||
navigation, stealth detection and trophy/RETURN completion remain separate tests.
|
||||
|
||||
## Bubble assets retained for later
|
||||
|
||||
`RetainedSprites.omt` Canv1 `orangebubble` at0x17FCE/66322 bytes decodes146×146,
|
||||
with15,824 opaque and5,492 transparent pixels. RGBA SHA256:
|
||||
`a3a678c47c1ce94946b1136560a84f3ef86c6884b981256a9fbff62fe8a988e4`.
|
||||
This is confirmed by the Bubble constructor's explicit archive/ID binding, not
|
||||
just its name: [Bubble report](bubble.md), constructor410840 REA
|
||||
`ev_a0c9ee6d5757a741190f3dfcc093bdc7d7b802bcdcd2cbc029422550d34e7cb2`,
|
||||
saved/exported/closed in `artifacts/bubble/rea-effect/`. No new ASE is indicated.
|
||||
SoundEffects Wave2/3/106 are gravitybubble/gravitybubbleoff/bubble boing; serialized
|
||||
resource identities alone do not establish repeat/stop ownership. Bubble pulse,
|
||||
growth/fade/collision and billboard orientation belong to that system report.
|
||||
@@ -1,5 +1,9 @@
|
||||
# First playable gadget implementation
|
||||
|
||||
Historical first slice. [Invisible continuation](invisible-implementation.md)
|
||||
supersedes its unimplemented Invisible/shared energy-warning items; other limits
|
||||
below remain scoped to the recorded2026-10-27 implementation.
|
||||
|
||||
2026-10-27. User-directed gameplay continuation; collision checkpoint35a2a66/
|
||||
0272f7b remains parked. This implements the original gadget screen and the combined
|
||||
shrink-ray/jetpack device, with a bounded3SOL target consumer. It does not complete
|
||||
|
||||
@@ -0,0 +1,108 @@
|
||||
# Invisible gameplay continuation
|
||||
|
||||
2026-11-02. Implements original item2/raw mode2 and shared energy warnings.
|
||||
Collision recovery remains parked at35a2a66/0272f7b; the preceding gadget
|
||||
source/packages7b5230c remain a separate verified milestone.
|
||||
|
||||
## Coverage and evidence
|
||||
|
||||
| System | Original contract | Port / remaining boundary |
|
||||
| --- | --- | --- |
|
||||
| Selection428E51 | Display2 precedes actual equip;9F8 tutorial override | Failed equip can retain display2/raw−1; successful equip starts both clocks0 |
|
||||
| Wrapper424E80 | After base movement; any controlled pointer | Separate from Jimmy input identity; raw NULL freezes/hides meter |
|
||||
| Activation | Recharge exactly7, energy>2/override, fixed−2 | Initial7-second recharge;7-second active timer; held reactivation; jump blocks activation only |
|
||||
| Material114/FC/target55D | Alpha.7, indexed blend flash; target eligibility | Existing Jimmy draw; targetability retained, full enemy AI consumers absent |
|
||||
| Meter4037F0 | Canv21/22, full gradient stretch, size/tint | Exact original pixels; logical placement/uniform scale is declared modern policy |
|
||||
| Companion/cleanup427FF0 | Immediate hide, D0/214 flags,9E8 restore guard | Separate movement/body flags; body integration gated without blanket AI pause |
|
||||
| CAM4165B7/MCA43129A | Default DeactivateInv1, named Jimmy lookup | Prelude separate from raw438 preparation; AI-null retains effect |
|
||||
| Energy42A920 | Scalar4F83D4 and warning latch4F83DC | Shared owner and80/182 callback order/hysteresis across ordinary loads |
|
||||
| Bubble follow-up | Equip/visual/drain/cleanup recovered | Runtime pending full movementmode2/jump/body contract |
|
||||
|
||||
Static reports retain hashes, VAs/file offsets, guarded bodies/sites, complete
|
||||
REA Evidence, exports/snapshots and provider errors: [Invisible](invisible.md),
|
||||
[assets/meter](gadget-followup-assets.md), [shared energy](player-energy.md),
|
||||
[independent review](invisible-review.md) and [Bubble](bubble.md). No new whole
|
||||
original-game execution was performed. The retained complete42A920 REA record
|
||||
was reused rather than repeating that investigation.
|
||||
|
||||
## Implementation and ownership
|
||||
|
||||
LabSimulation owns InvisibleGadget and invokes it after controlled movement,
|
||||
before its existing owned jetpack-effect phase. PlayerSceneBinding supplies both
|
||||
Jimmy input permission and raw-any-control. Another controlled actor permits
|
||||
this wrapper without granting Jimmy movement. Raw NULL freezes both timers and
|
||||
hides the meter without ending the material effect. The pure recovered suppressor
|
||||
branch is tested, but source globals4F8182/4F83E0 have no complete lifecycle
|
||||
provider yet. Existing modal/focus/debug capture remains a broader port policy.
|
||||
|
||||
Successful equip hides Goddard immediately, starts both timers0 and colors/shows
|
||||
the meter red. Initial recharge must reach exactly7 before a later tick can
|
||||
activate. Held primary without jump requires energy strictly>2 or the tutorial
|
||||
override, spends fixed2, sets remaining7/targetablefalse/alpha.7, then decrements
|
||||
remaining in the same invocation. No continuous Invisible drain, invented sound
|
||||
or edge latch is added. Ordinary jumping remains possible.
|
||||
|
||||
At remaining<=3, trunc(remaining×5)%2 selects conventional versus additive blend
|
||||
on material0. Expiry<=0 restores opaque/targetable/red; recharge begins next tick.
|
||||
The additive initial branch follows the existing chosen source graphics-option
|
||||
path; its original option predicate remains open. Blended world depth writes
|
||||
remain disabled as an explicit renderer policy. Captures verify port output,
|
||||
not original visual parity or self-occlusion equivalence.
|
||||
|
||||
PlayerGadgetMaterial changes the existing atlas draw without changing pose,
|
||||
geometry or authored visibility. InvisibleMeterOverlay uses exact Canv21/22 RGBA,
|
||||
source width27/height percent×1.04, white/red vertex tint and full texture stretch.
|
||||
Percentage is published before recharge clamps7, preserving its small ready
|
||||
overshoot. Source local positions become centered640×480 logical rectangles
|
||||
with uniform widescreen scale. Cached engine autoalignment scheduling is still
|
||||
open; original pixel-placement fidelity is not claimed.
|
||||
|
||||
SceneDirector emits named-Jimmy GadgetReleaseRequested at initial CAM/MCA
|
||||
activation when DeactivateInv is absent/true, before first MCA target/skip checks.
|
||||
This differs from ordered raw-owner438/410/flatten callbacks. Explicit0 can bypass
|
||||
the named prelude; raw-owner preparation can still clean. AI-null stops motion
|
||||
and clears control without invented cleanup. Release stores remaining7/recharge0
|
||||
and restores local state. Modern reset clears timers/diagnostics explicitly.
|
||||
|
||||
Companion movement/body-enable fields are distinct from AI Active. Equip disables
|
||||
both and hides Goddard; cleanup restores them outside the six proven PostLoad9E8
|
||||
blocked levels. ActorPatrol skips disabled body integration while retaining its
|
||||
bounded AI subset. Independent future writes to movement/body flags, full
|
||||
companion lifecycle and other AI modes remain separate work.
|
||||
|
||||
PlayerEnergy retains scalar and warning latch across ordinary scene rebuilds.
|
||||
Ray, active jetpack and Invisible share tutorial bypass, empty-crossing80 before
|
||||
write, low182 after scalar/before latch, strict<19 warning and>20 rearm. Raw saved
|
||||
scalar/debug refill does not invent a latch reset. TSK retains its original
|
||||
scalar only; complete damage/energy/pickup consumers remain unported.
|
||||
|
||||
## Controls and verification
|
||||
|
||||
Select owned Invisible in Tab/Space, wait for recharge, then hold Enter/Ctrl/left
|
||||
mouse without jump. F1→Player adds Give/Select Invisible, Unequip and timer/
|
||||
targetability diagnostics. F1 retains the existing gameplay/audio pause policy;
|
||||
Tab while a special gadget is equipped unequips first.
|
||||
|
||||
Fifteen managed groups cover numeric/sound order, retained energy ownership,
|
||||
strict gates, same-tick decrement, held activation, flash/expiry, raw-null/other
|
||||
owner distinctions, named cleanup, companion restoration, failed display/raw
|
||||
equip separation and original meter/widescreen geometry. Source coverage grows
|
||||
to182 Python checks plus separate HUD tests. Independent review ran the earlier
|
||||
12 groups before the final three binding/meter groups were added.
|
||||
|
||||
The eight-frame --smoke-invisible fixture explicitly advances836 additional
|
||||
normal player ticks between rendered phases. It grants owned item2 and skips the
|
||||
intro without relocating actors or directly mutating timers/materials. Headless
|
||||
and native1920×1080 GTX1070/private Xvfb pass charged, activated, alpha flash,
|
||||
additive flash, expired and unequipped checks; native uses real SDL Ctrl/Tab.
|
||||
Tutorial energy stays20. Both report zero enabled Vulkan validation errors.
|
||||
Six-phase captures were inspected. Logs/captures: artifacts/gadget-followup/.
|
||||
|
||||
These accelerated observations do not establish real-time original cadence,
|
||||
manual navigation, enemy immunity, tutorial completion or native Windows runtime.
|
||||
Complete scripts/test.sh passes182 Python+2 HUD checks, all managed suites,
|
||||
30 main GPU completions and17 isolated Vulkan material checks, with zero enabled
|
||||
validation errors. SDL dummy lifecycle and539 unchanged originals pass. Package
|
||||
results follow the clean source milestone in progress.md. Full enemy sensing/
|
||||
combat, graphics-option selection, cached canvas
|
||||
alignment, exact scheduler/x87 boundaries and the other gadgets remain open.
|
||||
@@ -0,0 +1,100 @@
|
||||
# Invisible implementation review
|
||||
|
||||
2026-11-01. Independent read-only review of the primary's current Invisible/energy
|
||||
runtime against [invisible.md](invisible.md), retained companion/preparation
|
||||
evidence and the original42A920 instructions. Reviewed files:
|
||||
InvisibleGadget, PlayerEnergy, LabSimulation, PlayerSceneBinding,
|
||||
PlayerGadgetMaterial, SceneDirector, ActorPatrol, Program and InvisibleTests.
|
||||
The reviewer edits only this report; primary owns fixes and integration.
|
||||
|
||||
## Directly evidenced correction found and resolved
|
||||
|
||||
The initial SceneDirector only released gadgets through current raw-owner438
|
||||
preparation. Original CAM4165B7..4165DC and MCA43129A..4312CC separately inspect
|
||||
DeactivateInv and look up **JIM1**, even when the controlled pointer is already
|
||||
NULL or another actor owns it. Both constructors default the property1; absent
|
||||
GAM data does not mean false. MCA's prelude runs before its first target-none
|
||||
branch. The initial implementation could therefore retain active Invisible
|
||||
through a CAM/MCA where original code cleans it.
|
||||
|
||||
Primary added GadgetReleaseRequested with an explicit JIM1 lookup and
|
||||
Integer("DeactivateInv",1) at single-CAM/initial-MCA activation, before target/
|
||||
skip checks. PlayerSceneBinding subscribes and uses existing selected-gadget
|
||||
cleanup. Re-reading confirms that correction is present. Existing ordered raw
|
||||
438/410/flatten preparation remains separate. Later MCA shot changes do not
|
||||
repeat the initial prelude. AI-null still dispatches410 without invented438/
|
||||
gadget cleanup; its raw-null pause can retain Invisible state as source does.
|
||||
|
||||
## Confirmed source alignment
|
||||
|
||||
- Invisible runs immediately after the player movement phase and before the
|
||||
existing owned effect phase. AnyControlled is passed separately from Jimmy
|
||||
input ownership. Null raw control freezes timers/hides the meter; a different
|
||||
nonnull owner can permit the wrapper without permitting Jimmy movement.
|
||||
- Equip accepts energy>0 or VR override. Display selection2 is retained even
|
||||
when the actual raw-mode equip rejects; caller cleanup removes the old special
|
||||
mode first. Successful equip resets both clocks0. Unequip stores remaining7,
|
||||
recharge0 and restores opaque/targetable presentation; modern full reset
|
||||
starts0 and clears diagnostic counts explicitly.
|
||||
- Activation uses remaining0 and recharge exactly7, primary without jump,
|
||||
energy strictly>2 or override, one fixed−2 adjustment and same-call remaining
|
||||
decrement. Initial recharge must complete first; reaching7 cannot activate
|
||||
until the next invocation. Held primary can reactivate after another recharge.
|
||||
- Recharge runs only with remaining0 and positive energy/override, clamps7 and
|
||||
turns the meter white. Expiry<=0 restores opaque/targetable/red; recharge
|
||||
starts next call. Active duration continues at zero energy or during jumps.
|
||||
- Opacity0.7, additive initial branch and last3s alternating conventional/
|
||||
additive blend match the guarded material path. Expiry argument0 means reset
|
||||
material alpha1/blend-disabled, not alpha0. The one-atlas Jimmy draw keeps
|
||||
authored visibility and geometry; no invented whole-model hide/fade is used.
|
||||
- PlayerEnergy implements strict19/20 warning hysteresis, empty-crossing sound80
|
||||
before the scalar write, low182 after the write/before latch and VR01..08
|
||||
helper bypass. The scalar and warning latch share a session owner across
|
||||
ordinary loads; raw saved/debug scalar assignment does not rearm the helper.
|
||||
The upper clamp compares the pre-store sum, and callback-driven scalar changes
|
||||
are respected by reloading after the crossing callback, as source42A975 does.
|
||||
- Companion hide/disable occurs on equip, including recharge, not on activation.
|
||||
The binding preserves distinct AI activation, body-enable and movement-enable
|
||||
fields. Its six-level restore exclusion matches the bounded PostLoad9E8
|
||||
mapping; it does not restore a saved previous visibility or blanket-pause AI.
|
||||
|
||||
## Explicit remaining boundaries
|
||||
|
||||
1. The pure Invisible suppressor branch is implemented/tested, but LabSimulation
|
||||
currently supplies no provider for source global4F8182, nor the primary helper's
|
||||
independent4F83E0 veto. Modern modal/focus/debug capture clears input/pauses
|
||||
simulation. Those policies do not establish the complete original global
|
||||
suppression lifecycle; document this as partial input coverage.
|
||||
2. Source55D/49D target eligibility is stored/observable, but full enemy sensing,
|
||||
lost-target, existing attack and class-specific consumers are absent. Generic
|
||||
409CC0 also permits positive enemy934 when the flag is false. Do not describe
|
||||
the slice as universal enemy avoidance or invulnerability.
|
||||
3. Companion9E8 is represented by known initial level policy. Later source
|
||||
setters/dynamic modes remain outside this bridge. MovementEnabled is stored
|
||||
but has no independent modern consumer yet; the bounded equip/cleanup path
|
||||
writes it together with BodyEnabled, which gates body integration. Independent
|
||||
changes to only one flag require their original consumers before expansion.
|
||||
4. Additive is the declared graphics509A13=false branch. The original setting
|
||||
predicate, general multi-material/LOD behavior, transparent depth state,
|
||||
original registry cadence and exhaustive x87 meter boundaries remain open.
|
||||
Existing full-panel/noclip pauses and full scene rebuild are modern policies.
|
||||
5. Meter resources/layout are being integrated by primary from the independent
|
||||
asset report. This review does not certify that unfinished overlay or final
|
||||
native/packaged renders. Full game and native Windows comparison remain open.
|
||||
|
||||
## Verification
|
||||
|
||||
The reviewer independently ran the current twelve managed Invisible/energy groups
|
||||
successfully using the existing project SDK, logged in
|
||||
`artifacts/invisible/runtime-review-tests.log`. That run covers energy callback
|
||||
ordering/hysteresis/retention/tutorial bypass, first recharge, activation strict
|
||||
threshold/jump, raw-null/suppressor pause, flash/expiry, repeated held activation,
|
||||
cleanup and material mapping. It predates the primary's additional binding/
|
||||
companion fixtures. Nine source/static-projection groups independently pass in
|
||||
`artifacts/invisible/tests.log`; these do not execute original code.
|
||||
|
||||
Final integration should retain explicit fixtures for raw-other-owner activation
|
||||
without Jimmy movement, AI-null freeze, named-Jimmy CAM/MCA cleanup while already
|
||||
raw-null, DeactivateInv default/explicit0, failed equip/display separation and
|
||||
companion restore restrictions. Primary owns those runtime additions and the
|
||||
complete suite, actual SDL/GPU input/readback, builds and release evidence.
|
||||
@@ -0,0 +1,172 @@
|
||||
# Invisible gadget source contract
|
||||
|
||||
2026-11-01. Original item2/raw mode2. This report records static recovery and
|
||||
bounded source projections; it does not claim original gameplay execution, port
|
||||
integration or native platform verification. Original files were read only.
|
||||
|
||||
## Evidence and addresses
|
||||
|
||||
EXE SHA256 is `f5281076e1a2492f2d61f87aae3f4544b6d0f535ebe33f9fbb6f78710fe1aea8`.
|
||||
`tools/binary/invisible.py ../Original` guards seven complete bounded spans,
|
||||
50 decisive instruction slices, eight virtual bindings and six constants. Its
|
||||
`artifacts/invisible/source-contract.json` records preferred VAs, PE-mapped file
|
||||
offsets, bytes and hashes. All code addresses below map to file offset VA−400000;
|
||||
the helper computes rather than assumes that mapping. Main source callers and
|
||||
state fields are distinct from the display item index documented in
|
||||
[gadget-controls.md](gadget-controls.md).
|
||||
|
||||
REA/Ghidra12.1.4 inspected a generated hashed EXE copy. Complete replies,
|
||||
Evidence export and closed-session snapshot are retained in
|
||||
`artifacts/invisible/rea-invisible-ipc/`:
|
||||
|
||||
| Procedure | REA Evidence |
|
||||
| --- | --- |
|
||||
|40E4A0 linked-model alpha/material setter|`ev_615030aa60b2346083853c40aa719ebc466e9f393fd870ea9722536a4f64cfac`|
|
||||
|409CC0 generic enemy target predicate|`ev_1c4fe58878638158ea6f33db1474848910256873c00f266968debbf2ea35bf3f`|
|
||||
|4037F0 meter size setter|`ev_525ca303ce70c16f524063053ebdd9fecd82054cf480d8f2f30f1ec0d7e08333`|
|
||||
|
||||
424E80 and427FF0 entry queries were unrecognized and returned input/mapping
|
||||
errors; no pseudocode is attributed to them. Their bounded instructions, vtable
|
||||
targets, branches and exact source identity supply the contracts below. The
|
||||
earlier default-sandbox batch (`rea-update/`) failed Ghidra's Unix-socket bind;
|
||||
its diagnostics and closed snapshot are retained, and `doctor.json` records the
|
||||
diagnostic follow-up. Local IPC permission fixed that host restriction without
|
||||
changing REA/client configuration or executing the target. Both sessions closed.
|
||||
|
||||
## State owners and update order — recovered
|
||||
|
||||
Jimmy complete-object vtable4A3BDC has1C8→424E80,178→427FF0,
|
||||
FC→40DD40(indexed material blend) and114→40E4A0(all linked materials alpha).
|
||||
Global signed WORD4F0588 is equipped mode. Menu display2 is separate.
|
||||
|
||||
| Jimmy complete field | Meaning established by this path |
|
||||
| --- | --- |
|
||||
|1E1C float|Remaining Invisible duration; constructor/equip zero, activation7|
|
||||
|1E20 float|Recharge; constructor/equip/activation zero, ready exactly7|
|
||||
|55D byte (=game-interface49D)|AI target visibility/eligibility flag; false while effect active|
|
||||
|9F8 byte (=game-interface938)|Energy override; constructor false, PostLoad true for VR01..08|
|
||||
|A18 pointer|Menu/UI owner|
|
||||
|A1C pointer|Goddard/companion owner|
|
||||
|
||||
Jimmy game-interface frame424600 calls base movement437940 at424C34, then
|
||||
complete slot1C8 at424C3F, then later complete1B4/1B0. Thus Invisible is a Jimmy
|
||||
wrapper phase after movement, distinct from the controlled-input callback and
|
||||
the ordinary ray's input phase. Existing full registry/fixed-step approximation
|
||||
remains separate.
|
||||
|
||||
At424E80 a null controlled pointer5099E4 hides both meter sprites and returns,
|
||||
freezing Invisible timers. Any nonnull controlled pointer passes; the leaf does
|
||||
not compare it with Jimmy's identity. Mode!=2 then returns. Mode2 shows both
|
||||
meter sprites before the remaining activation/timer branches. Menu modal/frame
|
||||
eligibility can stop the enclosing frame before this leaf; do not treat this
|
||||
as proof all menu/audio clocks follow this routine.
|
||||
|
||||
## Equip and activation — recovered
|
||||
|
||||
Selecting item2 reaches428E51 after the menu caller's close/old-gadget cleanup.
|
||||
The display-selection callback already ran at428D97. With energy<=0 and9F8 false,
|
||||
the branch writes raw mode−1 and skips companion/timer/target-flag/meter setup.
|
||||
It still reaches Practice-state handling and may load VR03. Do not restore the
|
||||
old special mode or normalize display2 into raw2 after a rejected equip.
|
||||
|
||||
With energy>0 or9F8 true, equip hides Goddard immediately through complete58(1),
|
||||
sets Goddard gameD0(0) and214(false), writes raw mode2, zeroes both timers, sets
|
||||
Jimmy55D=true and colors/shows the meter red. Goddard stays hidden for the entire
|
||||
equipped mode, including recharge; this is not a shared fade with Jimmy.
|
||||
|
||||
Activation in424EBA..424F68 requires primary helper42A7A0 true and jump helper
|
||||
42A730 false. If global4F8182 is true on that branch, the function returns before
|
||||
either timer advances. Suppression does not freeze a call with primary false or
|
||||
jump true. Otherwise activation requires remaining exactly0, recharge bits
|
||||
exactly float7, and energy **strictly>2** or9F8 true. Failed energy at this ready
|
||||
branch returns. Held primary has no separate edge latch here and can activate
|
||||
again after another completed recharge.
|
||||
|
||||
Success calls42A920 with fixed delta−2, sets remaining7, writes indexed material0
|
||||
blend6/1, applies alpha0.7 to all linked Jimmy materials, clears target flag55D
|
||||
and resets recharge0. The same invocation then decrements remaining bydt. There
|
||||
is no continuous Invisible energy drain, invented fire cooldown or activation
|
||||
sound in this leaf. Shared42A920 may emit its own energy warnings; primary owns
|
||||
that lifecycle. Ordinary jumps are allowed: mode2 is accepted in42A759; no
|
||||
Invisible-specific pose, new model or forced grounded requirement appears here.
|
||||
|
||||
## Timers, meter and material — recovered
|
||||
|
||||
After activation attempt, only remaining==0 and(energy>0 or9F8) grows recharge
|
||||
bydt. The meter receives recharge×stored-float(1/7)×100. At recharge>=7 the fill
|
||||
is colored white, then recharge is clamped to exactly7. Reaching ready during
|
||||
this call permits activation on the **next** invocation.
|
||||
|
||||
Independently, remaining>0 subtractsdt, writes meter percentage
|
||||
max(remaining×stored-float(1/7)×100,0), then expires at remaining<=0. Expiry sets
|
||||
remaining0, indexed blend6/7, alpha-reset argument0, target flagtrue and red meter.
|
||||
It does not grow recharge in that call; recharge resumes on the next invocation.
|
||||
If remaining is still positive and<=3, trunc(remaining×5)%2 selects indexed
|
||||
material0 dest7 when odd, dest1 when even; source factor remains6. This is a
|
||||
blend flash, not alpha on/off, uniform transparency ramp or mesh hiding.
|
||||
|
||||
40DD40(index,source,destination) writes the indexed material30/34 fields.
|
||||
40E4A0(alpha>0) walks the linked model57C material array88..8C, writes diffuse
|
||||
RGBA(1,1,1,alpha), enables blend flag38 bit0 and selects source6/dest1 when graphics
|
||||
flag509A13 is false, dest7 when true. For alpha<=0 it clears the blend bit, restores
|
||||
RGBA1 and6/7. Therefore expiry/cleanup mean opaque alpha1, not invisible alpha0.
|
||||
6/1 is SrcAlpha/One additive,6/7 SrcAlpha/InvSrcAlpha conventional alpha per
|
||||
[gadget-blending.md](gadget-blending.md). The graphics-option predicate remains
|
||||
unclosed. An upright current-Jimmy renderer can use the existing material variants;
|
||||
do not claim complete original material/LOD/depth-state equivalence.
|
||||
|
||||
Menu48D414 binds484→4036C0(show both),488→403700(hide both),
|
||||
48C→403730(red fill(1,.2,.2,1), show),490→4037A0(white fill).
|
||||
4037F0 sets fill width27×(windowWidth/640), height
|
||||
max(percent,0)×1.04×(windowHeight/480). Source meter sprite pointers are
|
||||
4F7CB0/4F8028. [Follow-up asset report](gadget-followup-assets.md) owns exact
|
||||
Canv21/22 bindings/layout and modern uniform-widescreen adaptation. Arithmetic
|
||||
uses x87 intermediates and float stores; exhaustive boundary equivalence is not
|
||||
claimed by the Python projection.
|
||||
|
||||
## Cleanup, control and AI consumers — recovered boundaries
|
||||
|
||||
427FF0 dispatches the mode table428844; entry2 reaches42810C. It writes material0
|
||||
blend6/7, remaining7 (not0), target flagtrue, recharge0 and hides both meter sprites.
|
||||
If Goddard exists and its complete9E8 flag is false, it shows Goddard and re-enables
|
||||
gameD0/214. It resets Jimmy alpha through114(0) and raw mode−1. Selecting Invisible
|
||||
again resets both timers0. Source constructor4227BE/C7 also starts both0.
|
||||
|
||||
CAM and initial MCA can explicitly clean inventions. CAM constructor415C09/D5
|
||||
defaults DeactivateInv to1 at complete9C0; property415F74 binds game-interface8F8
|
||||
(interface offsetC8 proven415A60). Activation4165B7 checks the field before JIM1
|
||||
lookup/cleanup178. MCA constructor430AA0 defaults completeEB8=1; property430D82
|
||||
binds interfaceDF0 (offsetC8 at430930), activation43129A/CC checks then cleans.
|
||||
Both use exact string `DeactivateInv` at4EDF10. Omitted GAM property therefore
|
||||
keeps defaulttrue; an explicit0 can suppress that prelude. Ordered raw-owner438
|
||||
preparation also calls cleanup178 at42AE14. AI-null40C4AD..527 calls410, STOP/
|
||||
sound148 and clears raw control, but that inspected block does **not** call438/
|
||||
178. Do not blanket-cancel Invisible on every control loss: timers can freeze
|
||||
with the effect retained while raw control is null. Reset/ordinary-load behavior
|
||||
must respect proven Init/PostLoad and callback boundaries, not one broad reset.
|
||||
|
||||
Generic enemy reads target game-interface49D at40847C,408788,4087FC to gate
|
||||
chase/acquisition/lost-target branches. REA409CC0 confirms a target pointer is
|
||||
required and the eligibility test permits49D=true **or** positive enemy934;
|
||||
Invisible is not proof universal enemy immunity. Later enemy modes/reaction
|
||||
consumers, attacks already underway and class-specific overrides remain open.
|
||||
The port can retain the flag and report its state without claiming enemies avoid
|
||||
Jimmy until the corresponding AI consumers are implemented.
|
||||
|
||||
## Verification and recommended bounded implementation
|
||||
|
||||
Nine deterministic Python groups pass in `artifacts/invisible/tests.log`:
|
||||
source identity/spans/sites/vtables/constants, equip/activation threshold split,
|
||||
first recharge/next-call activation, fixed cost/same-call decrement, jump and
|
||||
suppressor/control gates, zero-energy clocks, blend flash/exact-zero expiry,
|
||||
cleanup and source graphics branch. These are independently transcribed static
|
||||
projections, not original execution or modern runtime verification.
|
||||
|
||||
Implement mode2 in the existing post-movement Jimmy wrapper phase with separate
|
||||
raw-any-control and Jimmy-input ownership. Preserve exact timers/strict gates,
|
||||
original material/meter resources, Goddard hide/restore and evidence-backed
|
||||
cleanup points. Verify initial recharge, held activation, ordinary jump, last3s
|
||||
blend flash, expiry/recharge, low-energy rejection, VR exemption, modal pause,
|
||||
explicit/implicit cutscene cleanup and AI-null freeze. Keep full enemy AI,
|
||||
original graphics-option choice, exact scheduler/x87 boundaries and native
|
||||
Windows/original whole-game comparison explicitly unresolved.
|
||||
@@ -0,0 +1,65 @@
|
||||
# Shared player energy and warning sounds
|
||||
|
||||
2026-11-01. Static recovery reuses the complete local REA/Ghidra12.1.4 record
|
||||
`artifacts/shrink-ray/rea-primary-followup/04.json`, Evidence
|
||||
`ev_71897af12f4bfa1de946c6f17f3bbed34764fdc84258ce64516c8f1f904b465d`.
|
||||
Its exported bundle and closed snapshot remain beside it. No duplicate analysis
|
||||
session or original execution was needed. Supplementary instruction cross-checks
|
||||
are in `artifacts/gadget-followup/energy.instructions.txt`.
|
||||
|
||||
`tools/binary/player_energy.py ../Original` checks the full original EXE hash,
|
||||
the complete42A920..42AA13 body, ten decisive sites and four constants. Output
|
||||
`artifacts/gadget-followup/energy-source.json` records PE-mapped file offsets
|
||||
for all preferred VAs below. Original EXE SHA256:
|
||||
`f5281076e1a2492f2d61f87aae3f4544b6d0f535ebe33f9fbb6f78710fe1aea8`.
|
||||
For these .text locations, mapped file offset is VA−400000.
|
||||
|
||||
## Recovered state and order
|
||||
|
||||
Global float4F83D4 is the player energy scalar; byte4F83DC is a separate low-warning
|
||||
latch. Jimmy constructor42217E clearsEBX,422980 writesBL to the latch. Existing
|
||||
retained-loader evidence shows ordinary loads reuse Jimmy without repeating his
|
||||
constructor. TSK stores PlayerValue, not this latch; direct scalar load is distinct
|
||||
from calling the adjustment helper. Full new-game/load UI ownership remains open.
|
||||
|
||||
42A92B..42A93D compares the current game's FourCC against numericVR01..VR08 and
|
||||
returns for those tutorials without changing scalar, latch or playing sounds.
|
||||
Otherwise:
|
||||
|
||||
1. When old energy>0 and the requested sum<=0,42A967..42A972 requests SFX80 before
|
||||
the scalar changes. Staying at zero is not another crossing.
|
||||
2.42A975 reloads the live scalar, adds the delta and stores float32. The upper100
|
||||
comparison uses the still-live x87 sum. Above100 clamps100, clears the latch
|
||||
and returns (42A985..42A9A3).
|
||||
3. Negative stored energy clamps0. Stored energy<19 emits SFX182 once if the latch
|
||||
is false, then sets it true (42A9C3..42A9F7). The scalar is already published
|
||||
when that sound is requested; the latch is written afterward.
|
||||
4. Values19..20 inclusive preserve the latch; strictly>20 clears it
|
||||
(42A9F8..42AA12). A direct assignment/refill is not itself this helper call.
|
||||
|
||||
The shared consumers include ordinary ray426F5A (−dt), powered-fire421FB0's active
|
||||
phase (−dt×.5), Invisible424F26 (fixed−2 on activation), and Bubble42627C
|
||||
(−dt×.5; Bubble runtime remains pending). Tutorial immunity does not bypass the
|
||||
individual caller's activation gate; Jimmy PostLoad independently sets its9F8
|
||||
energy-override field for VR01..08.
|
||||
|
||||
## Current implementation and verification boundaries
|
||||
|
||||
`PlayerEnergy` owns scalar and warning latch. Main retains one instance across
|
||||
ordinary scene rebuilds; LabSimulation delegates scalar access and adjustments to
|
||||
it. Warning callbacks run in source write order and feed SceneAudio's existing
|
||||
SFX bank/gate. The ray and positive jetpack-effect phase now call this owner;
|
||||
Invisible spends2 through the same path. The independent JetpackBurst pure helper
|
||||
continues to expose its numeric projection for algorithm tests.
|
||||
|
||||
Modern doubles preserve the relevant two-float sum before stores; exhaustive x87
|
||||
rounding/control-word equivalence is not claimed. Nonfinite input is rejected.
|
||||
Saved scalar assignment and modern debug refill do not infer a warning reset.
|
||||
The modern debug checkpoint/load interface is not an original full save UI.
|
||||
|
||||
Managed tests cover strict19/20 boundaries, one-shot warning episodes, crossing
|
||||
sound before scalar/low sound after scalar, clamp, tutorial bypass and shared
|
||||
ordinary-load ownership. Source tests guard constructor, both new callsites,
|
||||
body/constants and offsets. They are port/static checks, separate from listening
|
||||
to the original whole game or native Windows verification. Whole energy/damage/
|
||||
pickup consumers, soundbank timing and exact original scheduler remain open.
|
||||
Reference in new issue
Block a user