| 166 | } |
| 167 | |
| 168 | List<EntityPtr> EntityMap::entitiesAt(Vec2F const& pos, EntityFilter const& filter) const { |
| 169 | auto entityList = entityQuery(RectF::withCenter(pos, {0, 0}), filter); |
| 170 | |
| 171 | sortByComputedValue(entityList, [&](EntityPtr const& entity) -> float { |
| 172 | return vmagSquared(entity->position() - pos); |
| 173 | }); |
| 174 | return entityList; |
| 175 | } |
| 176 | |
| 177 | List<TileEntityPtr> EntityMap::entitiesAtTile(Vec2I const& pos, EntityFilterOf<TileEntity> const& filter) const { |
| 178 | List<TileEntityPtr> values; |
nothing calls this directly
no test coverage detected