# NPC Spawner Navigation (using agent) huge delay when looping after update

**URL:** <https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857>\
**Category:** Issues and Bug Reporting\
**Tags:** fortnite-creative, unreal-editor-for-fortnite, fortnite\
**Created:** [August 16, 2024, 4:46pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857 "2024-08-16T16:46:56Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![ShockMaps](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ShockMaps](https://forums.unrealengine.com/u/ShockMaps)\
**Post date:** [August 16, 2024, 4:46pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/1 "2024-08-16T16:46:56Z")

</div>

### Please select what you are reporting on:

Verse

### What Type of Bug are you experiencing?

AI

### Summary

When calling NavigateTO from NPC Spawner using Agent as the target and the NPC is already inside the target radius, it will take a long time to stop running it, causing the NPC to remain stopped until the player reached a far distance from it.

### Steps to Reproduce

Place a NPC Spawner in the world, reference to a Verse Device.  
Loop a function calling NavigateTo and passing the Agent (Player) (with a Sleep(0.0) after each run)

Once the NPC reaches the player, try to move away and the NPC will take a long time to start moving towards the player again

### Expected Result

When calling NavigateTo and the NPC is already inside the radius, stop the function imediatelly

### Observed Result

NPC will stand still until the player reaches certain distance from it after finishing the previous NavigateTo and start a new one from the loop

### Platform(s)

Any

### Island Code

8039-8238-9814

---

<div class="post-metadata">

**Author:** ![Bug-Reporter](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bug-reporter/32/997076_2.png) [@Bug-Reporter](https://forums.unrealengine.com/u/Bug-Reporter)\
**Post date:** [August 16, 2024, 4:50pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/2 "2024-08-16T16:50:36Z")

</div>

The status of FORT-779853 incident has been moved from ‘In Testing’ to ‘Closed’. Resolution Reason: ‘Fixed’

---

<div class="post-metadata">

**Author:** ![Flak](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/flak/32/769441_2.png) [@Flak](https://forums.unrealengine.com/u/Flak)\
**Post date:** [August 16, 2024, 5:04pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/3 "2024-08-16T17:04:38Z")

</div>

Thank you, we’re taking a look.

---

<div class="post-metadata">

**Author:** ![ShockMaps](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ShockMaps](https://forums.unrealengine.com/u/ShockMaps)\
**Post date:** [August 16, 2024, 5:58pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/4 "2024-08-16T17:58:22Z")

</div>

The workaround we used was to only call NavigateTo if Distance(NPC, Player) \> ReachRadius + 100.0

---

<div class="post-metadata">

**Author:** ![SoyDallas](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/soydallas/32/968257_2.png) [@SoyDallas](https://forums.unrealengine.com/u/SoyDallas)\
**Post date:** [August 16, 2024, 6:02pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/5 "2024-08-16T18:02:05Z")

</div>

Yeah, if you have your reach radius like 300cm, the npc will navigate to like 363. NavigateTo() shouldnt end until ReachRadius is actually complete.

Its probably better just to avoid ?ReachRadius=X.X in your NavigateTo() and just use Distance() checks.

---

<div class="post-metadata">

**Author:** ![Flak](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/flak/32/769441_2.png) [@Flak](https://forums.unrealengine.com/u/Flak)\
**Post date:** [August 17, 2024, 10:09am UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/6 "2024-08-17T10:09:50Z")

</div>

Ticket added - FORT-779853

---

<div class="post-metadata">

**Author:** ![SoyDallas](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/soydallas/32/968257_2.png) [@SoyDallas](https://forums.unrealengine.com/u/SoyDallas)\
**Post date:** [August 17, 2024, 3:39pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/7 "2024-08-17T15:39:30Z")

</div>

We removed the ?ReachRadius on all our NavigateTo() calls. Something with that parameter is blowing up the NavigateTo where it never returns, leaving it stuck inside the loop but never continues execution. So the NPC just remains frozen. Its random though when it breaks, but easy enough to reproduce.

When you remove the ReachRadius from the navigation, you will need to monitor your distance to the target and end navigation when reached. In order to do this, you will need to spawn{} off your NavigateTo because its not async (which I thought it was before the update??)

After spawning the NavigateTo(), you can loop and monitor the distance to target. This approach has fixed all our npc movements.

---

<div class="post-metadata">

**Author:** ![MaxdY](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/maxdy/32/698344_2.png) [@MaxdY](https://forums.unrealengine.com/u/MaxdY)\
**Post date:** [August 18, 2024, 6:32am UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/8 "2024-08-18T06:32:46Z")

</div>

My map has this problem too and Im started getting lower player count and playtime. Please fix this ASAP 😢

---

<div class="post-metadata">

**Author:** ![leeshuriken](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@leeshuriken](https://forums.unrealengine.com/u/leeshuriken)\
**Post date:** [August 18, 2024, 1:35pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/9 "2024-08-18T13:35:01Z")

</div>

Hi SoyDallas,

Would you please include a snippet on how you built that part of the code?

Thank you!

---

<div class="post-metadata">

**Author:** ![Dropshots2Go](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dropshots2Go](https://forums.unrealengine.com/u/Dropshots2Go)\
**Post date:** [August 18, 2024, 2:37pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/10 "2024-08-18T14:37:56Z")

</div>

Any update on this? I’m losing playtime on my maps ☹

---

<div class="post-metadata">

**Author:** ![Jimbohalo10](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jimbohalo10/32/961440_2.png) [@Jimbohalo10](https://forums.unrealengine.com/u/Jimbohalo10)\
**Post date:** [August 19, 2024, 5:27am UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/11 "2024-08-19T05:27:23Z")

</div>

hi @leeshuriken ,  
found this potential answer  
[[STABILITY] NPC behaviour has changed/broken for existing maps - General / Issues and Bug Reporting - Epic Developer Community Forums (unrealengine.com)](https://forums.unrealengine.com/t/stability-npc-behaviour-has-changed-broken-for-existing-maps/1978281/12)  
also look in  
[[LAUNCHING SESSION] - MAJOR Issue - General / Issues and Bug Reporting - Epic Developer Community Forums (unrealengine.com)](https://forums.unrealengine.com/t/launching-session-major-issue/1978593/17)

---

<div class="post-metadata">

**Author:** ![Flak](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/flak/32/769441_2.png) [@Flak](https://forums.unrealengine.com/u/Flak)\
**Post date:** [August 19, 2024, 2:21pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/12 "2024-08-19T14:21:23Z")

</div>

We’re actively working on this!

---

<div class="post-metadata">

**Author:** ![natereese](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/natereese/32/726163_2.png) [@natereese](https://forums.unrealengine.com/u/natereese)\
**Post date:** [August 19, 2024, 2:54pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/13 "2024-08-19T14:54:07Z")

</div>

Awesome! Thanks for jumping on this so quickly. Internally we are trying to priorize some tasks for a launch we have this week. Any idea if we can anticipate a fix in the next few days? If not, no prob we’ll pursue a work around.

---

<div class="post-metadata">

**Author:** ![kirit01011](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@kirit01011](https://forums.unrealengine.com/u/kirit01011)\
**Post date:** [August 19, 2024, 3:04pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/14 "2024-08-19T15:04:18Z")

</div>

Commenting so I can find this later. Major issue for me as well.

---

<div class="post-metadata">

**Author:** ![kirit01011](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@kirit01011](https://forums.unrealengine.com/u/kirit01011)\
**Post date:** [August 19, 2024, 3:13pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/15 "2024-08-19T15:13:06Z")

</div>

Adding my forum post here as another data point basically outlining that the fact that even basic navigation (hiding something behind a wall) no longer works. [Staff at Epic - Please version your changes to Verse](https://forums.unrealengine.com/t/staff-at-epic-please-version-your-changes-to-verse/1983047)  
[NPC Navigation fails and appears dumber than before.](https://forums.unrealengine.com/t/npc-navigation-fails-and-appears-dumber-than-before/1983105)

---

<div class="post-metadata">

**Author:** ![Vilvalas](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/vilvalas/32/993743_2.png) [@Vilvalas](https://forums.unrealengine.com/u/Vilvalas)\
**Post date:** [August 19, 2024, 4:56pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/16 "2024-08-19T16:56:43Z")

</div>

This seems to be a duplicate of [[STABILITY] NPC behaviour has changed/broken for existing maps](https://forums.unrealengine.com/t/stability-npc-behaviour-has-changed-broken-for-existing-maps/1978281)

---

<div class="post-metadata">

**Author:** ![MaxdY](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/maxdy/32/698344_2.png) [@MaxdY](https://forums.unrealengine.com/u/MaxdY)\
**Post date:** [August 21, 2024, 11:39am UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/17 "2024-08-21T11:39:31Z")

</div>

How long will it take? Also I hope it will be hotfix instead of waiting untill next Fortnite update. 😢 NPC maps are really dying right now.

---

<div class="post-metadata">

**Author:** ![kirit01011](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@kirit01011](https://forums.unrealengine.com/u/kirit01011)\
**Post date:** [August 26, 2024, 2:53pm UTC](https://forums.unrealengine.com/t/npc-spawner-navigation-using-agent-huge-delay-when-looping-after-update/1978857/18 "2024-08-26T14:53:39Z")

</div>

@Flak has an update been posted on this matter? What are the NPC behavior changes? Have they been addressed?
