diff options
Diffstat (limited to 'scene/2d/navigation_agent_2d.cpp')
-rw-r--r-- | scene/2d/navigation_agent_2d.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/scene/2d/navigation_agent_2d.cpp b/scene/2d/navigation_agent_2d.cpp index 32da46e8a8..df23a40721 100644 --- a/scene/2d/navigation_agent_2d.cpp +++ b/scene/2d/navigation_agent_2d.cpp @@ -288,9 +288,12 @@ String NavigationAgent2D::get_configuration_warning() const { void NavigationAgent2D::update_navigation() { - if (agent_parent == nullptr) return; - if (navigation == nullptr) return; - if (update_frame_id == Engine::get_singleton()->get_physics_frames()) return; + if (agent_parent == nullptr) + return; + if (navigation == nullptr) + return; + if (update_frame_id == Engine::get_singleton()->get_physics_frames()) + return; update_frame_id = Engine::get_singleton()->get_physics_frames(); |