summaryrefslogtreecommitdiff
path: root/src/ai/trolly
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-04-06 07:48:51 +0000
committerrubidium <rubidium@openttd.org>2008-04-06 07:48:51 +0000
commitd6623cf6541af8cb27359b59b97cb9e47f61bd0e (patch)
treebf63686bb4da660cbcdc1074a869b5b86df60166 /src/ai/trolly
parent8cd1795fe32fc2afaa75f48b8b62ff992bf8f618 (diff)
downloadopenttd-d6623cf6541af8cb27359b59b97cb9e47f61bd0e.tar.xz
(svn r12588) -Codechange: do not access the destination of an order directly.
Diffstat (limited to 'src/ai/trolly')
-rw-r--r--src/ai/trolly/trolly.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ai/trolly/trolly.cpp b/src/ai/trolly/trolly.cpp
index 2876d240e..46aa0f10d 100644
--- a/src/ai/trolly/trolly.cpp
+++ b/src/ai/trolly/trolly.cpp
@@ -553,7 +553,7 @@ static bool AiNew_CheckVehicleStation(Player *p, Station *st)
const Order *order;
FOR_VEHICLE_ORDERS(v, order) {
- if (order->IsType(OT_GOTO_STATION) && GetStation(order->dest) == st) {
+ if (order->IsType(OT_GOTO_STATION) && GetStation(order->GetDestination()) == st) {
// This vehicle has this city in its list
count++;
}