Fix NavigationObstacle3D debug being affected by rotation and scale
Fixes NavigationObstacle3D debug being affected by rotation and scale.
This commit is contained in:
parent
44e399ed5f
commit
cbb9d21fd0
|
@ -148,10 +148,14 @@ void NavigationObstacle3D::_notification(int p_what) {
|
|||
}
|
||||
#ifdef DEBUG_ENABLED
|
||||
if (fake_agent_radius_debug_instance.is_valid() && radius > 0.0) {
|
||||
RS::get_singleton()->instance_set_transform(fake_agent_radius_debug_instance, get_global_transform());
|
||||
Transform3D debug_transform;
|
||||
debug_transform.origin = get_global_position();
|
||||
RS::get_singleton()->instance_set_transform(fake_agent_radius_debug_instance, debug_transform);
|
||||
}
|
||||
if (static_obstacle_debug_instance.is_valid() && get_vertices().size() > 0) {
|
||||
RS::get_singleton()->instance_set_transform(static_obstacle_debug_instance, get_global_transform());
|
||||
Transform3D debug_transform;
|
||||
debug_transform.origin = get_global_position();
|
||||
RS::get_singleton()->instance_set_transform(static_obstacle_debug_instance, debug_transform);
|
||||
}
|
||||
#endif // DEBUG_ENABLED
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue