dw_fluffos_v2/
dw_fluffos_v2/fluffos-2.9-ds2.05/
dw_fluffos_v2/fluffos-2.9-ds2.05/ChangeLog.old/
dw_fluffos_v2/fluffos-2.9-ds2.05/Win32/
dw_fluffos_v2/fluffos-2.9-ds2.05/compat/
dw_fluffos_v2/fluffos-2.9-ds2.05/compat/simuls/
dw_fluffos_v2/fluffos-2.9-ds2.05/include/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/clone/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/command/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/data/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/etc/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/include/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/inherit/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/inherit/master/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/log/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/single/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/single/tests/compiler/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/single/tests/efuns/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/single/tests/operators/
dw_fluffos_v2/fluffos-2.9-ds2.05/testsuite/u/
dw_fluffos_v2/fluffos-2.9-ds2.05/tmp/
dw_fluffos_v2/fluffos-2.9-ds2.05/windows/
dw_fluffos_v2/lib/
dw_fluffos_v2/lib/binaries/cmds/
dw_fluffos_v2/lib/binaries/cmds/creator/
dw_fluffos_v2/lib/binaries/cmds/living/
dw_fluffos_v2/lib/binaries/cmds/player/
dw_fluffos_v2/lib/binaries/d/admin/obj/
dw_fluffos_v2/lib/binaries/d/liaison/
dw_fluffos_v2/lib/binaries/global/virtual/
dw_fluffos_v2/lib/binaries/global/virtual/setup_compiler/
dw_fluffos_v2/lib/binaries/obj/handlers/autodoc/
dw_fluffos_v2/lib/binaries/obj/handlers/terrain_things/
dw_fluffos_v2/lib/binaries/obj/misc/
dw_fluffos_v2/lib/binaries/obj/misc/buckets/
dw_fluffos_v2/lib/binaries/obj/monster/
dw_fluffos_v2/lib/binaries/obj/reactions/
dw_fluffos_v2/lib/binaries/obj/reagents/
dw_fluffos_v2/lib/binaries/secure/cmds/creator/
dw_fluffos_v2/lib/binaries/secure/master/
dw_fluffos_v2/lib/binaries/std/
dw_fluffos_v2/lib/binaries/std/dom/
dw_fluffos_v2/lib/binaries/std/effects/object/
dw_fluffos_v2/lib/binaries/std/guilds/
dw_fluffos_v2/lib/binaries/std/languages/
dw_fluffos_v2/lib/binaries/std/races/
dw_fluffos_v2/lib/binaries/std/room/
dw_fluffos_v2/lib/binaries/std/room/basic/
dw_fluffos_v2/lib/binaries/std/shops/
dw_fluffos_v2/lib/binaries/std/shops/inherit/
dw_fluffos_v2/lib/binaries/www/
dw_fluffos_v2/lib/cmds/guild-race/
dw_fluffos_v2/lib/cmds/guild-race/crafts/
dw_fluffos_v2/lib/cmds/guild-race/other/
dw_fluffos_v2/lib/cmds/playtester/
dw_fluffos_v2/lib/cmds/playtester/senior/
dw_fluffos_v2/lib/d/admin/
dw_fluffos_v2/lib/d/admin/log/
dw_fluffos_v2/lib/d/admin/mapper/31-10-01/mapmaker/event/
dw_fluffos_v2/lib/d/admin/meetings/
dw_fluffos_v2/lib/d/admin/obj/
dw_fluffos_v2/lib/d/admin/room/we_care/
dw_fluffos_v2/lib/d/admin/save/
dw_fluffos_v2/lib/d/dist/
dw_fluffos_v2/lib/d/dist/mtf/
dw_fluffos_v2/lib/d/dist/pumpkin/
dw_fluffos_v2/lib/d/dist/pumpkin/chars/
dw_fluffos_v2/lib/d/dist/pumpkin/desert/
dw_fluffos_v2/lib/d/dist/pumpkin/gumboot/
dw_fluffos_v2/lib/d/dist/pumpkin/hospital/
dw_fluffos_v2/lib/d/dist/pumpkin/inherit/
dw_fluffos_v2/lib/d/dist/pumpkin/map/
dw_fluffos_v2/lib/d/dist/pumpkin/plain/
dw_fluffos_v2/lib/d/dist/pumpkin/pumpkin/
dw_fluffos_v2/lib/d/dist/pumpkin/save/
dw_fluffos_v2/lib/d/dist/pumpkin/squash/
dw_fluffos_v2/lib/d/dist/pumpkin/terrain/
dw_fluffos_v2/lib/d/dist/pumpkin/woods/
dw_fluffos_v2/lib/d/dist/start/
dw_fluffos_v2/lib/d/learning/TinyTown/buildings/
dw_fluffos_v2/lib/d/learning/TinyTown/map/
dw_fluffos_v2/lib/d/learning/TinyTown/roads/
dw_fluffos_v2/lib/d/learning/add_command/
dw_fluffos_v2/lib/d/learning/arms_and_weps/
dw_fluffos_v2/lib/d/learning/chars/
dw_fluffos_v2/lib/d/learning/cutnpaste/
dw_fluffos_v2/lib/d/learning/examples/npcs/
dw_fluffos_v2/lib/d/learning/examples/player_houses/npcs/
dw_fluffos_v2/lib/d/learning/examples/terrain_map/basic/
dw_fluffos_v2/lib/d/learning/functions/
dw_fluffos_v2/lib/d/learning/handlers/
dw_fluffos_v2/lib/d/learning/help_topics/npcs/
dw_fluffos_v2/lib/d/learning/help_topics/objects/
dw_fluffos_v2/lib/d/learning/help_topics/rcs_demo/
dw_fluffos_v2/lib/d/learning/help_topics/rooms/
dw_fluffos_v2/lib/d/learning/help_topics/rooms/crowd/
dw_fluffos_v2/lib/d/learning/help_topics/rooms/situations/
dw_fluffos_v2/lib/d/learning/items/
dw_fluffos_v2/lib/d/learning/save/
dw_fluffos_v2/lib/d/liaison/
dw_fluffos_v2/lib/d/liaison/NEWBIE/doc/
dw_fluffos_v2/lib/d/liaison/NEWBIE/save/oldlog/
dw_fluffos_v2/lib/db/
dw_fluffos_v2/lib/doc/
dw_fluffos_v2/lib/doc/creator/
dw_fluffos_v2/lib/doc/creator/autodoc/include/reaction/
dw_fluffos_v2/lib/doc/creator/autodoc/include/ritual_system/
dw_fluffos_v2/lib/doc/creator/autodoc/include/talker/
dw_fluffos_v2/lib/doc/creator/autodoc/include/terrain_map/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/baggage/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/clock/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/clothing/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/cont_save/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/corpse/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/money/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/monster/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/scabbard/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/service_provider/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/state_changer/
dw_fluffos_v2/lib/doc/creator/autodoc/obj/wand/
dw_fluffos_v2/lib/doc/creator/autodoc/std/book_dir/
dw_fluffos_v2/lib/doc/creator/autodoc/std/key/
dw_fluffos_v2/lib/doc/creator/autodoc/std/learning/
dw_fluffos_v2/lib/doc/creator/autodoc/std/map/
dw_fluffos_v2/lib/doc/creator/autodoc/std/race/
dw_fluffos_v2/lib/doc/creator/autodoc/std/weapon_logic/
dw_fluffos_v2/lib/doc/creator/files/
dw_fluffos_v2/lib/doc/creator/policy/
dw_fluffos_v2/lib/doc/creator/room/
dw_fluffos_v2/lib/doc/effects/
dw_fluffos_v2/lib/doc/ideas/
dw_fluffos_v2/lib/doc/known_command/
dw_fluffos_v2/lib/doc/lpc/basic_manual/
dw_fluffos_v2/lib/doc/lpc/intermediate/
dw_fluffos_v2/lib/doc/new/add_command/
dw_fluffos_v2/lib/doc/new/handlers/
dw_fluffos_v2/lib/doc/new/living/
dw_fluffos_v2/lib/doc/new/living/race/
dw_fluffos_v2/lib/doc/new/living/spells/
dw_fluffos_v2/lib/doc/new/player/
dw_fluffos_v2/lib/doc/new/room/guild/
dw_fluffos_v2/lib/doc/new/room/outside/
dw_fluffos_v2/lib/doc/new/room/storeroom/
dw_fluffos_v2/lib/doc/object/
dw_fluffos_v2/lib/doc/playtesters/
dw_fluffos_v2/lib/doc/policy/
dw_fluffos_v2/lib/doc/weapons/
dw_fluffos_v2/lib/global/handlers/
dw_fluffos_v2/lib/global/virtual/setup_compiler/
dw_fluffos_v2/lib/include/
dw_fluffos_v2/lib/include/cmds/
dw_fluffos_v2/lib/include/effects/
dw_fluffos_v2/lib/include/npc/
dw_fluffos_v2/lib/include/shops/
dw_fluffos_v2/lib/net/daemon/chars/
dw_fluffos_v2/lib/net/inherit/
dw_fluffos_v2/lib/net/intermud3/
dw_fluffos_v2/lib/net/intermud3/services/
dw_fluffos_v2/lib/net/obj/
dw_fluffos_v2/lib/net/save/
dw_fluffos_v2/lib/net/smnmp/
dw_fluffos_v2/lib/net/snmp/
dw_fluffos_v2/lib/obj/amulets/
dw_fluffos_v2/lib/obj/b_day/
dw_fluffos_v2/lib/obj/examples/
dw_fluffos_v2/lib/obj/food/alcohol/
dw_fluffos_v2/lib/obj/food/chocolates/
dw_fluffos_v2/lib/obj/food/fruits/
dw_fluffos_v2/lib/obj/food/meat/
dw_fluffos_v2/lib/obj/food/nuts/
dw_fluffos_v2/lib/obj/food/seafood/
dw_fluffos_v2/lib/obj/food/vegetables/
dw_fluffos_v2/lib/obj/fungi/
dw_fluffos_v2/lib/obj/furnitures/artwork/
dw_fluffos_v2/lib/obj/furnitures/bathroom/
dw_fluffos_v2/lib/obj/furnitures/beds/
dw_fluffos_v2/lib/obj/furnitures/cabinets/
dw_fluffos_v2/lib/obj/furnitures/chairs/
dw_fluffos_v2/lib/obj/furnitures/chests/
dw_fluffos_v2/lib/obj/furnitures/clocks/
dw_fluffos_v2/lib/obj/furnitures/crockery/
dw_fluffos_v2/lib/obj/furnitures/cupboards/
dw_fluffos_v2/lib/obj/furnitures/cushions/
dw_fluffos_v2/lib/obj/furnitures/fake_plants/
dw_fluffos_v2/lib/obj/furnitures/lamps/
dw_fluffos_v2/lib/obj/furnitures/mirrors/
dw_fluffos_v2/lib/obj/furnitures/outdoor/
dw_fluffos_v2/lib/obj/furnitures/safes/
dw_fluffos_v2/lib/obj/furnitures/shelves/
dw_fluffos_v2/lib/obj/furnitures/sideboards/
dw_fluffos_v2/lib/obj/furnitures/sofas/
dw_fluffos_v2/lib/obj/furnitures/stoves/
dw_fluffos_v2/lib/obj/furnitures/tables/
dw_fluffos_v2/lib/obj/furnitures/wardrobes/
dw_fluffos_v2/lib/obj/handlers/
dw_fluffos_v2/lib/obj/handlers/autodoc/
dw_fluffos_v2/lib/obj/jewellery/anklets/
dw_fluffos_v2/lib/obj/jewellery/bracelets/
dw_fluffos_v2/lib/obj/jewellery/earrings/
dw_fluffos_v2/lib/obj/jewellery/misc/
dw_fluffos_v2/lib/obj/jewellery/necklaces/
dw_fluffos_v2/lib/obj/jewellery/rings/
dw_fluffos_v2/lib/obj/media/
dw_fluffos_v2/lib/obj/misc/buckets/
dw_fluffos_v2/lib/obj/misc/jars/
dw_fluffos_v2/lib/obj/misc/papers/
dw_fluffos_v2/lib/obj/misc/player_shop/
dw_fluffos_v2/lib/obj/misc/shops/
dw_fluffos_v2/lib/obj/misc/traps/
dw_fluffos_v2/lib/obj/monster/
dw_fluffos_v2/lib/obj/monster/godmother/
dw_fluffos_v2/lib/obj/monster/transport/
dw_fluffos_v2/lib/obj/plants/inherit/
dw_fluffos_v2/lib/obj/potions/
dw_fluffos_v2/lib/open/boards/
dw_fluffos_v2/lib/save/autodoc/
dw_fluffos_v2/lib/save/bank_accounts/
dw_fluffos_v2/lib/save/boards/frog/
dw_fluffos_v2/lib/save/books/bed_catalog/
dw_fluffos_v2/lib/save/creators/
dw_fluffos_v2/lib/save/mail/
dw_fluffos_v2/lib/save/mail/p/
dw_fluffos_v2/lib/save/soul/data/
dw_fluffos_v2/lib/save/tasks/
dw_fluffos_v2/lib/save/vaults/
dw_fluffos_v2/lib/secure/cmds/lord/
dw_fluffos_v2/lib/secure/config/
dw_fluffos_v2/lib/secure/items/
dw_fluffos_v2/lib/secure/player/
dw_fluffos_v2/lib/soul/
dw_fluffos_v2/lib/soul/i/
dw_fluffos_v2/lib/soul/j/
dw_fluffos_v2/lib/soul/k/
dw_fluffos_v2/lib/soul/o/
dw_fluffos_v2/lib/soul/q/
dw_fluffos_v2/lib/soul/to_approve/
dw_fluffos_v2/lib/soul/u/
dw_fluffos_v2/lib/soul/v/
dw_fluffos_v2/lib/soul/wish_list/
dw_fluffos_v2/lib/soul/y/
dw_fluffos_v2/lib/soul/z/
dw_fluffos_v2/lib/std/creator/
dw_fluffos_v2/lib/std/effects/
dw_fluffos_v2/lib/std/effects/attached/
dw_fluffos_v2/lib/std/effects/external/
dw_fluffos_v2/lib/std/effects/fighting/
dw_fluffos_v2/lib/std/effects/other/
dw_fluffos_v2/lib/std/environ/
dw_fluffos_v2/lib/std/guilds/
dw_fluffos_v2/lib/std/hospital/
dw_fluffos_v2/lib/std/house/
dw_fluffos_v2/lib/std/house/onebedhouse/
dw_fluffos_v2/lib/std/house/onebedhut/
dw_fluffos_v2/lib/std/house/tworoomflat/
dw_fluffos_v2/lib/std/languages/
dw_fluffos_v2/lib/std/liquids/
dw_fluffos_v2/lib/std/nationality/
dw_fluffos_v2/lib/std/nationality/accents/
dw_fluffos_v2/lib/std/nationality/accents/national/
dw_fluffos_v2/lib/std/nationality/accents/regional/
dw_fluffos_v2/lib/std/npc/goals/
dw_fluffos_v2/lib/std/npc/goals/basic/
dw_fluffos_v2/lib/std/npc/goals/misc/
dw_fluffos_v2/lib/std/npc/inherit/
dw_fluffos_v2/lib/std/npc/plans/
dw_fluffos_v2/lib/std/npc/plans/basic/
dw_fluffos_v2/lib/std/outsides/
dw_fluffos_v2/lib/std/races/shadows/
dw_fluffos_v2/lib/std/room/basic/topography/
dw_fluffos_v2/lib/std/room/controller/
dw_fluffos_v2/lib/std/room/controller/topography/
dw_fluffos_v2/lib/std/room/furniture/games/
dw_fluffos_v2/lib/std/room/furniture/inherit/
dw_fluffos_v2/lib/std/room/inherit/carriage/
dw_fluffos_v2/lib/std/room/inherit/topography/
dw_fluffos_v2/lib/std/room/punishments/
dw_fluffos_v2/lib/std/room/topography/area/
dw_fluffos_v2/lib/std/room/topography/iroom/
dw_fluffos_v2/lib/std/room/topography/milestone/
dw_fluffos_v2/lib/std/shadows/
dw_fluffos_v2/lib/std/shadows/attached/
dw_fluffos_v2/lib/std/shadows/curses/
dw_fluffos_v2/lib/std/shadows/disease/
dw_fluffos_v2/lib/std/shadows/fighting/
dw_fluffos_v2/lib/std/shadows/room/
dw_fluffos_v2/lib/std/shops/controllers/
dw_fluffos_v2/lib/std/shops/objs/
dw_fluffos_v2/lib/std/shops/player_shop/
dw_fluffos_v2/lib/std/shops/player_shop/office_code/
dw_fluffos_v2/lib/std/socket/
dw_fluffos_v2/lib/www/
dw_fluffos_v2/lib/www/external/autodoc/
dw_fluffos_v2/lib/www/external/java/telnet/Documentation/
dw_fluffos_v2/lib/www/external/java/telnet/Documentation/images/
dw_fluffos_v2/lib/www/external/java/telnet/examples/
dw_fluffos_v2/lib/www/external/java/telnet/tools/
dw_fluffos_v2/lib/www/pics/
dw_fluffos_v2/lib/www/secure/creator/
dw_fluffos_v2/lib/www/secure/editors/
dw_fluffos_v2/lib/www/secure/survey_results/
dw_fluffos_v2/win32/
/*  -*- LPC -*-  */
/**
 * This is the room in which the newbie chooses which land they wish to
 * start in.
 * @author Pinkfish
 * @started Thu May 23 11:55:41 PDT 2002
 */

#include "path.h"
#include <config.h>
#include <language.h>
#include <money.h>

inherit PATH+"inside";

#define DEBUG 1
#define LOG PATH + "save/CHOICE"

private mapping _nationalities;
private object _sign;

void setup() {
   string name;
   string nationality;
   string region;

  _nationalities = ([
       "pumpkin" : "/std/nationality/pumpkin"
     ]);
  add_property("no teleport", 1);
  add_property("determinate", "");
/* Make it so you cannot godmother out of here */
  add_property("no godmother", 1);
  set_zone( "Newbie" );
  set_short( "Discworld's realm of choice" );
  set_light( 75 );
  set_long("You are on a huge open-air platform far, far above the Disc itself.  "
           "Down below, the water tumbles and falls off the rim of the disc "
           "spilling down and out into a spray of mist over the elephants and "
           "the back of A'tuin, the great star turtle.  There are several "
           "sets of stairs leading down off the platform to the unknown and "
           "a large dial sits in the middle of the room.  A large sign "
           "shimmers and hangs in the air in the middle of the platform.\n");

  add_item(({ "disc", "Disc", "discworld"}),
           "You can see from the sharp spire of Cori "
           "Celesti at the centre, to the surrounding Circle Sea, "
           "the deserts of Klatch, the watery world of Krull, and the "
           "mysterious Counterweight Continent.  A spectacular rimbow "
           "sparkles where the seas pour over the edge of the Disc.  As "
           "you study the map's details, you are sure you saw one of the "
           "elephants move.");

  add_item("rimbow", "It's like a rainbow except that it's caused by the "
           "water pouring off the edge of the disc.");
  
  add_item("elephant", "These are the four elephants that bear the weight"
           " of the Disc.");

  add_item(({ "floor", "platform" }),
           "The floor is made of some weird black stone that is "
           "semi-transparent, allowing the Disc below you to be "
           "seen through it.");
  
  add_item(({ "stairs", "stairways" }), "Stairs leading down to the "
           "dark unknown.  They all appear to be crafted of some thin, "
           "spidery metal.");

  add_item("dial", "The dial is a huge heavy looking stone dial, with some "
                   "arrows and numbers carved into the surface.  They say "
                   "'Klatch 4000 miles', 'Ankh-Morpork 3000 miles', "
                   "'Lancre 3500 miles', 'Bes Pelargic 3000 miles'.");

   _sign = add_sign("A huge shimmering sign, the letters are transparent "
      "and it is possible to walk through it.\n", 
      FOYER->format_sign(
      "Travellers choose your destination!  Which parts of the world "
      "do you want to explore?\n\n"
      "Look carefully at each of the lands "
      "before you make your choice - it determines the language you "
      "start with and your local accent, as well as where you start.\n\n"
      "The current list of available start nationalities is: " +
      query_multiple_short(keys(_nationalities)) + ".\n\n"
      "You can get 'info' on each nationality, and each region within "
      "a nationality.\n\n"
      "You choose your nationality with 'choose <nationality> <region>'; "
      "for example 'choose morpork Ankh-Morpork'.\n\n"
      "Use 'help here' for more help on 'info' and 'choose'.\n"),
      "shimmering sign", "sign", "general");

   foreach (name, nationality in _nationalities) {
      if (file_size(nationality + ".c") > 0) {
         add_item(name, nationality->query_information());
         foreach (region in nationality->query_regions()) {
            //add_exit("choose " + name + " " + lower_case(region), nationality->query_region_start_location(region), "stairs");
            //modify_exit("choose " + name + " " + lower_case(region), ({ "function", "setup_nationality" }) );
            add_item(name + " " + lower_case(region), nationality->query_region_description(region));
         }
      } else {
         printf("Bad nationality %O\n", nationality);
      }
   }

   add_help_file(PATH + "doc/choose_land");
} /* setup() */

