Skip to content

スケジュール済みマッチが実行中も返却され、同一マッチが二重起動し得る #45

Description

@nharu-0630

現象

SetMatchEnd はゲーム終了時にしか ScheduledMatches からマッチを除去しない(matchmaking/match_optimizer.go:218-235)。ゲーム実行中も GetMatches は同じマッチを返し続けるため、同じチーム編成のクライアントが再接続すると GetConnectionsWithMatchOptimizer が成立し、同一マッチのゲームが並行して二重起動する。2つ目の SetMatchEnd は「スケジュールされたマッチが見つかりませんでした」を警告して黙って捨てられ、スケジュールの消化数がずれる。

修正案

GetMatches で払い出したマッチに実行中フラグを立て、SetMatchEnd / SetMatchWeight で解除する。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions