kinnay/SMB35

Spectating doesn't work, all players except the last two get Error 2306-0103 upon death

just-another-random-person opened this issue · 3 comments

So we've managed to get a few friends set up their Switch to connect to our own hosted private server, and we finally had around 3-5 players a lot of the time.

We were wondering why almost everyone except the final two players would always immediately get an Error 2306-0103 upon death.

So it seems spectating is broken, anyone who would end up in spectate mode instead gets that error.

One of them suggested it might be because of the game trying to submit coin rankings to the (non-existent) coin leaderboard. But I decided to check the logs and it was:
WARNING:nintendo.nex.matchmaking_eagle:MatchmakeRefereeServer.end_round_with_partial_report not implemented
Screen Shot 2021-05-30 at 3 59 05 PM

Is there a quick way we can fix it so spectating works (if the issue is the coin leaderboard thing as they guessed)?
We plan to implement coin leaderboards eventually (even via something simple like SQLite), but for now, we hope to get spectating working at least since that's most of the fun of the game.

Also, when someone gets the error, the server just keeps spamming stacktraces (ClosedResourceError) in the log until the game ends (not sure if this is helpful):

Screen Shot 2021-05-30 at 4 00 12 PM

Thanks for any help, and also thanks so much for writing the server code!
It's amazing!

Fixed by implementing missing method

Screen Shot 2021-05-30 at 5 45 51 PM

Spectating works now.

I can do a pull request once I figure out how Git works, haven't fully used it before.

Cool! I never tested it with more than two players myself 😄

A pull request would be nice. If you can't figure it out just let me know and I'll add the missing method myself.

I was a bit lazy about error handling. Currently, the server ignores exceptions that occur when the server tries to relay an RPC packet to a node. See this line. That's why you are seeing the ClosedResourceError spam. We should probably remove the node instead.

P.S. Here's a list of error codes. Might be helpful if you ever get stuck on an error.

Removing the node might fix the other issue I just submitted, issue #6.