string find_region(string nationality, string region) {
   string tmp;

   foreach (tmp in nationality->query_regions()) {
      if (lower_case(tmp) == lower_case(region)) {
         return tmp;
      }
   }
   return 0;
}

void change_nationality(object person, string nationality, string region) {
   string old_nationality;
   int old_speak;
   int old_write;
   int new_speak;
   int new_write;
   string skill_speak;
   string skill_write;
   string lang;
   string guild;
   mixed newbie;

   // Find out what their old nationality is.
   nationality = _nationalities[nationality];
   old_nationality = this_player()->query_nationality();
#ifdef DEBUG
   debug_printf("Old nationality was %O, new nationality is %O.\n", old_nationality, nationality);
#endif
   // Move around the skills.
   lang = nationality->query_language();
   skill_speak = LANGUAGE_HAND->query_language_spoken_skill(lang);
   skill_write = LANGUAGE_HAND->query_language_written_skill(lang);
   old_speak = this_player()->query_skill(skill_speak);
   old_write = this_player()->query_skill(skill_write);
   if (old_speak > 100) {
      old_speak = 100;
   }
   this_player()->add_skill_level(skill_speak, 100 - old_speak); 
   if (old_write > 100) {
      old_write = 100;
   }
   this_player()->add_skill_level(skill_write, 100 - old_write);

   if (old_nationality &&
       old_nationality->query_language() != nationality->query_language()) {
      // Put the levels we removed into the old language. 
      lang = old_nationality->query_language();
      skill_speak = LANGUAGE_HAND->query_language_spoken_skill(lang);
      skill_write = LANGUAGE_HAND->query_language_written_skill(lang);
      new_speak = this_player()->query_skill(skill_speak);
      new_write = this_player()->query_skill(skill_write);
      if (new_speak > 100) {
         new_speak = 100;
      }
      this_player()->add_skill_level(skill_speak, old_speak - new_speak);
      if (new_write > 100) {
         new_write = 100;
      }
      this_player()->add_skill_level(skill_write, old_write - new_write);
   }
   this_player()->set_nationality(nationality);
   this_player()->set_nationality_region(find_region(nationality, region));
   lang = nationality->query_language();
   // Setup the default language correctly.
   this_player()->set_default_language(lang);
   this_player()->set_language(lang);

   guild = this_player()->query_guild_ob();
   newbie = this_player()->query_property("not real newbie");

   log_file( LOG , "%s:\n   %s the %s%s chose %s (%s)\n",
      ctime(time()),
      this_player()->query_short(), 
      guild ? capitalize(guild[12..<1]) : "Adventurer",
      newbie ? "" : " (newbie)",
      capitalize(this_player()->query_nationality_region()),
      capitalize(this_player()->query_nationality()[17..<1]));

   // mess with money.
   if (!this_player()->query_property("not real newbie")) {
      int value;
      string currency_area = "";
      mixed* array;

      value = this_player()->query_value_in("Newbie Area");
      currency_area = this_player()->query_nationality()->query_currency_area();
      // Hack to correct Sto Lat money from AM to Provincial
      if (this_player()->query_nationality_region() == "Sto Lat" ) {
         currency_area = "default";
      }
      tell_creator( "wyvyrn" ,
         "[ %s the %s%s picked %s and got money for %s ]\n",
         this_player()->query_short(), 
         guild ? capitalize(guild->query_name()[0..<2]) : "Adventurer",
         newbie ? "" : " (newbie)",
         this_player()->query_nationality_region(),
         currency_area);

      array = MONEY_HAND->create_money_array(value, currency_area);
      this_player()->set_money_array(array);
   } else {
      object ob;

      foreach (ob in all_inventory()) {
         if (!living(ob) && ob->query_short() != "shimmering sign") {
            ob->move(nationality->query_region_start_location(region));
         }
      }
      tell_creator( "wyvyrn" ,
         "[ %s the %s%s picked %s and kept their money ]\n",
         this_player()->query_short(), 
         guild ? capitalize(guild->query_name()[0..<2]) : "Adventurer",
         newbie ? "" : " (newbie)",
         this_player()->query_nationality_region());
   }
}

