Complete.Org: Mailing Lists: Archives: freeciv-dev: September 2004:
[Freeciv-Dev] (PR#10328) [PATCH] Remove useless 'variant' field
Home

[Freeciv-Dev] (PR#10328) [PATCH] Remove useless 'variant' field

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] (PR#10328) [PATCH] Remove useless 'variant' field
From: "Vasco Alexandre da Silva Costa via RT" <vasc@xxxxxxxxxxxxxx>
Date: Sat, 25 Sep 2004 10:18:57 -0700
Reply-to: RT_CorrespondAddressNotSet@xxxxxxxxxxxxxx

<URL: http://RT::WebBaseURL.not.configured:80/Ticket/Display.html?id=10328 >

The effects patch has made it redundant. This patch also removes some
leftovers in the rulesets from when "sewer_size" was still used.
Index: client/packhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/packhand.c,v
retrieving revision 1.403
diff -u -r1.403 packhand.c
--- client/packhand.c   21 Sep 2004 05:00:50 -0000      1.403
+++ client/packhand.c   25 Sep 2004 17:13:11 -0000
@@ -2268,7 +2268,6 @@
   b->build_cost = p->build_cost;
   b->upkeep = p->upkeep;
   b->sabotage = p->sabotage;
-  b->variant = p->variant;     /* FIXME: remove when gen-impr obsoletes */
   b->helptext = mystrdup(p->helptext);
   sz_strlcpy(b->soundtag, p->soundtag);
   sz_strlcpy(b->soundtag_alt, p->soundtag_alt);
Index: common/capstr.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/capstr.c,v
retrieving revision 1.189
diff -u -r1.189 capstr.c
--- common/capstr.c     22 Sep 2004 15:42:28 -0000      1.189
+++ common/capstr.c     25 Sep 2004 17:13:11 -0000
@@ -73,7 +73,7 @@
  * are not directly related to the capability strings discussed here.)
  */
 
-#define CAPABILITY "+Freeciv.Devel.2004.Sep.22"
+#define CAPABILITY "+Freeciv.Devel.2004.Sep.25"
 
 void init_our_capability(void)
 {
Index: common/improvement.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/improvement.c,v
retrieving revision 1.46
diff -u -r1.46 improvement.c
--- common/improvement.c        13 Sep 2004 15:54:51 -0000      1.46
+++ common/improvement.c        25 Sep 2004 17:13:11 -0000
@@ -243,14 +243,6 @@
 }
 
 /**************************************************************************
-FIXME: remove when gen-impr obsoletes
-**************************************************************************/
-int improvement_variant(Impr_Type_id id)
-{
-  return improvement_types[id].variant;
-}
-
-/**************************************************************************
  Returns 1 if the improvement is obsolete, now also works for wonders
 **************************************************************************/
 bool improvement_obsolete(const struct player *pplayer, Impr_Type_id id) 
Index: common/improvement.h
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/improvement.h,v
retrieving revision 1.33
diff -u -r1.33 improvement.h
--- common/improvement.h        13 Sep 2004 15:54:51 -0000      1.33
+++ common/improvement.h        25 Sep 2004 17:13:11 -0000
@@ -75,7 +75,6 @@
   int build_cost;                      /* Use wrappers to access this. */
   int upkeep;
   int sabotage;                /* Base chance of diplomat sabotage succeeding. 
*/
-  int variant;                 /* FIXME: remove when gen-impr obsoletes */
   struct Sprite *sprite;               /* icon of the improvement */
   char *helptext;
   char soundtag[MAX_LEN_NAME];
@@ -102,9 +101,6 @@
 const char *get_improvement_name(Impr_Type_id id);
 const char *get_improvement_name_orig(Impr_Type_id id);
 
-/* FIXME: remove improvement_variant() when gen-impr obsoletes */
-int improvement_variant(Impr_Type_id id);  
-
 bool improvement_obsolete(const struct player *pplayer, Impr_Type_id id);
 bool improvement_redundant(struct player *pplayer, const struct city *pcity,
                           Impr_Type_id id, bool want_to_build);
Index: common/packets.def
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/packets.def,v
retrieving revision 1.52
diff -u -r1.52 packets.def
--- common/packets.def  21 Sep 2004 05:00:51 -0000      1.52
+++ common/packets.def  25 Sep 2004 17:13:11 -0000
@@ -1147,7 +1147,6 @@
   IMPR_RANGE equiv_range;
   UINT16 build_cost;
   UINT8 upkeep, sabotage;
-  UINT8 variant;               /* FIXME: remove when gen-impr obsoletes */
   STRING soundtag[MAX_LEN_NAME];
   STRING soundtag_alt[MAX_LEN_NAME];
   STRING helptext[MAX_LEN_PACKET];
Index: data/civ1/buildings.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/civ1/buildings.ruleset,v
retrieving revision 1.38
diff -u -r1.38 buildings.ruleset
--- data/civ1/buildings.ruleset 21 Sep 2004 06:18:50 -0000      1.38
+++ data/civ1/buildings.ruleset 25 Sep 2004 17:13:17 -0000
@@ -181,7 +181,6 @@
       "Sea_Veteran"
       "Air_Veteran"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "b_barracks_i"
 sound_alt      = "b_generic"
 helptext       = _("\
@@ -305,7 +304,6 @@
       "Sea_Defend", 200, "Defenders"
       "Unit_No_Lose_Pop"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "b_city_walls"
 sound_alt      = "b_generic"
 helptext       = _("\
@@ -1233,7 +1231,6 @@
       "Prod_Bonus", "Continent", 50, "Generators"
       "Pollu_Prod_Pct", "Continent", -50, "Janitors"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_hoover_dam"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1295,7 +1292,6 @@
     { "name", "range", "value"
       "Force_Content", "Continent", 2
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_js_bachs_cathedral"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1353,7 +1349,6 @@
     { "name", "range", "value"
       "Sea_Move", "Player", 1
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_magellans_expedition"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1405,7 +1400,6 @@
     { "name", "value", "req_type", "req"
       "Make_Content", 4, "Building", "Cathedral"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_michelangelos_chapel"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1459,7 +1453,6 @@
       "Any_Government", "Player"
       "No_Anarchy", "Player"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_pyramids"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1542,7 +1535,6 @@
       "Any_Government", "Player"
       "No_Anarchy", "Player"
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_united_nations"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1576,7 +1568,6 @@
     { "name", "range", "value"
       "Make_Content_Mil_Per", "Player", 1
     }
-variant                = 1             ; FIXME: remove when gen-impr obsoletes
 sound          = "w_womens_suffrage"
 sound_alt      = "w_generic"
 helptext       = _("\
@@ -1621,8 +1612,6 @@
 
 ; FIXME: remove all of the following when gen-impr implemented...
 
-sewer_size=99;
-
 ; Techs which modify building effects:
 
 cathedral_plus="Never"
Index: data/civ2/buildings.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/civ2/buildings.ruleset,v
retrieving revision 1.41
diff -u -r1.41 buildings.ruleset
--- data/civ2/buildings.ruleset 21 Sep 2004 06:18:50 -0000      1.41
+++ data/civ2/buildings.ruleset 25 Sep 2004 17:13:18 -0000
@@ -2091,8 +2091,6 @@
 
 ; FIXME: remove all of the following when gen-impr implemented...
 
-sewer_size=12
-
 ; Techs which modify building effects:
 
 cathedral_plus="Theology"
Index: data/default/buildings.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/default/buildings.ruleset,v
retrieving revision 1.56
diff -u -r1.56 buildings.ruleset
--- data/default/buildings.ruleset      23 Sep 2004 19:46:56 -0000      1.56
+++ data/default/buildings.ruleset      25 Sep 2004 17:13:19 -0000
@@ -2196,8 +2196,6 @@
 
 ; FIXME: remove all of the following when gen-impr implemented...
 
-sewer_size=12
-
 ; Techs which modify building effects:
 
 cathedral_plus="Theology"
Index: data/history/buildings.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/history/buildings.ruleset,v
retrieving revision 1.13
diff -u -r1.13 buildings.ruleset
--- data/history/buildings.ruleset      21 Sep 2004 06:18:50 -0000      1.13
+++ data/history/buildings.ruleset      25 Sep 2004 17:13:23 -0000
@@ -2130,8 +2130,6 @@
 
 ; FIXME: remove all of the following when gen-impr implemented...
 
-sewer_size=12
-
 ; Techs which modify building effects:
 
 cathedral_plus="Theology"
Index: server/ruleset.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/ruleset.c,v
retrieving revision 1.195
diff -u -r1.195 ruleset.c
--- server/ruleset.c    13 Sep 2004 15:54:54 -0000      1.195
+++ server/ruleset.c    25 Sep 2004 17:13:25 -0000
@@ -1409,9 +1409,6 @@
       }
     }
 
-    /* FIXME: remove when gen-impr obsoletes */
-    b->variant = secfile_lookup_int_default(file, 0, "%s.variant", sec[i]);
-    
     sz_strlcpy(b->graphic_str,
               secfile_lookup_str_default(file, "-", "%s.graphic", sec[i]));
     sz_strlcpy(b->graphic_alt,
@@ -2890,7 +2887,6 @@
     packet.build_cost = b->build_cost;
     packet.upkeep = b->upkeep;
     packet.sabotage = b->sabotage;
-    packet.variant = b->variant;       /* FIXME: remove when gen-impr 
obsoletes */
     sz_strlcpy(packet.soundtag, b->soundtag);
     sz_strlcpy(packet.soundtag_alt, b->soundtag_alt);
 

[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#10328) [PATCH] Remove useless 'variant' field, Vasco Alexandre da Silva Costa via RT <=