Kastell/Assets/Scripts/GroundDetector.cs
Gerard Gascón f5c1616018 init
2025-02-02 23:45:04 +01:00

10 lines
No EOL
246 B
C#

using UnityEngine;
public class GroundDetector : MonoBehaviour {
private void OnTriggerEnter(Collider other) {
if (other.CompareTag("Ground")) {
FindAnyObjectByType<Interface>().Die();
FindAnyObjectByType<PlayerRotate>().Die();
}
}
}