mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
fixes crash on nodes with internal children
This commit is contained in:
parent
fe01776f05
commit
b9bade8db1
1 changed files with 1 additions and 1 deletions
|
|
@ -1823,7 +1823,7 @@ void Node::reparent(Node *p_parent, bool p_keep_global_transform) {
|
||||||
Node *check = to_visit[to_visit.size() - 1];
|
Node *check = to_visit[to_visit.size() - 1];
|
||||||
to_visit.resize(to_visit.size() - 1);
|
to_visit.resize(to_visit.size() - 1);
|
||||||
|
|
||||||
for (int i = 0; i < check->get_child_count(); i++) {
|
for (int i = 0; i < check->get_child_count(false); i++) {
|
||||||
Node *child = check->get_child(i, false);
|
Node *child = check->get_child(i, false);
|
||||||
to_visit.push_back(child);
|
to_visit.push_back(child);
|
||||||
if (child->data.owner == owner_temp) {
|
if (child->data.owner == owner_temp) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue