Do not add virtual vehicles to tile hash
This commit is contained in:
@@ -734,7 +734,7 @@ static void UpdateVehicleTileHash(Vehicle *v, bool remove)
|
|||||||
Vehicle **old_hash = v->hash_tile_current;
|
Vehicle **old_hash = v->hash_tile_current;
|
||||||
Vehicle **new_hash;
|
Vehicle **new_hash;
|
||||||
|
|
||||||
if (remove) {
|
if (remove || HasBit(v->subtype, GVSF_VIRTUAL)) {
|
||||||
new_hash = nullptr;
|
new_hash = nullptr;
|
||||||
} else {
|
} else {
|
||||||
int x = GB(TileX(v->tile), HASH_RES, HASH_BITS);
|
int x = GB(TileX(v->tile), HASH_RES, HASH_BITS);
|
||||||
|
Reference in New Issue
Block a user