Skip to main content

GetCurrentScript

This function was added in DSL 8

Description

Returns the current script.

function GetCurrentScript() --[[ ... ]] end

Parameters

None.

Return Values

  • script: userdata|script - The script object. userdata if checked with type(script), script if checked with type2(script).

Example

local script = GetCurrentScript()
print(script, GetScriptCollection(script))

See Also