mirror of
https://github.com/NotAKidoS/NAK_CVR_Mods.git
synced 2025-09-04 07:19:22 +00:00
[DesktopVRSwitch] Wait frame on MovementSystem OnPostSwitch.
testing
This commit is contained in:
parent
0fb7c3d401
commit
52d4ef3279
8 changed files with 123 additions and 48 deletions
|
@ -7,8 +7,6 @@ namespace NAK.DesktopVRSwitch.VRModeTrackers;
|
|||
|
||||
public class MetaPortTracker : VRModeTracker
|
||||
{
|
||||
private MetaPort _metaPort;
|
||||
|
||||
public override void TrackerInit()
|
||||
{
|
||||
VRModeSwitchManager.OnPostVRModeSwitch += OnPostSwitch;
|
||||
|
@ -21,7 +19,7 @@ public class MetaPortTracker : VRModeTracker
|
|||
|
||||
private void OnPostSwitch(bool intoVR)
|
||||
{
|
||||
_metaPort = MetaPort.Instance;
|
||||
MetaPort _metaPort = MetaPort.Instance;
|
||||
if (_metaPort == null)
|
||||
{
|
||||
DesktopVRSwitch.Logger.Error("Error while getting MetaPort!");
|
||||
|
@ -33,11 +31,11 @@ public class MetaPortTracker : VRModeTracker
|
|||
_metaPort.isUsingVr = intoVR;
|
||||
|
||||
// replace
|
||||
UpdateRichPresence();
|
||||
UpdateRichPresence(_metaPort);
|
||||
ResetSteamVROverrides(intoVR);
|
||||
}
|
||||
|
||||
private void UpdateRichPresence()
|
||||
private void UpdateRichPresence(MetaPort _metaPort)
|
||||
{
|
||||
// Hacky way of updating rich presence
|
||||
if (_metaPort.settings.GetSettingsBool("ImplementationRichPresenceDiscordEnabled", true))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue