Codechange: make TownID an enum

This commit is contained in:
Rubidium
2025-01-19 15:18:47 +01:00
committed by rubidium42
parent cda9c2759e
commit cd4482b5df
9 changed files with 18 additions and 15 deletions

View File

@@ -34,7 +34,7 @@
(ref_type == NR_TILE && ScriptMap::IsValidTile(::TileIndex(reference))) ||
(ref_type == NR_STATION && ScriptStation::IsValidStation(reference)) ||
(ref_type == NR_INDUSTRY && ScriptIndustry::IsValidIndustry(reference)) ||
(ref_type == NR_TOWN && ScriptTown::IsValidTown(reference)));
(ref_type == NR_TOWN && ScriptTown::IsValidTown(static_cast<TownID>(reference))));
::CompanyID c = ScriptCompany::FromScriptCompanyID(company);