diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-08-08 08:55:02 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-08 08:55:02 +0200 |
commit | b7127275151f8d5dc09b94d7769f3bc16efb58a1 (patch) | |
tree | d6a6fd77de7d47cf7544238860d2d3e35a693a48 /scene | |
parent | 836fe9adcd94e68c30d6042d1ce5bfabde6b3473 (diff) | |
parent | 8c324132d03d86d2bc243e780db14496b8f10c34 (diff) |
Merge pull request #64068 from DarkKilauea/fix-region-travel-cost
Diffstat (limited to 'scene')
-rw-r--r-- | scene/2d/navigation_region_2d.cpp | 2 | ||||
-rw-r--r-- | scene/3d/navigation_region_3d.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/scene/2d/navigation_region_2d.cpp b/scene/2d/navigation_region_2d.cpp index 6f189a57e8..cdf7c5afa9 100644 --- a/scene/2d/navigation_region_2d.cpp +++ b/scene/2d/navigation_region_2d.cpp @@ -422,7 +422,7 @@ real_t NavigationRegion2D::get_enter_cost() const { void NavigationRegion2D::set_travel_cost(real_t p_travel_cost) { ERR_FAIL_COND_MSG(p_travel_cost < 0.0, "The travel_cost must be positive."); travel_cost = MAX(p_travel_cost, 0.0); - NavigationServer2D::get_singleton()->region_set_enter_cost(region, travel_cost); + NavigationServer2D::get_singleton()->region_set_travel_cost(region, travel_cost); } real_t NavigationRegion2D::get_travel_cost() const { diff --git a/scene/3d/navigation_region_3d.cpp b/scene/3d/navigation_region_3d.cpp index 0abb0e8dea..4150b01651 100644 --- a/scene/3d/navigation_region_3d.cpp +++ b/scene/3d/navigation_region_3d.cpp @@ -119,7 +119,7 @@ real_t NavigationRegion3D::get_enter_cost() const { void NavigationRegion3D::set_travel_cost(real_t p_travel_cost) { ERR_FAIL_COND_MSG(p_travel_cost < 0.0, "The travel_cost must be positive."); travel_cost = MAX(p_travel_cost, 0.0); - NavigationServer3D::get_singleton()->region_set_enter_cost(region, travel_cost); + NavigationServer3D::get_singleton()->region_set_travel_cost(region, travel_cost); } real_t NavigationRegion3D::get_travel_cost() const { |