Complete.Org: Mailing Lists: Archives: freeciv-dev: March 2002:
[Freeciv-Dev] Re: [Bug][RFC] Stupid attack behaviour by AI (PR#1340)

[Freeciv-Dev] Re: [Bug][RFC] Stupid attack behaviour by AI (PR#1340)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx>, freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [Bug][RFC] Stupid attack behaviour by AI (PR#1340)
From: Raahul Kumar <raahul_da_man@xxxxxxxxx>
Date: Sat, 23 Mar 2002 20:56:17 -0800 (PST)

--- "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx> wrote:
> On Sat, 23 Mar 2002, Gregory Berkolaiko wrote:
> > Raahul Kumar drew my attention to this phenomenon: if you park your, say,
> > phalanx on a wee mountain outside an AI city then from time to time the
> > city's gates will burst open and AI will attack you with few phalanxes or
> > similarly inefficient units.  Seemingly without any real desire to kill
> you...
> ...
> > because reinforcements are counted in the attack but _not_ counted in the
> > loss.
> >
> > So what happens is:
> > AI accumulates quite a few defensive units.
> Why on Earth does the AI build and attack with _defensive_ units?

This is quite a vicious cycle. The answer is in three phases:

The AI system of what to build is prioritised in favour of military units, and
further weighted to favour defensive units first. It also checks the nearness
of enemy units and that phalanx on a mountain outside the city is very near.
than build attacking units the AI builds defensive units because it believes
that single phalanx will take out 3+ phalanx behind city walls. There is a bug
right here. Having enemy units outside the city leads the AI to *ALWAYS*
build defensive units.

There is also a bug in win/loss equation. As Greg described it, the AI wrongly
thinks it can destroy a fortified phalanx with four attacking phalanx. The cost
to it is far higher than my loss.

Naturally the AI attacks with defensive units because the building order has
left it with NO ATTACKING UNITS. It will never build any attacking units
in spite of the superior win chance of knights/catapault/legion against

> Yours,
> Per
> "Capitalism is the extraordinary belief that the nastiest of men,
> for the nastiest of reasons, will somehow work for the benefit of
> us all." -- John Maynard Keynes

Do You Yahoo!?
Yahoo! Movies - coverage of the 74th Academy Awards®

[Prev in Thread] Current Thread [Next in Thread]