Complete.Org: Mailing Lists: Archives: freeciv-dev: March 2002:
[Freeciv-Dev] Re: [PATCH] [1.1] cleanup of proccess_*_want() (PR#1295)]
Home

[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]
To: Petr Baudis <pasky@xxxxxxxxxxx>
Cc: "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx>, freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [PATCH] [1.1] cleanup of proccess_*_want() (PR#1295)]
From: Raahul Kumar <raahul_da_man@xxxxxxxxx>
Date: Mon, 4 Mar 2002 04:23:47 -0800 (PST)

--- Petr Baudis <pasky@xxxxxxxxxxx> wrote:
> Dear diary, on Mon, Mar 04, 2002 at 04:15:32AM CET, I got a letter,
> where Raahul Kumar <raahul_da_man@xxxxxxxxx> told me, that...
> > 
> > --- Petr Baudis <pasky@xxxxxxxxxxx> wrote:
> > > Dear diary, on Sun, Mar 03, 2002 at 09:46:21PM CET, I got a letter,
> > > where "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx> told me, that...
> > > > 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.
> > > 
> > > Post a patch on the top of this ;). Oh well, or it won't be probably so
> hard
> > > to
> > > fix..  but I'm not sure if the problem lies here or in assess_danger() or
> > > in...
> > > 
> > > But no behaviour changes in this patch, please.
> > > 
> > > > >    bool walls = city_got_citywalls(pcity);
> > > > 
> > > > > +        if (walls && move_type == LAND_MOVING) {
> > > > > +          desire *= pcity->ai.wallvalue;
> > > > > +          desire /= 10;
> > 
> > POWER_FACTOR should be here instead of 10.
> 
> It shouldn't. ai.wallvalue is just multiplied by 10 so that it has enough
> precision and doesn't have to be a float. See assess_danger().

I thought POWER_FACTOR did exactly the same thing? You mean to say it isn't 
about multiplying the nos to avoid floating point maths?



__________________________________________________
Do You Yahoo!?
Yahoo! Sports - sign up for Fantasy Baseball
http://sports.yahoo.com


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