summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2020-08-13 10:21:02 +0200
committerGitHub <noreply@github.com>2020-08-13 10:21:02 +0200
commita9cbbbb6788bf6fa5ea0e7c753a3302f4d638709 (patch)
tree2ca7cd209212c468d582b7c3b0ba4f60a9f635a2
parent3b3d82f40fc5d982ee7243d11ed24858859eb7b1 (diff)
parent677796a2c342ca221918e8dfa8d2361ae78082d1 (diff)
Merge pull request #41203 from KoBeWi/post_mortem_xd
Expose NOTIFICATION_POST_ENTER_TREE
-rw-r--r--doc/classes/Node.xml3
-rw-r--r--scene/main/node.cpp1
2 files changed, 4 insertions, 0 deletions
diff --git a/doc/classes/Node.xml b/doc/classes/Node.xml
index e921cbd58a..8f66c9df38 100644
--- a/doc/classes/Node.xml
+++ b/doc/classes/Node.xml
@@ -918,6 +918,9 @@
<constant name="NOTIFICATION_INTERNAL_PHYSICS_PROCESS" value="26">
Notification received every frame when the internal physics process flag is set (see [method set_physics_process_internal]).
</constant>
+ <constant name="NOTIFICATION_POST_ENTER_TREE" value="27">
+ Notification received when the node is ready, just before [constant NOTIFICATION_READY] is received. Unlike the latter, it's sent every time the node enters tree, instead of only once.
+ </constant>
<constant name="NOTIFICATION_WM_MOUSE_ENTER" value="1002">
Notification received from the OS when the mouse enters the game window.
Implemented on desktop and web platforms.
diff --git a/scene/main/node.cpp b/scene/main/node.cpp
index 4dcfcd9d96..653eb698d4 100644
--- a/scene/main/node.cpp
+++ b/scene/main/node.cpp
@@ -2852,6 +2852,7 @@ void Node::_bind_methods() {
BIND_CONSTANT(NOTIFICATION_PATH_CHANGED);
BIND_CONSTANT(NOTIFICATION_INTERNAL_PROCESS);
BIND_CONSTANT(NOTIFICATION_INTERNAL_PHYSICS_PROCESS);
+ BIND_CONSTANT(NOTIFICATION_POST_ENTER_TREE);
BIND_CONSTANT(NOTIFICATION_WM_MOUSE_ENTER);
BIND_CONSTANT(NOTIFICATION_WM_MOUSE_EXIT);