mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2026-07-24 12:06:41 +00:00
Codechange: make TownProductionEffect a scoped enum
This commit is contained in:
committed by
Peter Nelson
parent
7c6da0ae6d
commit
636fcf3af3
+1
-2
@@ -22,7 +22,6 @@
|
||||
#include "safeguards.h"
|
||||
|
||||
CargoSpec CargoSpec::array[NUM_CARGO];
|
||||
std::array<std::vector<const CargoSpec *>, NUM_TPE> CargoSpec::town_production_cargoes{};
|
||||
|
||||
/**
|
||||
* Bitmask of cargo types available. This includes phony cargoes like regearing cargoes.
|
||||
@@ -241,7 +240,7 @@ void InitializeSortedCargoSpecs()
|
||||
_standard_cargo_mask = 0;
|
||||
uint8_t nb_standard_cargo = 0;
|
||||
for (const auto &cargo : _sorted_cargo_specs) {
|
||||
assert(cargo->town_production_effect != INVALID_TPE);
|
||||
assert(cargo->town_production_effect != TownProductionEffect::Invalid);
|
||||
CargoSpec::town_production_cargoes[cargo->town_production_effect].push_back(cargo);
|
||||
if (cargo->classes.Test(CargoClass::Special)) break;
|
||||
nb_standard_cargo++;
|
||||
|
||||
Reference in New Issue
Block a user