Closed alexeystrakh closed 3 years ago
It was an issue in SteamVR_Render component (SteamVR Plugin SDK), which wasn't reporting OnInputFocus when the focus is back. So it was freezing the input on focus lost and didn't call the OnInputFocus to restore the game properly.
So I have set the following settings to false
SteamVR.settings.pauseGameWhenDashboardVisible = false
and update the SDK method to add its non-working logic inside that if:
private void OnInputFocus(bool hasFocus)
{
if (SteamVR.active == false)
return;
if (hasFocus)
{
if (SteamVR.settings.pauseGameWhenDashboardVisible)
{
Time.timeScale = timeScale;
SteamVR_Camera.sceneResolutionScale = sceneResolutionScale;
}
}
else
{
if (SteamVR.settings.pauseGameWhenDashboardVisible)
{
timeScale = Time.timeScale;
Time.timeScale = 0.0f;
sceneResolutionScale = SteamVR_Camera.sceneResolutionScale;
SteamVR_Camera.sceneResolutionScale = 0.5f;
}
}
}
In my Unity game where I integrated SteamVR Plugin SDK, once I activate a game menu and trying to return back, the game is frozen as if Time.timeScale = 0.
I found a similar issue but it doesn't really have a solution. I have also tried to disable the following settings with no luck:
Do I need to manually handle return from menu (the same is true for removing and putting back the headset) and unfreeze the game somehow?