summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhackykid <hackykid@openttd.org>2005-06-05 20:45:04 +0000
committerhackykid <hackykid@openttd.org>2005-06-05 20:45:04 +0000
commitea57dee837307d7a86a040e4121779f8e4bd1927 (patch)
tree756965eca8db87a17b89939114f957707d63d3b0
parenteb173099e92b0004fb9fd23253d9500481079a52 (diff)
downloadopenttd-ea57dee837307d7a86a040e4121779f8e4bd1927.tar.xz
(svn r2412) - Fix: [ 1214948 ] building vehicles without depot crashes game. (Chris Huebsch)
-rw-r--r--aircraft_gui.c2
-rw-r--r--roadveh_gui.c2
-rw-r--r--ship_gui.c2
-rw-r--r--train_gui.c2
4 files changed, 4 insertions, 4 deletions
diff --git a/aircraft_gui.c b/aircraft_gui.c
index 7cf0cf903..f58184464 100644
--- a/aircraft_gui.c
+++ b/aircraft_gui.c
@@ -1014,7 +1014,7 @@ static void PlayerAircraftWndProc(Window *w, WindowEvent *e)
tile = _last_built_aircraft_depot_tile;
do {
- if (IsTileOwner(tile, _local_player) && IsAircraftHangarTile(tile)) {
+ if (IsAircraftHangarTile(tile) && IsTileOwner(tile, _local_player)) {
ShowAircraftDepotWindow(tile);
ShowBuildAircraftWindow(tile);
return;
diff --git a/roadveh_gui.c b/roadveh_gui.c
index 31bb06d14..e9a8b70dd 100644
--- a/roadveh_gui.c
+++ b/roadveh_gui.c
@@ -892,7 +892,7 @@ static void PlayerRoadVehWndProc(Window *w, WindowEvent *e)
tile = _last_built_road_depot_tile;
do {
- if (IsTileOwner(tile, _local_player) && IsTileDepotType(tile, TRANSPORT_ROAD)) {
+ if (IsTileDepotType(tile, TRANSPORT_ROAD) && IsTileOwner(tile, _local_player)) {
ShowRoadDepotWindow(tile);
ShowBuildRoadVehWindow(tile);
return;
diff --git a/ship_gui.c b/ship_gui.c
index 375afe857..30a366539 100644
--- a/ship_gui.c
+++ b/ship_gui.c
@@ -996,7 +996,7 @@ static void PlayerShipsWndProc(Window *w, WindowEvent *e)
tile = _last_built_ship_depot_tile;
do {
- if (IsTileOwner(tile, _local_player) && IsTileDepotType(tile, TRANSPORT_WATER)) {
+ if (IsTileDepotType(tile, TRANSPORT_WATER) && IsTileOwner(tile, _local_player)) {
ShowShipDepotWindow(tile);
ShowBuildShipWindow(tile);
return;
diff --git a/train_gui.c b/train_gui.c
index 3d7c09435..ae53cef37 100644
--- a/train_gui.c
+++ b/train_gui.c
@@ -1343,7 +1343,7 @@ static void PlayerTrainsWndProc(Window *w, WindowEvent *e)
tile = _last_built_train_depot_tile;
do {
- if (IsTileOwner(tile, _local_player) && IsTileDepotType(tile, TRANSPORT_RAIL)) {
+ if (IsTileDepotType(tile, TRANSPORT_RAIL) && IsTileOwner(tile, _local_player)) {
ShowTrainDepotWindow(tile);
ShowBuildTrainWindow(tile);
return;