diff options
Diffstat (limited to 'modules/navigation')
-rw-r--r-- | modules/navigation/godot_navigation_server.cpp | 12 | ||||
-rw-r--r-- | modules/navigation/godot_navigation_server.h | 6 |
2 files changed, 9 insertions, 9 deletions
diff --git a/modules/navigation/godot_navigation_server.cpp b/modules/navigation/godot_navigation_server.cpp index 2cdb5b7cb4..6bb522cc01 100644 --- a/modules/navigation/godot_navigation_server.cpp +++ b/modules/navigation/godot_navigation_server.cpp @@ -123,8 +123,8 @@ void GodotNavigationServer::add_command(SetCommand *command) const { } } -Array GodotNavigationServer::get_maps() const { - Array all_map_rids; +TypedArray<RID> GodotNavigationServer::get_maps() const { + TypedArray<RID> all_map_rids; List<RID> maps_owned; map_owner.get_owned_list(&maps_owned); if (maps_owned.size()) { @@ -245,8 +245,8 @@ RID GodotNavigationServer::map_get_closest_point_owner(RID p_map, const Vector3 return map->get_closest_point_owner(p_point); } -Array GodotNavigationServer::map_get_regions(RID p_map) const { - Array regions_rids; +TypedArray<RID> GodotNavigationServer::map_get_regions(RID p_map) const { + TypedArray<RID> regions_rids; const NavMap *map = map_owner.get_or_null(p_map); ERR_FAIL_COND_V(map == nullptr, regions_rids); const LocalVector<NavRegion *> regions = map->get_regions(); @@ -257,8 +257,8 @@ Array GodotNavigationServer::map_get_regions(RID p_map) const { return regions_rids; } -Array GodotNavigationServer::map_get_agents(RID p_map) const { - Array agents_rids; +TypedArray<RID> GodotNavigationServer::map_get_agents(RID p_map) const { + TypedArray<RID> agents_rids; const NavMap *map = map_owner.get_or_null(p_map); ERR_FAIL_COND_V(map == nullptr, agents_rids); const LocalVector<RvoAgent *> agents = map->get_agents(); diff --git a/modules/navigation/godot_navigation_server.h b/modules/navigation/godot_navigation_server.h index da1f8cba0b..e5f4b421bc 100644 --- a/modules/navigation/godot_navigation_server.h +++ b/modules/navigation/godot_navigation_server.h @@ -85,7 +85,7 @@ public: void add_command(SetCommand *command) const; - virtual Array get_maps() const override; + virtual TypedArray<RID> get_maps() const override; virtual RID map_create() const override; COMMAND_2(map_set_active, RID, p_map, bool, p_active); @@ -107,8 +107,8 @@ public: virtual Vector3 map_get_closest_point_normal(RID p_map, const Vector3 &p_point) const override; virtual RID map_get_closest_point_owner(RID p_map, const Vector3 &p_point) const override; - virtual Array map_get_regions(RID p_map) const override; - virtual Array map_get_agents(RID p_map) const override; + virtual TypedArray<RID> map_get_regions(RID p_map) const override; + virtual TypedArray<RID> map_get_agents(RID p_map) const override; virtual void map_force_update(RID p_map) override; |