VR Development Framework
v 1.0.0
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
static KeyCode AVR.Core.AVR_Settings.get_key ( string  token)
inlinestatic

Get a registered setting of the type KeyCode.

Parameters
tokenToken identifying the given setting. A setting declared as domain = { setting = true } will be retrievable with the token /domain/setting.
Returns
Registered setting if a valid is found, otherwise KeyCode.None.

Definition at line 49 of file AVR_Settings.cs.

49  {
50  KeyCode key;
51  if (System.Enum.TryParse(AVR.Core.AVR_Settings.get_string(token), out key))
52  {
53  return key;
54  }
55  else {
56  AVR.Core.AVR_DevConsole.cerror(token + " does not contain a valid key or does not exist!", "AVR_Settings");
57  return KeyCode.None;
58  }
59  }