mirror of
https://github.com/Ukendio/jecs.git
synced 2026-05-13 14:24:14 +00:00
pull idr.records index out of iterator
This commit is contained in:
parent
af57f4024f
commit
8885a4d614
1 changed files with 2 additions and 1 deletions
|
|
@ -3334,6 +3334,7 @@ local function world_new(DEBUG: boolean?)
|
|||
return NOOP :: () -> i53
|
||||
end
|
||||
|
||||
local idr_record = idr.records[archetype_id]
|
||||
local nth = 0
|
||||
|
||||
return function(): i53?
|
||||
|
|
@ -3341,7 +3342,7 @@ local function world_new(DEBUG: boolean?)
|
|||
return nil
|
||||
end
|
||||
local target = entity_index_get_alive(world.entity_index,
|
||||
ECS_PAIR_SECOND(archetype.types[nth + idr.records[archetype_id]]))
|
||||
ECS_PAIR_SECOND(archetype.types[nth + idr_record]))
|
||||
nth += 1
|
||||
return target
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue