mirror of
https://github.com/valentderah/totk-pc-recomp.git
synced 2026-11-20 20:55:56 +00:00
The weapon's hit-record pool holds 10 records, and one charged swing above 60 fps fills it: the insert fails, and the list of hits made this frame stays empty. main+0x2906de0 then reads the empty list's slot, which holds a stale stack value, and passes it to the hit handler before the game's own count == 0 check would return; the stale value here pointed at the temp hit map and the read at main+0x870158 faulted reading 0x100000000a. Both count == 0 branches now go to main+0x2906df0, the game's check, under the realtime set. A non-empty list is unchanged, and below 60 fps the pool never fills. Verified on 1.4.3: a charged spear attack on an enemy at 120 and 144 fps no longer faults, and the damage at 60 and 120 fps matches the build without this patch.