Skip to content

Commit

Permalink
Consider spectators for waiting filter condition
Browse files Browse the repository at this point in the history
  • Loading branch information
kstreser authored and PunkPun committed May 7, 2024
1 parent 8c17455 commit cbcd413
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ Also thanks to:
* Kanar
* Kenny Hoxworth (hoxworth)
* Kevin Azzam (ChaoticMind)
* Kevin Streser
* Krishnakanth Mallik
* Kyle Smith (Smitty)
* Kyrre Soerensen (zypres)
Expand Down
2 changes: 1 addition & 1 deletion OpenRA.Mods.Common/Widgets/Logic/ServerListLogic.cs
Original file line number Diff line number Diff line change
Expand Up @@ -844,7 +844,7 @@ bool Filtered(GameServer game)
if (game.State == (int)ServerState.GameStarted && !filters.HasFlag(MPGameFilters.Started))
return true;

if (game.State == (int)ServerState.WaitingPlayers && !filters.HasFlag(MPGameFilters.Waiting) && game.Players != 0)
if (game.State == (int)ServerState.WaitingPlayers && !filters.HasFlag(MPGameFilters.Waiting) && game.Players + game.Spectators != 0)
return true;

if (game.Players + game.Spectators == 0 && !filters.HasFlag(MPGameFilters.Empty))
Expand Down

0 comments on commit cbcd413

Please sign in to comment.