summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKUDr <KUDr@openttd.org>2006-12-03 12:17:35 +0000
committerKUDr <KUDr@openttd.org>2006-12-03 12:17:35 +0000
commite3607281a0e8a719705f134fe9ca0ba7f088c8b9 (patch)
treed8accb5a3e9a2255a2bde03c565301258657139b
parentacac44820b15d0387cd4b246c3c42d90381acf8c (diff)
downloadopenttd-e3607281a0e8a719705f134fe9ca0ba7f088c8b9.tar.xz
(svn r7327) -Fix: [YAPF] missing YAPF cache notification when building road on rail (new crossing) or removing road from crossing
-rw-r--r--road_cmd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/road_cmd.c b/road_cmd.c
index 8c4da968e..116efd547 100644
--- a/road_cmd.c
+++ b/road_cmd.c
@@ -191,6 +191,7 @@ int32 CmdRemoveRoad(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
MakeRailNormal(tile, GetTileOwner(tile), GetCrossingRailBits(tile), GetRailTypeCrossing(tile));
MarkTileDirtyByTile(tile);
+ YapfNotifyTrackLayoutChange(tile, FIND_FIRST_BIT(GetTrackBits(tile)));
}
return _price.remove_road * 2;
}
@@ -354,6 +355,7 @@ int32 CmdBuildRoad(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
if (!EnsureNoVehicle(tile)) return CMD_ERROR;
if (flags & DC_EXEC) {
+ YapfNotifyTrackLayoutChange(tile, FIND_FIRST_BIT(GetTrackBits(tile)));
MakeRoadCrossing(tile, _current_player, GetTileOwner(tile), roaddir, GetRailType(tile), p2);
MarkTileDirtyByTile(tile);
}