Mercurial > hg > openttd
changeset 8388:11a08bc12922 draft
(svn r11958) -Fix (r11204): NewAI couldn't build any road vehicles when there were any tram grfs loaded
author | smatz <smatz@openttd.org> |
---|---|
date | Wed, 23 Jan 2008 13:06:00 +0000 |
parents | 170ba96bf00e |
children | 1604f6eb4b5a |
files | src/ai/trolly/build.cpp |
diffstat | 1 files changed, 3 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ai/trolly/build.cpp +++ b/src/ai/trolly/build.cpp @@ -248,6 +248,9 @@ /* Skip vehicles which can't take our cargo type */ if (rvi->cargo_type != _players_ainew[p->index].cargo && !CanRefitTo(i, _players_ainew[p->index].cargo)) continue; + /* Skip trams */ + if (HasBit(EngInfo(i)->misc_flags, EF_ROAD_TRAM)) continue; + // Is it availiable? // Also, check if the reliability of the vehicle is above the AI_VEHICLE_MIN_RELIABILTY if (!HasBit(e->player_avail, _current_player) || e->reliability * 100 < AI_VEHICLE_MIN_RELIABILTY << 16) continue;