Do not add virtual vehicles to tile hash

This commit is contained in:
Jonathan G Rennison
2019-05-27 14:54:07 +01:00
parent a7cfe167a3
commit 31ad8bdd07

View File

@@ -734,7 +734,7 @@ static void UpdateVehicleTileHash(Vehicle *v, bool remove)
Vehicle **old_hash = v->hash_tile_current;
Vehicle **new_hash;
if (remove) {
if (remove || HasBit(v->subtype, GVSF_VIRTUAL)) {
new_hash = nullptr;
} else {
int x = GB(TileX(v->tile), HASH_RES, HASH_BITS);