Complete.Org: Mailing Lists: Archives: freeciv-dev: November 2002:
[Freeciv-Dev] new patch: autoattack
Home

[Freeciv-Dev] new patch: autoattack

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] new patch: autoattack
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Sat, 23 Nov 2002 02:38:02 +0000 (GMT)

I reworked the autoattack patch pretty much from scratch. I didn't follow
my own advice to remove the existing autoattack code, though. I left it
there so that the patch should be easy to read...

In any case, this patch makes autoattack a server option that defaults to
off. It no longers requires (or allows) any client interaction on the
issue, as all units will autoattack automatically. The algorithm is
simplicity itself: If we have bigger chance of winning if we attack the
moved unit than if the moved unit attacks us, we autoattack it.

I didn't include the expection about fortification, mostly because I
forgot about it, but now I am not sure about it anyway.

Those who want to balance autoattack shold crank up occupychance to 100% -
it makes autoattack much less an "issue". I may also have a go at
implementing autoretreat for units that are about to be destroyed but have
lots of movement left, but I am not sure it is really desirable or will
be another option to gather dust.

  - Per

Attachment: autoattack3.diff
Description: Text document


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