/// <summary> /// Static contructor for the OVRInputControl class. /// </summary> static OVRInputControl() { Debug.Log("OVRInputControl has been deprecated and will be removed in a future release. Please migrate to OVRInput. " + "Refer to the documentation here for more information: " + "https://developer.oculus.com/documentation/game-engines/latest/concepts/unity-ovrinput/"); #if UNITY_ANDROID && !UNITY_EDITOR OVRGamepadController.SetReadAxisDelegate(ReadJoystickAxis); OVRGamepadController.SetReadButtonDelegate(ReadJoystickButton); #endif switch (Application.platform) { case RuntimePlatform.WindowsPlayer: Init_Windows(); break; case RuntimePlatform.WindowsEditor: Init_Windows_Editor(); break; case RuntimePlatform.Android: Init_Android(); break; case RuntimePlatform.OSXPlayer: Init_OSX(); break; case RuntimePlatform.OSXEditor: Init_OSX_Editor(); break; case RuntimePlatform.IPhonePlayer: Init_iPhone(); break; } string[] joystickNames = Input.GetJoystickNames(); for (int i = 0; i < joystickNames.Length; ++i) { if (verbose) { Debug.Log("Found joystick '" + joystickNames[i] + "'..."); } } }
/// <summary> /// Static contructor for the OVRInputControl class. /// </summary> static OVRInputControl() { #if UNITY_ANDROID && !UNITY_EDITOR OVRGamepadController.SetReadAxisDelegate(ReadJoystickAxis); OVRGamepadController.SetReadButtonDelegate(ReadJoystickButton); #endif switch (Application.platform) { case RuntimePlatform.WindowsPlayer: Init_Windows(); break; case RuntimePlatform.WindowsEditor: Init_Windows_Editor(); break; case RuntimePlatform.Android: Init_Android(); break; case RuntimePlatform.OSXPlayer: Init_OSX(); break; case RuntimePlatform.OSXEditor: Init_OSX_Editor(); break; case RuntimePlatform.IPhonePlayer: Init_iPhone(); break; } string[] joystickNames = Input.GetJoystickNames(); for (int i = 0; i < joystickNames.Length; ++i) { if (verbose) { Debug.Log("Found joystick '" + joystickNames[i] + "'..."); } } }