* server/EntityFactory.cpp, server/EntityFactory.h, server/Admin.cpp,
server/PersistantThingFactory.cpp, server/WorldRouter.cpp,
server/server.cpp: Rename EntityFactory to EntityBuilder, to make
it's function clearer.
* common/Database.h, common/Database.cpp: Add a new decoder for atlas
objects, and use it when getting the full contents of a table
full of Atlas data.
* server/Persistance.cpp, server/Persistance.h: Modify the API
for getting the rules table to use atlas objects rather than
messages.
* server/EntityFactory.cpp: Re-enable loading rules from the
Database, now that the data is available from the peristence
API in the right format.
* client/BaseClient.cpp, client/CharacterClient.cpp,
client/CharacterClient.h, client/CreatorClient.cpp,
client/CreatorClient.h, rulesets/BaseMind.cpp, rulesets/BaseMind.h,
rulesets/Character.cpp, rulesets/Entity.cpp, rulesets/Entity.h,
rulesets/MindFactory.cpp, rulesets/MindFactory.h, rulesets/Thing.cpp,
rulesets/World.cpp, server/Account.cpp, server/Connection.cpp,
server/EntityFactory.cpp, server/Persistor.cpp,
server/Persistor_impl.h, server/Restorer_impl.h,
server/WorldRouter.cpp: Remove the hard name attribute, now that
most entities don't set it.
* common/inheritance.cpp, common/inheritance.h: Introduce a type
node class as a carrier for all information, including default
values for a type.
* rulesets/Entity.h, rulesets/Entity.cpp, rulesets/Character.cpp:
Use a TypeNode pointer rather than a string giving the type
of an entity.
* client/Py_CreatorClient.cpp, rulesets/MemMap.cpp, rulesets/MemMap.h,
rulesets/MindFactory.cpp, rulesets/MindFactory.h,
rulesets/Py_Mind.cpp, rulesets/Py_Thing.cpp, rulesets/Stackable.cpp,
rulesets/World.cpp, server/PersistantThingFactory.h,
server/Restorer_impl.h, server/WorldRouter.cpp:
Adapt all the code that deals with types. Set the type pointer
up correctly in BaseMind.
* server/EntityFactory.cpp: Initialise the TypeNode pointer on new
entities.
* tests/inheritancetest.cpp: Adapt the test to cope with TypeNode.
* server/EntityFactory.h, server/EntityFactory.cpp: Clean up header
a little. Add some alerts for consistency. Stub out a method
for updating a task factory from a class description.
* common/AtlasFileLoader.cpp, common/AtlasFileLoader.h: Switch to
loading and storing the file using the Atlas Objects Decoder.
* server/EntityFactory.cpp, server/EntityFactory.h: Switch to using
Atlas Objects rather than Messages in most places. Makes much of
the code cleaner, and allows storage of richer class data.
* server/Admin.cpp: Update to match the modified EntityFactory API.
* server/EntityFactory.cpp, server/EntityFactory.h: Major overhaul of
error reporting when installing rules, covering many new cases, and
reporting errors more clearly.
* common/log.cpp, common/log.h: Switch to taking a C++ string reference
rather than a char *, as it is not really an optimisation, and it
makes the code simpler to read and write.
* client/BaseClient.cpp, client/ClientConnection.cpp,
common/AtlasFileLoader.cpp, common/BaseEntity.cpp,
common/Database.cpp, common/globals.cpp, common/id.cpp,
common/inheritance.cpp, common/log.cpp, common/log.h,
rulesets/Character.cpp, rulesets/Creator.cpp, rulesets/Entity.cpp,
rulesets/MemMap.cpp, rulesets/Motion.cpp, rulesets/Pedestrian.cpp,
rulesets/Py_Object.cpp, rulesets/Py_RootEntity.cpp,
rulesets/PythonMindScript.cpp, rulesets/PythonThingScript.cpp,
rulesets/Python_API.cpp, rulesets/Thing.cpp, server/Account.cpp,
server/Admin.cpp, server/ArithmeticFactory.cpp,
server/CommClient.cpp, server/CommListener.cpp,
server/CommMDNSPublisher.cpp, server/CommServer.cpp,
server/Connection.cpp, server/EntityFactory.cpp,
server/Persistance.cpp, server/Restoration.cpp,
server/ScriptFactory.cpp, server/TaskFactory.cpp,
server/WorldRouter.cpp, server/server.cpp: Convert over to using
new API correctly.
* data/mason.xml: Add biomass and transient to fircone, making its
script obsolete:
* server/EntityFactory.cpp: Complete the code that populates
operations on a tool based on the task activations in the
ruleset, removing the need for world builders to synchronise
this data manually.
* data/basic.xml, data/mason.xml: Remove operations from all tools
that only use them for activating tasks, now that this is handled
automatically.
* scripts/cyphesis-setup.sh: Complete the database setup script
functionality. Clean up the output, and polish.
* server/PersistantThingFactory.cpp, server/PersistantThingFactory.h,
server/PersistantThingFactory_impl.h: Partially specialise the non
persistent entity factory so we can register the persistor database
tables for the world object when persistence is disabled, so the
state of this entity can be restored.
* server/server.cpp: Tidy up the startup output.
* server/EntityFactory.cpp: Don't try and set up world persistence if
it is turned off.
* server/EntityFactory.cpp: When processing a new task rule, check
that the operation and tool classes referenced have been installed.
If not, make the class pending on those classes.
* rulesets/mason/world/tasks/Reap.py: New task to implement reaping
grass with a scythe.
* server/EntityFactory.cpp: Report an error more clearly.
* data/mason.xml: Fix a bug in the gravestone rule.
* date/mason.xml: Add new reap task class.
* common/globals.cpp, common/globals.h: Change the type and name
of the ruleset list to a string.
* rulesets/Python_API.cpp, server/EntityFactory.cpp,
server/server.cpp, tools/cyaddrules.cpp, tools/cydumprules.cpp,
tools/cyloadrules.cpp: Switch to using single ruleset config
variable.
* data/Makefile.am: Install the xml files for mason into the mason.d
subdir, as the rule loading code now prefers.
* server/EntityFactory.cpp, tools/cyaddrules.cpp,
tools/cyloadrules.cpp: Modify the way rule xml files are loaded
so files from the ruleset specific subdirectory are loaded first,
and the legacy way of doing it is done if this files, with a warning
message.
* configure.ac: Check for dirent.h.
* common/AtlasFileLoader.cpp: Report duplicate IDs when loading rule
data.
* data/basic.xml: Remove obsolete old overriden rules, as we will
no longer be doing rules that way.
* server/EntityFactory.cpp: When loading rulesets directly from
files, also load all files in ruleset.d.
* common/globals.cpp, common/globals.h: Add a config flag
to control whether database code is enabled.
* server/EntityFactory.cpp, server/EntityFactory.h,
server/PersistantThingFactory.cpp, server/PersistantThingFactory.h,
server/PersistantThingFactory_impl.h, server/Persistor.cpp:
Re-work the persistence code so that persistent or non-persistent
versions of entity factories are installed at startup, removing
the need to check whether the database is enabled during
runtime.
* common/newid.cpp, server/Connection.cpp, server/server.cpp:
Replace the const that used to control whether the database
was used with the config flag.
* server/EntityFactory.h, server/EntityFactory.cpp: Improve test
for task classes by checking if the class parent has already been
installed as a class.
* common/PropertyManager.cpp: When the PropertyManager is deleted,
set the instance variable to 0.
* server/EntityFactory.cpp, server/EntityFactory.h: Add a destructor
so the property manager can be deleted at shutdown.
* client/ClientPropertyManager.cpp, client/ClientPropertyManager.h:
A new class as a dummy property manager for the client side.
Never creates property objects.
* client/client.cpp: Instantiate the client property manager
during client initialisation.
* server/EntityFactory.cpp: Instatiate the server property manager
during server intialisation.
* common/PropertyManager.h: Add the singletons accessor, and
make the addProperty member return a pointer to the property.
* server/CorePropertyManager.h, server/CorePropertyManager.cpp:
Implement creating properties for server side entity objects.
* rulesets/Entity.cpp: Use the property manager singleton to
create properties if a new attribute is set which is not already
a property, and its also not already a soft attribute.
* FIXME, Makefile.am: Add new FIXME file which documents FIXMEs in
the code.
* server/EntityFactory.cpp: Remove the terrain feature classes
implemented as hard coded classes.
* data/basic.xml: Add the terrain feature classes as soft data
defined classes.
* rulesets/Py_Task.cpp: Missing missing return when an error is
detected.
* rulesets/Python_API.cpp: Remove obsolete Vector3D and Point3D
constructors and method tables, now replaced by init method
implementations.
* server/EntityFactory.cpp: Comment out as yet unused code for
updating a task factory from an admin client.
* server/Admin.cpp, server/EntityFactory.cpp, server/EntityFactory.h:
Change function args to take class descriptions for modification
as an Object not a Message. Makes it easier to defermine when
op definitions should be processed.
* server/Admin.cpp: Allow client to update op definition, passing
it to EntityFactory, just like other types.
* server/EntityFactory.h, server/EntityFactory.cpp: Add method to
handle updating op definitions. Catch a bug which might cause
a crash if the client updates a core C++ hard coded entity type.
* common/BaseWorld.h, rulesets/Character.cpp,
server/EntityFactory.cpp, server/EntityFactory.h,
server/TaskFactory.h, server/WorldRouter.cpp,
server/WorldRouter.h: Specify the target base type that a given
task is valid for, and provide target type when activating a task.
* data/mason.xml: Add target base types to most task rules.
* rulesets/mason/world/tasks/Combat.py: Fix the copyright date.
* rulesets/mason/world/tasks/Sharpen.py: Proof of concept task
for turning logs into stakes.
* common/custom.cpp: Add a "task" base class to the inheritance tree.
* server/EntityFactory.h, server/EntityFactory.cpp: Add
functionality to allow task rules to be installed and updated from
an admin client. Improve the error reporting for a number of error
conditions.
* server/Connection.cpp: Correct the copyright dates.
* server/Admin.cpp: Improve error reporting for a number of error
conditions. Remove obsolete commented out code for installing
rules using Set ops, and add error notification when the
admin client attempts to update an op definition. Allow the
admin client to install an op definition.
* common/BaseWorld.h, server/WorldRouter.h, server/WorldRouter.cpp:
Add interface to allow world entities to activate tasks based on
tool use operations.
* server/EntityFactory.h, server/EntityFactory.cpp: Add method which
createa a new task in response to an activation request.
* rulesets/Character.cpp: When a character uses a tool, use the
tool type and operation to activate a task if one is available.
* rulesets/ArithmeticScript.h: Remove redundant constructor.
* rulesets/ArithmeticScript.cpp: Provide empty virtual destructor
implementation.
* rulesets/Py_Statistics.cpp: Add debugging output, and remove
rubbish from __init__.
* rulesets/PythonArithmeticScript.cpp: Test implementation of
attribute.
* server/ArithmeticFactory.cpp, server/ArithmeticFactory.h: New
factory class to create instances of scripts to handle
statistics.
* server/EntityFactory.cpp, server/EntityFactory.h: Add new method
and supporting data structures to provide a way to create
statistics objects for newly created Character entities.
* server/PersistantThingFactory.cpp: Add a call to
EntityFactory::addStatisticsScript to the Character
specialisation of PersistantThingFactory::populate, giving
all characters a statistics script now.
* rulesets/mason/world/statistics/Statistics.py: Test implementation
of a class for all character statistics.