Add a 'Shutting down' state to the gameserver.

Tell the masterserver about it, so it can quickly remove games
from the list when they are finished, rather than waiting for the
5 minute TTL to expire.
This commit is contained in:
Sam Hegarty
2012-11-22 20:04:27 +13:00
committed by Chris Forbes
parent 3a77082c66
commit 0c104cfc3a
5 changed files with 48 additions and 20 deletions

View File

@@ -39,7 +39,7 @@ namespace OpenRA.Mods.RA.Server
public static bool ValidateCommand(S server, Connection conn, Session.Client client, string cmd)
{
if (server.GameStarted)
if (server.State == ServerState.GameStarted)
{
server.SendChatTo(conn, "Cannot change state when game started. ({0})".F(cmd));
return false;