Add a Hotkey class for user-configurable keys. Fixes #3779.
Users can now define and use hotkeys that include modifiers (ctrl/meta/shift/alt).
This commit is contained in:
@@ -148,23 +148,23 @@ namespace OpenRA.GameRules
|
||||
|
||||
public class KeySettings
|
||||
{
|
||||
public string CycleBaseKey = "backspace";
|
||||
public string ToLastEventKey = "space";
|
||||
public string ToSelectionKey = "home";
|
||||
public Hotkey CycleBaseKey = new Hotkey(Keycode.BACKSPACE, Modifiers.None);
|
||||
public Hotkey ToLastEventKey = new Hotkey(Keycode.SPACE, Modifiers.None);
|
||||
public Hotkey ToSelectionKey = new Hotkey(Keycode.HOME, Modifiers.None);
|
||||
|
||||
public string PauseKey = "f9";
|
||||
public string SellKey = "f10";
|
||||
public string PowerDownKey = "f11";
|
||||
public string RepairKey = "f12";
|
||||
public Hotkey PauseKey = new Hotkey(Keycode.F9, Modifiers.None);
|
||||
public Hotkey SellKey = new Hotkey(Keycode.F10, Modifiers.None);
|
||||
public Hotkey PowerDownKey = new Hotkey(Keycode.F11, Modifiers.None);
|
||||
public Hotkey RepairKey = new Hotkey(Keycode.F12, Modifiers.None);
|
||||
|
||||
public string AttackMoveKey = "a";
|
||||
public string StopKey = "s";
|
||||
public string ScatterKey = "x";
|
||||
public string DeployKey = "f";
|
||||
public string StanceCycleKey = "z";
|
||||
public string GuardKey = "d";
|
||||
public Hotkey AttackMoveKey = new Hotkey(Keycode.A, Modifiers.None);
|
||||
public Hotkey StopKey = new Hotkey(Keycode.S, Modifiers.None);
|
||||
public Hotkey ScatterKey = new Hotkey(Keycode.X, Modifiers.None);
|
||||
public Hotkey DeployKey = new Hotkey(Keycode.F, Modifiers.None);
|
||||
public Hotkey StanceCycleKey = new Hotkey(Keycode.Z, Modifiers.None);
|
||||
public Hotkey GuardKey = new Hotkey(Keycode.D, Modifiers.None);
|
||||
|
||||
public string CycleTabsKey = "tab";
|
||||
public Hotkey CycleTabsKey = new Hotkey(Keycode.TAB, Modifiers.None);
|
||||
}
|
||||
|
||||
public class IrcSettings
|
||||
|
||||
Reference in New Issue
Block a user