private void OnTriggerExit2D(Collider2D other)
 {
     if (other.gameObject.tag != "Player")
     {
         TriggerExit?.Invoke(this, other.gameObject);
     }
 }
 public void OnTriggerExit(Collider other)
 {
     if (CheckLayer(other))
     {
         TriggerExit?.Invoke(other);
     }
 }
Beispiel #3
0
        private void OnTriggerExit(Collider other)
        {
            var entity = other.GetComponentInParent <IGameEntity>();

            if (entity != null && TriggerExit != null)
            {
                TriggerExit?.Invoke(entity);
            }
        }
Beispiel #4
0
        protected virtual void OnTriggerExit(EventArgs e)
        {
            Log("Exited trigger: " + _name);
            if (debugLevel > 1)
            {
                ShowMessage("Exited trigger: " + ToString());
            }

            TriggerExit?.Invoke(this, index, e);
        }
Beispiel #5
0
        internal void OnTriggerExit(Collider collider)
        {
            TriggerExit?.Invoke(collider);

            var rigidbody = AttachedRigidBody;

            if (rigidbody)
            {
                rigidbody.OnTriggerExit(collider);
            }
        }
Beispiel #6
0
 internal void Trigger(Collider2D other, CollisionPairState state)
 {
     if (state.enter)
     {
         TriggerEnter?.Invoke(other);
     }
     if (state.stay)
     {
         TriggerStay?.Invoke(other);
     }
     if (state.exit)
     {
         TriggerExit?.Invoke(other);
     }
 }
Beispiel #7
0
        void Awake()
        {
            _triggerOverlap = GetComponent <TriggerOverlap>();

            _triggerExit = GetComponent <TriggerExit>();

            _input = GetComponentInParent <InputHandler>();

            _collider = GetComponent <Collider>();

            _triggerOverlap.OnTrigger += DisplayInteraction;

            _triggerExit.OnExit += HideInteraction;

            _input.OnInteract += ExecuteInteraction;
        }
Beispiel #8
0
 private void OnTriggerExit(Collider collider)
 {
     TriggerExit?.Invoke(gameObject, collider);
 }
Beispiel #9
0
 internal void OnTriggerExit(Collider collider)
 {
     TriggerExit?.Invoke(collider);
 }
Beispiel #10
0
 private void OnTriggerExit(Collider other)
 {
     TriggerExit.Invoke();
 }
Beispiel #11
0
 private void OnTriggerExit(Collider other) =>
 TriggerExit?.Invoke(other);
Beispiel #12
0
 private void OnTriggerExit()
 {
     TriggerExit.Invoke();
     Debug.Log("You have left the trigger zone");
 }
 private void OnTriggerExit(Collider other)
 {
     TriggerExit?.Invoke(this, new TriggerEventArgs(other));
 }
Beispiel #14
0
 public void OnTriggerExit(Collider other)
 {
     TriggerExit.SafeInvoke(other);
 }
Beispiel #15
0
 private void OnTriggerExit(Collider col)
 {
     TriggerExit?.Invoke(col.gameObject);
 }
Beispiel #16
0
 private void OnTriggerExit2D(Collider2D other)
 {
     TriggerExit?.Invoke(this, other.gameObject);
 }
Beispiel #17
0
 private void OnTriggerExit2D(Collider2D other)
 {
     TriggerExit?.Invoke(other);
 }
Beispiel #18
0
 public void RaiseTriggerExit(Collider other)
 {
     TriggerExit?.Invoke(other);
 }
Beispiel #19
0
 void OnTriggerExit(Collider collider) =>
 TriggerExit?.Invoke(collider);