Move hardcoded list of lobby options into yaml.
This commit is contained in:
@@ -836,6 +836,7 @@
|
|||||||
<Compile Include="Widgets\Logic\Ingame\Hotkeys\PauseHotkeyLogic.cs" />
|
<Compile Include="Widgets\Logic\Ingame\Hotkeys\PauseHotkeyLogic.cs" />
|
||||||
<Compile Include="Widgets\Logic\Ingame\Hotkeys\CycleStatusBarsHotkeyLogic.cs" />
|
<Compile Include="Widgets\Logic\Ingame\Hotkeys\CycleStatusBarsHotkeyLogic.cs" />
|
||||||
<Compile Include="Lint\CheckConflictingMouseBounds.cs" />
|
<Compile Include="Lint\CheckConflictingMouseBounds.cs" />
|
||||||
|
<Compile Include="Widgets\Logic\Lobby\LobbyOptionsLogic.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<Target Name="AfterBuild">
|
<Target Name="AfterBuild">
|
||||||
|
|||||||
@@ -285,7 +285,13 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
var optionsBin = Ui.LoadWidget("LOBBY_OPTIONS_BIN", lobby.Get("TOP_PANELS_ROOT"), new WidgetArgs());
|
var optionsBin = Ui.LoadWidget("LOBBY_OPTIONS_BIN", lobby.Get("TOP_PANELS_ROOT"), new WidgetArgs()
|
||||||
|
{
|
||||||
|
{ "orderManager", orderManager },
|
||||||
|
{ "getMap", (Func<MapPreview>)(() => map) },
|
||||||
|
{ "configurationDisabled", configurationDisabled }
|
||||||
|
});
|
||||||
|
|
||||||
optionsBin.IsVisible = () => panel == PanelType.Options;
|
optionsBin.IsVisible = () => panel == PanelType.Options;
|
||||||
|
|
||||||
var musicBin = Ui.LoadWidget("LOBBY_MUSIC_BIN", lobby.Get("TOP_PANELS_ROOT"), new WidgetArgs
|
var musicBin = Ui.LoadWidget("LOBBY_MUSIC_BIN", lobby.Get("TOP_PANELS_ROOT"), new WidgetArgs
|
||||||
@@ -297,8 +303,9 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
|
|
||||||
var optionsTab = lobby.Get<ButtonWidget>("OPTIONS_TAB");
|
var optionsTab = lobby.Get<ButtonWidget>("OPTIONS_TAB");
|
||||||
optionsTab.IsHighlighted = () => panel == PanelType.Options;
|
optionsTab.IsHighlighted = () => panel == PanelType.Options;
|
||||||
optionsTab.IsDisabled = () => !map.RulesLoaded || map.InvalidCustomRules || panel == PanelType.Kick || panel == PanelType.ForceStart;
|
optionsTab.IsDisabled = OptionsTabDisabled;
|
||||||
optionsTab.OnClick = () => panel = PanelType.Options;
|
optionsTab.OnClick = () => panel = PanelType.Options;
|
||||||
|
optionsTab.GetText = () => !map.RulesLoaded ? "Loading..." : optionsTab.Text;
|
||||||
|
|
||||||
var playersTab = lobby.Get<ButtonWidget>("PLAYERS_TAB");
|
var playersTab = lobby.Get<ButtonWidget>("PLAYERS_TAB");
|
||||||
playersTab.IsHighlighted = () => panel == PanelType.Players;
|
playersTab.IsHighlighted = () => panel == PanelType.Players;
|
||||||
@@ -340,101 +347,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
forceStartBin.Get<ButtonWidget>("OK_BUTTON").OnClick = startGame;
|
forceStartBin.Get<ButtonWidget>("OK_BUTTON").OnClick = startGame;
|
||||||
forceStartBin.Get<ButtonWidget>("CANCEL_BUTTON").OnClick = () => panel = PanelType.Players;
|
forceStartBin.Get<ButtonWidget>("CANCEL_BUTTON").OnClick = () => panel = PanelType.Players;
|
||||||
|
|
||||||
// Options panel
|
|
||||||
var optionCheckboxes = new Dictionary<string, string>()
|
|
||||||
{
|
|
||||||
{ "EXPLORED_MAP_CHECKBOX", "explored" },
|
|
||||||
{ "CRATES_CHECKBOX", "crates" },
|
|
||||||
{ "SHORTGAME_CHECKBOX", "shortgame" },
|
|
||||||
{ "FOG_CHECKBOX", "fog" },
|
|
||||||
{ "ALLYBUILDRADIUS_CHECKBOX", "allybuild" },
|
|
||||||
{ "ALLOWCHEATS_CHECKBOX", "cheats" },
|
|
||||||
{ "CREEPS_CHECKBOX", "creeps" },
|
|
||||||
{ "BUILDRADIUS_CHECKBOX", "buildradius" },
|
|
||||||
};
|
|
||||||
|
|
||||||
foreach (var kv in optionCheckboxes)
|
|
||||||
{
|
|
||||||
var checkbox = optionsBin.GetOrNull<CheckboxWidget>(kv.Key);
|
|
||||||
if (checkbox != null)
|
|
||||||
{
|
|
||||||
var option = new CachedTransform<Session.Global, Session.LobbyOptionState>(
|
|
||||||
gs => gs.LobbyOptions[kv.Value]);
|
|
||||||
|
|
||||||
var visible = new CachedTransform<Session.Global, bool>(
|
|
||||||
gs => gs.LobbyOptions.ContainsKey(kv.Value));
|
|
||||||
|
|
||||||
checkbox.IsVisible = () => visible.Update(orderManager.LobbyInfo.GlobalSettings);
|
|
||||||
checkbox.IsChecked = () => option.Update(orderManager.LobbyInfo.GlobalSettings).Enabled;
|
|
||||||
checkbox.IsDisabled = () => configurationDisabled() ||
|
|
||||||
option.Update(orderManager.LobbyInfo.GlobalSettings).Locked;
|
|
||||||
checkbox.OnClick = () => orderManager.IssueOrder(Order.Command(
|
|
||||||
"option {0} {1}".F(kv.Value, !option.Update(orderManager.LobbyInfo.GlobalSettings).Enabled)));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var optionDropdowns = new Dictionary<string, string>()
|
|
||||||
{
|
|
||||||
{ "TECHLEVEL", "techlevel" },
|
|
||||||
{ "STARTINGUNITS", "startingunits" },
|
|
||||||
{ "STARTINGCASH", "startingcash" },
|
|
||||||
{ "DIFFICULTY", "difficulty" },
|
|
||||||
{ "GAMESPEED", "gamespeed" }
|
|
||||||
};
|
|
||||||
|
|
||||||
var allOptions = new CachedTransform<MapPreview, LobbyOption[]>(
|
|
||||||
mapPreview => mapPreview.Rules.Actors["player"].TraitInfos<ILobbyOptions>()
|
|
||||||
.Concat(mapPreview.Rules.Actors["world"].TraitInfos<ILobbyOptions>())
|
|
||||||
.SelectMany(t => t.LobbyOptions(mapPreview.Rules))
|
|
||||||
.ToArray());
|
|
||||||
|
|
||||||
foreach (var kv in optionDropdowns)
|
|
||||||
{
|
|
||||||
var dropdown = optionsBin.GetOrNull<DropDownButtonWidget>(kv.Key + "_DROPDOWNBUTTON");
|
|
||||||
if (dropdown != null)
|
|
||||||
{
|
|
||||||
var optionValue = new CachedTransform<Session.Global, Session.LobbyOptionState>(
|
|
||||||
gs => gs.LobbyOptions[kv.Value]);
|
|
||||||
|
|
||||||
var option = new CachedTransform<MapPreview, LobbyOption>(
|
|
||||||
mapPreview => allOptions.Update(mapPreview).FirstOrDefault(o => o.Id == kv.Value));
|
|
||||||
|
|
||||||
var getOptionLabel = new CachedTransform<string, string>(id =>
|
|
||||||
{
|
|
||||||
string value;
|
|
||||||
if (id == null || !option.Update(map).Values.TryGetValue(id, out value))
|
|
||||||
return "Not Available";
|
|
||||||
|
|
||||||
return value;
|
|
||||||
});
|
|
||||||
|
|
||||||
dropdown.GetText = () => getOptionLabel.Update(optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Value);
|
|
||||||
dropdown.IsVisible = () => option.Update(map) != null;
|
|
||||||
dropdown.IsDisabled = () => configurationDisabled() ||
|
|
||||||
optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Locked;
|
|
||||||
|
|
||||||
dropdown.OnMouseDown = _ =>
|
|
||||||
{
|
|
||||||
Func<KeyValuePair<string, string>, ScrollItemWidget, ScrollItemWidget> setupItem = (c, template) =>
|
|
||||||
{
|
|
||||||
Func<bool> isSelected = () => optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Value == c.Key;
|
|
||||||
Action onClick = () => orderManager.IssueOrder(Order.Command("option {0} {1}".F(kv.Value, c.Key)));
|
|
||||||
|
|
||||||
var item = ScrollItemWidget.Setup(template, isSelected, onClick);
|
|
||||||
item.Get<LabelWidget>("LABEL").GetText = () => c.Value;
|
|
||||||
return item;
|
|
||||||
};
|
|
||||||
|
|
||||||
var options = option.Update(map).Values;
|
|
||||||
dropdown.ShowDropDown("LABEL_DROPDOWN_TEMPLATE", options.Count() * 30, options, setupItem);
|
|
||||||
};
|
|
||||||
|
|
||||||
var label = optionsBin.GetOrNull(kv.Key + "_DESC");
|
|
||||||
if (label != null)
|
|
||||||
label.IsVisible = () => option.Update(map) != null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var disconnectButton = lobby.Get<ButtonWidget>("DISCONNECT_BUTTON");
|
var disconnectButton = lobby.Get<ButtonWidget>("DISCONNECT_BUTTON");
|
||||||
disconnectButton.OnClick = () => { Ui.CloseWindow(); onExit(); };
|
disconnectButton.OnClick = () => { Ui.CloseWindow(); onExit(); };
|
||||||
|
|
||||||
@@ -552,8 +464,16 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
base.Dispose(disposing);
|
base.Dispose(disposing);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool OptionsTabDisabled()
|
||||||
|
{
|
||||||
|
return !map.RulesLoaded || map.InvalidCustomRules || panel == PanelType.Kick || panel == PanelType.ForceStart;
|
||||||
|
}
|
||||||
|
|
||||||
public override void Tick()
|
public override void Tick()
|
||||||
{
|
{
|
||||||
|
if (panel == PanelType.Options && OptionsTabDisabled())
|
||||||
|
panel = PanelType.Players;
|
||||||
|
|
||||||
var newMessages = Game.GlobalChat.History.Count(m => m.Type == ChatMessageType.Message);
|
var newMessages = Game.GlobalChat.History.Count(m => m.Type == ChatMessageType.Message);
|
||||||
globalChatUnreadMessages += newMessages - globalChatLastReadMessages;
|
globalChatUnreadMessages += newMessages - globalChatLastReadMessages;
|
||||||
globalChatLastReadMessages = newMessages;
|
globalChatLastReadMessages = newMessages;
|
||||||
|
|||||||
179
OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs
Normal file
179
OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs
Normal file
@@ -0,0 +1,179 @@
|
|||||||
|
#region Copyright & License Information
|
||||||
|
/*
|
||||||
|
* Copyright 2007-2017 The OpenRA Developers (see AUTHORS)
|
||||||
|
* This file is part of OpenRA, which is free software. It is made
|
||||||
|
* available to you under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation, either version 3 of
|
||||||
|
* the License, or (at your option) any later version. For more
|
||||||
|
* information, see COPYING.
|
||||||
|
*/
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using OpenRA.Network;
|
||||||
|
using OpenRA.Traits;
|
||||||
|
using OpenRA.Widgets;
|
||||||
|
|
||||||
|
namespace OpenRA.Mods.Common.Widgets.Logic
|
||||||
|
{
|
||||||
|
public class LobbyOptionsLogic : ChromeLogic
|
||||||
|
{
|
||||||
|
readonly ScrollPanelWidget panel;
|
||||||
|
readonly Widget optionsContainer;
|
||||||
|
readonly Widget checkboxRowTemplate;
|
||||||
|
readonly Widget dropdownRowTemplate;
|
||||||
|
|
||||||
|
readonly Func<MapPreview> getMap;
|
||||||
|
readonly OrderManager orderManager;
|
||||||
|
readonly Func<bool> configurationDisabled;
|
||||||
|
MapPreview mapPreview;
|
||||||
|
bool validOptions;
|
||||||
|
|
||||||
|
[ObjectCreator.UseCtor]
|
||||||
|
internal LobbyOptionsLogic(Widget widget, OrderManager orderManager, Func<MapPreview> getMap, Func<bool> configurationDisabled)
|
||||||
|
{
|
||||||
|
this.getMap = getMap;
|
||||||
|
this.orderManager = orderManager;
|
||||||
|
this.configurationDisabled = configurationDisabled;
|
||||||
|
|
||||||
|
panel = (ScrollPanelWidget)widget;
|
||||||
|
optionsContainer = widget.Get("LOBBY_OPTIONS");
|
||||||
|
optionsContainer.IsVisible = () => validOptions;
|
||||||
|
checkboxRowTemplate = optionsContainer.Get("CHECKBOX_ROW_TEMPLATE");
|
||||||
|
dropdownRowTemplate = optionsContainer.Get("DROPDOWN_ROW_TEMPLATE");
|
||||||
|
|
||||||
|
mapPreview = getMap();
|
||||||
|
RebuildOptions();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Tick()
|
||||||
|
{
|
||||||
|
var newMapPreview = getMap();
|
||||||
|
if (newMapPreview == mapPreview)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (newMapPreview.RulesLoaded)
|
||||||
|
{
|
||||||
|
// We are currently enumerating the widget tree and so can't modify any layout
|
||||||
|
// Defer it to the end of tick instead
|
||||||
|
Game.RunAfterTick(() =>
|
||||||
|
{
|
||||||
|
mapPreview = newMapPreview;
|
||||||
|
RebuildOptions();
|
||||||
|
validOptions = true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else
|
||||||
|
validOptions = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RebuildOptions()
|
||||||
|
{
|
||||||
|
if (mapPreview == null || mapPreview.Rules == null || mapPreview.InvalidCustomRules)
|
||||||
|
return;
|
||||||
|
|
||||||
|
optionsContainer.RemoveChildren();
|
||||||
|
optionsContainer.Bounds.Height = 0;
|
||||||
|
var allOptions = mapPreview.Rules.Actors["player"].TraitInfos<ILobbyOptions>()
|
||||||
|
.Concat(mapPreview.Rules.Actors["world"].TraitInfos<ILobbyOptions>())
|
||||||
|
.SelectMany(t => t.LobbyOptions(mapPreview.Rules))
|
||||||
|
.Where(o => o.Visible)
|
||||||
|
.OrderBy(o => o.DisplayOrder)
|
||||||
|
.ToArray();
|
||||||
|
|
||||||
|
Widget row = null;
|
||||||
|
var checkboxColumns = new Queue<CheckboxWidget>();
|
||||||
|
var dropdownColumns = new Queue<DropDownButtonWidget>();
|
||||||
|
|
||||||
|
foreach (var option in allOptions.Where(o => o is LobbyBooleanOption))
|
||||||
|
{
|
||||||
|
if (!checkboxColumns.Any())
|
||||||
|
{
|
||||||
|
row = checkboxRowTemplate.Clone();
|
||||||
|
row.Bounds.Y = optionsContainer.Bounds.Height;
|
||||||
|
optionsContainer.Bounds.Height += row.Bounds.Height;
|
||||||
|
foreach (var child in row.Children)
|
||||||
|
if (child is CheckboxWidget)
|
||||||
|
checkboxColumns.Enqueue((CheckboxWidget)child);
|
||||||
|
|
||||||
|
optionsContainer.AddChild(row);
|
||||||
|
}
|
||||||
|
|
||||||
|
var checkbox = checkboxColumns.Dequeue();
|
||||||
|
var optionValue = new CachedTransform<Session.Global, Session.LobbyOptionState>(
|
||||||
|
gs => gs.LobbyOptions[option.Id]);
|
||||||
|
|
||||||
|
checkbox.GetText = () => option.Name;
|
||||||
|
if (option.Description != null)
|
||||||
|
checkbox.GetTooltipText = () => option.Description;
|
||||||
|
|
||||||
|
checkbox.IsVisible = () => true;
|
||||||
|
checkbox.IsChecked = () => optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Enabled;
|
||||||
|
checkbox.IsDisabled = () => configurationDisabled() || optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Locked;
|
||||||
|
checkbox.OnClick = () => orderManager.IssueOrder(Order.Command(
|
||||||
|
"option {0} {1}".F(option.Id, !optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Enabled)));
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (var option in allOptions.Where(o => !(o is LobbyBooleanOption)))
|
||||||
|
{
|
||||||
|
if (!dropdownColumns.Any())
|
||||||
|
{
|
||||||
|
row = dropdownRowTemplate.Clone() as Widget;
|
||||||
|
row.Bounds.Y = optionsContainer.Bounds.Height;
|
||||||
|
optionsContainer.Bounds.Height += row.Bounds.Height;
|
||||||
|
foreach (var child in row.Children)
|
||||||
|
if (child is DropDownButtonWidget)
|
||||||
|
dropdownColumns.Enqueue((DropDownButtonWidget)child);
|
||||||
|
|
||||||
|
optionsContainer.AddChild(row);
|
||||||
|
}
|
||||||
|
|
||||||
|
var dropdown = dropdownColumns.Dequeue();
|
||||||
|
var optionValue = new CachedTransform<Session.Global, Session.LobbyOptionState>(
|
||||||
|
gs => gs.LobbyOptions[option.Id]);
|
||||||
|
|
||||||
|
var getOptionLabel = new CachedTransform<string, string>(id =>
|
||||||
|
{
|
||||||
|
string value;
|
||||||
|
if (id == null || !option.Values.TryGetValue(id, out value))
|
||||||
|
return "Not Available";
|
||||||
|
|
||||||
|
return value;
|
||||||
|
});
|
||||||
|
|
||||||
|
dropdown.GetText = () => getOptionLabel.Update(optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Value);
|
||||||
|
if (option.Description != null)
|
||||||
|
dropdown.GetTooltipText = () => option.Description;
|
||||||
|
dropdown.IsVisible = () => true;
|
||||||
|
dropdown.IsDisabled = () => configurationDisabled() ||
|
||||||
|
optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Locked;
|
||||||
|
|
||||||
|
dropdown.OnMouseDown = _ =>
|
||||||
|
{
|
||||||
|
Func<KeyValuePair<string, string>, ScrollItemWidget, ScrollItemWidget> setupItem = (c, template) =>
|
||||||
|
{
|
||||||
|
Func<bool> isSelected = () => optionValue.Update(orderManager.LobbyInfo.GlobalSettings).Value == c.Key;
|
||||||
|
Action onClick = () => orderManager.IssueOrder(Order.Command("option {0} {1}".F(option.Id, c.Key)));
|
||||||
|
|
||||||
|
var item = ScrollItemWidget.Setup(template, isSelected, onClick);
|
||||||
|
item.Get<LabelWidget>("LABEL").GetText = () => c.Value;
|
||||||
|
return item;
|
||||||
|
};
|
||||||
|
|
||||||
|
dropdown.ShowDropDown("LABEL_DROPDOWN_TEMPLATE", option.Values.Count() * 30, option.Values, setupItem);
|
||||||
|
};
|
||||||
|
|
||||||
|
var label = row.GetOrNull<LabelWidget>(dropdown.Id + "_DESC");
|
||||||
|
if (label != null)
|
||||||
|
{
|
||||||
|
label.GetText = () => option.Name;
|
||||||
|
label.IsVisible = () => true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
panel.ContentHeight = optionsContainer.Bounds.Y + optionsContainer.Bounds.Height;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
Background@LOBBY_OPTIONS_BIN:
|
Container@LOBBY_OPTIONS_BIN:
|
||||||
Width: PARENT_RIGHT
|
Width: PARENT_RIGHT
|
||||||
Height: PARENT_BOTTOM
|
Height: PARENT_BOTTOM
|
||||||
Background: scrollpanel-bg
|
|
||||||
Children:
|
Children:
|
||||||
Label@TITLE:
|
Label@TITLE:
|
||||||
Y: 0 - 25
|
Y: 0 - 25
|
||||||
@@ -10,117 +9,66 @@ Background@LOBBY_OPTIONS_BIN:
|
|||||||
Font: Bold
|
Font: Bold
|
||||||
Align: Center
|
Align: Center
|
||||||
Text: Map Options
|
Text: Map Options
|
||||||
Container:
|
ScrollPanel:
|
||||||
X: 30
|
Logic: LobbyOptionsLogic
|
||||||
Y: 30
|
Width: PARENT_RIGHT
|
||||||
Width: PARENT_RIGHT - 60
|
Height: PARENT_BOTTOM
|
||||||
Height: PARENT_BOTTOM - 75
|
|
||||||
Children:
|
Children:
|
||||||
Checkbox@EXPLORED_MAP_CHECKBOX:
|
Container@LOBBY_OPTIONS:
|
||||||
Width: 150
|
X: 18
|
||||||
Height: 20
|
Y: 30
|
||||||
Font: Regular
|
Width: PARENT_RIGHT - 24 - 18
|
||||||
Text: Explored Map
|
Height: PARENT_BOTTOM - 75
|
||||||
Checkbox@FOG_CHECKBOX:
|
Children:
|
||||||
Y: 35
|
Container@CHECKBOX_ROW_TEMPLATE:
|
||||||
Width: 150
|
Height: 35
|
||||||
Height: 20
|
Children:
|
||||||
Font: Regular
|
Checkbox@A:
|
||||||
Text: Fog of War
|
Width: 175
|
||||||
Checkbox@CRATES_CHECKBOX:
|
Height: 20
|
||||||
X: 170
|
Font: Regular
|
||||||
Width: 225
|
Visible: False
|
||||||
Height: 20
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Font: Regular
|
Checkbox@B:
|
||||||
Text: Crates
|
X: 195
|
||||||
Checkbox@ALLYBUILDRADIUS_CHECKBOX:
|
Width: 175
|
||||||
X: 170
|
Height: 20
|
||||||
Y: 35
|
Font: Regular
|
||||||
Width: 225
|
Visible: False
|
||||||
Height: 20
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Font: Regular
|
Checkbox@C:
|
||||||
Text: Build off Allies' ConYards
|
X: 375
|
||||||
Checkbox@SHORTGAME_CHECKBOX:
|
Width: 175
|
||||||
X: 400
|
Height: 20
|
||||||
Width: 150
|
Font: Regular
|
||||||
Height: 20
|
Visible: False
|
||||||
Font: Regular
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Text: Short Game
|
Container@DROPDOWN_ROW_TEMPLATE:
|
||||||
Checkbox@ALLOWCHEATS_CHECKBOX:
|
Height: 35
|
||||||
X: 400
|
Width: PARENT_RIGHT
|
||||||
Y: 35
|
Children:
|
||||||
Width: 150
|
Label@A_DESC:
|
||||||
Height: 20
|
Width: 80
|
||||||
Font: Regular
|
Height: 25
|
||||||
Text: Debug Menu
|
Align: Right
|
||||||
Checkbox@BUILDRADIUS_CHECKBOX:
|
Visible: False
|
||||||
Y: 70
|
DropDownButton@A:
|
||||||
Width: 150
|
X: 85
|
||||||
Height: 20
|
Width: 160
|
||||||
Font: Regular
|
Height: 25
|
||||||
Text: Limit ConYard Area
|
Font: Regular
|
||||||
Label@DIFFICULTY_DESC:
|
Visible: False
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Y: 70
|
Label@B_DESC:
|
||||||
Width: 160
|
X: PARENT_RIGHT - WIDTH - 183
|
||||||
Height: 25
|
Width: 160
|
||||||
Text: Mission Difficulty:
|
Height: 25
|
||||||
Align: Right
|
Align: Right
|
||||||
DropDownButton@DIFFICULTY_DROPDOWNBUTTON:
|
Visible: False
|
||||||
X: PARENT_RIGHT - WIDTH
|
DropDownButton@B:
|
||||||
Y: 70
|
X: PARENT_RIGHT - WIDTH - 18
|
||||||
Width: 160
|
Width: 160
|
||||||
Height: 25
|
Height: 25
|
||||||
Font: Regular
|
Font: Regular
|
||||||
Label@STARTINGCASH_DESC:
|
Visible: False
|
||||||
Y: 110
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Cash:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGCASH_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: $5000
|
|
||||||
Label@STARTINGUNITS_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 110
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Units:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGUNITS_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
DropDownButton@TECHLEVEL_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: 10
|
|
||||||
Label@TECHLEVEL_DESC:
|
|
||||||
Y: 150
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Tech Level:
|
|
||||||
Align: Right
|
|
||||||
Label@GAMESPEED_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 150
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Game Speed:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@GAMESPEED_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
@@ -1,115 +1,70 @@
|
|||||||
Background@LOBBY_OPTIONS_BIN:
|
Container@LOBBY_OPTIONS_BIN:
|
||||||
Width: PARENT_RIGHT
|
Width: PARENT_RIGHT
|
||||||
Height: PARENT_BOTTOM
|
Height: PARENT_BOTTOM
|
||||||
Background: dialog3
|
|
||||||
Children:
|
Children:
|
||||||
Label@TITLE:
|
Label@TITLE:
|
||||||
X: 0
|
|
||||||
Y: 0 - 27
|
Y: 0 - 27
|
||||||
Width: PARENT_RIGHT
|
Width: PARENT_RIGHT
|
||||||
Height: 25
|
Height: 25
|
||||||
Font: Bold
|
Font: Bold
|
||||||
Align: Center
|
Align: Center
|
||||||
Text: Map Options
|
Text: Map Options
|
||||||
Container:
|
ScrollPanel:
|
||||||
X: 30
|
Logic: LobbyOptionsLogic
|
||||||
Y: 30
|
Width: PARENT_RIGHT
|
||||||
Width: PARENT_RIGHT - 60
|
Height: PARENT_BOTTOM
|
||||||
Height: PARENT_BOTTOM - 75
|
|
||||||
Children:
|
Children:
|
||||||
Checkbox@EXPLORED_MAP_CHECKBOX:
|
Container@LOBBY_OPTIONS:
|
||||||
Width: 150
|
X: 18
|
||||||
Height: 20
|
Y: 30
|
||||||
Text: Explored Map
|
Width: PARENT_RIGHT - 18 - 24
|
||||||
Checkbox@FOG_CHECKBOX:
|
Height: PARENT_BOTTOM - 75
|
||||||
Y: 35
|
Children:
|
||||||
Width: 150
|
Container@CHECKBOX_ROW_TEMPLATE:
|
||||||
Height: 20
|
Height: 35
|
||||||
Text: Fog of War
|
Children:
|
||||||
Checkbox@CRATES_CHECKBOX:
|
Checkbox@A:
|
||||||
X: 170
|
Width: 175
|
||||||
Width: 225
|
Height: 20
|
||||||
Height: 20
|
Visible: False
|
||||||
Text: Crates
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Checkbox@ALLYBUILDRADIUS_CHECKBOX:
|
Checkbox@B:
|
||||||
X: 170
|
X: 195
|
||||||
Y: 35
|
Width: 175
|
||||||
Width: 225
|
Height: 20
|
||||||
Height: 20
|
Visible: False
|
||||||
Text: Build off Allies' ConYards
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Checkbox@SHORTGAME_CHECKBOX:
|
Checkbox@C:
|
||||||
X: 400
|
X: 375
|
||||||
Width: 150
|
Width: 175
|
||||||
Height: 20
|
Height: 20
|
||||||
Text: Short Game
|
Visible: False
|
||||||
Checkbox@ALLOWCHEATS_CHECKBOX:
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
X: 400
|
Container@DROPDOWN_ROW_TEMPLATE:
|
||||||
Y: 35
|
Height: 35
|
||||||
Width: 150
|
Width: PARENT_RIGHT
|
||||||
Height: 20
|
Children:
|
||||||
Text: Debug Menu
|
Label@A_DESC:
|
||||||
Label@DIFFICULTY_DESC:
|
Width: 80
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
Height: 25
|
||||||
Y: 70
|
Align: Right
|
||||||
Width: 160
|
Visible: False
|
||||||
Height: 25
|
DropDownButton@A:
|
||||||
Text: Mission Difficulty:
|
X: 85
|
||||||
Align: Right
|
Width: 160
|
||||||
DropDownButton@DIFFICULTY_DROPDOWNBUTTON:
|
Height: 25
|
||||||
X: PARENT_RIGHT - WIDTH
|
Visible: False
|
||||||
Y: 70
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Width: 160
|
Label@B_DESC:
|
||||||
Height: 25
|
X: PARENT_RIGHT - WIDTH - 183
|
||||||
Font: Regular
|
Width: 160
|
||||||
Label@STARTINGCASH_DESC:
|
Height: 25
|
||||||
Y: 110
|
Align: Right
|
||||||
Width: 80
|
Visible: False
|
||||||
Height: 25
|
DropDownButton@B:
|
||||||
Text: Starting Cash:
|
X: PARENT_RIGHT - WIDTH - 18
|
||||||
Align: Right
|
Width: 160
|
||||||
DropDownButton@STARTINGCASH_DROPDOWNBUTTON:
|
Height: 25
|
||||||
X: 85
|
Font: Regular
|
||||||
Y: 110
|
Visible: False
|
||||||
Width: 160
|
TooltipContainer: TOOLTIP_CONTAINER
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: $5000
|
|
||||||
Label@STARTINGUNITS_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 110
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Units:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGUNITS_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
DropDownButton@TECHLEVEL_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: 10
|
|
||||||
Label@TECHLEVEL_DESC:
|
|
||||||
Y: 150
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Tech Level:
|
|
||||||
Align: Right
|
|
||||||
Label@GAMESPEED_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 150
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Game Speed:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@GAMESPEED_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
@@ -1,121 +0,0 @@
|
|||||||
Background@LOBBY_OPTIONS_BIN:
|
|
||||||
Width: PARENT_RIGHT
|
|
||||||
Height: PARENT_BOTTOM
|
|
||||||
Background: dialog3
|
|
||||||
Children:
|
|
||||||
Label@TITLE:
|
|
||||||
X: 0
|
|
||||||
Y: 0 - 27
|
|
||||||
Width: PARENT_RIGHT
|
|
||||||
Height: 25
|
|
||||||
Font: Bold
|
|
||||||
Align: Center
|
|
||||||
Text: Map Options
|
|
||||||
Container:
|
|
||||||
X: 30
|
|
||||||
Y: 30
|
|
||||||
Width: PARENT_RIGHT - 60
|
|
||||||
Height: PARENT_BOTTOM - 75
|
|
||||||
Children:
|
|
||||||
Checkbox@EXPLORED_MAP_CHECKBOX:
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Explored Map
|
|
||||||
Checkbox@FOG_CHECKBOX:
|
|
||||||
Y: 35
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Fog of War
|
|
||||||
Checkbox@CRATES_CHECKBOX:
|
|
||||||
X: 170
|
|
||||||
Width: 225
|
|
||||||
Height: 20
|
|
||||||
Text: Crates
|
|
||||||
Checkbox@ALLYBUILDRADIUS_CHECKBOX:
|
|
||||||
X: 170
|
|
||||||
Y: 35
|
|
||||||
Width: 225
|
|
||||||
Height: 20
|
|
||||||
Text: Build off Allies' ConYards
|
|
||||||
Checkbox@SHORTGAME_CHECKBOX:
|
|
||||||
X: 400
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Short Game
|
|
||||||
Checkbox@ALLOWCHEATS_CHECKBOX:
|
|
||||||
X: 400
|
|
||||||
Y: 35
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Font: Regular
|
|
||||||
Text: Debug Menu
|
|
||||||
Checkbox@CREEPS_CHECKBOX:
|
|
||||||
Y: 70
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Worms
|
|
||||||
Label@DIFFICULTY_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 70
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Text: Mission Difficulty:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@DIFFICULTY_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 70
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Label@STARTINGCASH_DESC:
|
|
||||||
Y: 110
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Cash:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGCASH_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: $5000
|
|
||||||
Label@STARTINGUNITS_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 110
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Units:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGUNITS_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
DropDownButton@TECHLEVEL_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: 10
|
|
||||||
Label@TECHLEVEL_DESC:
|
|
||||||
Y: 150
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Tech Level:
|
|
||||||
Align: Right
|
|
||||||
Label@GAMESPEED_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 150
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Game Speed:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@GAMESPEED_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
@@ -85,7 +85,7 @@ ChromeLayout:
|
|||||||
common|chrome/lobby.yaml
|
common|chrome/lobby.yaml
|
||||||
common|chrome/lobby-mappreview.yaml
|
common|chrome/lobby-mappreview.yaml
|
||||||
d2k|chrome/lobby-players.yaml
|
d2k|chrome/lobby-players.yaml
|
||||||
d2k|chrome/lobby-options.yaml
|
common|chrome/lobby-options.yaml
|
||||||
common|chrome/lobby-music.yaml
|
common|chrome/lobby-music.yaml
|
||||||
common|chrome/lobby-kickdialogs.yaml
|
common|chrome/lobby-kickdialogs.yaml
|
||||||
common|chrome/lobby-globalchat.yaml
|
common|chrome/lobby-globalchat.yaml
|
||||||
|
|||||||
@@ -1,120 +0,0 @@
|
|||||||
Background@LOBBY_OPTIONS_BIN:
|
|
||||||
Width: PARENT_RIGHT
|
|
||||||
Height: PARENT_BOTTOM
|
|
||||||
Background: dialog3
|
|
||||||
Children:
|
|
||||||
Label@TITLE:
|
|
||||||
X: 0
|
|
||||||
Y: 0 - 27
|
|
||||||
Width: PARENT_RIGHT
|
|
||||||
Height: 25
|
|
||||||
Font: Bold
|
|
||||||
Align: Center
|
|
||||||
Text: Map Options
|
|
||||||
Container:
|
|
||||||
X: 30
|
|
||||||
Y: 30
|
|
||||||
Width: PARENT_RIGHT - 60
|
|
||||||
Height: PARENT_BOTTOM - 75
|
|
||||||
Children:
|
|
||||||
Checkbox@EXPLORED_MAP_CHECKBOX:
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Explored Map
|
|
||||||
Checkbox@FOG_CHECKBOX:
|
|
||||||
Y: 35
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Fog of War
|
|
||||||
Checkbox@CRATES_CHECKBOX:
|
|
||||||
X: 170
|
|
||||||
Width: 225
|
|
||||||
Height: 20
|
|
||||||
Text: Crates
|
|
||||||
Checkbox@ALLYBUILDRADIUS_CHECKBOX:
|
|
||||||
X: 170
|
|
||||||
Y: 35
|
|
||||||
Width: 225
|
|
||||||
Height: 20
|
|
||||||
Text: Build off Allies' ConYards
|
|
||||||
Checkbox@SHORTGAME_CHECKBOX:
|
|
||||||
X: 400
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Short Game
|
|
||||||
Checkbox@ALLOWCHEATS_CHECKBOX:
|
|
||||||
X: 400
|
|
||||||
Y: 35
|
|
||||||
Width: 150
|
|
||||||
Height: 20
|
|
||||||
Text: Debug Menu
|
|
||||||
Checkbox@BUILDRADIUS_CHECKBOX:
|
|
||||||
Y: 70
|
|
||||||
Width: 225
|
|
||||||
Height: 20
|
|
||||||
Text: Limit ConYard Area
|
|
||||||
Label@DIFFICULTY_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 70
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Text: Mission Difficulty:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@DIFFICULTY_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 70
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Label@STARTINGCASH_DESC:
|
|
||||||
Y: 110
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Cash:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGCASH_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: $5000
|
|
||||||
Label@STARTINGUNITS_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 110
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Starting Units:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@STARTINGUNITS_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 110
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
DropDownButton@TECHLEVEL_DROPDOWNBUTTON:
|
|
||||||
X: 85
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
Text: 10
|
|
||||||
Label@TECHLEVEL_DESC:
|
|
||||||
Y: 150
|
|
||||||
Width: 80
|
|
||||||
Height: 25
|
|
||||||
Text: Tech Level:
|
|
||||||
Align: Right
|
|
||||||
Label@GAMESPEED_DESC:
|
|
||||||
X: PARENT_RIGHT - WIDTH - 165
|
|
||||||
Y: 150
|
|
||||||
Width: 120
|
|
||||||
Height: 25
|
|
||||||
Text: Game Speed:
|
|
||||||
Align: Right
|
|
||||||
DropDownButton@GAMESPEED_DROPDOWNBUTTON:
|
|
||||||
X: PARENT_RIGHT - WIDTH
|
|
||||||
Y: 150
|
|
||||||
Width: 160
|
|
||||||
Height: 25
|
|
||||||
Font: Regular
|
|
||||||
@@ -100,7 +100,7 @@ ChromeLayout:
|
|||||||
common|chrome/lobby.yaml
|
common|chrome/lobby.yaml
|
||||||
common|chrome/lobby-mappreview.yaml
|
common|chrome/lobby-mappreview.yaml
|
||||||
common|chrome/lobby-players.yaml
|
common|chrome/lobby-players.yaml
|
||||||
ra|chrome/lobby-options.yaml
|
common|chrome/lobby-options.yaml
|
||||||
common|chrome/lobby-music.yaml
|
common|chrome/lobby-music.yaml
|
||||||
common|chrome/lobby-kickdialogs.yaml
|
common|chrome/lobby-kickdialogs.yaml
|
||||||
common|chrome/lobby-globalchat.yaml
|
common|chrome/lobby-globalchat.yaml
|
||||||
|
|||||||
Reference in New Issue
Block a user