27 lines
571 B
C#
27 lines
571 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class LocomotionSettingButton : MonoBehaviour
|
|
{
|
|
|
|
private MeshCollider _collider;
|
|
|
|
public GameObject LocomotionPanel;
|
|
// Start is called before the first frame update
|
|
void Start()
|
|
{
|
|
_collider = GetComponent<MeshCollider>();
|
|
LocomotionPanel.SetActive(false);
|
|
}
|
|
|
|
private void OnTriggerEnter(Collider other)
|
|
{
|
|
if (other.tag == "Hand")
|
|
{
|
|
LocomotionPanel.SetActive(!LocomotionPanel.activeSelf);
|
|
|
|
}
|
|
}
|
|
}
|