-
Notifications
You must be signed in to change notification settings - Fork 447
fix: host not generating its own local client disconnect notification #2822
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
fix: host not generating its own local client disconnect notification #2822
Conversation
} | ||
m_ServerNetworkManager.OnClientDisconnectCallback += firstCallback; | ||
m_ClientsDisconnected.Clear(); | ||
m_ServerNetworkManager.OnClientDisconnectCallback += OnClientDisconnected; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you also add a check for this behavior in OnConnectionEvent
? InvokeOnClientDisconnectCallback
should invoke both of them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also discovered an issue with StopOneClient while adding the test... so it was a 2 4 1.
Validated the ConnectionEvent.ClientDisconnected triggers under both scenarios and fixed the integration test method.
👍
Adding check for ConnectionEvent.ClientDisconnected for both test types. Fixing issue with StopOneClient destroying the NetworkManager when destroy is set to false.
This fix assures a host will invoke
OnClientDisconnectCallback
for its local client when it is internally shutting down.fix: #2789
Changelog
OnClientDisconnectCallback
for its own local client when internally shutting down.Testing and Documentation