1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-19 02:12:37 +01:00

Codechange: Use EnumBitSet for VehStates. (#13755)

Renamed from VehStatus because pluralising that is weird.
This commit is contained in:
Peter Nelson
2025-03-08 18:24:21 +00:00
committed by GitHub
parent 0b102db421
commit 91d22f7617
37 changed files with 199 additions and 206 deletions

View File

@@ -949,7 +949,7 @@ protected:
{
for (const Vehicle *v : Vehicle::Iterate()) {
if (v->type == VEH_EFFECT) continue;
if (v->vehstatus & (VS_HIDDEN | VS_UNCLICKABLE)) continue;
if (v->vehstatus.Any({VehState::Hidden, VehState::Unclickable})) continue;
/* Remap into flat coordinates. */
Point pt = this->RemapTile(v->x_pos / (int)TILE_SIZE, v->y_pos / (int)TILE_SIZE);