DWTD/Assets/Scripts/Player/Hand.cs
2024-09-04 01:08:09 +02:00

29 lines
717 B
C#

using Assets.Scripts;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Hand : MonoBehaviour
{
private WeaponSelectMenu weaponSelectMenu;
// Start is called before the first frame update
private void Start()
{
weaponSelectMenu = GameObject.FindObjectOfType<WeaponSelectMenu>();
}
// Update is called once per frame
private void Update()
{
if (ControlsManager.Controls.RightHand.WeaponSelect.WasPressedThisFrame())
{
weaponSelectMenu.Show(this);
}
if (ControlsManager.Controls.RightHand.WeaponSelect.WasReleasedThisFrame())
{
weaponSelectMenu.Hide();
}
}
}