I am currently experimenting with Godot 4’s multiplayer nodes, the MultiplayerSpawner and MultiplayerSyncronizer. Currently, I am wondering what is the proper way to remove or free nodes that have been spawned with MultiplayerSyncronizers as children. Right now, my Player scene has two syncronizers, one that the server updates to keep track of position, and then another that clients have authority of to sync their inputs. Now, when I try to remove a player from the tree or free a player on the server, it gives an error. I have ensured that the tree paths are identical on both the server and client sides. The player is removed on the client side as expected, but what is the proper way to avoid this error?
get_node: Node not found
get_cached_object: Failed to get cached path
Is this an error that breaks your game? or “just” a warning, because in the current version of godot there is a bug with the multiplayer deletion and cached references, which is already fixed for godot 4.3. If its not a gamebreaking error, wait for godot 4.3 and see if it still exists
No it’s technically not game breaking, but it does say that it’s an error and not a warning. It’s just one of the errors that doesn’t crash or halt the game. I was just wondering if I was doing something wrong, but if not then that’s good. Thanks!
I ended up making my own custom spawners and synchronizers for the time being as my work around solution. Not perfect, but it works for what I need and I like having the added customizability. Feel free to check it out in case it can be helpful to you: GitHub - Fernanman/CustomMultiplayerNodes: Custom multiplayer nodes for Godot 4.x.