Current release:	PAiN Virtual World Engine 0.41

Hello to everyone!
This is next alpha release of the PAiN Virtual World Engine project.
PAiN MUD codebase (v0.41) consists of the following parts:

1) PAiN DB (net.sourceforge.pain.db and net.sourceforge.pain.util packages)
	net.sourceforge.pain.db package contains database engine PAiN MUD Codebase uses today.
	This engine replaced previous C++ one, and provides more features support, and greater performance, 
	(since we avoid JNI mapping for every get/set methods call and reference consistency checks).
	The reason to rewrite C++ database engine with pure Java is to consolidate project code and
	to make easier multiplatform support for developers and project end-users (people who will 
	build it's own world upon PAiN engine). 
	Base PainDB features: 
		1) PainDB is a 'main memory database'. It loads whole database file into memory 
			and converts this image into real java objects during startup.
		2) Any access operation to any primitive or object field is a constant time operation(object is already in memory)
		3) PainDB is not OODB it has no GC. User should manually delete any object during runtime.
			In this case all references to this object will be setted to null automatically.
		4) PainDB supports all java primitive types, Strings, arrays, Lists(Array and Linked 
			realizations), Sets of objects, Strings(cookies), and 2 types of maps: IntKeyMap and StringKeyMap.
			Database allows to user a transparent way to work with these collections as 
			with natural java objects (java.util.Map,Set,List)
		5) PainDB engine tracks any changes done to persistent object and saves them during flush method call.
		6) User could have several db instances opened during runtime.		
		7) Transactions and subtransactions support. (Note: all changes flushed to disk only 
		   on 'flush' method call. We can ask PainDB to call flush every time after commit is done or
		   call it manually outsude from transaction (delayed commit).
		8) PainDb is not thread safe application. (PAiN Mud codebase doesn't 
			require PainDB to be thread safe, all core code of codebase is synchronous)
		9) You will need to have 2 times more RAM memory to run DB as your database file size.
			(all Anatolia maps converts in 15-20Mb paindb file. So you will need about 35Mb
			RAM for db memory image(and all runtime db objects), 
			8-12Mb will use JVM, and about 5-10Mb all other runtime items(socials, commands..)
			So 60-70Mb for a fully functional version should be enough. 
			(Anatolia 3.0 needs about 15Mb to run with all maps loaded but has a less detailed 
			persistent world structure, more primitive db capablities
			and written with C(lower mem usage) language but not with Java (GC))

			Note: if you convert all Anatholia files into PAiN DB format
			resulting database full size will reach 15-20Mb and server startup will take
			7-8 seconds (Cel-700). Also during project first start initial reset upon all areas
			will done (6-7 secs for reset and 4-5sec to commit changes (plus 8-10Mb to dbfile)).
		
	
2) PAiN
	Main part of the PAiN Server. Java source code, configuration files and build scripts.
		Static code: all packages in 'net.ssourceforge.pain' except 'logic' and 'plugin' and 'db' packages.
				This code is never reloaded, it handles telnet connections and class loaders. 
		Plugins: package 'plugins' -  every plugin could be reloaded by one. Plugin may use 
				directly any static layer code or have direct references to 'superplugins' code,
				 but should never use 'logic' code by static references (to support separate reloading for the logic code). 
				Plugin could create events which will be mapped by static core into logic code class. 
				Plugins used to keep large amount of data separate from logic (ex: socials mapping, commands mapping)
				for faster logic layer reloading. Also plugins could be unloaded (logic code is always 'lazy-loaded')
		Logic: package 'logic' - reloaded every time you ask it to reload or any plugin is reloaded. 
				Classes in this package reloaded all in once, to allow static compilation and static references
				in code to each other. (see help for _reload command, make sure you have permissions (god, or grant))

		Note: All these tricks with classloaders and different reloading level give us all
			benefits of static compilation with errors reporting during compilation time
			(script languages lacks in such level of compilation and inspection).
			Also it give us a full control for reloading. 
			(Ex: paindb persistent objects classes should not be reloaded spontaneous)


	Compiled java source code supplied in 'classes' folder. 
	WARN: jdk1.4 required!
	
	To start server:
	1) modify every script you will run to set valid environment variables.
	   (You will need to set only JAVA_HOME and JUNIT_JAR(for tests) variables)
	2) run 'run_converter.cmd' to import area files from ROM format to PAiN db format (/area/area.lst)
	3) run 'run.cmd' and enjoy!:)
		*) Linux users will need to rewrite supplied *.bat files to meet the requirements of they active shell.

	(note: if you run 'run.cmd' before  ROM areas convertion default world instance will be created.)
	Note: default PAiN Mud Codebase login is 'god', password 'god'.
	Only 'god' has Builder role required to enable builder mode.

	Only one area(Midgaard) from ROM (Anatolia) distribution supplied with this release. All other areas you can get directly from
	Anatolia arhieves (http://www.anatoliamud.org/).

	Change Log:

	Version 0.41 (16-Sep-2003)  new features and bugfixes:	
		1) Bugfix: critical bugfixes in PAiN DB engine .
		2) Commands added: grant, ungrant, reject, allow, password, showgrants, showrejects, exists, force
		3) Help command enhancements: tips by first command character
		4) DbStringSet added to PainDB. Code duplication in PAiN DB maps/sets realization cleared
		5) Command accessebility in command interface added (isAccessableCommand)
		6) Number of PAiN DB tests triples
		7) Bugfix: remove active player
		8) Player is now relocated into special place after exit
		9) Objects creation mechanism proposed: see GlobalFactory class.
		10) A number of minor improvemets	
	
	Version 0.4 (1-Sep-2003)  new features and bugfixes:	
		1) PAiN DB is now supports transactions and subtransactions (savepoints)
		    Every logical action is now enveloped by transaction. If error
			occurs all changes done by this action will be safely rolled back.
			This is the only way to handle runtime errors without stopping program.

		2) Online builder mode added. Use '@build' command to enable builder mode.
		   (only 'god' player has Builder role and can use this command today)  
		3) 'Help' added for any available command and for builder mode.
		4) With this release junit tests added into project. Look 'tests' folder.
			To compile and run tests you will need junit.jar library in classpath.
		5) Persistent world structure completely redesigned. 
		    This time it's final redesign and next versions will brign only additional
			features.
		6) Internal logger enhancements: rolling by time or by size. Delayed flushing.
		7) Reload code enhanced.  Shutdown timer added.
		8) Console commands parsing code and command-to-event mapping is now reloadable. 
		9) More commands added (kill, destroy)
		10) StringKeyMap is supported by PAiN DB.
		11) Rom24ToPain converter fixups

			
	Version 0.35 (04-Apr-2003)  new features and bugfixes:	
		1) C++ database was replaced with Java Db realization.
			New realization is more powerfull and is ot slower than old one.
			This is a first PAiN release you can run on Linux or Mac platform.
		2) FlushAct added (save,flush,commit console commands)
		3) Some small bug fixing and code enhancing.

	
	Version 0.34 (28-Oct-2002) new features and bugfixes:
		1) Prototypes redesigned. All Prototypes now are DynObject successors.
		2) Tick Plugin added: (RefreshAct and ResetAct instantiator)
			Reset Act resets thing resets only with this version;
			Refresh Act refreshes only MovePoints (there is no other parameters to exhaust today :( )
		3) WorldTime and WorldCalendar added. From this release every World has it's own TIME, saved in DB.
			One PAiN hour is about 114 seconds, One PAiN year is about 10 Earth days;
		4) TimeAct will show you cuurent Time('time' console command) and Date('date' console command)
		5) Many small modifications and improvements in Act classes 
			(ShoutAct, RangeOutAct added, TellAct modified, QuitAct clarified... :) )
		6) More complete impl of Console state transitions (documented in /doc/artifacts.mdl)
		7) /doc/artifacts.mdl is a Documentation file for some(not all) PAiN features, will be updated with every future release.
		8) Fixed some small bugs in paindb and paindll packages
		9) ShutdownAct added '_shutdown SERVER' command:)
		10) CreatureFactory is now system.CreateCreatureAct - it's code could be reloaded in runtime, 
			also CreateThingAct added (factory for Things)
		
	
	Version 0.32 (21-Oct-2002) new features and bugfixes:
		1) 'Plugins' concept added. 'Plugin'  is a small sub-applications with dynamic reloading ability. It's loaded
			with different to Acts classloader. See SocialAct, SocialPlugin to understand how we can use it;
		2) 'Act' concept clarified: Act is a function, it could be reloaded many times during application work - so 
			act should not contain many static computations during class initilization. See SocialAct, SocialPlugin to
			understand how we could move from Act class heavy loaded function. Act class could not be preloaded.
		3) OutTagAct added. See 'qui' command description in /etc/command_mapping.cfg.
		4) GetCharWorld implemented. TellAct works via GetCharWorld now. more impls in ScanAct. LogoAct rewritten.
			ReloadAct now can reload Plugins. SocialAct divided into SocialAct and SocialPlugin(socials data container)
		5) Console.out() simplified. OutputText class removed.
		6) Fixed bug in paindb code (putting one element twice in map(or set) caused failure)
		7) Fixed bug with ExpiredConsoleAct (for logged players now calls QuitAct) - not heavily tested!
			and .. maybe new bugs added :)

	
	Version 0.31 (14-Oct-2002)
		1) Fixed some bugs with ConsoleOutAct, TellAct
		2) Fixing bugs with hardcoded urls in pain core
		3) EmoteAct, WhoAct, WhereAct added
		4) Fixing a few small bugs in Text2ActProcessor


	
	Version 0.3 (5-Oct-2002)
		1) More clear Act framework : methods prepare and execute. 
			Act can be produced in prepared state in runtime or should implement prepare method 
			if it was instantiated from text command or other boundary to system interface
		2) Text output template support (see act.txt from Anatholia release located in /pain/doc folder)
		   ConsoleOutAct supports all required outputs type! (actRoom(), actVictim(), actChar....)
		3) Colored text output (Ex: 'Hello {WWorld{x' '{W' means white color starts, '{x' -  default color
		4) Anatholia-like socials format supported! (/pain/etc/socials.cfg, SocialAct) 
		   It's about 300 new text commands!
		5) Dynamic act reloading ('_reload' command, 'ReloadAct') 
			All 'pain.act.Act' subclasses loaded with different to system classloader and could be reloaded any time 
			without server shutdown. To pay its price we can call specified acts from other packages only by its text name:
			Ex: CoreContext.createAct("pain.act.LookAct"), inside pain.act
				package we could have direct 
				instantiation: Ex: new LookAct();
		6) GetCharRoomAct implementation.
		7) Telnet impementation enhancements(better connection state monitoring);
		8) If player quits the game his character left the room.


	
	Version 0.2 (24-Aug-2002)
		1) Import Anatolia area files to pain database. 
		2) Character creation(regitration, login, quit commands). 
		3) Browsing the world(move command, look room)
		4) look, say, tell command implementation
		5) Framework to create new commands (Act files and command mapping)
		6) Transparent for developer persistent engine for 'pain.data.*' structs
		7) Weak telnet IO implementation
		8) Flexible command name mapping to the code-files interface
		9) Some bugs fixed in native db code and 'pain.persistence' package since previous release
		10) ReferenceSet and ReferenceMap(int keys) types database support

	
	Version 0.1 (04-Aug-2002)
		1) Database engine written in C++.
		2) JNI wrapper for all database methods to Java
		3) Implemented and ready to use 'pain.persistence' package. 



	ToDo: (v0.4x)
		Increase number of available commands.
		Increase the number of tests in testbase.
		PAiN DB: export to xml, html
		Bugfixing and small features impl.
		
	ToDo: (v0.5)
			a) Gui management tool. Partial code integration into database.
			b) Some kind of open API to map different JVM languages with it. 


This code distributed AS IS and not tested heavily.
Any help for this project in any area will be appreciated!

Distributed under the GPL license.




