[Freeciv-Dev] Re: (PR#14915) AI sometimes builds duplicate improvement
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://bugs.freeciv.org/Ticket/Display.html?id=14915 >
On Mon, 19 Dec 2005, Benedict Adamson wrote:
> The AI sometimes tries to build an improvement in a city that already
> has that improvement. This seems to happen only for barracks and other
> EFT_VETERAN_BUILD improvements, suggesting a problem in the military
> adviser code; work by myself for PR12682 suggests that its is not
> because of the ai_manage_buildings function.
ai/advmilitary.c:adjust_ai_unit_choice() line 1223:
/* TODO: separate checks based on other requirements (e.g., unit class) */
if ((id = ai_find_source_building(pplayer, EFT_VETERAN_BUILD)) != B_LAST) {
choice->choice = id;
choice->type = CT_BUILDING;
}
This code looks suspicious.
- Per
- [Freeciv-Dev] Re: (PR#14915) AI sometimes builds duplicate improvement,
Per I. Mathisen <=
|
|