mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-15 19:19:58 -04:00
Keep the fraction of a frame the ocarina recorder's clock was losing above 60 fps, in a new patch set orecord.
The ocarina manager counts the length of each note and rest in whole 60 Hz frames and adds the time manager's frames per update to that clock at four sites (main+0x32926c8, main+0x3293410, main+0x3296b08, main+0x3296da4) through fcvtzu, which cuts the step toward zero. Above 60 fps the step is under one frame, so the clock never moved: a recording kept its notes without their lengths (the recorder leaves a length of 0 out), the 360 and 120 frame limits never came, and a recording ended after a fixed 60 frames of its timer instead of following the clock; at the 40 and 45 fps limits it counted one a frame. The set replaces each fcvtzu with nine words that add the fraction carried on the patch page's +264, store what is left after the cut (NaN and negatives as 0) and convert the sum. Steps of one and two frames give the game's count with the fraction left at 0, so 30 and 60 fps are unchanged. The words call nothing and take no lock (one of the functions returns through an unsaved x30), and use only v16-v18, which the three functions never name. The set is appended so that no existing set's index moves; ocarina_timing = 0 gives the game's words. Not reproduced before the change (read from the code). The generator's check of the original words passed against the 1.1.1 main, the new tests/ocarina_timing_check.py passed (.venv, Unicorn), as did frame_step_check, text_speed_check, sprint_check, movie_timeline_check, cfg_parse_check, launcher_test and cfg_rows_check. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -550,6 +550,17 @@ words each setting writes and the set it switches, the skip site's decide bit an
|
||||
player may skip and one the game keeps from skipping, the speed site's factor for that typewriter and no other, the
|
||||
registers and flags both sites leave alone, and a start that kept the set off. No game files.
|
||||
|
||||
A change to the ocarina recorder's clock (the set `orecord` of `recomp/patches-v111.txt`, `ocarina_timing`) passes
|
||||
`python tests\ocarina_timing_check.py --cc <clang>` (`.venv`, Unicorn): it checks the set's four sites, their original
|
||||
word and nine replacement words, the page word resolved to the patch page at each site and no other set's word on the
|
||||
page's +264; it lifts the words and runs them against the game's word and a float32 model: steps of one and two frames
|
||||
give the game's count with the fraction left at 0, the steps of the 40 to 240 fps limits count 3600 frames a minute
|
||||
(0 and 1 in turn at 120, 5 in every 12 updates at 144, 1 in every 4 at 240), NaN, negative, infinite and huge steps
|
||||
give the game's count, and only x8, v16-v18 and FPSR change; and it runs the nine words in Unicorn at each site against
|
||||
the lifted C over 10,000 random steps and fractions, comparing registers and the page bit for bit. It does not cover
|
||||
the sites inside their functions: a regenerate of the game code does, and its check of the original words. No game
|
||||
files.
|
||||
|
||||
A change to the mouse camera (`runtime/mouse_direct.c`, the mouse path of `runtime/input.c`, the set `mouse_direct` of
|
||||
`recomp/patches-v111.txt` or `patches-v143.txt`) passes `python tests\mouse_direct_check.py --cc <clang> --deps
|
||||
<ucrt64>\include`, which builds `mouse_direct.c`, and `input.c` with `--deps`, with the rest of the runtime stubbed and
|
||||
|
||||
Reference in New Issue
Block a user