码迷,mamicode.com
首页 > 编程语言 > 详细

unity 5.6.1 Oculus手柄输入问题

时间:2017-07-24 15:25:23      阅读:243      评论:0      收藏:0      [点我收藏+]

标签:img   测试   alt   分享   技术分享   debug   bug   button   deb   

unity文档中提到 轴的 ID 是5和6,但是测试后发现,ID是6和7,很坑

技术分享

 

技术分享

 

 

 1 void Update () {
 2         if (Input.GetKeyDown(KeyCode.JoystickButton0)) {
 3             Debug.Log ("确定");
 4         }
 5         if (Input.GetKeyDown(KeyCode.JoystickButton1)) {
 6             Debug.Log ("返回");
 7         }
 8         Debug.Log (Input.GetAxis("OculusRL"));
 9         Debug.Log (Input.GetAxis("OculusUD"));
10     }

 

unity 5.6.1 Oculus手柄输入问题

标签:img   测试   alt   分享   技术分享   debug   bug   button   deb   

原文地址:http://www.cnblogs.com/Jason-c/p/7229052.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!