mirror of
https://github.com/unixtensor/Roblox-Elevator-Game.git
synced 2026-02-04 04:06:49 +00:00
48 lines
1.0 KiB
Lua
48 lines
1.0 KiB
Lua
--!optimize 2
|
|
--!native
|
|
--!strict
|
|
|
|
local MapDir = script.Parent
|
|
local MainDir = MapDir.Parent
|
|
|
|
local TagService = require(MainDir:WaitForChild("TagService"))
|
|
|
|
type LightCallback = (Player: Player) -> ()
|
|
|
|
type ClassConstructor = typeof(setmetatable({} :: Constructor_Return_Props, {} :: Impl_Constructor))
|
|
type Impl_Constructor = {
|
|
__index: Impl_Constructor,
|
|
constructor: Constructor_Fun,
|
|
--Class functions
|
|
AddHook: (self: ClassConstructor, Callback: LightCallback) -> (),
|
|
Enable: (self: ClassConstructor) -> (),
|
|
Disable: (self: ClassConstructor) -> ()
|
|
}
|
|
|
|
type Constructor_Fun = (LightSwitches: TagService.LightSwitchTree) -> ClassConstructor
|
|
type Constructor_Return_Props = {
|
|
LightSwitches: TagService.LightSwitchTree
|
|
}
|
|
|
|
local Lights = {} :: Impl_Constructor
|
|
Lights.__index = Lights
|
|
|
|
function Lights.constructor(LightSwitches)
|
|
return setmetatable({
|
|
LightSwitches = LightSwitches
|
|
}, Lights)
|
|
end
|
|
|
|
function Lights:AddHook(Callback)
|
|
|
|
end
|
|
|
|
function Lights:Enable()
|
|
|
|
end
|
|
|
|
function Lights:Disable()
|
|
|
|
end
|
|
|
|
return Lights |