summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scene/2d/navigation_agent_2d.cpp1
-rw-r--r--scene/3d/navigation_agent.cpp1
2 files changed, 2 insertions, 0 deletions
diff --git a/scene/2d/navigation_agent_2d.cpp b/scene/2d/navigation_agent_2d.cpp
index f5fe113f29..e345a076ae 100644
--- a/scene/2d/navigation_agent_2d.cpp
+++ b/scene/2d/navigation_agent_2d.cpp
@@ -215,6 +215,7 @@ void NavigationAgent2D::set_target_location(Vector2 p_location) {
navigation_path.clear();
target_reached = false;
navigation_finished = false;
+ update_frame_id = 0;
}
Vector2 NavigationAgent2D::get_target_location() const {
diff --git a/scene/3d/navigation_agent.cpp b/scene/3d/navigation_agent.cpp
index 728fc947e9..3da1ea66d6 100644
--- a/scene/3d/navigation_agent.cpp
+++ b/scene/3d/navigation_agent.cpp
@@ -234,6 +234,7 @@ void NavigationAgent::set_target_location(Vector3 p_location) {
navigation_path.clear();
target_reached = false;
navigation_finished = false;
+ update_frame_id = 0;
}
Vector3 NavigationAgent::get_target_location() const {