# How to get the trigger box to ignore everything except the player?

**URL:** <https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [March 5, 2015, 3:34pm UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401 "2015-03-05T15:34:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_4dc6cba7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_4dc6cba7](https://forums.unrealengine.com/u/anonymous_user_4dc6cba7)\
**Post date:** [March 5, 2015, 3:34pm UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401/1 "2015-03-05T15:34:28Z")

</div>

Basically, I have created an AI that chases the player whenever the player enters its trigger box. However the problem is that even if another AI overlaps with the trigger box, the AI will still go ahead and chase the player. So I was wondering is there anyway to fix this problem? Thanks!

 ![32459-capture.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/b/e/fbed13f261319ff144ba4d9026e4834d88cae46d.jpeg)

---

<div class="post-metadata">

**Author:** ![Purecyn](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Purecyn](https://forums.unrealengine.com/u/Purecyn)\
**Post date:** [March 5, 2015, 3:42pm UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401/2 "2015-03-05T15:42:30Z")

</div>

Cast the overlaping pawn to your player character BP. If it pases, it’s a player.

---

<div class="post-metadata">

**Author:** ![Jurif](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Jurif](https://forums.unrealengine.com/u/Jurif)\
**Post date:** [March 5, 2015, 4:15pm UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401/3 "2015-03-05T16:15:09Z")

</div>

After the triggered event,  
get the instigator (who caused the overlap event),  
then check the instigator is a player class or check if is the AI class.  
This should work, if it returns false then means this is not AI controller.

 ![32500-screenshot368.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/4/5/d4554e19b637d609cba569bdebf19ebb0861e183.jpeg)

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_4dc6cba7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_4dc6cba7](https://forums.unrealengine.com/u/anonymous_user_4dc6cba7)\
**Post date:** [March 6, 2015, 2:46am UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401/4 "2015-03-06T02:46:08Z")

</div>

Thanks it worked! 🙂

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_4dc6cba7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_4dc6cba7](https://forums.unrealengine.com/u/anonymous_user_4dc6cba7)\
**Post date:** [March 6, 2015, 2:46am UTC](https://forums.unrealengine.com/t/how-to-get-the-trigger-box-to-ignore-everything-except-the-player/309401/5 "2015-03-06T02:46:25Z")

</div>

Thank you! 🙂
