Skip to main content

System

Class

Properties

name

System.name: string

The name of this node.

parent

System.parent: Group?

What Group this node belongs to. When the parent runs, this node also runs (with the proper order).

enabled

System.enabled: boolean

If the node is enabled or not. While disabled, this node won't run itself or any of it's children.

kind

This item is read only and cannot be modified. Read Only
System.kind: "System"

callback

This item is read only and cannot be modified. Read Only
System.callback: SystemCallback

The function that should be ran when this system runs.

Functions

new

System.new(
namestring,
callbackSystemCallback
) → System

Types

type SystemCallback = (dtnumber) → ()

Creates a new System with the given name and callback.

Before

System:Before(dependentNode) → System

A reference to node.insertBefore.

After

System:After(dependencyNode) → System

A reference to node.insertAfter.

In

System:In(parentGroup) → System

A reference to node.insertIn.

Resolve

System:Resolve() → System

A reference to node.resolve.

SetEnabled

System:SetEnabled(enabledboolean) → ()

A reference to node.setEnabled.

Run

System:Run(dtnumber) → ()
Show raw api
{
    "functions": [
        {
            "name": "new",
            "desc": "Creates a new [System] with the given name and callback.",
            "params": [
                {
                    "name": "name",
                    "desc": "",
                    "lua_type": "string"
                },
                {
                    "name": "callback",
                    "desc": "",
                    "lua_type": "SystemCallback"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "System\n"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 24,
                "path": "src/system.luau"
            }
        },
        {
            "name": "Before",
            "desc": "A reference to [node.insertBefore].",
            "params": [
                {
                    "name": "dependent",
                    "desc": "",
                    "lua_type": "Node"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "System"
                }
            ],
            "function_type": "method",
            "source": {
                "line": 64,
                "path": "src/system.luau"
            }
        },
        {
            "name": "After",
            "desc": "A reference to [node.insertAfter].",
            "params": [
                {
                    "name": "dependency",
                    "desc": "",
                    "lua_type": "Node"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "System"
                }
            ],
            "function_type": "method",
            "source": {
                "line": 75,
                "path": "src/system.luau"
            }
        },
        {
            "name": "In",
            "desc": "A reference to [node.insertIn].",
            "params": [
                {
                    "name": "parent",
                    "desc": "",
                    "lua_type": "Group"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "System"
                }
            ],
            "function_type": "method",
            "source": {
                "line": 86,
                "path": "src/system.luau"
            }
        },
        {
            "name": "Resolve",
            "desc": "A reference to [node.resolve].",
            "params": [],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "System"
                }
            ],
            "function_type": "method",
            "source": {
                "line": 96,
                "path": "src/system.luau"
            }
        },
        {
            "name": "SetEnabled",
            "desc": "A reference to [node.setEnabled].",
            "params": [
                {
                    "name": "enabled",
                    "desc": "",
                    "lua_type": "boolean"
                }
            ],
            "returns": [],
            "function_type": "method",
            "source": {
                "line": 106,
                "path": "src/system.luau"
            }
        },
        {
            "name": "Run",
            "desc": "Calls [System.callback].",
            "params": [
                {
                    "name": "dt",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [],
            "function_type": "method",
            "source": {
                "line": 116,
                "path": "src/system.luau"
            }
        }
    ],
    "properties": [
        {
            "name": "name",
            "desc": "The name of this node.",
            "lua_type": "string",
            "source": {
                "line": 17,
                "path": "src/types.luau"
            }
        },
        {
            "name": "parent",
            "desc": "What [Group] this node belongs to. When the parent runs, this node also runs (with the proper order).",
            "lua_type": "Group?",
            "source": {
                "line": 32,
                "path": "src/types.luau"
            }
        },
        {
            "name": "enabled",
            "desc": "If the node is enabled or not. While disabled, this node won't run itself or any of it's children.",
            "lua_type": "boolean",
            "source": {
                "line": 47,
                "path": "src/types.luau"
            }
        },
        {
            "name": "_dependencies",
            "desc": "A set of [Nodes](Node) that should run before this one.",
            "lua_type": "{ [Node]: true }",
            "private": true,
            "source": {
                "line": 64,
                "path": "src/types.luau"
            }
        },
        {
            "name": "_dependents",
            "desc": "A set of [Nodes](Node) that should run after this one.",
            "lua_type": "{ [Node]: true }",
            "private": true,
            "source": {
                "line": 81,
                "path": "src/types.luau"
            }
        },
        {
            "name": "kind",
            "desc": "\t",
            "lua_type": "\"System\"",
            "readonly": true,
            "source": {
                "line": 31,
                "path": "src/system.luau"
            }
        },
        {
            "name": "callback",
            "desc": "The function that should be ran when this system runs.\n\n\t",
            "lua_type": "SystemCallback",
            "readonly": true,
            "source": {
                "line": 40,
                "path": "src/system.luau"
            }
        }
    ],
    "types": [
        {
            "name": "SystemCallback",
            "desc": "",
            "lua_type": "(dt: number) -> ()",
            "source": {
                "line": 16,
                "path": "src/system.luau"
            }
        }
    ],
    "name": "System",
    "desc": "",
    "tags": [
        "Class"
    ],
    "source": {
        "line": 5,
        "path": "src/system.luau"
    }
}