(svn r23676) -Fix [FS#4913] (r23412): when removing road stops the wrong tile was checked for updating the infrastructure cache

replace/41b28d7194a279bdc17475d4fbe2ea6ec885a466
rubidium 13 years ago
parent 3f7b812891
commit 2c09939bd3

@ -2003,7 +2003,7 @@ CommandCost CmdRemoveRoadStop(TileIndex tile, DoCommandFlag flags, uint32 p1, ui
/* Update company infrastructure counts. */
RoadType rt;
FOR_EACH_SET_ROADTYPE(rt, rts) {
Company *c = Company::GetIfValid(GetRoadOwner(tile, rt));
Company *c = Company::GetIfValid(GetRoadOwner(cur_tile, rt));
if (c != NULL) {
c->infrastructure.road[rt] += CountBits(road_bits);
DirtyCompanyInfrastructureWindows(c->index);

Loading…
Cancel
Save