Fix #10556: Duplication of road infrastructure count updates (#10557)

When building a road stop
This commit is contained in:
Jonathan G Rennison
2023-03-08 18:38:19 +00:00
committed by GitHub
parent 3287acd114
commit c74dfe393f

View File

@@ -2058,9 +2058,6 @@ CommandCost CmdBuildRoadStop(DoCommandFlag flags, TileIndex tile, uint8 width, u
UpdateCompanyRoadInfrastructure(tram_rt, tram_owner, ROAD_STOP_TRACKBIT_FACTOR);
Company::Get(st->owner)->infrastructure.station++;
UpdateCompanyRoadInfrastructure(road_rt, road_owner, ROAD_STOP_TRACKBIT_FACTOR);
UpdateCompanyRoadInfrastructure(tram_rt, tram_owner, ROAD_STOP_TRACKBIT_FACTOR);
SetCustomRoadStopSpecIndex(cur_tile, specindex);
if (roadstopspec != nullptr) {
st->SetRoadStopRandomBits(cur_tile, GB(Random(), 0, 8));