ISInterface:AddHotkey

From Lavish Software Wiki
Jump to navigation Jump to search

Syntax

  • bool AddHotkey(char *Name, char *Combo, char *Command, bool Press=false)

Purpose

To add a hotkey

Usage

Parameters

  • char *Name
[in] Name of the hotkey
  • char *Combo
[in] Keys to trigger the command
  • char *Command
[in] Command to be executed
  • bool Press
[in] Optional [defaults to False] if TRUE the hotkey will be activated on keys being pressed, if false the hotkey will be activated on release

Return Value

  • bool
Returns true on success, false on failure

Examples

Add a Hotkey

  • pISInterface->AddHotkey("Wireframe on","f8","wireframe on",TRUE)
  • pISInterface->AddHotkey("Wireframe off","f8","wireframe off",FALSE)
Creates two hotkeys, will turn wireframe on when f8 is held down, and turn it off when it is released


See Also