[Freeciv-Dev] Re: Patch: generalized granary size (PR#635)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Sun, Dec 24, 2000 at 12:03:20PM +0100, Thue wrote:
> On Sunday 24 December 2000 04:32, mike_jing@xxxxxxxxx wrote:
> > >So in a city of size 1 food has a value of 57, while in a city of size 2,
> > >whire it takes 50% more to make the city grow, the value of
> > >food is only 2/3*57 = 38. Then you would expect the next value to be
> > > 3/4*38 = 28.5, but apperantly the author of this code miscalculated
> > >(used 2/3 instead)...
> >
> > It doesn't sound unreasonable. Of course, one can't be sure without some
> > kind of testing or unless the author suddenly reappears.
>
> Well, looking in the Changelog I can see that on May 24 the way to calculate
> the foodbox width changed, but the food_weighting() function was not updated.
> So assuming it to be wrong is not a bad guess.
> It is also IMO generally bad karma to assume an uncommented function that
> doesn't make sense to you to be perfect and therefore refuse to follow your
> own good sense. With the amount of legacy code the AI contains we will then
> never get anywhere. But you should of course test it in an actual game before
> commiting.
>
> -Thue
>
The values fixed in correspond to 76 / city_size, except that the value
for size 1 is 57 instead of 76. This looks like a manual tweak.
As Thue points out, prior to May 1999, fooxbox_width was = city_size.
(instead of city_size+1)
What this means is that prior to the May 1999 change,
the AI valued each unit of city growth the same, except that
getting size 2 was worth only 3/4 as much
(because of the first value being 57 instead of 76).
--
Andrew McGuinness Luton, UK andrew_mcguinness@xxxxxxxxxxxxx
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), mike_jing, 2000/12/23
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Thue, 2000/12/24
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635),
Andrew McGuinness <=
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Andrew McGuinness, 2000/12/24
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Thue, 2000/12/25
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Andrew McGuinness, 2000/12/25
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Thue, 2000/12/26
- [Freeciv-Dev] Re: Patch: generalized granary size (PR#635), Tony Stuckey, 2000/12/27
|
|