All IG code should use the interface of LocatedEntity when dealing
with any entity, rather than sometimes requiring Entity. Add virtual
functions to the interface where required, and modify all other interfaces
to stop them using Entity. This makes the code way cleaner, and much better
de-coupled.
* common/Identified.cpp, common/Identified.h:
Flatten down the base classes into one called Router.
* client/CharacterClient.cpp, client/CreatorClient.cpp,
rulesets/BaseMind.cpp, rulesets/Character.cpp,
rulesets/Creator.cpp, rulesets/Entity.cpp,
rulesets/LocatedEntity.cpp, rulesets/MemEntity.cpp,
rulesets/Plant.cpp, rulesets/Stackable.cpp,
rulesets/Thing.cpp, rulesets/World.cpp,
server/Account.cpp, server/Admin.cpp,
server/Connection.cpp, server/ExternalMind.cpp,
server/Lobby.cpp, server/Master.cpp,
server/Peer.cpp, server/Player.cpp,
server/ServerRouting.cpp, server/SlaveClientConnection.cpp,
server/TrustedConnection.cpp, tests/LocatedEntitytest.cpp,
tests/ThingupdatePropertiestest.cpp: Update all the operation
routing classes to use the modified base class correctly.
* server/CommPeer.h, server/CommPeer.cpp: Re-factor CommPeer to
only be used for initiating peer connections.
* server/Admin.cpp: Use the modified CommPeer constructor.
* server/CommClient.h, server/CommClient.cpp: Make the connection
a pointer rather than a reference, and pass it in during setup.
* server/CommClientFactory.h, server/CommClientFactory.cpp: Re-factor
the commclient factory to take connection type as a template param,
and create the client and connection objects separately.
* server/server.cpp: Use the modified CommClientFactory parameter.
* server/Makefile.am: Remove the different kinds of client class
from the build.
* common/Identified.cpp, common/Identified.h, rulesets/Character.h,
rulesets/LocatedEntity.h, server/Account.h, server/Admin.cpp,
server/CommClient.cpp, server/CommClient.h, server/Connection.cpp,
server/Connection.h, server/ExternalMind.h,
server/ExternalProperty.cpp, server/ExternalProperty.h,
server/Lobby.h, server/Master.h, server/Peer.h,
server/ServerRouting.h, server/SlaveClientConnection.h:
Rename IdentifiedRouter to Router as it's the base class
for pretty much all routers.
* client/BaseClient.cpp, common/BaseEntity.cpp, common/BaseEntity.h,
common/Identified.cpp, common/Identified.h, common/Makefile.am,
common/OOGThing.cpp, common/OOGThing.h, common/OperationRouter.cpp,
common/OperationRouter.h, rulesets/Character.h, rulesets/Entity.h,
rulesets/LocatedEntity.cpp, rulesets/LocatedEntity.h,
server/Account.cpp, server/Account.h, server/Admin.cpp,
server/CommClient.cpp, server/CommClient.h, server/Connection.cpp,
server/Connection.h, server/ExternalMind.cpp, server/ExternalMind.h,
server/ExternalProperty.cpp, server/ExternalProperty.h,
server/Lobby.cpp, server/Lobby.h, server/Master.cpp, server/Master.h,
server/Peer.cpp, server/Peer.h, server/ServerRouting.cpp,
server/ServerRouting.h, server/SlaveClientConnection.cpp,
server/SlaveClientConnection.h: Factor out the more pointless base
classes, in favor of simple interface. Move destroyed signal to
Entity, which is the only place it is needed.
* server/Admin.cpp, server/Connection.cpp, server/Connection.h,
server/ServerRouting.cpp, server/ServerRouting.h: Use the much
simpler OperationRouter interface when handling routing operations
round the server.
* 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/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.
* common/log.cpp, common/log.h, common/BaseEntity.cpp,
common/BaseEntity.h: Switch to taking a C++ string reference rather
than a char *, for the rest of the logging and error related
calls.
* common/Database.cpp, common/log.cpp, common/log.h,
rulesets/PythonMindScript.cpp, server/Account.cpp,
server/Admin.cpp, server/Connection.cpp, server/Player.cpp,
tools/cyisoload.cpp: Convert over to using the new API correctly.
* 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:
* common/const.h: Remove obsolete config option to disable
range checks and calculations.
* client/ObserverClient.cpp, rulesets/Movement.cpp,
server/Admin.cpp, tools/AdminClient.h, tools/cycmd.cpp:
Remove const.h from files which no longer require it.
* rulesets/Python_API.cpp: Remove python bindings for obsolete
constants.
* rulesets/Thing.cpp, rulesets/World.cpp, server/WorldRouter.cpp:
Remove obsolete rotten code for handling sight without ranges.
* tests/consttest.cpp: Remove tests for removed constants.
* rulesets/Entity.cpp, server/Account.cpp, server/Admin.cpp,
server/Connection.cpp, server/EntityFactory.h,
server/Persistor_impl.h, tools/cycmd.cpp:
Switch from using deprecated sigc++ 1.2 headers to the right
sigc++ 2.0 equivalents.
* common/BaseEntity.cpp, rulesets/Character.cpp, rulesets/Creator.cpp,
server/Account.cpp, server/Admin.cpp, server/Connection.cpp,
server/Lobby.cpp, server/WorldRouter.cpp: Don't bother with serial
numbers on ops generated inside the server. They just leak and upset
clients.
* common/accountbase.cpp, server/Admin.cpp, server/Persistance.cpp,
server/server.cpp, server/slave.cpp: Add more checks to ensure
that not getting an ID from the database always fails cleanly.
* 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/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/BaseEntity.h, common/BaseWorld.h, common/Property.h,
modules/Location.h, rulesets/Entity.cpp, rulesets/Entity.h,
server/Account.cpp, server/Account.h, server/Admin.cpp,
server/Admin.h, server/Connection.cpp, server/Connection.h,
server/Persistor.cpp, server/Persistor.h, server/Persistor_impl.h,
tools/cycmd.cpp: Update usage of sigc++ to the native 2.0 API
rather than the deprecated compatability API. Eleminate the
manual disconnection code for deleted objects, as this is now
handled automatically by sigc::trackable.
* common/types.h: Switch the core object index for the server, and
the subscription index for connections to use integer IDs.
* server/Admin.cpp, server/Connection.cpp, server/Connection.h,
server/ExternalMind.cpp, server/ServerRouting.h:
Modify code to use integer object indices.
* server/Lobby.cpp: Remove debug output.
* server/Admin.cpp, server/CommPeer.cpp, server/CommPeer.h,
server/CommPeerListener.cpp, server/Peer.cpp, server/Peer.h:
Re-work classes for peer connections to use integer IDs.
* server/Lobby.cpp, server/Lobby.h: Modify interface so its more
obvious that lobby only handles accounts, and adjust to have
integer ID.
* server/Connection.cpp, server/Connection.h,
server/TrustedConnection.cpp, server/TrustedConnection.h: Use
integer IDs, and modify to match new Lobby API changes.
* server/ServerRouting.cpp, server/ServerRouting.h, server/server.cpp:
Modify server to have integer ID, and handle ID for Lobby as well.
* server/CommListener.cpp, server/CommLocalClient.cpp,
server/CommLocalClient.h, server/CommRemoteClient.cpp,
server/CommRemoteClient.h, server/CommUnixListener.cpp:
Modify communication classes for normal clients to handle
integer IDs on the connection classes.