diff options
author | tron <tron@openttd.org> | 2005-01-16 11:24:58 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-01-16 11:24:58 +0000 |
commit | ae796740aab0ee480759d2015014b29e2a7aedb4 (patch) | |
tree | bc9e7bccf2119556badf2efe43aca901dfc0a76e /ai_build.c | |
parent | d2643dc483abbd086441b126912f466127253b06 (diff) | |
download | openttd-ae796740aab0ee480759d2015014b29e2a7aedb4.tar.xz |
(svn r1536) Move GET_TILEHEIGHT, GET_TILETYPE and IS_TILETYPE to map.h, turn them into inline functions and add some asserts
Diffstat (limited to 'ai_build.c')
-rw-r--r-- | ai_build.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ai_build.c b/ai_build.c index e8f9edf95..f5745f62c 100644 --- a/ai_build.c +++ b/ai_build.c @@ -174,11 +174,11 @@ int AiNew_Build_RoutePart(Player *p, Ai_PathFinderInfo *PathFinderInfo, byte fla if (old_dir != -1 && old_dir != dir) break; old_dir = dir; // There is already some road, and it is a bridge.. don't build!!! - if (!IS_TILETYPE(route[part], MP_TUNNELBRIDGE)) { + if (!IsTileType(route[part], MP_TUNNELBRIDGE)) { // Build the tile res = DoCommandByTile(route[part], dir, 0, flag | DC_NO_WATER, CMD_BUILD_ROAD); // Currently, we ignore CMD_ERRORs! - if (res == CMD_ERROR && flag == DC_EXEC && !IS_TILETYPE(route[part], MP_STREET) && !EnsureNoVehicle(route[part])) { + if (res == CMD_ERROR && flag == DC_EXEC && !IsTileType(route[part], MP_STREET) && !EnsureNoVehicle(route[part])) { // Problem.. let's just abort it all! DEBUG(ai,0)("Darn, the route could not be builded.. aborting!"); p->ainew.state = AI_STATE_NOTHING; |