Jump to: navigation, search

VASSAL Reference Manual

Home > Module > Game Piece Palette > Game Piece > Global Hotkey

Global Hotkey

This trait adds an action that invokes  hotkey, i.e., a keyboard shortcut for a toolbar button in the main controls windows or a Map Window.

Menu Text:  Right-click menu text
Keyboard command:   Keyboard shortcut of the menu item that initiates the command
Global Hotkey:   The hotkey that will be applied to the controls window.
EXAMPLE:   A Dice Button component has been added to the toolbar, using the hotkey F2.  A GamePiece is given a Global Hotkey trait with Menu text Roll Dice, Keyboard Command CTRL-R and Global Hotkey F2.  Now, selecting the piece and typing CTRL-R or selecting Roll Dice from the right-click menu will roll the dice button just as if the player had pressed the button in the toolbar or typed F2 from the keyboard.