DataType:luainfo

From the wonderful RedGuides Wiki

Accessed with the "Script" member from the DataType:lua

Returns information primarily about the specified Lua script.


This Data Type is referenced in MQ2Lua, and accessed by Top-Level Object(s): Lua
luainfo is used as a return type by these members:  [ Toggle ]

Page Member Description
lua Script[<PID>] the accessor to get info on individual scripts. Accepts scriptname or a PID as an index. If no index provided, it will default to the last executed script that has finished running.

Members

Type Member Description
int PID the PID of the running or most recently executed version of this script
ReturnCount The number of returns from the script, will be 0 if the script has not ended
string Arguments a comma delimited list of arguments passed to the script
EndTime The time the most recent execution of the script ended or NULL if the script has not ended
Name the name of the script
Path the full path of the script
Return if not indexed, a comma-delimited list of return values. Accepts an integer index to get a single return value if there is more than one
StartTime The time the most recent execution of the script was started
Status The execution status of the script

Examples

  • To see a list of arguments passed to the script that's running at PID 2,

/echo ${Lua.Script[2].Arguments}

See also