void HandleTouchpad_ControlPortal_PressDown(TouchpadDirection touchpadDirection)
        {
            switch (touchpadDirection)
            {
            case TouchpadDirection.Up:
                PortalScript.ResetPortalPosition();
                break;

            case TouchpadDirection.Down:
                dartGenerator.DestroyObjs();
                break;
            }
        }
示例#2
0
        void HandleTouchpad(ButtonStage buttonStage, Vector2 axis)
        {
            switch (buttonStage)
            {
            case ButtonStage.PressDown:

                TouchpadDirection touchpadDirection = ViveSR_Experience_ControllerDelegate.GetTouchpadDirection(axis, false);

                if (touchpadDirection == TouchpadDirection.Up)
                {
                    DynamicMeshScript.SetMeshDisplay(!DynamicMeshScript.ShowDynamicCollision);
                    DisplayMesh.text = DisplayMesh.text == "[Show]" ? "[Hide]" : "[Show]";
                }
                else if (touchpadDirection == TouchpadDirection.Down)
                {
                    dartGenerator.DestroyObjs();
                }
                break;
            }
        }