(svn r11666) -Fix (r11504): when removing buoys, return to water or canal depending on their owner
authorglx
Wed, 19 Dec 2007 02:41:25 +0000
changeset 8601 6b2ddb5baade
parent 8600 bb089962319d
child 8602 9e75e594a068
(svn r11666) -Fix (r11504): when removing buoys, return to water or canal depending on their owner
src/station_cmd.cpp
src/water.h
src/water_cmd.cpp
--- a/src/station_cmd.cpp	Tue Dec 18 21:25:44 2007 +0000
+++ b/src/station_cmd.cpp	Wed Dec 19 02:41:25 2007 +0000
@@ -1908,7 +1908,7 @@
 		/* We have to set the water tile's state to the same state as before the
 		 * buoy was placed. Otherwise one could plant a buoy on a canal edge,
 		 * remove it and flood the land (if the canal edge is at level 0) */
-		MakeWaterOrCanalDependingOnSurroundings(tile, GetTileOwner(tile));
+		MakeWaterOrCanalDependingOnOwner(tile, GetTileOwner(tile));
 		MarkTileDirtyByTile(tile);
 
 		UpdateStationVirtCoordDirty(st);
--- a/src/water.h	Tue Dec 18 21:25:44 2007 +0000
+++ b/src/water.h	Wed Dec 19 02:41:25 2007 +0000
@@ -8,6 +8,7 @@
 void TileLoop_Water(TileIndex tile);
 void DrawShipDepotSprite(int x, int y, int image);
 void DrawCanalWater(TileIndex tile);
+void MakeWaterOrCanalDependingOnOwner(TileIndex tile, Owner o);
 void MakeWaterOrCanalDependingOnSurroundings(TileIndex t, Owner o);
 
 #endif /* WATER_H */
--- a/src/water_cmd.cpp	Tue Dec 18 21:25:44 2007 +0000
+++ b/src/water_cmd.cpp	Wed Dec 19 02:41:25 2007 +0000
@@ -140,7 +140,7 @@
 	return cost.AddCost(_price.build_ship_depot);
 }
 
-static void MakeWaterOrCanalDependingOnOwner(TileIndex tile, Owner o)
+void MakeWaterOrCanalDependingOnOwner(TileIndex tile, Owner o)
 {
 	if (o == OWNER_WATER) {
 		MakeWater(tile);