Lua run

From Valve Developer Community
Revision as of 10:38, 6 July 2019 by Deprecated (talk | contribs) (GMOD's lua_run entity)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Lua run.png Template:GMOD point It runs Lua code from a specific file.

Keyvalues

Code (Code) ([todo internal name (i)]) <string>
Lua code to run when triggered.
Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Flags

  • 1: Run code on spawn

Inputs

RunCode
Run Code that was defined in the entity.
RunPassedCode <stringRedirectInput/string>
Run code that was passed as a variable.


Outputs