diff options
author | tron <tron@openttd.org> | 2005-06-07 18:13:49 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-06-07 18:13:49 +0000 |
commit | fa8f46c0b7f4723c12ddefd77d619ca98b6c7c6c (patch) | |
tree | 918dadd86e83f26d5de3c32831397bc35434bfa7 /ai_build.c | |
parent | d0cdb45b6c634b4b7238f9b8b8cd9344cb7b1ac3 (diff) | |
download | openttd-fa8f46c0b7f4723c12ddefd77d619ca98b6c7c6c.tar.xz |
(svn r2432) Use GetEngine() instead of DEREF_ENGINE() or even _engines[]
Diffstat (limited to 'ai_build.c')
-rw-r--r-- | ai_build.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ai_build.c b/ai_build.c index 32d31331f..84cc80f22 100644 --- a/ai_build.c +++ b/ai_build.c @@ -221,7 +221,7 @@ int AiNew_PickVehicle(Player *p) { for (i=start+count-1;i>=start;i--) { // Is it availiable? // Also, check if the reliability of the vehicle is above the AI_VEHICLE_MIN_RELIABILTY - if (!HASBIT(_engines[i].player_avail, _current_player) || _engines[i].reliability * 100 < AI_VEHICLE_MIN_RELIABILTY << 16) continue; + if (!HASBIT(GetEngine(i)->player_avail, _current_player) || GetEngine(i)->reliability * 100 < AI_VEHICLE_MIN_RELIABILTY << 16) continue; // Can we build it? ret = DoCommandByTile(0, i, 0, DC_QUERY_COST, CMD_BUILD_ROAD_VEH); if (!CmdFailed(ret)) break; |