Merge pull request #10670 from RockyTV/rockytv

Disable 1 human versus bots games
This commit is contained in:
Oliver Brakmann
2016-02-06 15:36:22 +01:00
5 changed files with 22 additions and 10 deletions

View File

@@ -318,7 +318,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic
if (startGameButton != null)
{
startGameButton.IsDisabled = () => configurationDisabled() || Map.RuleStatus != MapRuleStatus.Cached ||
orderManager.LobbyInfo.Slots.Any(sl => sl.Value.Required && orderManager.LobbyInfo.ClientInSlot(sl.Key) == null);
orderManager.LobbyInfo.Slots.Any(sl => sl.Value.Required && orderManager.LobbyInfo.ClientInSlot(sl.Key) == null) ||
(orderManager.LobbyInfo.GlobalSettings.DisableSingleplayer && orderManager.LobbyInfo.IsSinglePlayer);
startGameButton.OnClick = () =>
{
// Bots and admins don't count