summaryrefslogtreecommitdiff
path: root/src/station_cmd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r--src/station_cmd.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index 0fc0a14df..67afd5a1d 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -2932,7 +2932,8 @@ void BuildOilRig(TileIndex tile)
st->string_id = GenerateStationName(st, tile, STATIONNAMING_OILRIG);
- MakeOilrig(tile, st->index);
+ assert(IsTileType(tile, MP_INDUSTRY));
+ MakeOilrig(tile, st->index, GetWaterClass(tile));
st->owner = OWNER_NONE;
st->airport_flags = 0;
@@ -2967,7 +2968,8 @@ void DeleteOilRig(TileIndex tile)
{
Station *st = GetStationByTile(tile);
- MakeWater(tile);
+ MakeWaterKeepingClass(tile, OWNER_NONE);
+ MarkTileDirtyByTile(tile);
st->dock_tile = 0;
st->airport_tile = 0;