// OVRInput.Update();
if (OVRInput.GetUp(OVRInput.Button.Three))
{
Debug.Log("remote click");
text.text = "X";
}
if (OVRInput.GetUp(OVRInput.Button.Four))
{
Debug.Log("remote click");
text.text = "Y";
}
if (OVRInput.Get(OVRInput.Button.One,OVRInput.Controller.RTouch))
{
Debug.Log("攻击键A");
text.text = "Attack A";
}
if (OVRInput.Get(OVRInput.Button.Two, OVRInput.Controller.RTouch))
{
Debug.Log("攻击键B");
text.text = "ATTack B";
}

//if (OVRInput.Get(OVRInput.RawButton.LThumbstickUp))
//{
// Debug.Log("左侧遥感");
// text.text = "LeftSide";
//}
//if (OVRInput.Get(OVRInput.RawButton.LThumbstickDown))
//{
// Debug.Log("左侧遥感");
// text.text = "LeftSide";
//}
////右侧遥感上下左右
//if (OVRInput.Get(OVRInput.RawButton.RThumbstickUp))
//{
// Debug.Log("右侧遥感");
// text.text = "RThumbstickUp";
//}
//if (OVRInput.Get(OVRInput.RawButton.RThumbstickDown))
//{
// Debug.Log("右侧遥感");
// text.text = "RThumbstickDown";
//}
//if (OVRInput.Get(OVRInput.RawButton.RThumbstickRight))
//{
// Debug.Log("右侧遥感");
// text.text = "RThumbstickRight";
//}
//if (OVRInput.Get(OVRInput.RawButton.RThumbstickLeft))
//{
// Debug.Log("右侧遥感");
// text.text = "RThumbstickLeft";
//}



vt =OVRInput.Get(OVRInput.Axis2D.PrimaryThumbstick);
if (vt.x != 0 && vt.y != 0)
{
text.text = vt.x + " " + vt.y;
}
vt = OVRInput.Get(OVRInput.Axis2D.SecondaryThumbstick);
if (vt.x != 0 && vt.y != 0)
{
text.text = vt.x + " " + vt.y;
}
//射击
float aa=OVRInput.Get(OVRInput.Axis1D.PrimaryIndexTrigger);
if (aa!= 0)
{
text.text = aa+ " A1";
}
aa = OVRInput.Get(OVRInput.Axis1D.SecondaryIndexTrigger);
if (aa != 0)
{
text.text = aa + " A2";
}
//握柄按钮
float aaa=OVRInput.Get(OVRInput.Axis1D.PrimaryHandTrigger);
if (aaa != 0)
{
text.text = aaa + " AAAA1";
}
aaa = OVRInput.Get(OVRInput.Axis1D.SecondaryHandTrigger);
if (aaa != 0)
{
text.text = aaa + " AAAA2";
}

//遥感按键
if (OVRInput.Get(OVRInput.Button.PrimaryThumbstick))
{
text.text = "1";
Debug.Log("1");
}
if (OVRInput.Get(OVRInput.Button.SecondaryThumbstick))
{
text.text = "2";
Debug.Log("2");
}
//触摸按钮
if (OVRInput.Get(OVRInput.Touch.PrimaryThumbRest))
{
text.text = "3";
Debug.Log("3");
}
if (OVRInput.Get(OVRInput.Touch.SecondaryThumbRest))
{
text.text = "4";
Debug.Log("4");
}

oculus按键大全的更多相关文章

  1. VBS自动按键大全,vbs基本和特殊按键

    CreateObject("Wscript.Shell") SendKeys [String] 脚本实现自动按键盘的某个键 过程是:按下F5间隔50毫秒松开F5间隔3000毫秒按下 ...

  2. Vim常用按键大全

    Vim完全可以用键盘进行操作.本文将常用的按键归纳总结. 第一部分:一般模式可用的按钮,如光标移动.复制粘贴.查找替换等 移动光标的方法 h, j, k, l 光标向左,下,上,右移动 Ctrl + ...

  3. TXT文件用法大全【荐】--------按键精灵

    来源:全文链接 (3)读取TXT文件指定某一行的第?到第?个字 UserVar t=2 "读出txt第几行文本" UserVar i=5 "从第几个字开始读取" ...

  4. 键盘按键keyCode大全,js页面快捷键

    字母和数字键的键码值(keyCode) 按键 键码 按键 键码 按键 键码 按键 键码 A 65 J 74 S 83 1 49 B 66 K 75 T 84 2 50 C 67 L 76 U 85 3 ...

  5. 键盘按钮keyCode大全:获取按键对应的键值的方法

    没有大全,只有方法,授人与鱼不如授人于渔: 下面这行代码,大家可以打在控制台里,直接进行测试: document.body.onkeyup = function (e) { e = e || wind ...

  6. 键盘按键KeyCode大全

  7. adb 常用命令大全(6)- 模拟按键输入

    语法格式 input [<source>] <command> [<arg>...] 物理键 # 电源键 adb shell input keyevent 26 # ...

  8. [No00009B]win10快捷键大全

    微软为Win10命令行(Command Prompt)加入了Ctrl + V的支持 Win10新增功能快捷键大全: 贴靠窗口:Win + 左/右 >  Win + 上/下 > 窗口可以变为 ...

  9. JavaScript资源大全中文版(Awesome最新版--转载自张果老师博客)

    JavaScript资源大全中文版(Awesome最新版)   目录 前端MVC 框架和库 包管理器 加载器 打包工具 测试框架 框架 断言 覆盖率 运行器 QA 工具 基于 Node 的 CMS 框 ...

  10. Android Permission 访问权限大全(转)

    程序执行需要读取到安全敏感项必需在androidmanifest.xml中声明相关权限请求, 完整列表如下: android.permission.ACCESS_CHECKIN_PROPERTIES允 ...

随机推荐

  1. 性能测试-IO密集型-直接会话可能会断了,命令执行不了

    1.IO密集型模拟命令 该命令会开启1个worker不停的读写临时文件,同时启动6个workers不停的调用sync系统调用提交缓存 stress-ng -i 6 --hdd 1 --timeout ...

  2. 搭建CentOS 7

    首先,操作系统要部署在哪一个盘符下就在哪一个盘符下创建一个空文件夹,用来存放实验环境.这里的实验环境的文件夹可以命名为CentOS 7 x64. VMware中,"文件"--&qu ...

  3. Win10下如何添加“中文简体(美式键盘)”输入法

    参考Win10下如何添加"中文简体(美式键盘)"输入法 设置>>时间和语言>>语言>>添加语言>>选择要安装的语言>>英 ...

  4. ipmitool for windows下载网址

    ipmitool for windows版本下载网址 http://ipmiutil.sourceforge.net/

  5. server配置,IDE,快捷键索引目录

    查看内存占用  ps -aux --sort -rss 查看是否运行某个进程,ps -aux | grep xxxxx 查看端口占用 netstat -tunlp | grep 6379 docker ...

  6. 从FGUI中取一张图片并返回一个Sprite

    从Fgui中的图集中取一个图素,把图素用到场景等非UI的地方. 此操作会动态创建一个Sprite对象,效率不好,不适合大量使用. private static Dictionary<string ...

  7. 关于SaaS的图

  8. Ubuntu下CodeBlocks控制台程序中文显示乱码解决问题

    今天在CodeBlocks下折腾来半天,终于把中文乱码给解决了,其实很简单. 在环境设置里进行如下设置:把Terminal to launch console programs那个选项改成gnome- ...

  9. 【Python】语言的控制流程

    二.Python语言的控制流程 1.程序的组织结构 1.1 顺序结构:从上到下顺序的执行代码,直到程序结束,没有任何判断和跳转 1.2 选择结构:根据判断条件的布尔值选择性的执行部分代码:if语句 1 ...

  10. oracle 高级队列

    转载:http://www.idevelopment.info/data/Oracle/DBA_tips/Advanced_Queuing/AQ_2.shtml Overview This artic ...