-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Peer Disconnect Reconnect Replication Issue #89129
Comments
I've made some progress
If I use relative NodePaths over Strings and create a new config the issue goes away. There is one consequence in doing this, the old editor SRC is overwritten. Which makes sense since I'm using a new SRC in its place. |
Using those recommendations above, minus making a new config and using the scene generated one. I think the issue is resolved. I have made version 2 the last thing that keeps happening is every time I add a property to the SRC it throws an error.
Happens once on first connect, twice on second connect |
I did a little more debugging. It seems like the replication_config is cached somewhere for the MultiplayerSynchronizer even if its deleted from the scene tree. I got it down to one error relating to "Condition 'properties.find(p_path)' is true." if I only allowed the server side to add the new parameter when the client first connects. This makes sense if the only the server creates it, I assume it gets replicated in some fashion to the client. Then, if the client disconnects and the syncer is deleted, upon returning when the server creates a new syncer, the added property already exists in the replication config, throwing the error message. This then explains the original issue relating to the old player node path still existing when using an absolute path, after a new client reconnects. The old property still exists with the old absolute path! (I tried switching the order of client server on who added the new property and it seemed the error only happened on whoever was the second actor to add the property. It turns out the client can add the property and determine what is replicated for itself?! 😮) (on second thought, this could be a consequence of two SceneMultiplayer setup on the same tree, my other project had the original issue, but on separate processes, but after updating to a relative path that issue went away and a different issue cropped in that could be unrelated.) |
I have also noticed that the MultiplayerSynchronizer is being cached, and even after it's deleted, errors continue to appear related to a MultiplayerSynchronizer that no longer exists. Additionally, when the MultiplayerSynchronizer was still in place but I removed one of its fields, I kept encountering the same error, likely because it remains cached somewhere. I should be able to debug this issue.
My version that I compiled: v4.4.dev.custom_build [e4e024a] |
Tested versions
System information
Ubuntu 22.04 - Godot 4.2.1
Issue description
If a MultiplayerSynchronizer's SceneReplicationConfig is modified via script and client disconnects and reconnects. Previous multiplayer unique id replication is still cached and throughs errors. Newly connected Clients are no longer replicated.
If replication_config is not touched with script there is no issue.
Steps to reproduce
Peer Connects
Create "player" with MultiplayerSynchronizer
Disconnect player
Reconnect player
Minimal reproduction project (MRP)
client_reconnect_issue.zip
Project has interface to reproduce issue.
Read short instructions watch output.
Example output
The text was updated successfully, but these errors were encountered: