Nations Module
==============
http://www.crimson-blade.org/snippets/

Disclaimer
==========

This code has been tested on a heavily modified version
of SMAUG 1.4a, there is no guarentee that it will work
on your copy, and I retain no responcibilty if this code
does anything to your code, your game, or the system it's
running on.

Terms of Use
============

(1) All comments and headers must be left in place.
(2) If you find a bug in the code, please report it to the
    SMAUG MAILING LIST (smaug@realms.game.org) and/or directly
    to myself: jbellone@comcast.net
(3) This code may only be re-distributed with the author's concent.
(4) I would like an email telling me that your using the code. This
    tells me actually how many people are using it, and if I should
    produce further snippets and code updates.
(5) If you are not abiding by the Diku, Merc, and Smaug codebase
    licenses, you may not use this code. (considering that your
    using Smaug).

Overview
========

This code was originally designed (and revised several times) by myself and
my staff member, Chris; both of us whom at the time were (and sort of still
are) frequent roleplayers on the Realms of Despair.

This code was modelled after the player driven structure of "Nations" in RoD;
in hopes to be eventually added to the game.

The code was removed from the Hometowns module a few months ago, rewritten to
be standalone and work alot different from the version that has been floating
around in the old hometown code. 

Nations are basically a "race guild" that are Roleplay organizations; they have
a "Nations Leader", "Nations First" and "Nations Second" and have a similar
function for viewing: "nations"

Also this code allows for the ability for the Nation Leader to create positions
for other players to hold. This helps assign positions for Roleplay without
them actually "existing". These are only viewed when you are viewing a Nation
(nations <nation>). 

The most recent addition was Chris's brainchild; allowing anyone to swear their
alligance to a Nation; this is controlled by the fealty command.

I have also included the fourteen (14) race definition files that would be standard
for RoD; these should be most of (if not all) of the ones for standard SMAUG.

Instructions
============================

(1) db.c

    Under:
    log_string("Building wizinfo");
    build_wizinfo();
    
    Add:
    /* load nations call 4/2/02	       -Nopey */
    log_string("Loading Nations...");
    load_nations();
    
(2) act_info.c

  Find the function do_who; add this to the list of inital function variables:
  
  bool fNation;
  int  iNation = 0;
  
  Under:
  fLeader	   = FALSE;
  
  Add:
  fNation        = FALSE; /* Nopey - nations.c */
  
  Under:
		if ( iRace != MAX_RACE )
		  fRaceRestrict = TRUE;
		  
  Add:
		/* nations who argument -Nopey */
		for(iNation=0; iNation > MAX_NATIONS; iNation++)
                {
                  if(nation_list[iNation] && !str_cmp(capitalize(arg), nation_list[iNation]->name))
                  {
                    fNation = TRUE;
                    break;
                  }
                }
  After:
  && fCouncilMatch == FALSE
  
  Add:
  && fNation == FALSE
  
  Change:
  	 send_to_char( "That's not a class, race, order, guild,"
			" council or deity.\n\r", ch );

  To:
	 send_to_char( "That's not a class, race, order, guild,"
			" council, nation or deity.\n\r", ch );
			
  Below:
	if ( (d->connected != CON_PLAYING && d->connected != CON_EDITING)
	||   !can_see( ch, d->character ) || d->original)
	    continue;
  Add:
	/* nations.c -Nopey */
	if((fNation == TRUE) && ((ch->pcdata->nation == NULL) || (ch->pcdata->nation != nation_list[iNation])))
         continue;
         
(3) Add nations.c and nations.h into your Makefile
(4) Make clean, recompile
(5) Create command listings for do_nations (mortal), do_fealty (mortal), do_editnation (nation leader), do_setnation (immortal)
(6) Cedit save cmdtable
(7) Enjoy!
(8) [optional] Use the included /nations/ directory files to start up your game. You may have to edit the races
    a little bit to suit your game; these were based off RoD's structure... not sure how exact that is to stock
    SMAUG, AFKMUD, Chronicles, etc.
(9) Please report all bugs to the mailing list and/or http://crimson-blade.org/snippets/ (bug report script)

Help?
=====

Send a email to: jbellone@comcast.net
With the Subject: NATIONS

Noplex, Implmentor of Crimson Blade
http://www.crimson-blade.org
http://www.crimson-blade.org/snippets/
telnet://www.crimson-blade.org:8888
