diff options
author | rubidium <rubidium@openttd.org> | 2007-08-30 13:03:56 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2007-08-30 13:03:56 +0000 |
commit | cb7eaff3534c1d18c9c8bc06be04ceb437d97765 (patch) | |
tree | 141633b357757cb790c904dc033f8479d58ba5e5 /src/disaster_cmd.cpp | |
parent | ac5fde61fb03059daee4b505dcaad84f21b93857 (diff) | |
download | openttd-cb7eaff3534c1d18c9c8bc06be04ceb437d97765.tar.xz |
(svn r11003) -Codechange: replace Vehicle->next to Vehicle->Next() and Vehicle->SetNext() so we can trap instances that change a next pointer and (in the future) update the first/previous pointers based on that.
Diffstat (limited to 'src/disaster_cmd.cpp')
-rw-r--r-- | src/disaster_cmd.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/disaster_cmd.cpp b/src/disaster_cmd.cpp index c274513a7..a88a1bfe8 100644 --- a/src/disaster_cmd.cpp +++ b/src/disaster_cmd.cpp @@ -158,7 +158,7 @@ static void SetDisasterVehiclePos(Vehicle *v, int x, int y, byte z) VehiclePositionChanged(v); EndVehicleMove(v); - if ((u = v->next) != NULL) { + if ((u = v->Next()) != NULL) { int safe_x = clamp(x, 0, MapMaxX() * TILE_SIZE); int safe_y = clamp(y - 1, 0, MapMaxY() * TILE_SIZE); BeginVehicleMove(u); @@ -173,7 +173,7 @@ static void SetDisasterVehiclePos(Vehicle *v, int x, int y, byte z) VehiclePositionChanged(u); EndVehicleMove(u); - if ((u = u->next) != NULL) { + if ((u = u->Next()) != NULL) { BeginVehicleMove(u); u->x_pos = x; u->y_pos = y; |