summaryrefslogtreecommitdiff
path: root/src/ai
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2007-03-31 01:16:17 +0000
committerbelugas <belugas@openttd.org>2007-03-31 01:16:17 +0000
commit377fbf9eb7f879375da364d9c8ad4ab2dd1eeeb4 (patch)
treedf158a61082a4a256676308b8590314e3595ebee /src/ai
parenta76488861990d586352e3d4e5f7686be782480c3 (diff)
downloadopenttd-377fbf9eb7f879375da364d9c8ad4ab2dd1eeeb4.tar.xz
(svn r9530) -Codechange: Replace a direct industry type access by a behaviour
Diffstat (limited to 'src/ai')
-rw-r--r--src/ai/default/default.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ai/default/default.cpp b/src/ai/default/default.cpp
index edbd0f9c4..258935f73 100644
--- a/src/ai/default/default.cpp
+++ b/src/ai/default/default.cpp
@@ -1424,7 +1424,7 @@ static void AiWantOilRigAircraftRoute(Player *p)
if (t != NULL) {
// Find a random oil rig industry
in = AiFindRandomIndustry();
- if (in != NULL && in->type == IT_OIL_RIG) {
+ if (in != NULL && GetIndustrySpec(in->type)->behaviour & INDUSTRYBEH_AI_AIRSHIP_ROUTES) {
if (DistanceManhattan(t->xy, in->xy) < 60)
break;
}