Which is executed first, the constructor or _ready in C#

Godot Version

4.2 Mono


I didn’t learn c#, I switched from c++ to it for the sake of my thesis. I don’t remember much, but I think the constructor will be executed first to create an object, and then _ready. give me an exact answer, thanks in advance

Afaik, in gdscript (and I would guess C# too):

_init() is run on each node down the tree.
_ready() is run on each node coming back up the tree.

I didn’t quite catch your train of thought. I’m writing test code now, and if all goes well, I’ll close the topic.

The constructor. The Node lifetime is explained in its description.

1 Like