Node not Found: MultiplayerSynchronizer on client late-joining

Godot Version

Godot 4.6

Question

I have been working on a multiplayer class-based shooter demo for a short bit now, but i’ve been stuck on this single issue for ages. If you host, the client joins and then when you select your character (which spawns the multiplayersynchronizer) it works perfectly with everything synced between all clients. If you choose a character before the other client joins then the host player floats midair and you get these two errors

image

I have looked around at other questions on the forums, but i was unable to find the answer. Any help would be appreciated!

Here is a link to the game files: MultiplayerClassShooterGodot – Google Drive

The player has not spawned yet on this client

This is from the late-join client’s perspective, so the High Level Multiplayer is trying to update a Node it receives information for, but this client, having only joined, has not yet spawned that Node

You need to send the late-join client the info about the status of the game, so that is can spawn players and pickups and whatnot

1 Like

I’m already passing a dictionary to all players that join that tells them all the necessary info for all players (name, id, character) so im unsure of what extra info i need to pass for them to spawn properly

I took a look at your project, you are sending the data, but if a client joins late it never gets it:

I modified map_handler.gd

func _ready():
	if not multiplayer.is_server():
		print("Client GameManager.players = %s" % GameManager.players)
	else:
		print("Server GameManager.players = %s" % GameManager.players)

The result:

In the main menu, you have a signal for the connection, but if the server is not in this scene, then it won’t call peer_connected() which is why you don’t see Player connected 116353488 in the logs.

You need to connect multiplayer.peer_connected in the MapHandler scene too, and use the signal to send the game state to the client; meanwhile, the client should wait to have received the data before changing scene.

So you don’t have the client call startgame() here and you make a new method in your GameManager that will send the data to the new client.

Then, have a signal client-side in the main menu that makes the client call startgame() when the client’s GameManager is updated by the new method you create

1 Like

I think im understanding the issue, but i was wondering if you had knew of some example projects or such that could show me how those are implemented since i can’t seem to figure mine out. Here is what i got so far:

First off i have peer connected in the maphandler that calls the updateclient function on the server.

This is the update client function. So it will go through to the server and grab the servers Gamemanager.players so it can then pass it over to the client. at the end it emits the signal for the client to load the map (which it no longer does on its own). The same issues persist. I also made some changes to the sendplayerinformation script on the “if multiplayer.is_server()” part to make sure all players are sent to all clients

Still, thank you for the help up to this point

1 Like

Adding this in case anyone else has the same issues.

I resolved it by switching to using just RPC calls instead of the built-in multiplayer system.