mirror of
https://github.com/NotAKidoS/NAK_CVR_Mods.git
synced 2025-09-02 14:29:25 +00:00
fix hud scale
This commit is contained in:
parent
485eb7fd79
commit
9fee74f587
1 changed files with 4 additions and 7 deletions
|
@ -16,11 +16,6 @@ using Valve.VR;
|
||||||
using HarmonyLib;
|
using HarmonyLib;
|
||||||
using Object = UnityEngine.Object;
|
using Object = UnityEngine.Object;
|
||||||
|
|
||||||
//Remove VRIK on VR to Desktop
|
|
||||||
//Remove LookAtIK on Desktop to VR
|
|
||||||
|
|
||||||
//Set Desktop camera to head again...?
|
|
||||||
//Recenter collision position (in VR it shifts around)
|
|
||||||
|
|
||||||
//tell the game to change VRMode/DesktopMode for Steam/Discord presence
|
//tell the game to change VRMode/DesktopMode for Steam/Discord presence
|
||||||
//RichPresence.PopulatePresence();
|
//RichPresence.PopulatePresence();
|
||||||
|
@ -61,7 +56,8 @@ public class DesktopVRSwitch : MelonMod
|
||||||
MelonCoroutines.Start(AttemptPlatformSwitch());
|
MelonCoroutines.Start(AttemptPlatformSwitch());
|
||||||
|
|
||||||
//how long we wait until we assume an error occured
|
//how long we wait until we assume an error occured
|
||||||
timedSwitch = Time.time + 10f;
|
if (m_entryTimedErrorCatch.Value)
|
||||||
|
timedSwitch = Time.time + 10f;
|
||||||
}
|
}
|
||||||
|
|
||||||
//catch if coroutine just decided to not finish... which happens?
|
//catch if coroutine just decided to not finish... which happens?
|
||||||
|
@ -71,7 +67,7 @@ public class DesktopVRSwitch : MelonMod
|
||||||
MelonCoroutines.Start(AttemptPlatformSwitch(true));
|
MelonCoroutines.Start(AttemptPlatformSwitch(true));
|
||||||
}
|
}
|
||||||
|
|
||||||
//correct player position
|
//correct player position while switching
|
||||||
if (isAttemptingSwitch && !MovementSystem.Instance.canMove)
|
if (isAttemptingSwitch && !MovementSystem.Instance.canMove)
|
||||||
{
|
{
|
||||||
MovementSystem.Instance.TeleportToPosRot(avatarPos, avatarRot, false);
|
MovementSystem.Instance.TeleportToPosRot(avatarPos, avatarRot, false);
|
||||||
|
@ -273,6 +269,7 @@ public class DesktopVRSwitch : MelonMod
|
||||||
|
|
||||||
//sets hud position, rotation, and scale based on MetaPort isUsingVr
|
//sets hud position, rotation, and scale based on MetaPort isUsingVr
|
||||||
CVRTools.ConfigureHudAffinity();
|
CVRTools.ConfigureHudAffinity();
|
||||||
|
CohtmlHud.Instance.gameObject.transform.localScale = new Vector3(1.2f, 1f, 1.2f);
|
||||||
}
|
}
|
||||||
catch (Exception)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue