Remove AUTO_VAR macro and _toString function (#592)
This commit is contained in:
@@ -13,7 +13,7 @@ TripWireTile::TripWireTile(int id) : Tile(id, Material::decoration, isSolidRende
|
||||
|
||||
int TripWireTile::getTickDelay(Level *level)
|
||||
{
|
||||
// 4J: Increased (x2); quick update caused problems with shared
|
||||
// 4J: Increased (x2); quick update caused problems with shared
|
||||
// data between client and server.
|
||||
return 20; // 10;
|
||||
}
|
||||
@@ -164,15 +164,14 @@ void TripWireTile::checkPressed(Level *level, int x, int y, int z)
|
||||
int data = level->getData(x, y, z);
|
||||
bool wasPressed = (data & MASK_POWERED) == MASK_POWERED;
|
||||
bool shouldBePressed = false;
|
||||
|
||||
|
||||
ThreadStorage *tls = (ThreadStorage *)TlsGetValue(Tile::tlsIdxShape);
|
||||
vector<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));
|
||||
if (!entities->empty())
|
||||
{
|
||||
for (AUTO_VAR(it, entities->begin()); it != entities->end(); ++it)
|
||||
for (auto& e : *entities)
|
||||
{
|
||||
shared_ptr<Entity> e = *it;
|
||||
if (!e->isIgnoringTileTriggers())
|
||||
if ( e && !e->isIgnoringTileTriggers())
|
||||
{
|
||||
shouldBePressed = true;
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user