Skip to content

Commit

Permalink
Merge pull request #58650 from lawnjelly/portals_fix_prefix_duplication
Browse files Browse the repository at this point in the history
Portals - fix duplication of instanced scenes during conversion
  • Loading branch information
akien-mga authored Mar 1, 2022
2 parents 29d78f2 + 4ec4b5a commit 195b737
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scene/3d/room_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2073,9 +2073,10 @@ void RoomManager::_flip_portals_recursive(Spatial *p_node) {
}

void RoomManager::_set_owner_recursive(Node *p_node, Node *p_owner) {
if (p_node != p_owner) {
if (!p_node->get_owner() && (p_node != p_owner)) {
p_node->set_owner(p_owner);
}

for (int n = 0; n < p_node->get_child_count(); n++) {
_set_owner_recursive(p_node->get_child(n), p_owner);
}
Expand Down

0 comments on commit 195b737

Please sign in to comment.