GUISpinner

new GUISpinner(id, options, guimanager, callback, append)

Creates a new GUISpinner

Parameters

NameTypeDescription
Name
id
Type
string
Description
The id and name element
Name
options
Type
json
Description
Options of element
Name
guimanager
Type
GUIManager
Description
The gui manager
Name
callback
Type
function
Description
Trigger function by change (optional)
Name
append
Type
bool
Description
is added to the <body>. => True by default (optional)

Options

  • w: width of input number (in pixel)
  • h: height of input number (in pixel)
  • x: position left of input number (in pixel)
  • y: position top of input number (in pixel)
  • min: min value input number => 0 by default (optional)
  • max: max value input number => 100 by default (optional)
  • step: graduation of input number => 1 by default (optional)
  • value: Current value of the input number => 50 by default (optional)
  • orient: orientation of the input number => "horizontal" by default (optional)
  • zIndex: depth of the element (int) => 1 by default
  • tabindex: Tab order of the field.

Methods

getNumber() → void

Get the number value of element

setVisible(bool, fade) → void

Set this GUI element to visible or invisible

isVisible() → void

Returns element if is visible or no

dispose() → void

Dispose the GUISpinner, and delete element.