jimmy tremblay-Bernier 86fbe09b20 initial commit
2022-03-12 20:32:56 -05:00

22 lines
546 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Valve.VR;
public class SteamInput : MonoBehaviour
{
public Bow m_Bow = null;
public SteamVR_Behaviour_Pose m_Pose = null;
public SteamVR_Action_Boolean m_PullAction = null;
// Update is called once per frame
void Update()
{
if (m_PullAction.GetLastStateDown(m_Pose.inputSource))
m_Bow.Pull(m_Pose.gameObject.transform);
if (m_PullAction.GetStateUp(m_Pose.inputSource))
m_Bow.Release();
}
}