summaryrefslogtreecommitdiffstats
path: root/scene/3d/navigation_obstacle_3d.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/3d/navigation_obstacle_3d.cpp')
-rw-r--r--scene/3d/navigation_obstacle_3d.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/scene/3d/navigation_obstacle_3d.cpp b/scene/3d/navigation_obstacle_3d.cpp
index 95881b1d5a..98cd5efef2 100644
--- a/scene/3d/navigation_obstacle_3d.cpp
+++ b/scene/3d/navigation_obstacle_3d.cpp
@@ -167,13 +167,11 @@ NavigationObstacle3D::NavigationObstacle3D() {
obstacle = NavigationServer3D::get_singleton()->obstacle_create();
NavigationServer3D::get_singleton()->obstacle_set_height(obstacle, height);
-
- set_radius(radius);
- set_height(height);
- set_vertices(vertices);
- set_avoidance_layers(avoidance_layers);
- set_avoidance_enabled(avoidance_enabled);
- set_use_3d_avoidance(use_3d_avoidance);
+ NavigationServer3D::get_singleton()->obstacle_set_radius(obstacle, radius);
+ NavigationServer3D::get_singleton()->obstacle_set_vertices(obstacle, vertices);
+ NavigationServer3D::get_singleton()->obstacle_set_avoidance_layers(obstacle, avoidance_layers);
+ NavigationServer3D::get_singleton()->obstacle_set_use_3d_avoidance(obstacle, use_3d_avoidance);
+ NavigationServer3D::get_singleton()->obstacle_set_avoidance_enabled(obstacle, avoidance_enabled);
#ifdef DEBUG_ENABLED
NavigationServer3D::get_singleton()->connect("avoidance_debug_changed", callable_mp(this, &NavigationObstacle3D::_update_fake_agent_radius_debug));