[Pkg-freeciv-devel] 2.0.0 bugs

Jason Dorje Short jdorje@users.sf.net
Sat, 23 Apr 2005 15:07:15 -0400


This is a multi-part message in MIME format.
--------------020508080509060601040501
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit

There will be a 2.0.1 release shortly.

In the meantime this patch fixes a serious bug causing easy and novice
difficulty levels to be way too hard.

-jason

--------------020508080509060601040501
Content-Type: text/x-patch;
 name="expand.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="expand.diff"

Index: ai/advdomestic.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/ai/advdomestic.c,v
retrieving revision 1.120
retrieving revision 1.120.2.1
diff -u -r1.120 -r1.120.2.1
--- ai/advdomestic.c	29 Sep 2004 02:24:18 -0000	1.120
+++ ai/advdomestic.c	23 Apr 2005 17:21:21 -0000	1.120.2.1
@@ -160,8 +160,11 @@
 
   if (unit_type != U_LAST
       && est_food > utype_food_cost(get_unit_type(unit_type), gov)) {
-    /* settler_want calculated in settlers.c called from ai_manage_cities() */
-    int want = pcity->ai.settler_want;
+    /* The settler want is calculated in settlers.c called from
+     * ai_manage_cities.  The expand value is the % that the AI should
+     * value expansion (basically to handicap easier difficutly levels)
+     * and is set when the difficulty level is changed (stdinhand.c). */
+    int want = pcity->ai.settler_want * pplayer->ai.expand / 100;
 
     /* Allowing multiple settlers per city now. I think this is correct.
      * -- Syela */

--------------020508080509060601040501--