Controls – Template

From Bohemia Interactive Community
Revision as of 13:34, 20 December 2021 by Lou Montana (talk | contribs) (Fix examples, Add mouse buttons)
Jump to navigation Jump to search

Shows a key-styled keyboard shortcut and/or a mouse button. It also adds the page to the Controls template usage error category on usage error.

  • Mouse button can be (case-insensitive):
    • mouseL or LMB
    • mouseL2 or LMB2
    • mouseR or RMB
    • mouseM or MMB
  • Keyboard key can be anything - the first letter will be capitalised, see {{Controls/Control}}.

This template is used on these pages.

Usage

{{Controls|ctrl1|ctrl2|ctrl3|ctrl4}}

  • ctrl1: first control
  • ctrl2: (Optional) second control
  • ctrl3: (Optional) third control
  • ctrl4: (Optional) fourth control
Examples
Code Result
{{Controls}} -no controls defined-
{{Controls|Ctrl}} Ctrl
{{Controls|Ctrl|LMB}} Ctrl + Left Mouse Button
{{Controls|Ctrl|Shift|T}} Ctrl + ⇧ Shift + T
{{Controls|Ctrl|Alt|Shift|T}} Ctrl + Alt + ⇧ Shift + T
{{Controls|Ctrl|Alt|Shift|T|U}} Ctrl + Alt + ⇧ Shift + T