mirror of
https://github.com/Ukendio/jecs.git
synced 2025-04-25 09:30:03 +00:00
mayhaps a regression, we shall see
This commit is contained in:
parent
19819bfcad
commit
3e15fcd0ae
1 changed files with 3 additions and 5 deletions
|
@ -500,20 +500,18 @@ function World.query(world: World, ...: i53): Query
|
||||||
function preparedQuery:__iter()
|
function preparedQuery:__iter()
|
||||||
return function()
|
return function()
|
||||||
local archetype = compatibleArchetype[1]
|
local archetype = compatibleArchetype[1]
|
||||||
local entities = archetype.entities
|
local row = next(archetype.entities, lastRow)
|
||||||
local row = next(entities, lastRow)
|
|
||||||
while row == nil do
|
while row == nil do
|
||||||
lastArchetype, compatibleArchetype = next(compatibleArchetypes, lastArchetype)
|
lastArchetype, compatibleArchetype = next(compatibleArchetypes, lastArchetype)
|
||||||
if lastArchetype == nil then
|
if lastArchetype == nil then
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
archetype = compatibleArchetype[1]
|
archetype = compatibleArchetype[1]
|
||||||
entities = archetype.entities
|
row = next(archetype.entities, row)
|
||||||
row = next(entities, row)
|
|
||||||
end
|
end
|
||||||
lastRow = row
|
lastRow = row
|
||||||
|
|
||||||
local entityId = entities[row :: number]
|
local entityId = archetype.entities[row :: number]
|
||||||
local columns = archetype.columns
|
local columns = archetype.columns
|
||||||
local tr = compatibleArchetype[2]
|
local tr = compatibleArchetype[2]
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue