From dfea13ce7682b4d0f235bc7a9e7076ffd2b304fd Mon Sep 17 00:00:00 2001 From: Fridge Date: Wed, 9 Jul 2025 14:40:43 +0100 Subject: [PATCH 1/2] Change MouseInterval to 1 --- CREDITS.md | 1 + docs/User-Interface.md | 2 +- docs/Whats-New.md | 2 +- src/Misc/Hooks.BugFixes.cpp | 12 ++++++++++++ 4 files changed, 15 insertions(+), 2 deletions(-) diff --git a/CREDITS.md b/CREDITS.md index 75d37617b5..617b0792b6 100644 --- a/CREDITS.md +++ b/CREDITS.md @@ -589,6 +589,7 @@ This page lists all the individual contributions to the project by their author. - **Joshy** - Original FlyingStrings implementation - **CnCVK** - Original custom locomotors experiment - **ZΞPHYɌUS** - win/lose themes code +- **Fridge** - Cursor Fix code - **Neargye (Daniil Goncharov)** - [nameof library](https://github.com/Neargye/nameof) (MIT) - **ayylmao** - help with docs, extensive and thorough testing - **SMxReaver** - help with docs, extensive and thorough testing diff --git a/docs/User-Interface.md b/docs/User-Interface.md index 30b4f2c345..e49a509eac 100644 --- a/docs/User-Interface.md +++ b/docs/User-Interface.md @@ -11,7 +11,7 @@ This page lists all user interface additions, changes, fixes that are implemente - Fixed position and layer of info tip and reveal production cameo on selected building. - Timer (superweapon, mission etc) blinking color scheme can be customized by setting `[AudioVisual] -> TimerBlinkColorScheme`. Defaults to third color scheme listed in `[Colors]`. - Fixed sidebar not updating queued unit numbers when adding or removing units when the production is on hold. - +- Fixed cursor from being hardcoded to update/render 60 times a second no matter how fast the game is rendering. Now the Cursor will update and render much more frequently. ```{note} You can use the improved vanilla font which can be found on [Phobos supplementaries repo](https://github.com/Phobos-developers/PhobosSupplementaries) which has way more Unicode character coverage than the default one. ``` diff --git a/docs/Whats-New.md b/docs/Whats-New.md index f971b3c093..cf3c9bfeb8 100644 --- a/docs/Whats-New.md +++ b/docs/Whats-New.md @@ -450,7 +450,7 @@ Vanilla fixes: - Fixed an issue that jumpjet harvester will overlap when manually entering refinery buildings and cause game crashes (by CrimRecya) - Fixed an issue that `Spawned` aircraft will fly towards the edge of the map when its `Spawner` is under EMP (by CrimRecya) - Projectiles with `Vertical=true` now drop straight down if fired off by AircraftTypes instead of behaving erratically (by Starkku) - +- Fixed cursor from being hardcoded to update/render 60 times a second no matter how fast the game is rendering. Now the Cursor will update and render much more frequently (by Fridge) Phobos fixes: - Fixed the bug that `AllowAirstrike=no` cannot completely prevent air strikes from being launched against it (by NetsuNegi) - `600 The shield of the attached object is broken` bug fix for the triggered event (by FlyStar) diff --git a/src/Misc/Hooks.BugFixes.cpp b/src/Misc/Hooks.BugFixes.cpp index 15d1d70f16..d2d5e7ad7e 100644 --- a/src/Misc/Hooks.BugFixes.cpp +++ b/src/Misc/Hooks.BugFixes.cpp @@ -21,6 +21,7 @@ #include #include #include +#include #include #include @@ -2279,3 +2280,14 @@ DEFINE_HOOK(0x415F25, AircraftClass_FireAt_Vertical, 0x6) return 0; } + + +//Jul 7, 2025 - Fridge: Cursor Refresh rate fix(from 60 to game render rate) +DEFINE_HOOK(0x7B8536, StartMouseThread_AdjustMouseInterval, 0xA) +{ + + // Original - Thread_Mouse_Args.Interval = 16ms + Game::MouseThread.Interval = 1; + + return 0x7B8540; +} From 3a28acf6c806aad55bea6749cdfd9bfc06088d3e Mon Sep 17 00:00:00 2001 From: Fridge Date: Wed, 9 Jul 2025 15:23:43 +0100 Subject: [PATCH 2/2] Update to Correct YRpp version --- YRpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/YRpp b/YRpp index d1bb108f4a..152c0b767d 160000 --- a/YRpp +++ b/YRpp @@ -1 +1 @@ -Subproject commit d1bb108f4abe6a99e31603f783b9e9320c9d23ce +Subproject commit 152c0b767de518d13c8b6fd1e7f7d0a4565c7840