SteamVR 设置进入UI 直 射线显示, teleporting不显示
出了UI 射线不显示, teleporting显示
我是直接在之前, 封装射线检测信息里面加的代码
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.EventSystems;
using Valve.VR.Extras;
using Valve.VR;
using Valve.VR.InteractionSystem;
public class SteamVRLaserWrapper : MonoBehaviour
{
private SteamVR_LaserPointer steamVrLaserPointer;
//sxc
private Hand hand;
private void Awake()
{
steamVrLaserPointer = gameObject.GetComponent<SteamVR_LaserPointer>();
steamVrLaserPointer.PointerIn += OnPointerIn;
steamVrLaserPointer.PointerOut += OnPointerOut;
steamVrLaserPointer.PointerClick += OnPointerClick;
//sxc
steamVrLaserPointer.thickness = 0f;
if (hand == null)
{
hand = this.GetComponent<Hand>();
}
}
vo