Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2005:
[Freeciv-Dev] (PR#12963) nation.ruleset has init_government
Home

[Freeciv-Dev] (PR#12963) nation.ruleset has init_government

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] (PR#12963) nation.ruleset has init_government
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Mon, 2 May 2005 15:12:34 -0700
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=12963 >

This patch:
 - Adds a new nation ruleset define init_government, which sets the
starting government of a nation. This is very useful for modpacks.
 - Removes useless AI hints in nation rulesets, replacing them with the
above and init_units (implemented earlier).

The latter makes it rather big.

  - Per

Index: ai/aihand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/ai/aihand.c,v
retrieving revision 1.111
diff -u -r1.111 aihand.c
--- ai/aihand.c 12 Apr 2005 14:44:35 -0000      1.111
+++ ai/aihand.c 2 May 2005 22:08:43 -0000
@@ -23,6 +23,7 @@
 #include "government.h"
 #include "log.h"
 #include "map.h"
+#include "nation.h"
 #include "packets.h"
 #include "player.h"
 #include "shared.h"
@@ -412,8 +413,9 @@
     /* We have few cities in the beginning, compensate for this to ensure
      * that we are sufficiently forward-looking. */
     int want = MAX(ai->goal.govt.val, 100);
+    struct nation_type *pnation = get_nation_by_plr(pplayer);
 
-    if (pplayer->government == game.default_government) {
+    if (pplayer->government == pnation->init_government) {
       /* Default government is the crappy one we start in (like Despotism).
        * We want something better pretty soon! */
       want += 25 * game.turn;
Index: client/packhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/packhand.c,v
retrieving revision 1.499
diff -u -r1.499 packhand.c
--- client/packhand.c   1 May 2005 16:18:13 -0000       1.499
+++ client/packhand.c   2 May 2005 22:08:44 -0000
@@ -2114,7 +2114,6 @@
   }
 
   game.government_when_anarchy = packet->government_when_anarchy;
-  game.default_government = packet->default_government;
 
   game.num_unit_types = packet->num_unit_types;
   game.num_impr_types = packet->num_impr_types;
@@ -2479,6 +2478,13 @@
   }
   pl->city_style = p->city_style;
 
+  memcpy(pl->init_techs, p->init_techs, sizeof(pl->init_techs));
+  memcpy(pl->init_buildings, p->init_buildings, 
+         sizeof(pl->init_buildings));
+  memcpy(pl->init_units, p->init_units, 
+         sizeof(pl->init_units));
+  pl->init_government = p->init_government;
+
   if (p->legend[0] != '\0') {
     pl->legend = mystrdup(_(p->legend));
   } else {
Index: common/game.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/game.c,v
retrieving revision 1.207
diff -u -r1.207 game.c
--- common/game.c       27 Apr 2005 16:31:46 -0000      1.207
+++ common/game.c       2 May 2005 22:08:44 -0000
@@ -262,7 +262,6 @@
  
   game.nation_count = 0;
   game.government_count = 0;
-  game.default_government = G_MAGIC;        /* flag */
   game.government_when_anarchy = G_MAGIC;   /* flag */
 
   game.palace_building = B_LAST;
Index: common/game.h
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/game.h,v
retrieving revision 1.182
diff -u -r1.182 game.h
--- common/game.h       30 Apr 2005 17:09:27 -0000      1.182
+++ common/game.h       2 May 2005 22:08:45 -0000
@@ -153,9 +153,7 @@
   int num_tech_types;  /* including A_NONE */
 
   int government_count;
-  int default_government;
   int government_when_anarchy;
-  int ai_goal_government;      /* kludge */
 
   int nation_count;
   int playable_nation_count;
Index: common/nation.h
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/nation.h,v
retrieving revision 1.43
diff -u -r1.43 nation.h
--- common/nation.h     30 Apr 2005 17:09:27 -0000      1.43
+++ common/nation.h     2 May 2005 22:08:45 -0000
@@ -96,6 +96,7 @@
   /* Items given to this nation at game start.  Server only. */
   int init_techs[MAX_NUM_TECH_LIST];
   int init_buildings[MAX_NUM_BUILDING_LIST];
+  int init_government;
   Unit_type_id init_units[MAX_NUM_UNIT_LIST];
 
   /* Groups which this nation is assigned to */
Index: common/packets.def
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/packets.def,v
retrieving revision 1.112
diff -u -r1.112 packets.def
--- common/packets.def  1 May 2005 16:18:14 -0000       1.112
+++ common/packets.def  2 May 2005 22:08:45 -0000
@@ -1119,6 +1119,9 @@
 
   UINT8 city_style;
   TECH_LIST init_techs[MAX_NUM_TECH_LIST];
+  UNIT_TYPE init_units[MAX_NUM_UNIT_LIST];
+  IMPROVEMENT init_buildings[MAX_NUM_BUILDING_LIST];
+  GOVERNMENT init_government;
 
   UINT8 leader_count;
   STRING leader_name[MAX_NUM_LEADERS:leader_count][MAX_LEN_NAME];
@@ -1223,7 +1226,6 @@
   UINT8 num_tech_types;
   TECH_LIST rtech_partisan_req[MAX_NUM_TECH_LIST]; 
   UINT8 government_when_anarchy;
-  UINT8 default_government;
   UINT8 government_count;
   UINT8 nation_count;
   UINT8 playable_nation_count;
Index: common/player.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/player.c,v
retrieving revision 1.175
diff -u -r1.175 player.c
--- common/player.c     1 May 2005 16:18:14 -0000       1.175
+++ common/player.c     2 May 2005 22:08:49 -0000
@@ -106,7 +106,6 @@
   sz_strlcpy(plr->name, ANON_PLAYER_NAME);
   sz_strlcpy(plr->username, ANON_USER_NAME);
   plr->is_male = TRUE;
-  plr->government=game.default_government;
   plr->nation = NO_NATION_SELECTED;
   plr->team = TEAM_NONE;
   plr->is_started = FALSE;
Index: data/default/governments.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/default/governments.ruleset,v
retrieving revision 1.29
diff -u -r1.29 governments.ruleset
--- data/default/governments.ruleset    28 Mar 2005 17:14:58 -0000      1.29
+++ data/default/governments.ruleset    2 May 2005 22:08:49 -0000
@@ -15,7 +15,6 @@
 options="1.9"
 
 [governments]
-default="Despotism"
 when_anarchy="Anarchy"
 
 ; Below: The individual government types, one per section.
Index: data/nation/afghani.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/afghani.ruleset,v
retrieving revision 1.6
diff -u -r1.6 afghani.ruleset
--- data/nation/afghani.ruleset 29 Apr 2005 17:58:10 -0000      1.6
+++ data/nation/afghani.ruleset 2 May 2005 22:08:50 -0000
@@ -16,7 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Iron Working", "Horseback Riding", "Trade", "Monarchy"
+init_government="Despotism"
+init_units=""
 wonder="Marco Polo's Embassy"
 government="Monarchy"
 
Index: data/nation/american.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/american.ruleset,v
retrieving revision 1.14
diff -u -r1.14 american.ruleset
--- data/nation/american.ruleset        29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/american.ruleset        2 May 2005 22:08:51 -0000
@@ -67,8 +67,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Trade", "Engineering", "Democracy",
-             "Railroad", "Explosives", "Automobile"
+init_government="Despotism"
+init_units=""
 wonder="Statue of Liberty"
 government="Democracy"
 civilwar_nations = "filipino"
Index: data/nation/arab.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/arab.ruleset,v
retrieving revision 1.10
diff -u -r1.10 arab.ruleset
--- data/nation/arab.ruleset    29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/arab.ruleset    2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals="Monarchy", "Philosophy", "Chivalry", "Trade", "Bridge Building",
-           "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Oracle"
 government="Monarchy"
 civilwar_nations = "turk", "persian"
Index: data/nation/argentine.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/argentine.ruleset,v
retrieving revision 1.14
diff -u -r1.14 argentine.ruleset
--- data/nation/argentine.ruleset       29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/argentine.ruleset       2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy", "The Republic", "Iron Working", "Trade", "Navigation",
-           "Railroad", "Steel", "Industrialization", "Democracy"
+init_government="Despotism"
+init_units=""
 wonder="J.S. Bach's Cathedral"
 government="Democracy"
 civilwar_nations = "chilean"
Index: data/nation/assyrian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/assyrian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 assyrian.ruleset
--- data/nation/assyrian.ruleset        29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/assyrian.ruleset        2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy","Trade","Mathematics","Chivalry","Iron Working",
-             "Theology","Monotheism","Code of Laws","Engineering","Astronomy"
+init_government="Despotism"
+init_units=""
 wonder="Great Library"
 government="Democracy"
 
Index: data/nation/australian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/australian.ruleset,v
retrieving revision 1.12
diff -u -r1.12 australian.ruleset
--- data/nation/australian.ruleset      29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/australian.ruleset      2 May 2005 22:08:51 -0000
@@ -18,8 +18,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Chivalry","Iron Working","Trade","Navigation",
-           "Railroad","Steel"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Democracy"
 
Index: data/nation/austrian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/austrian.ruleset,v
retrieving revision 1.4
diff -u -r1.4 austrian.ruleset
--- data/nation/austrian.ruleset        29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/austrian.ruleset        2 May 2005 22:08:51 -0000
@@ -11,8 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "The Republic", "Gunpowder", "Metallurgy",
-             "Plastics"
+init_government="Despotism"
+init_units=""
 wonder= "J.S. Bach's Cathedral"
 government = "Monarchy"
 
Index: data/nation/aztec.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/aztec.ruleset,v
retrieving revision 1.12
diff -u -r1.12 aztec.ruleset
--- data/nation/aztec.ruleset   29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/aztec.ruleset   2 May 2005 22:08:51 -0000
@@ -16,8 +16,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Chivalry", "Iron Working", "Trade",
-             "Navigation", "Railroad", "Communism"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Communism"
 civilwar_nations = "inca"
Index: data/nation/babylonian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/babylonian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 babylonian.ruleset
--- data/nation/babylonian.ruleset      29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/babylonian.ruleset      2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy","Philosophy","Mathematics","Chivalry",
-             "Theology","Monotheism"
+init_government="Despotism"
+init_units=""
 wonder="Hanging Gardens"
 government="Monarchy"
 civilwar_nations = "israeli", "persian", "arab"
Index: data/nation/barbarian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/barbarian.ruleset,v
retrieving revision 1.9
diff -u -r1.9 barbarian.ruleset
--- data/nation/barbarian.ruleset       29 Apr 2005 17:58:10 -0000      1.9
+++ data/nation/barbarian.ruleset       2 May 2005 22:08:51 -0000
@@ -11,7 +11,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Warrior Code"
+init_government="Despotism"
+init_units=""
 wonder = "Apollo Program"
 government = "Despotism"
 
Index: data/nation/bavarian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/bavarian.ruleset,v
retrieving revision 1.12
diff -u -r1.12 bavarian.ruleset
--- data/nation/bavarian.ruleset        29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/bavarian.ruleset        2 May 2005 22:08:51 -0000
@@ -14,8 +14,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Feudalism", "Gunpowder", "Railroad",
-             "Explosives"
+init_government="Despotism"
+init_units=""
 wonder= "Leonardo's Workshop"
 government = "Monarchy"
 civilwar_nations = "german"
Index: data/nation/belgian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/belgian.ruleset,v
retrieving revision 1.6
diff -u -r1.6 belgian.ruleset
--- data/nation/belgian.ruleset 29 Apr 2005 17:58:10 -0000      1.6
+++ data/nation/belgian.ruleset 2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Warrior Code", "Monarchy", "Democracy", "Gunpowder",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Cure for Cancer"
 government = "Monarchy"
 
Index: data/nation/boer.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/boer.ruleset,v
retrieving revision 1.13
diff -u -r1.13 boer.ruleset
--- data/nation/boer.ruleset    29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/boer.ruleset    2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Trade", "Engineering", "Gunpowder",
-            "Railroad", "Explosives"
+init_government="Despotism"
+init_units=""
 wonder= "Magellan's Expedition"
 government= "Communism"
 civilwar_nations = "dutch"
Index: data/nation/bosnia.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/bosnia.ruleset,v
retrieving revision 1.5
diff -u -r1.5 bosnia.ruleset
--- data/nation/bosnia.ruleset  29 Apr 2005 17:58:10 -0000      1.5
+++ data/nation/bosnia.ruleset  2 May 2005 22:08:51 -0000
@@ -24,8 +24,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="The Republic", "Navigation", "Iron Working", "Gunpowder",
-           "Explosives"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Republic"
 ciwilwar_nations="croatian", "serbian"
Index: data/nation/brazilian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/brazilian.ruleset,v
retrieving revision 1.15
diff -u -r1.15 brazilian.ruleset
--- data/nation/brazilian.ruleset       29 Apr 2005 17:58:10 -0000      1.15
+++ data/nation/brazilian.ruleset       2 May 2005 22:08:51 -0000
@@ -23,9 +23,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Ceremonial Burial", "Code of Laws", "Bridge Building",
-             "Flight", "Banking", "Conscription", "The Corporation",
-             "Labor Union"
+init_government="Despotism"
+init_units=""
 wonder="Marco Polo's Embassy"
 government="Republic"
 civilwar_nations = "chilean"
Index: data/nation/byzantium.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/byzantium.ruleset,v
retrieving revision 1.4
diff -u -r1.4 byzantium.ruleset
--- data/nation/byzantium.ruleset       29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/byzantium.ruleset       2 May 2005 22:08:51 -0000
@@ -23,8 +23,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Construction", "Engineering", "Chivalry",
-             "Code of Laws", "Seafaring", "Monotheism", "Economics"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Monarchy"
 civilwar_nations = "greek", "italian", "turk", "arab"
Index: data/nation/canadian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/canadian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 canadian.ruleset
--- data/nation/canadian.ruleset        29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/canadian.ruleset        2 May 2005 22:08:51 -0000
@@ -14,8 +14,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Trade", "Engineering", "Democracy",
-             "Railroad", "Explosives", "Automobile"
+init_government="Despotism"
+init_units=""
 wonder="Cure For Cancer"
 government="Democracy"
 civilwar_nations = "american"
Index: data/nation/carthaginian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/carthaginian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 carthaginian.ruleset
--- data/nation/carthaginian.ruleset    29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/carthaginian.ruleset    2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy", "Philosophy","Chivalry","Trade","Bridge Building",
-           "Navigation"
+init_government="Despotism"
+init_units=""
 wonder="Lighthouse"
 government="Monarchy"
 civilwar_nations = "roman"
Index: data/nation/catalan.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/catalan.ruleset,v
retrieving revision 1.14
diff -u -r1.14 catalan.ruleset
--- data/nation/catalan.ruleset 29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/catalan.ruleset 2 May 2005 22:08:51 -0000
@@ -23,8 +23,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Navigation", "Chivalry", "Trade",
-  "Monotheism", "Economics", "Leadership", "The Republic", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="A.Smith's Trading Co."
 government="Republic"
 civilwar_nations = "spanish", "portuguese"
Index: data/nation/chilean.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/chilean.ruleset,v
retrieving revision 1.16
diff -u -r1.16 chilean.ruleset
--- data/nation/chilean.ruleset 29 Apr 2005 17:58:10 -0000      1.16
+++ data/nation/chilean.ruleset 2 May 2005 22:08:51 -0000
@@ -24,8 +24,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Iron Working", "Trade", "Navigation", "The Republic",
-           "Railroad", "Steel", "Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Democracy"
 civilwar_nations = "argentine"
Index: data/nation/chinese.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/chinese.ruleset,v
retrieving revision 1.12
diff -u -r1.12 chinese.ruleset
--- data/nation/chinese.ruleset 29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/chinese.ruleset 2 May 2005 22:08:51 -0000
@@ -25,8 +25,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Trade", "Philosophy", "Bridge Building",
-             "Railroad", "Communism"
+init_government="Despotism"
+init_units=""
 wonder="Great Wall"
 government="Communism"
 civilwar_nations = "vietnamese", "japanese", "korean"
Index: data/nation/columbian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/columbian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 columbian.ruleset
--- data/nation/columbian.ruleset       29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/columbian.ruleset       2 May 2005 22:08:51 -0000
@@ -11,8 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Feudalism", "The Republic", "Gunpowder", "Explosives",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Statue of Liberty"
 government = "Democracy"
 
Index: data/nation/cornish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/cornish.ruleset,v
retrieving revision 1.11
diff -u -r1.11 cornish.ruleset
--- data/nation/cornish.ruleset 29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/cornish.ruleset 2 May 2005 22:08:51 -0000
@@ -14,7 +14,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Iron Working", "Feudalism", "Invention"
+init_government="Despotism"
+init_units=""
 wonder = "King Richard's Crusade"
 government = "Republic"
 civilwar_nations = "english", "irish"
Index: data/nation/croatian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/croatian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 croatian.ruleset
--- data/nation/croatian.ruleset        29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/croatian.ruleset        2 May 2005 22:08:51 -0000
@@ -28,8 +28,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="The Republic", "Trade", "Engineering", "Democracy",
-           "Railroad", "Explosives", "Automobile"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Republic"
 civilwar_nations = "slovenian"
Index: data/nation/czech.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/czech.ruleset,v
retrieving revision 1.11
diff -u -r1.11 czech.ruleset
--- data/nation/czech.ruleset   29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/czech.ruleset   2 May 2005 22:08:51 -0000
@@ -26,9 +26,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Iron Working", "Literacy", "Astronomy", "Bridge Building",
-             "The Republic", "Metallurgy", "Medicine", "University",
-             "Explosives"
+init_government="Despotism"
+init_units=""
 wonder = "Shakespeare's Theatre"
 government = "Republic"
 civilwar_nations = "croatian"
Index: data/nation/danish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/danish.ruleset,v
retrieving revision 1.18
diff -u -r1.18 danish.ruleset
--- data/nation/danish.ruleset  29 Apr 2005 17:58:10 -0000      1.18
+++ data/nation/danish.ruleset  2 May 2005 22:08:51 -0000
@@ -29,8 +29,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Chivalry", "Trade", "Theology", "University",
-             "Navigation", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Democracy"
 civilwar_nations = "english", "icelandic"
Index: data/nation/dunedain.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/dunedain.ruleset,v
retrieving revision 1.13
diff -u -r1.13 dunedain.ruleset
--- data/nation/dunedain.ruleset        29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/dunedain.ruleset        2 May 2005 22:08:51 -0000
@@ -22,7 +22,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Iron Working", "Feudalism", "Construction"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Monarchy"
 civilwar_nations = "mordor"
Index: data/nation/dutch.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/dutch.ruleset,v
retrieving revision 1.14
diff -u -r1.14 dutch.ruleset
--- data/nation/dutch.ruleset   29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/dutch.ruleset   2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Map Making", "The Republic", "Trade", "Navigation",
-  "Economics", "Democracy"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Democracy"
 civilwar_nations = "boer"
Index: data/nation/egyptian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/egyptian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 egyptian.ruleset
--- data/nation/egyptian.ruleset        29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/egyptian.ruleset        2 May 2005 22:08:51 -0000
@@ -22,8 +22,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Philosophy", "Navigation", "Iron Working",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Pyramids"
 government="Monarchy"
 civilwar_nations = "israeli"
Index: data/nation/elvish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/elvish.ruleset,v
retrieving revision 1.4
diff -u -r1.4 elvish.ruleset
--- data/nation/elvish.ruleset  29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/elvish.ruleset  2 May 2005 22:08:51 -0000
@@ -23,7 +23,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = ""
+init_government="Despotism"
+init_units=""
 
 ; Think of the Girdle of Melian, the Encircling Mountains around Rivendell, 
the rivers (Silverlode and Anduin) around Lothlorien, etc.
 wonder="Great Wall"
Index: data/nation/english.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/english.ruleset,v
retrieving revision 1.13
diff -u -r1.13 english.ruleset
--- data/nation/english.ruleset 29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/english.ruleset 2 May 2005 22:08:51 -0000
@@ -22,8 +22,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy",  "Chivalry", "Trade", "Theology", "Monotheism",
-             "Navigation", "Democracy", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="King Richard's Crusade"
 government="Democracy"
 civilwar_nations = "american", "australian", "canadian"
Index: data/nation/estonian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/estonian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 estonian.ruleset
--- data/nation/estonian.ruleset        29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/estonian.ruleset        2 May 2005 22:08:51 -0000
@@ -16,7 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy","Chivalry","The Republic","Democracy","Conscription"
+init_government="Despotism"
+init_units=""
 wonder="United Nations"
 government = "Democracy"
 civilwar_nations = "danish", "dutch"
Index: data/nation/ethiopian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/ethiopian.ruleset,v
retrieving revision 1.5
diff -u -r1.5 ethiopian.ruleset
--- data/nation/ethiopian.ruleset       29 Apr 2005 17:58:10 -0000      1.5
+++ data/nation/ethiopian.ruleset       2 May 2005 22:08:51 -0000
@@ -16,8 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Pottery", "Ceremonial Burial", "Mysticism",
-             "Trade"
+init_government="Despotism"
+init_units=""
 wonder="Hanging Gardens"
 government="Monarchy"
 
Index: data/nation/filipino.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/filipino.ruleset,v
retrieving revision 1.14
diff -u -r1.14 filipino.ruleset
--- data/nation/filipino.ruleset        29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/filipino.ruleset        2 May 2005 22:08:51 -0000
@@ -14,7 +14,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Gunpowder", "Democracy"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Communism"
 civilwar_nations = "japanese"
Index: data/nation/finnish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/finnish.ruleset,v
retrieving revision 1.12
diff -u -r1.12 finnish.ruleset
--- data/nation/finnish.ruleset 29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/finnish.ruleset 2 May 2005 22:08:51 -0000
@@ -22,9 +22,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Iron Working", "Literacy", "Engineering", "Map Making",
-             "The Republic", "Metallurgy", "Industrialization", "Electronics",
-             "Tactics"
+init_government="Despotism"
+init_units=""
 wonder="Women's Suffrage"
 government="Republic"
 civilwar_nations = "viking"
Index: data/nation/french.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/french.ruleset,v
retrieving revision 1.14
diff -u -r1.14 french.ruleset
--- data/nation/french.ruleset  29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/french.ruleset  2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Chivalry", "Philosophy", "The Republic",
-             "Monotheism", "Engineering", "Navigation", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Republic"
 civilwar_nations = "canadian"
Index: data/nation/galician.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/galician.ruleset,v
retrieving revision 1.4
diff -u -r1.4 galician.ruleset
--- data/nation/galician.ruleset        29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/galician.ruleset        2 May 2005 22:08:51 -0000
@@ -20,8 +20,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Iron Working", "Navigation", "Chivalry", "Trade",
-  "Monotheism", "The Republic"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Republic"
 
Index: data/nation/german.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/german.ruleset,v
retrieving revision 1.20
diff -u -r1.20 german.ruleset
--- data/nation/german.ruleset  29 Apr 2005 17:58:10 -0000      1.20
+++ data/nation/german.ruleset  2 May 2005 22:08:51 -0000
@@ -29,8 +29,8 @@
 init_techs = ""
 init_buildings=""
 
-tech_goals = "The Republic", "Iron Working", "Gunpowder", "Explosives",
-             "Flight"
+init_government="Despotism"
+init_units=""
 wonder     = "J.S. Bach's Cathedral"
 government = "Republic"
 civilwar_nations = "french", "italian"
Index: data/nation/greek.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/greek.ruleset,v
retrieving revision 1.13
diff -u -r1.13 greek.ruleset
--- data/nation/greek.ruleset   29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/greek.ruleset   2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Philosophy", "Trade", "Engineering",
-             "Iron Working", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Lighthouse"
 government="Republic"
 civilwar_nations = "egyptian", "persian"
Index: data/nation/hobbits.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/hobbits.ruleset,v
retrieving revision 1.5
diff -u -r1.5 hobbits.ruleset
--- data/nation/hobbits.ruleset 29 Apr 2005 17:58:10 -0000      1.5
+++ data/nation/hobbits.ruleset 2 May 2005 22:08:51 -0000
@@ -20,8 +20,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Map Making", "The Republic", "Trade", "Navigation",
-  "Economics", "Democracy"
+init_government="Despotism"
+init_units=""
 ; Hanging Gardens: as Samwise used his gift from Galadriel, all plants grew 
fast, and the first year was called 'the year of Plenty'
 wonder="Hanging Gardens"
 government="Monarchy"
Index: data/nation/hungarian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/hungarian.ruleset,v
retrieving revision 1.12
diff -u -r1.12 hungarian.ruleset
--- data/nation/hungarian.ruleset       29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/hungarian.ruleset       2 May 2005 22:08:51 -0000
@@ -13,8 +13,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "The Republic", "Iron Working", "Chivalry", "Theology",
-             "Gunpowder", "Railroad", "Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="J.S. Bach's Cathedral"
 government="Republic"
 civilwar_nations = "lithuanian", "croatian", "slovenian"
Index: data/nation/icelandic.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/icelandic.ruleset,v
retrieving revision 1.4
diff -u -r1.4 icelandic.ruleset
--- data/nation/icelandic.ruleset       29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/icelandic.ruleset       2 May 2005 22:08:51 -0000
@@ -19,7 +19,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Navigation", "Trade"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Republic"
 civilwar_nations = "danish", "english", "canadian"
Index: data/nation/inca.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/inca.ruleset,v
retrieving revision 1.12
diff -u -r1.12 inca.ruleset
--- data/nation/inca.ruleset    29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/inca.ruleset    2 May 2005 22:08:51 -0000
@@ -21,7 +21,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Chivalry","Philosophy","Monotheism", "Invention"
+init_government="Despotism"
+init_units=""
 wonder="Great Wall"
 government="Monarchy"
 civilwar_nations = "aztec"
Index: data/nation/indian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/indian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 indian.ruleset
--- data/nation/indian.ruleset  29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/indian.ruleset  2 May 2005 22:08:51 -0000
@@ -15,8 +15,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Philosophy", "The Republic", "Iron Working",
-             "Engineering", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Oracle"
 government="Republic"
 civilwar_nations = "arab"
Index: data/nation/indonesian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/indonesian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 indonesian.ruleset
--- data/nation/indonesian.ruleset      29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/indonesian.ruleset      2 May 2005 22:08:51 -0000
@@ -11,7 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Feudalism", "Navigation", "Flight", "Rocketry"
+init_government="Despotism"
+init_units=""
 wonder= "Magellan's Expedition"
 government = "Despotism"
 
Index: data/nation/irish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/irish.ruleset,v
retrieving revision 1.14
diff -u -r1.14 irish.ruleset
--- data/nation/irish.ruleset   29 Apr 2005 17:58:10 -0000      1.14
+++ data/nation/irish.ruleset   2 May 2005 22:08:51 -0000
@@ -42,8 +42,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Ceremonial Burial", "Literacy", "The Republic", "Engineering",
- "Monotheism", "Gunpowder", "Railroad", "Explosives", "Computers"
+init_government="Despotism"
+init_units=""
 wonder = "Marco Polo's Embassy"
 government = "Democracy"
 civilwar_nations = "cornish", "english", "scottish", "welsh"
Index: data/nation/israeli.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/israeli.ruleset,v
retrieving revision 1.11
diff -u -r1.11 israeli.ruleset
--- data/nation/israeli.ruleset 29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/israeli.ruleset 2 May 2005 22:08:51 -0000
@@ -19,8 +19,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Iron Working","Trade","Monotheism","Navigation",
-           "Railroad","Steel","Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="J.S. Bach's Cathedral"
 government="Democracy"
 civilwar_nations = "arab"
Index: data/nation/italian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/italian.ruleset,v
retrieving revision 1.12
diff -u -r1.12 italian.ruleset
--- data/nation/italian.ruleset 29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/italian.ruleset 2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "The Wheel", "Iron Working", "Construction",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder = "Leonardo's Workshop"
 government = "Republic"
 civilwar_nations = "kenyan"
Index: data/nation/japanese.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/japanese.ruleset,v
retrieving revision 1.13
diff -u -r1.13 japanese.ruleset
--- data/nation/japanese.ruleset        29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/japanese.ruleset        2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Philosophy", "The Republic", "Iron Working",
-             "Engineering", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Oracle"
 government="Republic"
 civilwar_nations = "korean", "filipino"
Index: data/nation/kampuchean.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/kampuchean.ruleset,v
retrieving revision 1.4
diff -u -r1.4 kampuchean.ruleset
--- data/nation/kampuchean.ruleset      29 Apr 2005 17:58:10 -0000      1.4
+++ data/nation/kampuchean.ruleset      2 May 2005 22:08:51 -0000
@@ -16,8 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Philosophy", "The Republic", "Iron Working",
-             "Engineering", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Oracle"
 government="Communism"
 
Index: data/nation/kenyan.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/kenyan.ruleset,v
retrieving revision 1.11
diff -u -r1.11 kenyan.ruleset
--- data/nation/kenyan.ruleset  29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/kenyan.ruleset  2 May 2005 22:08:51 -0000
@@ -10,7 +10,8 @@
 city_style = "Tropical"
 init_techs=""
 init_buildings=""
-tech_goals="Monarchy","Warrior Code","Iron Working","Navigation"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Republic"
 
Index: data/nation/korean.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/korean.ruleset,v
retrieving revision 1.11
diff -u -r1.11 korean.ruleset
--- data/nation/korean.ruleset  29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/korean.ruleset  2 May 2005 22:08:51 -0000
@@ -12,8 +12,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Iron Working","Philosophy","Invention","Gunpowder",
-           "Railroad","Steel"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Democracy"
 civilwar_nations = "japanese"
Index: data/nation/latvian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/latvian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 latvian.ruleset
--- data/nation/latvian.ruleset 29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/latvian.ruleset 2 May 2005 22:08:51 -0000
@@ -13,7 +13,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy","Chivalry","Gunpowder","Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="Cure For Cancer"
 government = "Democracy"
 civilwar_nations = "polish", "swedish"
Index: data/nation/lithuanian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/lithuanian.ruleset,v
retrieving revision 1.11
diff -u -r1.11 lithuanian.ruleset
--- data/nation/lithuanian.ruleset      29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/lithuanian.ruleset      2 May 2005 22:08:51 -0000
@@ -17,7 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy","Chivalry","The Republic","Railroad","Explosives"
+init_government="Despotism"
+init_units=""
 wonder="Copernicus' Observatory"
 government = "Republic"
 civilwar_nations = "polish", "danish"
Index: data/nation/malaysian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/malaysian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 malaysian.ruleset
--- data/nation/malaysian.ruleset       29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/malaysian.ruleset       2 May 2005 22:08:51 -0000
@@ -11,8 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Warrior Code", "The Republic", "Navigation", "Railroad",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Magellan's Expedition"
 government = "The Republic"
 
Index: data/nation/martian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/martian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 martian.ruleset
--- data/nation/martian.ruleset 29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/martian.ruleset 2 May 2005 22:08:51 -0000
@@ -12,7 +12,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "RailRoad", "Space Travel"
+init_government="Despotism"
+init_units=""
 wonder="Apollo Program"
 government="Communism"
 
Index: data/nation/mexican.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/mexican.ruleset,v
retrieving revision 1.3
diff -u -r1.3 mexican.ruleset
--- data/nation/mexican.ruleset 29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/mexican.ruleset 2 May 2005 22:08:51 -0000
@@ -11,8 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Warrior Code", "The Republic", "Gunpowder", "Explosives",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Statue of Liberty"
 government = "The Republic"
 
Index: data/nation/mongol.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/mongol.ruleset,v
retrieving revision 1.11
diff -u -r1.11 mongol.ruleset
--- data/nation/mongol.ruleset  29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/mongol.ruleset  2 May 2005 22:08:51 -0000
@@ -20,8 +20,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy",  "Chivalry", "Trade", "Bridge Building",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Monarchy"
 civilwar_nations = "chinese", "russian"
Index: data/nation/mordor.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/mordor.ruleset,v
retrieving revision 1.11
diff -u -r1.11 mordor.ruleset
--- data/nation/mordor.ruleset  29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/mordor.ruleset  2 May 2005 22:08:51 -0000
@@ -18,7 +18,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Bronze Working", "Iron Working", "Construction"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Monarchy"
 civilwar_nations = "dunedain"
Index: data/nation/newzealand.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/newzealand.ruleset,v
retrieving revision 1.2
diff -u -r1.2 newzealand.ruleset
--- data/nation/newzealand.ruleset      29 Apr 2005 17:58:10 -0000      1.2
+++ data/nation/newzealand.ruleset      2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 init_buildings=""
 
 
-tech_goals = "The Republic", "Navigation", "Metallurgy", "Steam Engine",
-             "Railroad", "Tactics", "Steel"
+init_government="Despotism"
+init_units=""
 wonder="Women's Suffrage"
 government="Republic"
 
Index: data/nation/nigerian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/nigerian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 nigerian.ruleset
--- data/nation/nigerian.ruleset        29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/nigerian.ruleset        2 May 2005 22:08:51 -0000
@@ -11,7 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Warrior Code", "Feudalism", "Gunpowder", "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Statue of Liberty"
 government = "Despotism"
 
Index: data/nation/observer.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/observer.ruleset,v
retrieving revision 1.2
diff -u -r1.2 observer.ruleset
--- data/nation/observer.ruleset        29 Apr 2005 17:58:10 -0000      1.2
+++ data/nation/observer.ruleset        2 May 2005 22:08:51 -0000
@@ -11,7 +11,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = ""
+init_government="Despotism"
+init_units=""
 wonder = ""
 government = "Anarchy"
 
Index: data/nation/persian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/persian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 persian.ruleset
--- data/nation/persian.ruleset 29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/persian.ruleset 2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Polytheism", "Philosophy", "Trade", "Engineering",
-             "Iron Working", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Hanging Gardens"
 government="Monarchy"
 civilwar_nations = "babylonian", "arab"
Index: data/nation/phoenician.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/phoenician.ruleset,v
retrieving revision 1.3
diff -u -r1.3 phoenician.ruleset
--- data/nation/phoenician.ruleset      29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/phoenician.ruleset      2 May 2005 22:08:51 -0000
@@ -19,7 +19,8 @@
 advisors=100,100,100,100,100,100,100
 init_techs=""
 
-tech_goals = "Alphabet", "Trade", "Seafaring", "Navigation"
+init_government="Despotism"
+init_units=""
 
 init_techs=""
 init_buildings=""
Index: data/nation/polish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/polish.ruleset,v
retrieving revision 1.20
diff -u -r1.20 polish.ruleset
--- data/nation/polish.ruleset  29 Apr 2005 17:58:10 -0000      1.20
+++ data/nation/polish.ruleset  2 May 2005 22:08:51 -0000
@@ -31,12 +31,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic",
-             "Trade",
-             "Engineering",
-             "Monotheism",
-             "Gunpowder",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Copernicus' Observatory"
 government="Democracy"
 civilwar_nations = "lithuanian", "silesian", "ukrainian"
Index: data/nation/portuguese.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/portuguese.ruleset,v
retrieving revision 1.13
diff -u -r1.13 portuguese.ruleset
--- data/nation/portuguese.ruleset      29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/portuguese.ruleset      2 May 2005 22:08:51 -0000
@@ -20,8 +20,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Iron Working", "Navigation", "Trade",
-            "The Republic", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Republic"
 civilwar_nations = "brazilian"
Index: data/nation/quebecois.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/quebecois.ruleset,v
retrieving revision 1.3
diff -u -r1.3 quebecois.ruleset
--- data/nation/quebecois.ruleset       29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/quebecois.ruleset       2 May 2005 22:08:51 -0000
@@ -17,8 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy","Trade","Mathematics","Chivalry","Iron Working",
-             "Theology","Invention","Code of Laws","Engineering","Astronomy"
+init_government="Despotism"
+init_units=""
 wonder="Great Library"
 government="Democracy"
 
Index: data/nation/roman.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/roman.ruleset,v
retrieving revision 1.15
diff -u -r1.15 roman.ruleset
--- data/nation/roman.ruleset   29 Apr 2005 17:58:10 -0000      1.15
+++ data/nation/roman.ruleset   2 May 2005 22:08:51 -0000
@@ -22,8 +22,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "The Wheel", "Iron Working", "Construction",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Leonardo's Workshop"
 government="Republic"
 civilwar_nations = "italian", "spanish", "french"
Index: data/nation/russian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/russian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 russian.ruleset
--- data/nation/russian.ruleset 29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/russian.ruleset 2 May 2005 22:08:51 -0000
@@ -19,8 +19,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Philosophy", "Chivalry", "Trade",
-             "Bridge Building", "Railroad", "Communism"
+init_government="Despotism"
+init_units=""
 wonder="Women's Suffrage"
 government="Communism"
 civilwar_nations = "ukrainian", "polish"
Index: data/nation/scottish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/scottish.ruleset,v
retrieving revision 1.17
diff -u -r1.17 scottish.ruleset
--- data/nation/scottish.ruleset        29 Apr 2005 17:58:10 -0000      1.17
+++ data/nation/scottish.ruleset        2 May 2005 22:08:51 -0000
@@ -21,8 +21,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Iron Working","Trade","Navigation","Railroad","Steel",
-           "Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Democracy"
 civilwar_nations = "welsh"
Index: data/nation/serbian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/serbian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 serbian.ruleset
--- data/nation/serbian.ruleset 29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/serbian.ruleset 2 May 2005 22:08:51 -0000
@@ -25,8 +25,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="The Republic", "The Wheel", "Iron Working", "Construction",
-           "Railroad", "Automobile"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Monarchy"
 civilwar_nations = "slovenian"
Index: data/nation/silesian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/silesian.ruleset,v
retrieving revision 1.16
diff -u -r1.16 silesian.ruleset
--- data/nation/silesian.ruleset        29 Apr 2005 17:58:10 -0000      1.16
+++ data/nation/silesian.ruleset        2 May 2005 22:08:51 -0000
@@ -24,7 +24,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="The Republic", "Trade", "Feudalism", "Railroad", "Steel"
+init_government="Despotism"
+init_units=""
 wonder="Great Wall" ; Yes, we had own great wall ("WaÅ?y Å?lÄ?skie") 
 government="Democracy"
 civilwar_nations = "polish"
Index: data/nation/singaporean.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/singaporean.ruleset,v
retrieving revision 1.10
diff -u -r1.10 singaporean.ruleset
--- data/nation/singaporean.ruleset     29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/singaporean.ruleset     2 May 2005 22:08:52 -0000
@@ -35,8 +35,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Iron Working", "Trade", "Monotheism", "Navigation",
-  "Railroad", "Steel", "Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="J.S. Bach's Cathedral"
 government="Republic"
 
Index: data/nation/sioux.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/sioux.ruleset,v
retrieving revision 1.11
diff -u -r1.11 sioux.ruleset
--- data/nation/sioux.ruleset   29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/sioux.ruleset   2 May 2005 22:08:52 -0000
@@ -16,7 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Philosophy", "The Republic", "Iron Working"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Republic"
 civilwar_nations = "american"
Index: data/nation/slovakian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/slovakian.ruleset,v
retrieving revision 1.2
diff -u -r1.2 slovakian.ruleset
--- data/nation/slovakian.ruleset       29 Apr 2005 17:58:10 -0000      1.2
+++ data/nation/slovakian.ruleset       2 May 2005 22:08:52 -0000
@@ -25,8 +25,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Iron Working", "Gunpowder", "Explosives",
-             "Flight"
+init_government="Despotism"
+init_units=""
 wonder= "Leonardo's Workshop"
 government="Democracy"
 civilwar_nations="hungarian"
Index: data/nation/slovenian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/slovenian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 slovenian.ruleset
--- data/nation/slovenian.ruleset       29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/slovenian.ruleset       2 May 2005 22:08:52 -0000
@@ -19,8 +19,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="The Republic", "Trade", "Engineering", "Democracy",
-           "Railroad", "Explosives", "Automobile"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Democracy"
 civilwar_nations = "serbian"
Index: data/nation/spanish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/spanish.ruleset,v
retrieving revision 1.13
diff -u -r1.13 spanish.ruleset
--- data/nation/spanish.ruleset 29 Apr 2005 17:58:10 -0000      1.13
+++ data/nation/spanish.ruleset 2 May 2005 22:08:52 -0000
@@ -23,8 +23,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Monarchy", "Philosophy", "Navigation", "Iron Working",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Democracy"
 civilwar_nations = "chilean", "argentine"
Index: data/nation/sumerian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/sumerian.ruleset,v
retrieving revision 1.3
diff -u -r1.3 sumerian.ruleset
--- data/nation/sumerian.ruleset        29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/sumerian.ruleset        2 May 2005 22:08:52 -0000
@@ -16,8 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Bronze Working","Writing","Trade","Astronomy",
-             "Theology","Code of Laws","Economics","Communism"
+init_government="Despotism"
+init_units=""
 wonder="A.Smith's Trading Co."
 government="Communism"
 
Index: data/nation/swedish.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/swedish.ruleset,v
retrieving revision 1.17
diff -u -r1.17 swedish.ruleset
--- data/nation/swedish.ruleset 29 Apr 2005 17:58:10 -0000      1.17
+++ data/nation/swedish.ruleset 2 May 2005 22:08:52 -0000
@@ -19,7 +19,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Map Making", "The Republic", "Trade", "Gunpowder"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Democracy"
 civilwar_nations = "viking"
Index: data/nation/swiss.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/swiss.ruleset,v
retrieving revision 1.6
diff -u -r1.6 swiss.ruleset
--- data/nation/swiss.ruleset   29 Apr 2005 17:58:10 -0000      1.6
+++ data/nation/swiss.ruleset   2 May 2005 22:08:52 -0000
@@ -15,8 +15,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Democracy", "Iron Working", "Trade", "Engineering",
-             "Railroad", "Bridge Building", "Banking"
+init_government="Despotism"
+init_units=""
 wonder="United Nations"
 government="Democracy"
 
Index: data/nation/taiwanese.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/taiwanese.ruleset,v
retrieving revision 1.5
diff -u -r1.5 taiwanese.ruleset
--- data/nation/taiwanese.ruleset       29 Apr 2005 17:58:10 -0000      1.5
+++ data/nation/taiwanese.ruleset       2 May 2005 22:08:52 -0000
@@ -11,8 +11,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Feudalism", "The Republic", "Democracy", "Explosives",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Marco Polo's Embassy"
 government = "Democracy"
 
Index: data/nation/thai.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/thai.ruleset,v
retrieving revision 1.12
diff -u -r1.12 thai.ruleset
--- data/nation/thai.ruleset    29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/thai.ruleset    2 May 2005 22:08:52 -0000
@@ -16,8 +16,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "The Republic", "Engineering", "Invention", "Railroad",
-             "Explosives"
+init_government="Despotism"
+init_units=""
 wonder= "Marco Polo's Embassy"
 government = "Democracy"
 civilwar_nations = "vietnamese"
Index: data/nation/turk.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/turk.ruleset,v
retrieving revision 1.12
diff -u -r1.12 turk.ruleset
--- data/nation/turk.ruleset    29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/turk.ruleset    2 May 2005 22:08:52 -0000
@@ -22,8 +22,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Philosophy", "Mathematics", "Chivalry",
-             "Theology", "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Republic"
 civilwar_nations = "slovenian", "czech"
Index: data/nation/ukrainian.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/ukrainian.ruleset,v
retrieving revision 1.10
diff -u -r1.10 ukrainian.ruleset
--- data/nation/ukrainian.ruleset       29 Apr 2005 17:58:10 -0000      1.10
+++ data/nation/ukrainian.ruleset       2 May 2005 22:08:52 -0000
@@ -17,7 +17,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Chivalry","The Republic","Gunpowder","Leadership","Explosives"
+init_government="Despotism"
+init_units=""
 wonder="Sun Tzu's War Academy"
 government="Communism"
 civilwar_nations = "polish"
Index: data/nation/venezuelan.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/venezuelan.ruleset,v
retrieving revision 1.3
diff -u -r1.3 venezuelan.ruleset
--- data/nation/venezuelan.ruleset      29 Apr 2005 17:58:10 -0000      1.3
+++ data/nation/venezuelan.ruleset      2 May 2005 22:08:52 -0000
@@ -22,10 +22,8 @@
                }
 init_techs=""
 init_buildings=""
-tech_goals = "Code of Laws", "Iron Working", "The Wheel", "Monarchy",
-             "Literacy", "The Republic", "Gunpowder", "Leadership",
-            "Conscription", "Tactics", "Amphibious Warfare", "Magnetism",
-             "Mobile Warfare", "Combined Arms", "Rocketry"
+init_government="Despotism"
+init_units=""
 wonder="A.Smith's Trading Co."
 government=""
 cities =
Index: data/nation/vietnamese.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/vietnamese.ruleset,v
retrieving revision 1.9
diff -u -r1.9 vietnamese.ruleset
--- data/nation/vietnamese.ruleset      29 Apr 2005 17:58:10 -0000      1.9
+++ data/nation/vietnamese.ruleset      2 May 2005 22:08:52 -0000
@@ -14,8 +14,8 @@
 
 init_techs=""
 init_buildings=""
-tech_goals = "Feudalism", "The Republic", "Gunpowder", "Explosives",
-             "Guerilla Warfare"
+init_government="Despotism"
+init_units=""
 wonder= "Great Wall"
 government = "Communism"
 
Index: data/nation/viking.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/viking.ruleset,v
retrieving revision 1.17
diff -u -r1.17 viking.ruleset
--- data/nation/viking.ruleset  29 Apr 2005 17:58:10 -0000      1.17
+++ data/nation/viking.ruleset  2 May 2005 22:08:52 -0000
@@ -35,8 +35,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "The Republic", "The Wheel", "Iron Working", "Construction",
-             "Railroad"
+init_government="Despotism"
+init_units=""
 wonder="Magellan's Expedition"
 government="Republic"
 civilwar_nations = "swedish", "finnish", "icelandic"
Index: data/nation/welsh.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/welsh.ruleset,v
retrieving revision 1.11
diff -u -r1.11 welsh.ruleset
--- data/nation/welsh.ruleset   29 Apr 2005 17:58:10 -0000      1.11
+++ data/nation/welsh.ruleset   2 May 2005 22:08:52 -0000
@@ -25,8 +25,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals="Monarchy","Iron Working","Trade","Navigation","Railroad","Steel",
-           "Industrialization"
+init_government="Despotism"
+init_units=""
 wonder="Hoover Dam"
 government="Democracy"
 civilwar_nations = "scottish"
Index: data/nation/zulu.ruleset
===================================================================
RCS file: /home/freeciv/CVS/freeciv/data/nation/zulu.ruleset,v
retrieving revision 1.12
diff -u -r1.12 zulu.ruleset
--- data/nation/zulu.ruleset    29 Apr 2005 17:58:10 -0000      1.12
+++ data/nation/zulu.ruleset    2 May 2005 22:08:52 -0000
@@ -27,8 +27,8 @@
 init_techs=""
 init_buildings=""
 
-tech_goals = "Monarchy", "Philosophy", "Chivalry", "Trade", "Bridge Building",
-             "Railroad", "Communism"
+init_government="Despotism"
+init_units=""
 wonder="Apollo Program"
 government="Communism"
 
Index: server/barbarian.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/barbarian.c,v
retrieving revision 1.88
diff -u -r1.88 barbarian.c
--- server/barbarian.c  29 Apr 2005 17:41:17 -0000      1.88
+++ server/barbarian.c  2 May 2005 22:08:52 -0000
@@ -115,7 +115,7 @@
 
   /* make a new player */
 
-  server_player_init(barbarians, TRUE);
+  create_player_ingame(barbarians);
 
   barbarians->nation = game.nation_count - 1;
   pick_ai_player_name(game.nation_count - 1, barbarians->name);
Index: server/plrhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/plrhand.c,v
retrieving revision 1.370
diff -u -r1.370 plrhand.c
--- server/plrhand.c    1 May 2005 16:18:14 -0000       1.370
+++ server/plrhand.c    2 May 2005 22:08:53 -0000
@@ -1643,19 +1643,28 @@
 }
 
 /********************************************************************** 
-The initmap option is used because we don't want to initialize the map
-before the x and y sizes have been determined
+  Create a new player, without setting stuff that gets set anyway
+  on game start.
 ***********************************************************************/
-void server_player_init(struct player *pplayer, bool initmap)
+void server_player_init(struct player *pplayer)
 {
-  if (initmap) {
-    player_map_allocate(pplayer);
-  }
-  pplayer->player_no = pplayer-game.players;
+  pplayer->player_no = pplayer - game.players; /* count pointer refs */
   ai_data_init(pplayer);
 }
 
 /********************************************************************** 
+  Create a player during the game.
+***********************************************************************/
+void create_player_ingame(struct player *pplayer)
+{
+  struct nation_type *pnation = get_nation_by_plr(pplayer);
+
+  server_player_init(pplayer);
+  pplayer->government = pnation->init_government;
+  player_map_allocate(pplayer);
+}
+
+/********************************************************************** 
  This function does _not_ close any connections attached to this player.
  cut_connection is used for that.
 ***********************************************************************/
@@ -1930,13 +1939,15 @@
   /* alright, we can create an observer. go for it. */
   pplayer = &game.players[game.nplayers];
 
-  /* only allocate a player map is the game is running or a game is loaded
+  /* only allocate a player map if the game is running or a game is loaded
    * in pregame. This is because a game map might not be created otherwise.
    *
    * FIXME: could we use map_is_empty here? */
-  server_player_init(pplayer,
-                     (server_state == RUN_GAME_STATE || !game.is_new_game));
-
+  if (server_state == RUN_GAME_STATE || !game.is_new_game) {
+    create_player_ingame(pplayer);
+  } else {
+    server_player_init(pplayer);
+  }
   sz_strlcpy(pplayer->name, OBSERVER_NAME);
   sz_strlcpy(pplayer->username, ANON_USER_NAME);
   pplayer->is_connected = FALSE;
@@ -1980,11 +1991,11 @@
   Nation_type_id *civilwar_nations = get_nation_civilwar(pplayer->nation);
 
   /* make a new player */
-  server_player_init(cplayer, TRUE);
+  cplayer->nation = pick_available_nation(civilwar_nations);
+  create_player_ingame(cplayer);
 
   /* select a new name and nation for the copied player. */
   /* Rebel will always be an AI player */
-  cplayer->nation = pick_available_nation(civilwar_nations);
   pick_ai_player_name(cplayer->nation, cplayer->name);
 
   sz_strlcpy(cplayer->username, ANON_USER_NAME);
Index: server/plrhand.h
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/plrhand.h,v
retrieving revision 1.71
diff -u -r1.71 plrhand.h
--- server/plrhand.h    1 May 2005 04:57:45 -0000       1.71
+++ server/plrhand.h    2 May 2005 22:08:53 -0000
@@ -29,7 +29,8 @@
 
 enum plr_info_level { INFO_MINIMUM, INFO_MEETING, INFO_EMBASSY, INFO_FULL };
 
-void server_player_init(struct player *pplayer, bool initmap);
+void server_player_init(struct player *pplayer);
+void create_player_ingame(struct player *pplayer);
 void server_remove_player(struct player *pplayer);
 void kill_player(struct player *pplayer);
 void kill_dying_players(void);
Index: server/ruleset.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/ruleset.c,v
retrieving revision 1.250
diff -u -r1.250 ruleset.c
--- server/ruleset.c    1 May 2005 12:01:15 -0000       1.250
+++ server/ruleset.c    2 May 2005 22:08:54 -0000
@@ -1654,9 +1654,6 @@
 
   sec = secfile_get_secnames_prefix(file, "government_", &nval);
 
-  game.default_government
-    = lookup_government(file, "governments.default", filename);
-  
   game.government_when_anarchy
     = lookup_government(file, "governments.when_anarchy", filename);
 
@@ -1819,7 +1816,6 @@
 
   packet.government_count = game.government_count;
   packet.government_when_anarchy = game.government_when_anarchy;
-  packet.default_government = game.default_government;
 
   packet.num_unit_types = game.num_unit_types;
   packet.num_impr_types = game.num_impr_types;
@@ -2086,8 +2082,9 @@
 
   sec = secfile_get_secnames_prefix(file, "nation", &nval);
 
-  for( i=0; i<game.nation_count; i++) {
+  for (i = 0; i < game.nation_count; i++) {
     pl = get_nation_by_idx(i);
+    char tmp[200] = "\0";
     
     groups = secfile_lookup_str_vec(file, &dim, "%s.groups", sec[i]);
     pl->num_groups = dim;
@@ -2248,6 +2245,9 @@
                         filename);
     lookup_unit_list(file, sec[i], "init_units", pl->init_units, filename,
                      FALSE);
+    mystrlcat(tmp, sec[i], 200);
+    mystrlcat(tmp, ".init_government", 200);
+    pl->init_government = lookup_government(file, tmp, filename);
 
     /* read "normal" city names */
 
@@ -2986,6 +2986,11 @@
     }
     packet.city_style = n->city_style;
     memcpy(packet.init_techs, n->init_techs, sizeof(packet.init_techs));
+    memcpy(packet.init_buildings, n->init_buildings, 
+           sizeof(packet.init_buildings));
+    memcpy(packet.init_units, n->init_units, 
+           sizeof(packet.init_units));
+    packet.init_government = n->init_government;
 
     sz_strlcpy(packet.legend, n->legend);
 
Index: server/savegame.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/savegame.c,v
retrieving revision 1.239
diff -u -r1.239 savegame.c
--- server/savegame.c   1 May 2005 16:18:14 -0000       1.239
+++ server/savegame.c   2 May 2005 22:08:55 -0000
@@ -1661,7 +1661,7 @@
   int id;
   int target_no;
 
-  server_player_init(plr, TRUE);
+  create_player_ingame(plr);
   ai = ai_data_get(plr);
 
   plr->ai.barbarian_type = secfile_lookup_int_default(file, 0, 
"player%d.ai.is_barbarian",
Index: server/srv_main.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/srv_main.c,v
retrieving revision 1.251
diff -u -r1.251 srv_main.c
--- server/srv_main.c   1 May 2005 16:18:14 -0000       1.251
+++ server/srv_main.c   2 May 2005 22:08:56 -0000
@@ -1709,25 +1709,23 @@
 }
 
 /**************************************************************************
-  Server loop, run to set up one game.
+  Apply some final adjustments from the ruleset on to the game state.
+  We cannot do this during ruleset loading, since some players may be
+  added later than that.
 **************************************************************************/
 static void final_ruleset_adjustments()
 {
-  int i;
+  players_iterate(pplayer) {
+    struct nation_type *pnation = get_nation_by_plr(pplayer);
 
-  for (i = 0; i < MAX_NUM_PLAYERS + MAX_NUM_BARBARIANS; i++) {
-    if (game.players[i].government == G_MAGIC) {
-      game.players[i].government = game.default_government;
-    }
-  }
+    pplayer->government = pnation->init_government;
 
-  if (game.default_government == game.government_when_anarchy) {
-    players_iterate(pplayer) {
+    if (pnation->init_government == game.government_when_anarchy) {
       /* If we do not do this, an assert will trigger. This enables us to
        * select a valid government on game start. */
       pplayer->revolution_finishes = 0;
-    } players_iterate_end;
-  }
+    }
+  } players_iterate_end;
 }
 
 /**************************************************************************
Index: server/stdinhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/stdinhand.c,v
retrieving revision 1.402
diff -u -r1.402 stdinhand.c
--- server/stdinhand.c  1 May 2005 13:59:21 -0000       1.402
+++ server/stdinhand.c  2 May 2005 22:08:57 -0000
@@ -906,7 +906,7 @@
   }
 
   pplayer = &game.players[game.nplayers];
-  server_player_init(pplayer, FALSE);
+  server_player_init(pplayer);
   sz_strlcpy(pplayer->name, arg);
   sz_strlcpy(pplayer->username, ANON_USER_NAME);
   pplayer->was_created = TRUE; /* must use /remove explicitly to remove */

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