mirror of
https://github.com/Ukendio/jecs.git
synced 2025-04-24 17:10:03 +00:00
37 lines
683 B
Text
37 lines
683 B
Text
--!optimize 2
|
|
--!native
|
|
|
|
local ReplicatedStorage = game:GetService("ReplicatedStorage")
|
|
local Matter = require(ReplicatedStorage.DevPackages.Matter)
|
|
local ecr = require(ReplicatedStorage.DevPackages.ecr)
|
|
local jecs = require(ReplicatedStorage.Lib)
|
|
local newWorld = Matter.World.new()
|
|
local ecs = jecs.World.new()
|
|
|
|
return {
|
|
ParameterGenerator = function()
|
|
local registry2 = ecr.registry()
|
|
|
|
return registry2
|
|
end,
|
|
|
|
Functions = {
|
|
Matter = function()
|
|
for i = 1, 1000 do
|
|
newWorld:spawn()
|
|
end
|
|
end,
|
|
|
|
ECR = function(_, registry2)
|
|
for i = 1, 1000 do
|
|
registry2.create()
|
|
end
|
|
end,
|
|
|
|
Jecs = function()
|
|
for i = 1, 1000 do
|
|
ecs:entity()
|
|
end
|
|
end,
|
|
},
|
|
}
|