diff options
author | rubidium <rubidium@openttd.org> | 2007-04-29 21:24:08 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2007-04-29 21:24:08 +0000 |
commit | 0def47a3b00b74157483ff73090e57d62e9f913d (patch) | |
tree | 776fa0d9e85c7423a43aaea0f6277b62b8acecf9 /src/disaster_cmd.cpp | |
parent | 5eb076402f759d926ee0a5c99b0100621b04f6a6 (diff) | |
download | openttd-0def47a3b00b74157483ff73090e57d62e9f913d.tar.xz |
(svn r9754) -Codechange: make classes for all vehicle types, so we can make nicer/better maintainable code, i.e. virtual methods instead of switches.
Diffstat (limited to 'src/disaster_cmd.cpp')
-rw-r--r-- | src/disaster_cmd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/disaster_cmd.cpp b/src/disaster_cmd.cpp index 9368646de..c6cc16a05 100644 --- a/src/disaster_cmd.cpp +++ b/src/disaster_cmd.cpp @@ -121,7 +121,7 @@ static void DisasterVehicleUpdateImage(Vehicle *v) * and owned by nobody */ static void InitializeDisasterVehicle(Vehicle *v, int x, int y, byte z, Direction direction, byte subtype) { - v->type = VEH_DISASTER; + v = new (v) DisasterVehicle(); v->x_pos = x; v->y_pos = y; v->z_pos = z; |