HPL3/SOMA/Scripting/Scripting Api/MovingButton
This page has been automatically generated, but it needs descriptions added to the various fields/functions in order to be complete. |
Have some helpful descriptions to add to this class? Edit this page and add your insight to the Wiki!
Contents
- 1 Summary
- 2 Function Detail
- 2.1 MovingButton_Blink
- 2.2 MovingButton_GetStateAmount
- 2.3 MovingButton_IsDisabled
- 2.4 MovingButton_IsLocked
- 2.5 MovingButton_IsSwitchedOn
- 2.6 MovingButton_SetCanBeSwitchedOff
- 2.7 MovingButton_SetCanBeSwitchedOn
- 2.8 MovingButton_SetDisabled
- 2.9 MovingButton_SetLocked
- 2.10 MovingButton_SetReturnToOffTime
- 2.11 MovingButton_SetSwitchedOn
Summary
Return Type | Function and Description |
---|---|
void | MovingButton_Blink(const tString &in asName) Makes the MovingButton blink in accordance to how it is set up in the ent file |
float | MovingButton_GetStateAmount(const tString &in asName) Returns the current state of the MovingButton |
bool | MovingButton_IsDisabled(const tString &in asName) Checks if the MovingButton is disabled (will not light up or respond to presses) |
bool | MovingButton_IsLocked(const tString &in asName) Checks if the MovingButton is locked |
bool | MovingButton_IsSwitchedOn(const tString &in asName) Returns the state of the button, on/off |
void | MovingButton_SetCanBeSwitchedOff(const tString &in asName, bool abState) Sets if the moving button can be switched off by the player or not |
void | MovingButton_SetCanBeSwitchedOn(const tString &in asName, bool abState) Sets if the moving button can be switched on by the player or not |
void | MovingButton_SetDisabled(const tString &in asName, bool abState, bool abUseEffects = true) Sets the MovingButtons disabled state |
void | MovingButton_SetLocked(const tString &in asName, bool abState, bool abUseEffects = true) Sets the MovingButtons locked state |
void | MovingButton_SetReturnToOffTime(const tString &in asName, float afTime) Sets the time it should take for the button to return to its off state |
void | MovingButton_SetSwitchedOn(const tString &in asName, bool abState, bool abEffects) Switches a button on/off |
Function Detail
MovingButton_Blink
void MovingButton_Blink(const tString &in asName)
Makes the MovingButton blink in accordance to how it is set up in the ent file.
Parameters
- asName (tString) — name of MovingButton.
Returns:
- void
MovingButton_GetStateAmount
float MovingButton_GetStateAmount(const tString &in asName)
Returns the current state of the MovingButton
Parameters
- asName (tString) — name of MovingButton.
Returns:
- float—
MovingButton_IsDisabled
bool MovingButton_IsDisabled(const tString &in asName)
Checks if the MovingButton is disabled (will not light up or respond to presses).
Parameters
- asName (tString) — name of MovingButton.
Returns:
- bool—true = disabled, false = enabled.
MovingButton_IsLocked
bool MovingButton_IsLocked(const tString &in asName)
Checks if the MovingButton is locked.
Parameters
- asName (tString) — name of MovingButton.
Returns:
- bool—true = locked, false = unlocked.
MovingButton_IsSwitchedOn
bool MovingButton_IsSwitchedOn(const tString &in asName)
Returns the state of the button, on/off.
Parameters
- asName (tString) — name of button.
Returns:
- bool—true = on - false = off.
MovingButton_SetCanBeSwitchedOff
void MovingButton_SetCanBeSwitchedOff(const tString &in asName,
bool abState)
Sets if the moving button can be switched off by the player or not
Parameters
- asName (tString) — name of button.
- abState (bool) — true = can be switched off - false = can't be switched off.
Returns:
- void
MovingButton_SetCanBeSwitchedOn
void MovingButton_SetCanBeSwitchedOn(const tString &in asName,
bool abState)
Sets if the moving button can be switched on by the player or not
Parameters
- asName (tString) — name of button.
- abState (bool) — true = can be switched on - false = can't be switched on.
Returns:
- void
MovingButton_SetDisabled
void MovingButton_SetDisabled(const tString &in asName,
bool abState,
bool abUseEffects = true)
Sets the MovingButtons disabled state
Parameters
- asName (tString) — name of MovingButton.
- abState (bool) — true = disabled, false = not disabled
- abUseEffects (bool) — if color should fade in or be set instantly.
Returns:
- void
MovingButton_SetLocked
void MovingButton_SetLocked(const tString &in asName,
bool abState,
bool abUseEffects = true)
Sets the MovingButtons locked state
Parameters
- asName (tString) — name of MovingButton.
- abState (bool) — true = locked, false = unlocked.
- abUseEffects (bool) — if color should fade in or be set instantly.
Returns:
- void
MovingButton_SetReturnToOffTime
void MovingButton_SetReturnToOffTime(const tString &in asName,
float afTime)
Sets the time it should take for the button to return to its off state.
Parameters
- asName (tString) — name of button.
- afTime (float) — time to return to off state.
Returns:
- void
MovingButton_SetSwitchedOn
void MovingButton_SetSwitchedOn(const tString &in asName,
bool abState,
bool abEffects)
Switches a button on/off.
the change will not be apparent to the player.
Parameters
- asName (tString) — name of button.
- abState (bool) — true = on - false = off.
- abEffects (bool) — if the change should activate effects associated with it. If false,
Returns:
- void