Lua:Electrics

Lua:Electrics

From BeamNG

Revision as of 02:52, 22 January 2015 by Nug700 (talk | contribs) (Created page with "Contains functions and attributes to control the electrical system. File locations: lua\vehicle\electrics.lua == Attributes == <source lang="lua"> table values = {} table di...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Contains functions and attributes to control the electrical system.

File locations: lua\vehicle\electrics.lua

Attributes

table values = {}
table disabledState = {}

Member Functions

nil updateValue (func, smoothing)
nil generateBlinkPulse (dt)
nil rpmspinUpdate (dt)
nil update (dt)
nil reset ()
nil beamBroke (id) -- function body commented out.

Internal functions:

nil signalModeChanged ()

User input functions:

nil toggle_left_signal ()
nil toggle_right_signal ()
nil toggle_warn_signal ()
nil toggle_lights ()
nil setLightsState (newval)

Public Interface

  • update
  • toggle_left_signal
  • toggle_right_signal
  • toggle_warn_signal
  • toggle_lights
  • setLightsState
  • beamBroke
  • reset
  • init