【VRTK】【VR开发】【Unity】10-连续移动

在这里插入图片描述

课程配套学习资源下载

https://download.csdn.net/download/weixin_41697242/88485426?spm=1001.2014.3001.5503

【概述】

连续移动与瞬移有如下不同:

  1. 连续移动不容易打断沉浸
  2. 对于新手或者不适应者来说更容易晕动
    我对玩家的建议:连续移动前后左右可以用摇杆,转向用自己物理转向不容易晕动且有最佳沉浸感。

【捕获水平和垂直坐标轴输入】

这次采用与之前不同的另一种方式捕获摇杆的水平轴和垂直轴方向的输入。
VRTK提供了 1D Axis Action方法用来捕获摇杆输入。

  1. 在Hierarchy中展开Button Input Actions。
  2. 在Project面板中展开Packages-》Tilia Input Unity Input Manager-》。。。-》Prefabs-》Actions
  3. 拖拽Input Unity Input Manager 1D Axis Action预制件到Hierarchy中的Button Input Actions。将预制件重命名为“Thumbstick Horizontal Axis Input.”。
  4. 在Hierarchy中选中Thumbstick, Horizontal Axis Input,在属性面板中展开Unity Input

猜你喜欢

转载自blog.csdn.net/weixin_41697242/article/details/134627392