public static bool GetBounds(SteamVR_PlayArea.Size size, ref HmdQuad_t pRect) { if (size == SteamVR_PlayArea.Size.Calibrated) { bool flag = !SteamVR.active && !SteamVR.usingNativeSupport; if (flag) { EVRInitError eVRInitError = EVRInitError.None; OpenVR.Init(ref eVRInitError, EVRApplicationType.VRApplication_Other); } CVRChaperone chaperone = OpenVR.Chaperone; bool flag2 = chaperone != null && chaperone.GetPlayAreaRect(ref pRect); if (!flag2) { UnityEngine.Debug.LogWarning("Failed to get Calibrated Play Area bounds! Make sure you have tracking first, and that your space is calibrated."); } if (flag) { OpenVR.Shutdown(); } return flag2; } try { string text = size.ToString().Substring(1); string[] array = text.Split(new char[] { 'x' }, 2); float num = float.Parse(array[0]) / 200f; float num2 = float.Parse(array[1]) / 200f; pRect.vCorners0.v0 = num; pRect.vCorners0.v1 = 0f; pRect.vCorners0.v2 = num2; pRect.vCorners1.v0 = num; pRect.vCorners1.v1 = 0f; pRect.vCorners1.v2 = -num2; pRect.vCorners2.v0 = -num; pRect.vCorners2.v1 = 0f; pRect.vCorners2.v2 = -num2; pRect.vCorners3.v0 = -num; pRect.vCorners3.v1 = 0f; pRect.vCorners3.v2 = num2; return true; } catch { } return false; }