Now coloring A* cells by owning player color. Added checkbox to cheats menu.

This commit is contained in:
Matthias Mailänder
2013-03-10 07:33:25 +01:00
parent 7d0de5645f
commit 493eb10b96
4 changed files with 49 additions and 22 deletions

View File

@@ -59,6 +59,11 @@ namespace OpenRA.Mods.RA.Widgets.Logic
widget.Get<ButtonWidget>("RESET_EXPLORATION").OnClick = () =>
world.IssueOrder(new Order("DevResetExploration", world.LocalPlayer.PlayerActor, false));
var dbgOverlay = world.WorldActor.TraitOrDefault<DebugOverlay>();
var showAstarCostCheckbox = widget.Get<CheckboxWidget>("SHOW_ASTAR");
showAstarCostCheckbox.IsChecked = () => dbgOverlay != null ? dbgOverlay.Visible : false;
showAstarCostCheckbox.OnClick = () => { if (dbgOverlay != null) dbgOverlay.Visible ^= true; };
widget.Get<ButtonWidget>("CLOSE").OnClick = () => { Ui.CloseWindow(); onExit(); };
}