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

fix bad map id momentarily being sent when hitting panic button in tclient #150

Merged
merged 5 commits into from
Jun 8, 2024

Conversation

ILW8
Copy link
Contributor

@ILW8 ILW8 commented Jun 8, 2024

follow-up to #109

tosu has regressed compared to gosu wherein it still occasionally returns the wrong map ID when certain actions occur on the tournament client (e.g. pressing panic button when gameplay starts and client #0 hasn't loaded in).
A number of tournament overlays update pick/bans using current map ID, and this flip-flopping of map IDs can mess up autopick. Of course, it's fairly trivial to fix this on the overlay side, but a regression is a regression.

ILW8 added 3 commits May 26, 2024 17:17
followup to tosuapp#109

a number of tournament overlays update pick/bans using current map ID. tosu has regressed compared to gosu wherein it still occasionally returns the wrong map ID when certain actions occur on the tournament client (e.g. pressing panic button when gameplay starts and client #0 hasn't loaded in)
@cyperdark
Copy link
Collaborator

can you showcase the issue? video will be cool @ILW8

@ILW8
Copy link
Contributor Author

ILW8 commented Jun 8, 2024

Sure, I'll try to replicate it when another streamer can take a match (probably sunday). It happens infrequently enough that it's hard to reproduce, but frequently enough that it keeps you on the lookout while streaming.

@ILW8
Copy link
Contributor Author

ILW8 commented Jun 8, 2024

Well it just happened, what a coincidence! Unfortunately I don't have a recording of the logs, but you can see on stream that the "picked by" switched from China to United States after hitting the panic button in tclient.
https://www.twitch.tv/videos/2166479543?t=00h10m57s

To illustrate the issue better, assume that the currently picked map is map id 112233. When entering gameplay and then pressing Panic, here's what the ws messages might look like:

  • map id 112233
  • map id 112233
  • map id 112233
  • map id 112233
  • map id 445566
  • map id 445566
  • map id 112233
  • map id 112233
    where 445566 is any arbitrary other map ID.
    When the messages go back and forth between 112233 and 445566, the overlay thinks 112233 got picked again and marks it as picked by the other team.

You can find the overlay code at https://github.com/shdewz/4wc-stream-overlay/blob/main/mappool/index.js. The same map auto-pick flow worked fine for 3WC which used gosumemory

@ILW8 ILW8 force-pushed the fix/tourney-unstable-map-id branch from 4cca66e to fa46c08 Compare June 8, 2024 04:03
@KotRikD KotRikD merged commit 73d3c9d into tosuapp:master Jun 8, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

3 participants