Skip to content
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

PlayFabMultiplayerManager.LeaveNetwork is broken #34

Open
angebrajuka opened this issue May 31, 2023 · 7 comments
Open

PlayFabMultiplayerManager.LeaveNetwork is broken #34

angebrajuka opened this issue May 31, 2023 · 7 comments

Comments

@angebrajuka
Copy link

After leaving a network with other players still in the network, the OnNetworkLeft callback isn't called and the manager enters a broken state in which it can't host or join another network.

@nassosterz-ms
Copy link
Contributor

Thank you for reporting this.

I just tried reproducing this and cannot observe this behavior. Could you give more information about the version of the PlayFab Party Unity plugin you are using? Also, what platform.

You can inspect this part of the code: PARTY_STATE_CHANGE_TYPE.PARTY_STATE_CHANGE_TYPE_LEAVE_NETWORK_COMPLETED of PlayFabMultiplayerManager.cs.

I see with a debugger that I am hitting this state change and that OnNetworkLeft is called. Subsequently, I try to rejoin the network with success.

@angebrajuka
Copy link
Author

I'm using PlayFab Party version 1.7.6.0-main.0 and I am on Windows 10.
It only happens when there are multiple people in a network and a player leaves, that player not getting an OnNetworkLeft callback.

@nassosterz-ms
Copy link
Contributor

nassosterz-ms commented May 31, 2023

Could you attach a debugger and see if you are hitting the state change I mentioned above? You can attach a debugger using either Visual Studio or Visual Studio Code.

@angebrajuka
Copy link
Author

After a little more digging it seems like enabling "Run In Background" in the Player settings fixes the issue, perhaps it has something to do with my setup. I don't get the state change when Run In Background is off but I do get it when it's on. strange.

@nassosterz-ms
Copy link
Contributor

Checked that our sample application had "Run In Background" enabled. Tried disabling it to see if this could be reproduced but no luck - specifically, in a network with multiple clients, the one that calls Leave Network is able to rejoin the network.

Also seeing with the debugger that PARTY_STATE_CHANGE_TYPE.PARTY_STATE_CHANGE_TYPE_LEAVE_NETWORK_COMPLETED is called.

Trying to think if there is any way we could help here.

@nassosterz-ms
Copy link
Contributor

Is there any update?

@angebrajuka
Copy link
Author

I think this thread can be closed, it seems like a very specific set of circumstances to cause the error (potentially error on my part) and I was able to fix it in my case by enabling run in background

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants