fix(fps): water ripples keep moving above 60 fps #2409
No reviewers
Labels
No labels
accessibility
autorelease: pending
autorelease: tagged
bug
dependencies
documentation
duplicate
enhancement
github_actions
good first issue
help wanted
invalid
question
testing wanted
wontfix
No milestone
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Hookshot!2409
Loading…
Reference in a new issue
No description provided.
Delete branch "port/fritchii-timing"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Title: fix(fps): water ripples keep moving above 60 fps
With the Frame rate cap above 60, the rings that Link and other actors make in water stop moving. The water's ripple simulation runs a whole number of steps per frame. Above 60 fps each frame's step is less than 1, so that number rounds down to 0 every frame.
What changes
f_800672e0) runs its ripple simulation(int)step × substepstimes a frame.hos_frame_whole(nx2/oot_patches.pyWHOLE_SITES), with the fraction carried per water object (x21). Each surface then runs its 60 steps a second whatever the frame rate.host/frame_whole.hkeeps 64 remainders instead of 16. A scene's water surfaces each use one every frame, and if there were more surfaces than slots they would push each other out in turn and freeze again.Ported from Fritchii. atk3001 found it for Lichii (zortos293/Lichii#1152 and #1180). Frizti ported the site and the per-object accumulator to Fritchii: d389685a4 and 063dbb741. Fritchii patches the game's code with an accumulator cave. Here it is one more entry in the existing whole-frames mechanism.
Verified
tests/test_frame_whole.pycovers the new site (the patch replaces its one cut, once). It now also checks that 40 surfaces, each stepped once a frame at 144 fps, still get 59–60 steps a second, and that a reused slot starts again from 0.tests/run_all.py: 356 passed, 13 skipped. The 4 failures (test_wayland_libdecor_hint,test_nup_read_name,test_bake_portability,test_builder_log_read_only) also fail on main on this machine.Not tested
github-sync referenced this pull request2026-11-12 06:22:54 +00:00