Make map:get_entities() return an iterator
Created by: christopho
map:get_entities(prefix) currently returns an array of entities. It is always used as
for _, entity in ipairs(map:get_entities(prefix)) do
...
end
Returning an iterator would be more handy:
for entity in map:get_entities(prefix) do
...
end