This is so fucking cool!!!!
I've managed to get AI to pretty much entirely fix the 60hz cap for Prey, but using kind of a workaround: in a nutshell, instead of trying to patch the game to work at more than 60hz, the solution decouples simulation tick from display rendering, i.e the game logic still runs at 60fps, but the rendering can go as high as it wants (even 1000fps, but I've tested it up to 360hz) then the patch interpolates all world transforms and joint matrices + player camera rotation and player position to match the desired frame rate.
This would leave the game feeling sluggish though at e.g 240hz because mouse movement is still applied at 60hz ticks and then interpolated in the other frames, so the patch applies an additional mouse delta override on the mouse position at display time that feeds into the next game logic tick; this way you get properly instantly responsive 240hz mouse response rate even if the game is internally running at 60.
Now that I understand the approach used more, I now feel like this might be a valid universal approach for these kind of games that have locked fps issues; so I will try applying it to other games; in a nutshell:
decouple game logic from rendering (this could simply mean multiple display, or 'presentation' frames for each real logic frame)
interpolate all world positions, rotations & animations in non-logic frames towards the next logic frame
add a per-frame mouse delta override to restore mouse input latency to 240hz/whateverhz levels
I feel like I want to make a dedicated post for this and expand upon it.
This is possible only thanks to AI which has infinite patience and very good pattern recognition abilities, and particularly, these last AIs that have come out in the last couple months seem just very very good at reverse-engineering and decompiling executables. I have a feeling you can do much more than what I've done here provided you can properly guide it and be torough while testing, explaining coincisely what is happening and why something is not working.
The fix ended up being harder than I tought though; I kept fighting a ~4hz stutter when I booted the game sometimes (meaning, I would restart the game and it would go away, then start the game again later and come back, and persist for the whole game session) and it turns out it was a timer/scheduling issue; the game uses low resolution timer functions (1ms resolution) to determine whether or not to schedule the next game tick or not, and at high refresh rates this would trip the timer up (schedule two ticks at once every ~240ms, resulting in an intermittent ~4hz stutter/jump/overcorrection); after fighting with the underlying interpolation system already set up I decided to make the AI look upstream and it ended up working.
What is interesting is that 5.6 Sol was stuck trying to fix the underlying interp system with recovery mechanism after recovery mechanism, and only when I prompted the AI to look around some more we've managed to spot the issue; so for now we puny humans still have some value to provide, what scares me is for how long.. I only had to point the AI towards a direction (like a manager telling the developer to change direction) but eventually the AI will be able to pivot by itself (and I'm sure it already can in many circumstances).
I still can't believe we have the ability to literally shape compiled executables to our will pretty much using these tools, so fucking cool :D.
I've already deployed patches for other games, namely:
Dishonored 2, tested 3 levels, 360hz
Dishonored Death of the Outsider, tested 2 levels, 360hz
Dead Space 3 Raw Input mouse fix, this one CHANGES the game, so much more fun to play
And they seem to work fine so far, I played Dead Space 3 with the mod through to chapter 14 (about ~70% of the campaign) and so far spotted only a minor bug where camera freezes accumulate mouse delta which gets applied all at once when the camera is released by the game (e.g when the game forces you to look at something) and I'm pretty confident that I can fix that eventually with a few rounds of LLMs.
I'll eventually make a post for each game probably, this is just the first one.
Prey (2006) High-Framerate FixView fix → See ya.