summaryrefslogtreecommitdiff
path: root/modules/navigation
diff options
context:
space:
mode:
authorMicky <micheledevita2@gmail.com>2022-08-13 12:26:13 +0200
committerMicky <micheledevita2@gmail.com>2022-08-13 12:40:55 +0200
commitb62d06fbeddfd7e584587d1a86f69ed09dff65e6 (patch)
tree1702c3826ee2bc08796ac4d406afa86e9930e36d /modules/navigation
parentf2a61684143af02a8cbe7002645af817607f9bd6 (diff)
Rename Navigation's `neighbor_dist` to `neightbor_distance`
NavigationAgent2D/3D.`neighbor_dist` -> `neighbor_distance` (also affects setters and getters) NavigationServer2D/3D.`agent_set_neighbor_dist()` -> `agent_set_neighbor_distance()` Also changes their parameters' names. Doesn't affect "Agent.neighborDist_" in Agent.h
Diffstat (limited to 'modules/navigation')
-rw-r--r--modules/navigation/godot_navigation_server.cpp4
-rw-r--r--modules/navigation/godot_navigation_server.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/modules/navigation/godot_navigation_server.cpp b/modules/navigation/godot_navigation_server.cpp
index 2cdb5b7cb4..8cd53161d7 100644
--- a/modules/navigation/godot_navigation_server.cpp
+++ b/modules/navigation/godot_navigation_server.cpp
@@ -453,11 +453,11 @@ COMMAND_2(agent_set_map, RID, p_agent, RID, p_map) {
}
}
-COMMAND_2(agent_set_neighbor_dist, RID, p_agent, real_t, p_dist) {
+COMMAND_2(agent_set_neighbor_distance, RID, p_agent, real_t, p_distance) {
RvoAgent *agent = agent_owner.get_or_null(p_agent);
ERR_FAIL_COND(agent == nullptr);
- agent->get_agent()->neighborDist_ = p_dist;
+ agent->get_agent()->neighborDist_ = p_distance;
}
COMMAND_2(agent_set_max_neighbors, RID, p_agent, int, p_count) {
diff --git a/modules/navigation/godot_navigation_server.h b/modules/navigation/godot_navigation_server.h
index da1f8cba0b..aab225f8f8 100644
--- a/modules/navigation/godot_navigation_server.h
+++ b/modules/navigation/godot_navigation_server.h
@@ -135,7 +135,7 @@ public:
virtual RID agent_create() const override;
COMMAND_2(agent_set_map, RID, p_agent, RID, p_map);
virtual RID agent_get_map(RID p_agent) const override;
- COMMAND_2(agent_set_neighbor_dist, RID, p_agent, real_t, p_dist);
+ COMMAND_2(agent_set_neighbor_distance, RID, p_agent, real_t, p_distance);
COMMAND_2(agent_set_max_neighbors, RID, p_agent, int, p_count);
COMMAND_2(agent_set_time_horizon, RID, p_agent, real_t, p_time);
COMMAND_2(agent_set_radius, RID, p_agent, real_t, p_radius);