v5 - Fix for unity 2022.3.62f3 not having get_graphicsDeviceID#1235
v5 - Fix for unity 2022.3.62f3 not having get_graphicsDeviceID#1235ManlyMarco merged 3 commits intoBepInEx:v5-ltsfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes a compatibility issue with Unity 2022.3.62f3 where the SystemInfo.graphicsDeviceID property is not available, which was causing BepInEx5 to fail.
Key Changes:
- Added try-catch block around
SystemInfo.graphicsDeviceIDaccess in theIsHeadlessproperty to handle missing property gracefully - Returns
false(non-headless) as fallback when the property is unavailable
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
no, unity 2022 just has no graphicsDeviceID, the only relatively sane way is to check DeviceName or whatever but that requires checking strings which can turn into a fun rabbit hole in and of itself (just ask the mesa people) |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
That's weird, Unity docs say this property exists in all versions, is your game compiled for console/android? https://docs.unity3d.com/6000.3/Documentation/ScriptReference/SystemInfo-graphicsDeviceID.html |
the docs lied, i checked the DLLs (unityjit-win32) it's not there |
Co-authored-by: ManlyMarco <39247311+ManlyMarco@users.noreply.github.com>
Description
fixes error with missing method
Motivation and Context
allows one to run bepinex5
How Has This Been Tested?
yeah
Screenshots (if appropriate):
Types of changes
Checklist: