From 99b702ea3d12952b842055a4d5d4b1928ed69186 Mon Sep 17 00:00:00 2001 From: George Marques Date: Tue, 30 Apr 2024 11:50:10 -0300 Subject: GDScript: Call implicit ready on base script first It is generally expected that the base class is called before the inherited clas. This commit implements this behavior for the implicit ready function (`@onready` annotation) to make it consistent with the expectations. --- modules/gdscript/gdscript.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'modules/gdscript/gdscript.h') diff --git a/modules/gdscript/gdscript.h b/modules/gdscript/gdscript.h index 7bd68ac0b1..51267ecb84 100644 --- a/modules/gdscript/gdscript.h +++ b/modules/gdscript/gdscript.h @@ -365,6 +365,8 @@ class GDScriptInstance : public ScriptInstance { SelfList::List pending_func_states; + void _call_implicit_ready_recursively(GDScript *p_script); + public: virtual Object *get_owner() { return owner; } -- cgit v1.2.3