1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-16 08:52:40 +01:00

Codechange: Add Count() method to BaseBitSet.

This commit is contained in:
Peter Nelson
2025-05-13 20:09:26 +01:00
committed by Peter Nelson
parent ecc3438519
commit 66c16a1d1f
3 changed files with 12 additions and 3 deletions

View File

@@ -976,7 +976,7 @@ static const IntervalTimer<TimerGameCalendar> _calendar_engines_daily({TimerGame
CloseWindowById(WC_ENGINE_PREVIEW, i);
e->preview_company = CompanyID::Invalid();
}
} else if (CountBits(e->preview_asked.base()) < MAX_COMPANIES) {
} else if (e->preview_asked.Count() < MAX_COMPANIES) {
e->preview_company = GetPreviewCompany(e);
if (e->preview_company == CompanyID::Invalid()) {