int setup_nationality(string direction, object person) {
   string* bits;

   bits = explode(direction, " ");
   change_nationality(person, bits[1], implode(bits[2..], " "));
   return 1;
}

int do_choose(string nat, string region) {
   string region_new;
   string nationality;
   string loc;

   nationality = lower_case(nat);
   if (!_nationalities[nationality]) {
      add_failed_mess("There is no nationality " + nationality + ".\n");
      return 0;
   }
   nat = nationality;
   nationality = _nationalities[nationality];
   region_new = find_region(nationality, region);
   if (!region_new) {
      add_failed_mess("Cannot find the region " + region +
                      " in the nationality " + nat + ".  It must be "
                      "one of " +
                      query_multiple_short(nationality->query_regions()) + ".\n");
      return 0;
   }

   // Try and find the region.
#ifdef DEBUG
   debug_printf("Nationality is %O, region is %O, player is %O.\n", 
      nationality, region_new, this_player()->query_short());
#endif
   change_nationality(this_player(), nat, region_new);
   loc = nationality->query_region_start_location(region_new);
   this_player()->move_with_look(loc, "$N arrive$s into the world.",
                                 "$N disappears to a better life.");
   this_player()->remove_property("not real newbie");
   if (clonep(this_object())) {
      call_out((: dest_me :), 10);
      if (_sign) {
         _sign->dest_me();
      }
   }
   return 1;
}

