OSL ‐ Globals() - Mistium/Origin-OS GitHub Wiki
The globals function returns an object of all functions, commands and methods.
{
"commands": {},
"functions": {},
"methods": {}
}
Some example data for the Globals()
function is
{
"commands": {
"hello": {
"type": "command",
"code": [
"log \"hello\" ∆"
],
"parameters": [
""
],
"name": "hello"
}
},
"functions": {
"rand": {
"type": "function",
"code": [
"return random() * this.input"
],
"parameters": [
"this.input"
],
"name": "rand"
}
},
"methods": {
"inpt.addition": {
"type": "method",
"code": [
"return inpt + this.val"
],
"parameters": [
"this.input"
],
"input": "inpt",
"name": "inpt.addition"
}
}
}