Closed zlsa closed 5 years ago
The "failed to load assembly" errors are a bit misleading, this is "normal" behavior, Unity tries to load the openvr dll but fails because it's not supposed to be trying to load it. But that's fine.
I saw this line in your log: [ERR 19:05:53.006] [KerbalVR] HMD not found on this system.
for some reason the plugin is not finding your VR set. I'm not sure how else to diagnose this... What VR system are you using? I assume it works fine for other games? SteamVR is running when you launch KSP? (actually if it's not running beforehand, it's supposed to automatically launch SteamVR)
Oh, I forgot to mention I'm using an Oculus Rift CV1 and SteamVR fully detects the headset, both controllers, and all three sensors before I start KSP. And it's been working for all SteamVR games that I've tried so far.
OK, so I've done some digging and found that the SteamVR runtime isn't discovered for some reason:
[ERR 19:53:03.887] [KerbalVR] SteamVR runtime not found on this system.
Which would explain the early shutdown. I'm looking into it now and will update this issue as soon as I find out more.
Oh hey, I solved it. It has to do with running as administrator (which I was doing for an unrelated issue.)
When you run as admin, it looks for the SteamVR vrpath config file in the administrator's AppData
folder. All that vrpath config file does is point to C:\Program Files (x86)\Steam\steamapps\common\SteamVR
, but if that file is not found, I'd guess the OpenVR API just gives up.
So the solution would be to either:
I'll close the issue, as it's been resolved.
thanks for looking into this!
I ran this on a minimally reproducible setup.
(No mods beside KerbalVR.)
KSP.log
Of note is the following block, right at the beginning:
I don't know the details of Unity's plugin architecture (or that of KerbalVR or KSP for that matter), but a cursory search brought up a similar looking issue.