(svn r1742) - Fix: fixed bug introduced in r1730 where AI players had problems when building aircrafts
authorbjarni
Sun, 30 Jan 2005 21:06:09 +0000
changeset 1238 ba0c6c551c1d
parent 1237 1c7a3f9c94b9
child 1239 133586622b78
(svn r1742) - Fix: fixed bug introduced in r1730 where AI players had problems when building aircrafts
aircraft_cmd.c
--- a/aircraft_cmd.c	Sun Jan 30 20:50:06 2005 +0000
+++ b/aircraft_cmd.c	Sun Jan 30 21:06:09 2005 +0000
@@ -166,7 +166,7 @@
 	// Workaround: TODO: make AI players try to build planes in a hangar instead of just an airport tile.
 	if (!IsAircraftHangarTile((TileIndex)tile) && IS_HUMAN_PLAYER(_current_player)) return CMD_ERROR;
 
-	if (_map_owner[tile] != _current_player) return CMD_ERROR;
+	if (_map_owner[tile] != _current_player && IS_HUMAN_PLAYER(_current_player)) return CMD_ERROR;
 
 	SET_EXPENSES_TYPE(EXPENSES_NEW_VEHICLES);