From f8427fa242b3909438295fdee690464be415501a Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Sun, 16 Sep 2012 11:04:03 +1200 Subject: [PATCH] refuse to start the game unless required slots are full. --- OpenRA.Mods.RA/ServerTraits/LobbyCommands.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/OpenRA.Mods.RA/ServerTraits/LobbyCommands.cs b/OpenRA.Mods.RA/ServerTraits/LobbyCommands.cs index 9502065def..efede1ed21 100644 --- a/OpenRA.Mods.RA/ServerTraits/LobbyCommands.cs +++ b/OpenRA.Mods.RA/ServerTraits/LobbyCommands.cs @@ -91,6 +91,12 @@ namespace OpenRA.Mods.RA.Server { "startgame", s => { + if (server.lobbyInfo.Slots.Any(sl => sl.Value.Required && + server.lobbyInfo.ClientInSlot(sl.Key) == null)) + { + server.SendChat(conn, "Unable to start the game until required slots are full."); + return true; + } server.StartGame(); return true; }},