added a new hotkey to select all units on screen

closes #4182
This commit is contained in:
Matthias Mailänder
2013-12-06 09:07:51 +01:00
parent f7eb6a29d5
commit 08166c0a64
4 changed files with 9 additions and 0 deletions

View File

@@ -202,6 +202,12 @@ namespace OpenRA.Widgets
}
else if (Hotkey.FromKeyInput(e) == Game.Settings.Keys.PauseKey && World.LocalPlayer != null) // Disable pausing for spectators
World.SetPauseState(!World.Paused);
else if (Hotkey.FromKeyInput(e) == Game.Settings.Keys.SelectAllUnitsKey)
{
var ownUnitsOnScreen = SelectActorsInBox(World, worldRenderer.Viewport.TopLeft, worldRenderer.Viewport.BottomRight,
a => a.Owner == World.RenderPlayer);
World.Selection.Combine(World, ownUnitsOnScreen, false, false);
}
}
return false;