示例#1
0
 public override void OnDeactivated()
 {
     s_moduleInstance = null;
     m_deviceUidToIndex.Clear();
     m_indexToDevices.Clear();
     m_connectedDevices.Clear();
 }
示例#2
0
 public override void OnActivated()
 {
     s_moduleInstance            = this;
     m_currentInputSubsystemType = DetectCurrentInputSubsystemType();
     EnsureDeviceStateLength(DEVICE_STATE_LENGTH);
     Debug.Log("Activated XRLoader Name: " + XRGeneralSettings.Instance.Manager.activeLoader.name);
 }
示例#3
0
        public override bool ShouldActiveModule()
        {
#if UNITY_2019_3_OR_NEWER && VIU_XR_GENERAL_SETTINGS
            return(VIUSettings.activateSteamVRModule && UnityXRModule.HasActiveLoader(OPENVR_XR_LOADER_NAME));
#elif UNITY_5_4_OR_NEWER
            return(VIUSettings.activateSteamVRModule && XRSettings.enabled && XRSettings.loadedDeviceName == "OpenVR");
#else
            return(VIUSettings.activateSteamVRModule && SteamVR.enabled);
#endif
        }
示例#4
0
 public override void OnDeactivated()
 {
     base.OnDeactivated();
     s_moduleInstance = null;
 }
示例#5
0
 public override void OnActivated()
 {
     s_moduleInstance = this;
     base.OnActivated();
 }