mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Hide CSGShape's debug_collision_shape when it is invisible
(cherry picked from commit 173e2c7f29)
This commit is contained in:
parent
73b0984764
commit
cf61f5e938
1 changed files with 5 additions and 0 deletions
|
|
@ -573,6 +573,11 @@ void CSGShape3D::_notification(int p_what) {
|
||||||
// Update this node's parent only if its own visibility has changed, not the visibility of parent nodes
|
// Update this node's parent only if its own visibility has changed, not the visibility of parent nodes
|
||||||
parent_shape->_make_dirty();
|
parent_shape->_make_dirty();
|
||||||
}
|
}
|
||||||
|
if (is_visible()) {
|
||||||
|
_update_debug_collision_shape();
|
||||||
|
} else {
|
||||||
|
_clear_debug_collision_shape();
|
||||||
|
}
|
||||||
last_visible = is_visible();
|
last_visible = is_visible();
|
||||||
} break;
|
} break;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue