mirror of
https://github.com/Ukendio/jecs.git
synced 2025-08-05 03:39:17 +00:00
* Initial commit * Add tests * Dedup observers * Handle filters on table creation * Handle Archetype deletion * Remove print * Fix type errors * Cleanup code * Manually inline code * Build terms for cached queries * Specialized cached query iterator * Remove shadowed variable * Inverse statement * Rework demo * Fix metatable * Use generalized iteration
34 lines
992 B
Text
34 lines
992 B
Text
local ReplicatedStorage = game:GetService("ReplicatedStorage")
|
|
local RunService = game:GetService("RunService")
|
|
local UserInputService = game:GetService("UserInputService")
|
|
local jabby = require(ReplicatedStorage.Packages.jabby)
|
|
local std = ReplicatedStorage.std
|
|
local scheduler = require(std.scheduler)
|
|
local world = require(std.world)
|
|
|
|
local function start(modules)
|
|
for _, module in modules do
|
|
require(module)
|
|
end
|
|
local events = scheduler.COLLECT()
|
|
scheduler.BEGIN(events)
|
|
jabby.set_check_function(function(player)
|
|
return true
|
|
end)
|
|
if RunService:IsClient() then
|
|
local player = game:GetService("Players").LocalPlayer
|
|
local playergui = player:WaitForChild("PlayerGui")
|
|
local client = jabby.obtain_client()
|
|
UserInputService.InputBegan:Connect(function(input)
|
|
if input.KeyCode == Enum.KeyCode.F4 then
|
|
local home = playergui:FindFirstChild("Home")
|
|
if home then
|
|
home:Destroy()
|
|
end
|
|
client.spawn_app(client.apps.home)
|
|
end
|
|
end)
|
|
end
|
|
end
|
|
|
|
return start
|