My remote scene tree is missing nodes

Godot Version

.NET v4.2.1

Context

I’m currently working on my first project in Godot to learn the basics of the engine.
I’m running into a lot of things that I don’t understand, but this error in particular throws me off.

I have a basic Node3D-scene which contains a collection of boxes and pipes; objects that the player uses to reach the end of the level.

A couple of the last boxes I have placed (on the left) do not appear as part of the remote scene when running the scene i.e. the player cannot see or collide with the object as it does not exist in the scene at runtime.

Question

Why are these nodes (Platform, Platform2) not part of the scene when I run the game?

Anything in your scripts (especially the one attached to 04Level) that might remove those nodes? Try setting a breakpoint (by clicking left of a line number: you should see a red dot indicating the breakpoint, clicking once more will remove it again), e.g. at the beginning of your _ready or _init function, and run your game. It should immediately pause, giving you time to inspect the remote tree and figure out if the nodes are still in the tree at that point.

I doubt that any script is the root cause of this issue. None of the scripts remove anything from the scene tree, only adds (e.g. instantiating player, instantiating camera). The LevelManager-script, which is on 04Level, only reloads the scene if requested using a static function that calls Instance.GetTree().ReloadCurrentScene();.

It’s probably relevant to mention that the Mesh Instances present inside the Platform and Platform2 Static Area 3Ds will be visible in the remote scene if they are not children of those Static Areas.

Is there a weird interaction between Mesh Instance and Static Area here?

Update

I am still unable to resolve this issue. I am gaining no progress.

I checked the scene file for any errors regarding sub-resources or parenting issues, but as far as I know the scene is unable to load if errors exist within the scene file.
This issue doesn’t make sense to me. I’ve used Unity for ~7 years and have never run into issues like this.

If there are any interested readers, who wants to dig a little deeper with me, I made the GitHub repo public here.

xD
your platform is in water, you can change collision layer masks or check if collider is a player


First what i noticed object entered tree and exited with short GD.Print(“msg”);

obraz

2 Likes

Wow. I feel dumb now. Argh!
Thanks for finding the error.

1 Like