Instance API Reference
This section refers to every method and property available on a SystemData instance.
Methods
Section titled “Methods”InitializeSurfaceControl
Section titled “InitializeSurfaceControl”- Type:
(self: SystemData) -> () - Intiates the controller (if available)
IntializeSiren
Section titled “IntializeSiren”- Type:
(self: SystemData, Siren: string, SirenIDs: {number} | number) -> () - Intiates the siren
RefreshSiren
Section titled “RefreshSiren”- Type:
(self: SystemData, IDs: {number} | number) -> () - Refreshes a siren
SirenOn
Section titled “SirenOn”- Type:
(self: SystemData, SirenCategory: number, Name: string, Asset: {AssetID: string, Volume: number, Speed: number}, Playing: boolean, NoEffectCheck: boolean?, Player: Player?) -> () - Play a siren
SirenOff
Section titled “SirenOff”- Type:
(self: SystemData, SirenCategory: number) -> () - Stop a siren
EnableSiren
Section titled “EnableSiren”- Type:
(self: SystemData, Siren: string, IDs: {number} | number, Overwrite: boolean?, Player: Player | boolean | nil) -> () - Logic for siren handling - enabling
DisableSiren
Section titled “DisableSiren”- Type:
(self: SystemData, IDs: {number} | number | "All", Stop: boolean?, Ignore: {string}?) -> () - Logic for siren handling - disabling
ResumeSiren
Section titled “ResumeSiren”- Type:
(self: SystemData, IDs: {number} | number) -> () - Logic for siren handling - resuming
CleanUp
Section titled “CleanUp”- Type:
(self: SystemData) -> () - Clean up the instance
InitializeUI
Section titled “InitializeUI”- Type:
(self: SystemData, Player: Player, Seat: Seat) -> () - Initialize the controller UI for a player seated (if any)
RemoveUI
Section titled “RemoveUI”- Type:
(self: SystemData, Seat: Seat) -> () - remove the controller UI from the player seated
InitializeController
Section titled “InitializeController”- Type:
(self: SystemData) -> () - Initialize the logic for the controller
ChangeStatus
Section titled “ChangeStatus”- Type:
(self: SystemData, From: string, NewVal: any) -> () - Update the pattern when an update occures
Int_Lightos
Section titled “Int_Lightos”- Type:
(self: SystemData) -> () - Initialize the lights
InitializeModules
Section titled “InitializeModules”- Type:
(self: SystemData, ModulesLocation: Instance) -> () - Initialize the pattern modules
CreateTask
Section titled “CreateTask”- Type:
(self: SystemData, module: string, name: string, exe: () -> ()) -> () - Create a pattern task
KillTask
Section titled “KillTask”- Type:
(self: SystemData, module: string, name: string, NoDL: boolean?) -> () - Kill a pattern task
KillAllTask
Section titled “KillAllTask”- Type:
(self: SystemData) -> () - Kill all pattern tasks
Properties
Section titled “Properties”Halted
Section titled “Halted”- Type:
boolean - Whenever the system is halted (for clean up)
DefaultLightProp
Section titled “DefaultLightProp”- Type:
{ Shadow: boolean?, Range: number?, Angle: number?, Brightness: number? } - DefaultLightProp propriety
SirenDefaultProp
Section titled “SirenDefaultProp”- Type:
{ Volume: number, Speed: number } - SirenDefaultProp propriety
SpecialNames
Section titled “SpecialNames”- Type:
{} - List of states that are considered “special”, uses a different logic
- Type:
string - ID of the instance
System
Section titled “System”- Type:
Instance - The instance
CurrentStage
Section titled “CurrentStage”- Type:
number - The current stage
MaxStage
Section titled “MaxStage”- Type:
number - MaxStage propriety
MaxDir
Section titled “MaxDir”- Type:
number - MaxDir propriety
CurrentDir
Section titled “CurrentDir”- Type:
number - The current directional stage
CurrentAlt
Section titled “CurrentAlt”- Type:
number - The current alternative value
Toggles
Section titled “Toggles”- Type:
{[string]: boolean} - Unused
Settings
Section titled “Settings”- Type:
Config - The instance configuration
SurfaceElements
Section titled “SurfaceElements”- Type:
{[string]: Instance} - All of the surfaces from the controller
AvailableSirens
Section titled “AvailableSirens”- Type:
{[number]: string} - List of every available siren instances
SirenParts
Section titled “SirenParts”- Type:
{[number]: {[number]: {["Player"]: AudioPlayer,["Emitter"]: AudioEmitter,["Effects"]: Folder,["Wires"]: {["Player"]: Wire,["Effects"]: {Wire}}}}}
- List of every siren parts
SirenSounds
Section titled “SirenSounds”- Type:
{[number]: Instance} - Unused
Modules
Section titled “Modules”- Type:
{[string]: {Content: {},Tasks: {[string]: thread},Spawns: {[string]: thread},DL: () -> (),Settings: {RunOnce: {string},},RunningData: string,Data: {[string]: {Started: boolean,Cancelled: boolean,Running: boolean,Ended: boolean,Stopped: boolean}}}}
- List of every pattern modules