summaryrefslogtreecommitdiff
path: root/ai/trolly/pathfinder.c
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-03-11 09:10:46 +0000
committertron <tron@openttd.org>2006-03-11 09:10:46 +0000
commit929fae7b685a21e2337736084e42731f84cf8cba (patch)
tree5a49ef225f58c5e3ddaaa72935a0c65e716fe884 /ai/trolly/pathfinder.c
parent6892e04d14a78818c6cdbf71b0d1f92996a10bc6 (diff)
downloadopenttd-929fae7b685a21e2337736084e42731f84cf8cba.tar.xz
(svn r3816) Use existing accessors
Diffstat (limited to 'ai/trolly/pathfinder.c')
-rw-r--r--ai/trolly/pathfinder.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ai/trolly/pathfinder.c b/ai/trolly/pathfinder.c
index d5244a1da..17fc15b66 100644
--- a/ai/trolly/pathfinder.c
+++ b/ai/trolly/pathfinder.c
@@ -9,6 +9,7 @@
#include "../../command.h"
#include "trolly.h"
#include "../../depot.h"
+#include "../../tunnel_map.h"
#include "../../variables.h"
#include "../ai.h"
@@ -236,7 +237,7 @@ static void AyStar_AiPathFinder_GetNeighbours(AyStar *aystar, OpenListNode *curr
// This problem only is valid for tunnels:
// When the last tile was not yet a tunnel, check if we enter from the right side..
if ((_m[atile].m5 & 0x80) == 0) {
- if (i != (_m[atile].m5 & 3U)) continue;
+ if (GetTunnelDirection(atile) != i) continue;
}
}
}