private void HandleEnter(GameObject other) { if (!other.CompareTag(tagFilter)) { return; } events.OnTriggerEnter?.Invoke(); TriggerEntered?.Invoke(other.gameObject); _count++; }
private void OnCollisionPairCreated(EntityCollidable sender, BroadPhaseEntry other, NarrowPhasePair pair) { if (!(other.Tag is Collider)) { Console.WriteLine("ERROR: TAG WAS NOT COLLIDER."); } else { Collider otherCollider = (Collider)other.Tag; TriggerEntered?.Invoke(otherCollider); } }
private void OnTriggerEnter(Collider other) { TriggerEntered?.Invoke(other); }
private void OnTriggerExit2D(Collider2D collision) { TriggerEntered?.Invoke(collision); }