mirror of
https://github.com/Ukendio/jecs.git
synced 2025-04-25 09:30:03 +00:00
Add comment to world_query_archetypes
This commit is contained in:
parent
207c9b5268
commit
7f2d6a9e79
1 changed files with 8 additions and 3 deletions
|
@ -926,15 +926,20 @@ do
|
||||||
return query
|
return query
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Meant for directly iterating over archetypes to minimize
|
||||||
|
-- function call overhead. Should not be used unless iterating over
|
||||||
|
-- hundreds of thousands of entities in bulk.
|
||||||
|
local function world_query_archetypes()
|
||||||
|
return compatible_archetypes
|
||||||
|
end
|
||||||
|
|
||||||
local it = {
|
local it = {
|
||||||
__iter = world_query_iter,
|
__iter = world_query_iter,
|
||||||
next = world_query_next,
|
next = world_query_next,
|
||||||
with = world_query_with,
|
with = world_query_with,
|
||||||
without = world_query_without,
|
without = world_query_without,
|
||||||
replace = world_query_replace,
|
replace = world_query_replace,
|
||||||
archetypes = function()
|
archetypes = world_query_archetypes
|
||||||
return compatible_archetypes
|
|
||||||
end
|
|
||||||
} :: any
|
} :: any
|
||||||
|
|
||||||
setmetatable(it, it)
|
setmetatable(it, it)
|
||||||
|
|
Loading…
Reference in a new issue