mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 14:11:15 +00:00
[MP] Fix remote net ID cleanup
Synchronizers for spawned nodes were not correctly keeping track of the
net ID assigned by the remote, preventing the replication from
performing the proper cleanup.
This resulted in errors being thrown when sync messages were received
after despawn (which is possible due to their unreliable nature).
(cherry picked from commit 89dacb88ec)
This commit is contained in:
parent
1dfd92797e
commit
0b03a281e1
2 changed files with 2 additions and 1 deletions
|
|
@ -49,11 +49,11 @@ void MultiplayerSynchronizer::_stop() {
|
|||
}
|
||||
#endif
|
||||
root_node_cache = ObjectID();
|
||||
reset();
|
||||
Node *node = is_inside_tree() ? get_node_or_null(root_path) : nullptr;
|
||||
if (node) {
|
||||
get_multiplayer()->object_configuration_remove(node, this);
|
||||
}
|
||||
reset();
|
||||
}
|
||||
|
||||
void MultiplayerSynchronizer::_start() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue