summaryrefslogtreecommitdiff
path: root/scene/main/node.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2016-11-28 15:19:50 +0100
committerGitHub <noreply@github.com>2016-11-28 15:19:50 +0100
commit35e754db593b838524bd1ee1b5e84111b1c38e27 (patch)
tree70d5efc9a98e5d493cc6d119e90009d05bdb74bb /scene/main/node.cpp
parentf28ff8a20888f49cc744d0cc3b8455cfb1cf6874 (diff)
parentb6eab006dbd21d25a664486809109fffa9533124 (diff)
Merge pull request #7138 from bojidar-bg/ready_guard
Do not enter _ready twice
Diffstat (limited to 'scene/main/node.cpp')
-rw-r--r--scene/main/node.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/scene/main/node.cpp b/scene/main/node.cpp
index f4fb48682c..78a5cb7302 100644
--- a/scene/main/node.cpp
+++ b/scene/main/node.cpp
@@ -172,7 +172,10 @@ void Node::_propagate_ready() {
data.children[i]->_propagate_ready();
}
data.blocked--;
- notification(NOTIFICATION_READY);
+ if(!data.ready_notified) {
+ data.ready_notified=true;
+ notification(NOTIFICATION_READY);
+ }
}
@@ -2999,6 +3002,7 @@ Node::Node() {
data.fixed_process=false;
data.idle_process=false;
data.inside_tree=false;
+ data.ready_notified=false;
data.owner=NULL;
data.OW=NULL;