先给出手柄按键的大致示意图——
按键控制的脚本格式大致如下——
using UnityEngine;
using System.Collections;
public class shoubingkongzhi : MonoBehaviour {
///
/// 手柄
///
SteamVR_TrackedObject tracked;
void Awake()
{
//获取手柄
tracked = GetComponent();
}