int do_info(string nat, string region) {
   string region_new;
   string nationality;

   nationality = lower_case(nat);
   if (!_nationalities[nationality]) {
      add_failed_mess("There is no nationality " + nationality + ".\n");
      return 0;
   }
   nationality = _nationalities[nationality];
   region_new = find_region(nationality, region);
   if (!region_new) {
      add_failed_mess("Cannot find the region " + region +
                      " in the nationality " + nat + ".  It must be "
                      "one of " +
                      query_multiple_short(nationality->query_regions()) + ".\n");
      return 0;
   }

   // Try and find the region.
#ifdef DEBUG
   debug_printf("Nationality is %O, region is %O, player is %O.\n", 
      nationality, region_new, this_player()->query_short());
#endif
   write(nationality->query_region_description(region_new) + "\n");
   return 1;
}

int do_nationality_info(string nationality) {
   string ret;
   string region;

   nationality = lower_case(nationality);
   if (!_nationalities[nationality]) {
      add_failed_mess("There is no nationality " + nationality + ".\n");
      return 0;
   }

   nationality = _nationalities[nationality];

   ret = nationality->query_information() +
         "Regions you can choose:\n";
   foreach (region in nationality->query_regions()) {
      ret += "  * " + region + "\n";
   }
   write(ret);
   return 1;
}

void init() {
  add_command("info", "<word'nation'>", (: do_nationality_info($4[0]) :));
  add_command("info", "<word'nation'> <string'region'>", (: do_info($4[0], $4[1]) :));
  add_command("choose", "<word'nationality'> <string'region'>", (: do_choose($4[0], $4[1]) :));
}

void fixup_player(object player) {
   object ob;

   ob = clone_object(__FILE__);
   player->move_with_look(ob);
}

string query_quit_handler() {
   return __FILE__;
}