summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorplanetmaker <planetmaker@openttd.org>2011-12-13 21:10:43 +0000
committerplanetmaker <planetmaker@openttd.org>2011-12-13 21:10:43 +0000
commit86c19475799bd3857414903668a5daa4c54d0569 (patch)
tree86448d395e4aac2a4e4c3b6c88fb68e047e785d2 /src
parent994b541fcfea09cf4e9c9bb3940a47f0fb3bb108 (diff)
downloadopenttd-86c19475799bd3857414903668a5daa4c54d0569.tar.xz
(svn r23511) -Fix [FS#4885] (r23504): Aircraft orders could not be shared anymore when they had no range property declared (Hirundo)
Diffstat (limited to 'src')
-rw-r--r--src/order_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/order_cmd.cpp b/src/order_cmd.cpp
index 44f6f295e..41fc55a88 100644
--- a/src/order_cmd.cpp
+++ b/src/order_cmd.cpp
@@ -1401,7 +1401,7 @@ CommandCost CmdModifyOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
*/
bool CheckAircraftOrderDistance(const Aircraft *v, const Order *first)
{
- if (first == NULL) return true;
+ if (first == NULL || v->acache.cached_max_range == 0) return true;
/* Iterate over all orders to check the distance between all
* 'goto' orders and their respective next order (of any type). */