summaryrefslogtreecommitdiff
path: root/src/water_cmd.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2009-05-24 16:52:42 +0000
committerfrosch <frosch@openttd.org>2009-05-24 16:52:42 +0000
commita4557c7da4329188e3561d9404891c0346f8f70e (patch)
tree96e7ba45ee42e5b0d0c8ca2867b081a56ebef645 /src/water_cmd.cpp
parentb7d065ce99886e2cf86883469a077f653428e5b8 (diff)
downloadopenttd-a4557c7da4329188e3561d9404891c0346f8f70e.tar.xz
(svn r16416) -Fix [FS#2912]: Rework deleting of news when referenced vehicles/stations/industries are deleted.
Diffstat (limited to 'src/water_cmd.cpp')
-rw-r--r--src/water_cmd.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/water_cmd.cpp b/src/water_cmd.cpp
index d4b3f69a6..a37fc27ec 100644
--- a/src/water_cmd.cpp
+++ b/src/water_cmd.cpp
@@ -841,10 +841,9 @@ static void FloodVehicle(Vehicle *v)
AI::NewEvent(v->owner, new AIEventVehicleCrashed(v->index, v->tile, AIEventVehicleCrashed::CRASH_FLOODED));
SetDParam(0, pass);
- AddNewsItem(STR_NEWS_DISASTER_FLOOD_VEHICLE,
- NS_ACCIDENT_VEHICLE,
- v->index,
- 0);
+ AddVehicleNewsItem(STR_NEWS_DISASTER_FLOOD_VEHICLE,
+ NS_ACCIDENT,
+ v->index);
CreateEffectVehicleRel(v, 4, 4, 8, EV_EXPLOSION_LARGE);
SndPlayVehicleFx(SND_12_EXPLOSION, v);
}