You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-17 14:11:06 +00:00
Fix NavigationObstacle not estimating radius
This commit is contained in:
@@ -216,12 +216,11 @@ real_t NavigationObstacle::estimate_agent_radius() const {
|
|||||||
}
|
}
|
||||||
Vector3 s = parent_spatial->get_global_transform().basis.get_scale();
|
Vector3 s = parent_spatial->get_global_transform().basis.get_scale();
|
||||||
radius *= MAX(s.x, MAX(s.y, s.z));
|
radius *= MAX(s.x, MAX(s.y, s.z));
|
||||||
}
|
|
||||||
|
|
||||||
if (radius > 0.0) {
|
if (radius > 0.0) {
|
||||||
return radius;
|
return radius;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return 1.0; // Never a 0 radius
|
return 1.0; // Never a 0 radius
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user