DRHPS/code-csharp/en_US/INT_CollisionChat.cs
2025-04-08 11:31:35 +08:00

18 lines
339 B
C#

using UnityEngine;
public class INT_CollisionChat : MonoBehaviour
{
public INT_Chat ChatToCollide;
public bool HasRan;
private void OnTriggerEnter2D(Collider2D other)
{
if (other.tag == "Player" && !HasRan)
{
HasRan = true;
ChatToCollide.RUN();
}
}
}