diff options
author | peter1138 <peter1138@openttd.org> | 2019-02-24 18:52:15 +0000 |
---|---|---|
committer | PeterN <peter@fuzzle.org> | 2019-03-09 16:33:47 +0000 |
commit | ed6084523d546641d4ec9ff5f560387d7c40670f (patch) | |
tree | ec96379c0b76df7b6da28e4c33e16ed7d72eef3e /src/industry_cmd.cpp | |
parent | 46aca9377b01a6626a972151e6fc4c62eec76ba7 (diff) | |
download | openttd-ed6084523d546641d4ec9ff5f560387d7c40670f.tar.xz |
Codechange: Convert StationList from SmallVector to std::set.
Diffstat (limited to 'src/industry_cmd.cpp')
-rw-r--r-- | src/industry_cmd.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp index ad12e5450..cc05893fb 100644 --- a/src/industry_cmd.cpp +++ b/src/industry_cmd.cpp @@ -2432,7 +2432,7 @@ static int WhoCanServiceIndustry(Industry *ind) StationList stations; FindStationsAroundTiles(ind->location, &stations); - if (stations.Length() == 0) return 0; // No stations found at all => nobody services + if (stations.size() == 0) return 0; // No stations found at all => nobody services const Vehicle *v; int result = 0; @@ -2468,7 +2468,7 @@ static int WhoCanServiceIndustry(Industry *ind) /* Same cargo produced by industry is dropped here => not serviced by vehicle v */ if ((o->GetUnloadType() & OUFB_UNLOAD) && !c_accepts) break; - if (stations.Contains(st)) { + if (stations.find(st) != stations.end()) { if (v->owner == _local_company) return 2; // Company services industry result = 1; // Competitor services industry } |