refactor: remove AABB::newTemp when not returned

This commit is contained in:
orng
2026-03-27 21:56:57 -05:00
parent 534879e2e7
commit d7d99db4c5
24 changed files with 112 additions and 111 deletions

View File

@@ -132,9 +132,10 @@ void TripWireTile::checkPressed(Level* level, int x, int y, int z) {
bool shouldBePressed = false;
ThreadStorage* tls = m_tlsShape;
std::vector<std::shared_ptr<Entity> >* entities = level->getEntities(
nullptr, AABB::newTemp(x + tls->xx0, y + tls->yy0, z + tls->zz0,
x + tls->xx1, y + tls->yy1, z + tls->zz1));
AABB offs_aabb(x + tls->xx0, y + tls->yy0, z + tls->zz0, x + tls->xx1,
y + tls->yy1, z + tls->zz1);
std::vector<std::shared_ptr<Entity> >* entities =
level->getEntities(nullptr, &offs_aabb);
if (!entities->empty()) {
for (AUTO_VAR(it, entities->begin()); it != entities->end(); ++it) {
std::shared_ptr<Entity> e = *it;