コード例 #1
0
 public virtual void Init(FloatingScreen floatingScreen)
 {
     _floatingScreen = floatingScreen;
     _screenHandle   = floatingScreen.handle.transform;
     _realPos        = floatingScreen.transform.position;
     _realRot        = floatingScreen.transform.rotation;
     _vrPointer      = GetComponent <VRPointer>();
 }
コード例 #2
0
 protected void OnDestroy()
 {
     OnGrab              = null;
     OnRelease           = null;
     _vrPointer          = null;
     _floatingScreen     = null;
     _screenHandle       = null;
     _grabbingController = null;
 }
コード例 #3
0
 public virtual void Init(FloatingScreen floatingScreen, VRPointer pointer)
 {
     _floatingScreen = floatingScreen;
     _screenHandle   = floatingScreen.handle.transform;
     _realPos        = floatingScreen.transform.position;
     _realRot        = floatingScreen.transform.rotation;
     _vrPointer      = pointer;
     _isFpfc         = Environment.CommandLine.Contains("fpfc");
 }
コード例 #4
0
 public virtual void Init(FloatingScreen floatingScreen, VRPointer pointer)
 {
     _floatingScreen = floatingScreen;
     _screenHandle   = floatingScreen.handle.transform;
     _realPos        = floatingScreen.transform.position;
     _realRot        = floatingScreen.transform.rotation;
     _vrPointer      = pointer;
     _fpfc           = Resources.FindObjectsOfTypeAll <FirstPersonFlyingController>().FirstOrDefault();
 }
コード例 #5
0
        //It's just for testing so don't yell at me
        private IEnumerator PresentTest <T>() where T : ViewController
        {
            yield return(new WaitForSeconds(1));

            ViewController testViewController = BeatSaberUI.CreateViewController <T>();

            FloatingScreen.FloatingScreen floatingScreen = FloatingScreen.FloatingScreen.CreateFloatingScreen(new Vector2(400, 200), true, Vector3.zero, Quaternion.identity);
            floatingScreen.SetRootViewController(testViewController, ViewController.AnimationType.None);
            Resources.FindObjectsOfTypeAll <MainFlowCoordinator>().First().InvokeMethod <object, FlowCoordinator>("PresentViewController", new object[] { testViewController, null, ViewController.AnimationDirection.Horizontal, false });
        }
コード例 #6
0
        public virtual void Init(FloatingScreen floatingScreen)
        {
            VRPointer vrPointer = GetComponent <VRPointer>();

            Init(floatingScreen, vrPointer);
        }