Merge pull request #66585 from timothyqiu/navobs-radius

This commit is contained in:
Rémi Verschelde 2022-09-29 09:40:41 +02:00 committed by GitHub
commit 0d388255e6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -216,12 +216,11 @@ real_t NavigationObstacle::estimate_agent_radius() const {
}
Vector3 s = parent_spatial->get_global_transform().basis.get_scale();
radius *= MAX(s.x, MAX(s.y, s.z));
}
if (radius > 0.0) {
return radius;
if (radius > 0.0) {
return radius;
}
}
return 1.0; // Never a 0 radius
}