Exemple #1
0
 void Update()
 {
     if (isLeft)
     {
         if (XRVive.isLeftTriggerTouchGetKeyDown())
         {
             grab();
         }
         if (XRVive.isLeftTriggerTouchGetKeyUp())
         {
             release();
         }
     }
     else
     {
         if (XRVive.isRightTriggerTouchGetKeyDown())
         {
             grab();
         }
         if (XRVive.isRightTriggerTouchGetKeyUp())
         {
             release();
         }
     }
 }
Exemple #2
0
 void Update()
 {
     // Left Controller Trackpad Press:8 Touch:16
     // Right Controller Trackpad Press:9 Touch:17
     if (XRVive.isLeftTrackPadTouchGetKeyUp())
     {
         animator.SetInteger(LEFT_HAND_POSE_NAME, (int)HandPose._base);
     }
     if (XRVive.isLeftTrackPadTouchGetKey())
     {
         if (XRVive.isLeftTrackPadLeftUpTouched())
         {
             animator.SetInteger(LEFT_HAND_POSE_NAME, (int)HandPose.rocknroll);
         }
         else if (XRVive.isLeftTrackPadRightUpTouched())
         {
             animator.SetInteger(LEFT_HAND_POSE_NAME, (int)HandPose.point);
         }
         else if (XRVive.isLeftTrackPadLeftDownTouched())
         {
             animator.SetInteger(LEFT_HAND_POSE_NAME, (int)HandPose.v);
         }
         else if (XRVive.isLeftTrackPadRightDownTouched())
         {
             animator.SetInteger(LEFT_HAND_POSE_NAME, (int)HandPose.fist);
         }
     }
     if (XRVive.isRightTrackPadTouchGetKeyUp())
     {
         animator.SetInteger(RIGHT_HAND_POSE_NAME, (int)HandPose._base);
     }
     if (XRVive.isRightTrackPadTouchGetKey())
     {
         if (XRVive.isRightTrackPadLeftUpTouched())
         {
             animator.SetInteger(RIGHT_HAND_POSE_NAME, (int)HandPose.point);
         }
         else if (XRVive.isRightTrackPadRightUpTouched())
         {
             animator.SetInteger(RIGHT_HAND_POSE_NAME, (int)HandPose.rocknroll);
         }
         else if (XRVive.isRightTrackPadLeftDownTouched())
         {
             animator.SetInteger(RIGHT_HAND_POSE_NAME, (int)HandPose.fist);
         }
         else if (XRVive.isRightTrackPadRightDownTouched())
         {
             animator.SetInteger(RIGHT_HAND_POSE_NAME, (int)HandPose.v);
         }
     }
 }
Exemple #3
0
 void Update()
 {
     if (XRVive.isLeftTriggerTouchGetKey() && XRVive.isLeftTrackPadPressGetKey())
     {
         if (XRVive.isLeftTrackPadLeftUpTouched())
         {
             morph.setEyeJitome();
         }
         else if (XRVive.isLeftTrackPadRightUpTouched())
         {
             morph.setEyeX();
         }
         else if (XRVive.isLeftTrackPadLeftDownTouched())
         {
             morph.resetMorph();
         }
         else if (XRVive.isLeftTrackPadRightDownTouched())
         {
             morph.resetMorph();
         }
     }
     if (XRVive.isRightTriggerTouchGetKey() && XRVive.isRightTrackPadPressGetKey())
     {
         if (XRVive.isRightTrackPadLeftUpTouched())
         {
             morph.setEyeSmall();
         }
         else if (XRVive.isRightTrackPadRightUpTouched())
         {
             morph.setEyeLine();
         }
         else if (XRVive.isRightTrackPadLeftDownTouched())
         {
             morph.setEyeSmile();
         }
         else if (XRVive.isRightTrackPadRightDownTouched())
         {
             morph.setEyeSmile();
         }
     }
 }