# "Pawn Sensing" doesn't work

**URL:** <https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020>\
**Category:** AI\
**Tags:** unreal-engine, pawn-sensing, pawn, Blueprint, question\
**Created:** [March 9, 2016, 1:20pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020 "2016-03-09T13:20:51Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Marco\_I](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Marco\_I](https://forums.unrealengine.com/u/Marco_I)\
**Post date:** [March 9, 2016, 1:20pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/1 "2016-03-09T13:20:51Z")

</div>

Hi guys,  
I followed this tutorial: [Unreal Engine 4 Tutorial - AI Pawn Sensing - YouTube](https://www.youtube.com/watch?v=59INcP9Vsmo)

I made everything like the video, but the character with pawn sensing doesn’t follow me at all.  
Should I do something else?

Regarding my project, I just have a normal character controlled by me with keyboard inside a normal scenario. Nothing particular has made inside of it.

---

<div class="post-metadata">

**Author:** ![Tensa\_Zangetsu](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Tensa\_Zangetsu](https://forums.unrealengine.com/u/Tensa_Zangetsu)\
**Post date:** [March 9, 2016, 2:29pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/2 "2016-03-09T14:29:23Z")

</div>

Hi Marco,

the recommended approach regarding “Sensing” activities is to use the **AIPerception** Component. The Pawn Sensing Component seems deprecated by now and at least not maintained anymore.

---

<div class="post-metadata">

**Author:** ![Marco\_I](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Marco\_I](https://forums.unrealengine.com/u/Marco_I)\
**Post date:** [March 9, 2016, 2:50pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/3 "2016-03-09T14:50:07Z")

</div>

Hi Tensa,  
thank you for your reply.  
Yeah I know that is deprecated, and will be replaced very soon by the **AIPerception** component, but since I really need something in a simple way for now, can I still use the **Pawn Sensing** component?

I mean, it still should work, right? I just want to understand why it doesn’t work.  
**AIPerception** seems a little bit more complicated for now, I need to show something very simple as an example of interaction between characters.

---

<div class="post-metadata">

**Author:** ![Tensa\_Zangetsu](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Tensa\_Zangetsu](https://forums.unrealengine.com/u/Tensa_Zangetsu)\
**Post date:** [March 9, 2016, 3:03pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/4 "2016-03-09T15:03:02Z")

</div>

Well, PawnSensing should still be functional, indeed.  
Did you put the NavMesh on the map?

---

<div class="post-metadata">

**Author:** ![Marco\_I](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Marco\_I](https://forums.unrealengine.com/u/Marco_I)\
**Post date:** [March 9, 2016, 3:15pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/5 "2016-03-09T15:15:13Z")

</div>

Uhm… no? I’m completely new to this, I made interior design usually! 😃  
Is it complicated to do? What I have to do exactly?

---

<div class="post-metadata">

**Author:** ![Marco\_I](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Marco\_I](https://forums.unrealengine.com/u/Marco_I)\
**Post date:** [March 9, 2016, 4:19pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/6 "2016-03-09T16:19:05Z")

</div>

Ok seems that it works now. 🙂 Thanks!

---

<div class="post-metadata">

**Author:** ![JJFawkes](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JJFawkes](https://forums.unrealengine.com/u/JJFawkes)\
**Post date:** [March 27, 2019, 5:58am UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/7 "2019-03-27T05:58:36Z")

</div>

I spent several hours debugging this issue, if anyone else has the same problem, try registering the delegate function inside BeginPlay. I had it registered in the constructor and it was never called. I don’t know why we can’t use AddDynamic in constructors, but in some cases it just doesn’t work.  
As soon as I moved it to BeginPlay everything worked as expected.

---

<div class="post-metadata">

**Author:** ![the\_green\_arrow](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@the\_green\_arrow](https://forums.unrealengine.com/u/the_green_arrow)\
**Post date:** [September 30, 2019, 11:48pm UTC](https://forums.unrealengine.com/t/pawn-sensing-doesnt-work/350020/8 "2019-09-30T23:48:06Z")

</div>

You could try binding events in PostInitializeComponents(). That’s where ideally you should bind the events;
