[Freeciv-Dev] Re: [PATCH] [1.1] cleanup of proccess_*_want() (PR#1295)]
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Sun, 3 Mar 2002, Petr Baudis wrote:
> so, now I'm trying my luck with getting something slightly larger and more
> complicated into CVS - this cleanup cleans proccess_(defender|attacker)_want()
> functions, corrects TODO appropriatelly, and renames pcity->ai.(f|a) into
> something more descriptive. Behaviour is not changed (autogames are same).
One behaviour that should be changed is the AI's inclination to build way
too many city walls and coastal fortresses, while leaving its cities
without a single defender when it thinks they are out of danger. Too many
times I've seen these cities invaded and taken over by barbarians.
> I think it's ready to actually go in, altough I'm open to objections and
> ideas how to extend/correct it even more (I expect many hints for better and
> more comments, and possibly also for better variable names - in fact, all
> those
> one-letter variables have usually same mean in the whole AI - but I didn't
> i.e.
> renamed f to 'loss', but to 'bcost' here, contrary to findvictim()).
It looks ok to me.
> bool walls = city_got_citywalls(pcity);
> + if (walls && move_type == LAND_MOVING) {
> + desire *= pcity->ai.wallvalue;
> + desire /= 10;
> + }
> + if (move_type == LAND_MOVING) {
> + desire *= pcity->ai.wallvalue;
> + desire /= 10;
> + }
Just curious: Why does the AI consider city walls here?
Yours,
Per
"What we anticipate seldom occurs: but what we least expect generally
happens." -- Benjamin Disraeli
- [Freeciv-Dev] Re: [PATCH] [1.1] cleanup of proccess_*_want() (PR#1295)],
Per I. Mathisen <=
|
|