summaryrefslogtreecommitdiff
path: root/src/road_cmd.cpp
diff options
context:
space:
mode:
authortruebrain <truebrain@openttd.org>2009-01-12 17:11:45 +0000
committertruebrain <truebrain@openttd.org>2009-01-12 17:11:45 +0000
commitc2406cd42d481a697602b430111a9e59af61660f (patch)
treeced1a262eb143ad6e64ec02f4a4c89835c0c32fd /src/road_cmd.cpp
parentec97e1fd0d6ca942805fa25d94007437bc0ed952 (diff)
downloadopenttd-c2406cd42d481a697602b430111a9e59af61660f.tar.xz
(svn r15027) -Merge: tomatos and bananas left to be, here is NoAI for all to see.
NoAI is an API (a framework) to build your own AIs in. See: http://wiki.openttd.org/wiki/index.php/AI:Main_Page With many thanks to: - glx and Rubidium for their syncing, feedback and hard work - Yexo for his feedback, patches, and AIs which tested the system very deep - Morloth for his feedback and patches - TJIP for hosting a challenge which kept NoAI on track - All AI authors for testing our AI API, and all other people who helped in one way or another -Remove: all old AIs and their cheats/hacks
Diffstat (limited to 'src/road_cmd.cpp')
-rw-r--r--src/road_cmd.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/road_cmd.cpp b/src/road_cmd.cpp
index 54ebd80e3..6ed96d653 100644
--- a/src/road_cmd.cpp
+++ b/src/road_cmd.cpp
@@ -925,10 +925,7 @@ static CommandCost ClearTile_Road(TileIndex tile, byte flags)
/* Clear the road if only one piece is on the tile OR the AI tries
* to clear town road OR we are not using the DC_AUTO flag */
- if ((CountBits(b) == 1 && GetRoadBits(tile, ROADTYPE_TRAM) == ROAD_NONE) ||
- ((flags & DC_AI_BUILDING) && GetOtherRoadBits(tile, ROADTYPE_ROAD) == ROAD_NONE && IsRoadOwner(tile, ROADTYPE_ROAD, OWNER_TOWN)) ||
- !(flags & DC_AUTO)
- ) {
+ if ((CountBits(b) == 1 && GetRoadBits(tile, ROADTYPE_TRAM) == ROAD_NONE) || !(flags & DC_AUTO)) {
RoadTypes rts = GetRoadTypes(tile);
CommandCost ret(EXPENSES_CONSTRUCTION);
for (RoadType rt = ROADTYPE_ROAD; rt < ROADTYPE_END; rt++) {