Complete.Org: Mailing Lists: Archives: freeciv-ai: October 2002:
[freeciv-ai] Re: Coordinate naval attacks with enemy attacked cities
Home

[freeciv-ai] Re: Coordinate naval attacks with enemy attacked cities

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Jordi Negrevernis i Font <jorneg@xxxxxxxxxxx>
Cc: freeciv ai <freeciv-ai@xxxxxxxxxxx>
Subject: [freeciv-ai] Re: Coordinate naval attacks with enemy attacked cities
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Mon, 28 Oct 2002 13:30:12 +0000 (GMT)

On Sun, 27 Oct 2002, Jordi Negrevernis i Font wrote:
>   This patch makes the naval attack units look for an invaded coastal
> city. And if it find it go there to help allied invasion forces.
>
>   I think it follows the style code. It's againt cvs Sep 25 +
> massiveai2.diff.
>
>   I don't use unit_do_goto - or something like this - after finding
> the cities - find_coastal_enemy_city_attacked -. Surprissintly goes
> there to attack!!!!

You have reinvented the wheel - there has been in cvs which is supposed to
do this for many years, it has just never really worked.

See find_something_to_kill() and reinforcements_cost_and_value() and
and invasion_funct().

Granted, your code is much cleaner, and probably works (as opposed to the
existing code) but duplicating this code doesn't seem like a very good
idea. I would much rather have a total rewrite of the attack code.

(If you want to read find_something_to_kill() I really recommend reading
the massive-AI version.)

  - Per



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