* 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.
* 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.
* client/CharacterClient.cpp, client/ClientConnection.h,
rulesets/Character.cpp, rulesets/Character.h, tools/cyaddrules.cpp,
tools/cyconfig.cpp, tools/cyconvertrules.cpp, tools/cyctrl.cpp,
tools/cydumprules.cpp, tools/cyloadrules.cpp, tools/cypasswd.cpp:
Add inline documentation.
* client/CharacterClient.h, client/CharacterClient.cpp: Remove
overriden sight operation handlers, as they are no longer
present in the base class, and will never be called.
* client/ClientConnection.h: Remove obsolete unimplemented template
declaration.
* rulesets/Entity.cpp: Remove documentation for an argument that was
never there.
* tools/cyctrl.cpp: Mark as removed from the build.
* Add a FIXME about removing hard coded gender property
* client/CharacterClient.cpp: Remove pointless class scope when
acessing member variable.
* tools/cycmd.cpp: Don't wait forever for responses from the
server to commands.
* common/BaseEntity.h, common/BaseEntity.cpp: Add an integer ID
member variable, and accessor, and require it to be initialised
along with string ID in constructor.
* common/const.cpp, common/const.h: Add a const for the integer value
of the world ID.
* rulesets/Area.cpp, rulesets/Area.h, rulesets/BaseMind.cpp,
rulesets/BaseMind.h, rulesets/Character.cpp, rulesets/Character.h,
rulesets/Creator.cpp, rulesets/Creator.h, rulesets/Entity.cpp,
rulesets/Entity.h, rulesets/Food.cpp, rulesets/Food.h,
rulesets/Line.cpp, rulesets/Line.h, rulesets/MemEntity.cpp,
rulesets/MemEntity.h, rulesets/Plant.cpp, rulesets/Plant.h,
rulesets/Stackable.cpp, rulesets/Stackable.h, rulesets/Structure.cpp,
rulesets/Structure.h, rulesets/Thing.cpp, rulesets/Thing.h,
rulesets/World.cpp, rulesets/World.h: Add integer ID handling to
constructors of all in-game entity classes.
* rulesets/MemMap.cpp: Initialise integer ID of entities in the mind
map.
* rulesets/MindFactory.cpp, rulesets/MindFactory.h: Handle integer
ID when constructing mind objects.
* server/EntityFactory.cpp, server/EntityFactory.h,
server/PersistantThingFactory_impl.h: Handle integer
ID when contructing entity objects.
* server/Restoration.cpp, server/Restoration.h, server/Restorer.h,
server/Restorer_impl.h: Handle integer ID when restoring from
database.
* server/WorldRouter.cpp: Assign integer ID when constructing the
world.
* client/CharacterClient.cpp: Add some debug output, and fix a bug
which ignored all replies to client ops.
* server/WorldRouter.cpp: Fix a bug in OpQueEntry which stored
a smart pointer reference rather than really storing the
smart pointer.
* rulesets/Entity.cpp, rulesets/Thing.cpp: Move Create op subscription
into Entity, as that is where the method is.
* rulesets/World.cpp: Create a boulder entity when the pickaxe
is used on rocky terain.
* client/CharacterClient.cpp: Don't process ops from the server in
* modules/WorldTime.h, modules/WorldTime.cpp: Clean up typedef
and member names, and implement querying the season.
* client/CharacterClient.cpp: Remove some obsolete unconverted
Python code.
* physics/Collision.h: Update some comments.
* rulesets/Py_WorldTime.cpp: Implement access to season lookup
from scripts.
* client/CharacterClient.cpp, client/CharacterClient.h: Prefix
members with m_.
* client/CommClient.cpp, client/CommClient.h, client/ObserverClient.h:
Rename CommClient to BaseClient to avoid name clash with CommClient
in the server directory.
* common/BaseEntity.cpp, common/BaseEntity.h,
rulesets/Character.cpp, rulesets/Creator.cpp,
server/CommClient.cpp, server/ExternalMind.cpp,
server/ExternalMind.h, client/CharacterClient.cpp,
client/CommClient.cpp: Remove the message method from BaseEntity
and everything that inherits from it - its redundant.
* tests/Charactertest.cpp, tests/Creatortest.cpp,
tests/EntityExerciser.h: Sort out the tests so they no longer use
message, and try and get the character class tests working a bit
better.
* server/WorldRouter.cpp: Slightly randomize starting position
of characters to avoid getting stuck.
* rulesets/mason/define_world.py: Move the world contents around a bit
to make room for larger spawn area.
* rulesets/World.cpp: Make sure we don't degfault if we get a height
outside current area of terrain.
* client/ClientConnection.cpp, client/CharacterClient.cpp:
Set an error condition if the server disconnects unexpectedly,
and thus return an error to the script causing an exit.
* client/CharacterClient.cpp, client/ClientConnection.cpp,
client/CommClient.cpp, server/Account.cpp,
server/CommClient.cpp, server/Connection.cpp,
tools/cycmd.cpp: Update required headers, now that they
are not all pulled in by Atlas/Objects/Decoder.h.
* server/Lobby.cpp: Add some debugging messages.
* server/CommServer.cpp: Tweak select loop so that closed connections
are cleaned up as soon as they are detected.
* rulesets/World.cpp: Make demo terrain a bit more mountainous.
* Convert entire codebase over to using Atlas-C++ 0.4.90, as
start of transition to 0.6 API.
* Use " instead of < when including application headers.
* Re-work the interface between server and worldrouter objects
so that the are less tied together, and more flexible.
* common/globals.cpp: Only persist this sessions command line
options if the user is overriding the installation directory.
* cyphesis.vconf, client/Py_CreatorClient.cpp,
client/Py_CreatorClient.h, client/client.cpp:
Add client functionality to allow diferent scripts to be run to
perform different functions on the server.
* client/CharacterClient.cpp: Add debug option.
* rulesets/Character.h: Make mind operation functions virtual,
so they can be overridden.
* common/BaseWorld.h, server/WorldRouter.cpp,
server/WorldRouter.h: Add server functions to search for
entities by name or type.
* rulesets/Creator.h, rulesets/Creator.cpp: Allow creator to
specify a look without an id to search for entities with
a given name or type.
* client/CreatorClient.cpp, client/CreatorClient.h,
client/ObserverClient.cpp, client/ObserverClient.h,
client/Py_CreatorClient.cpp, rulesets/basic/editor.py,
rulesets/mason/define_world.py:
Add support for looking for entities in the world by name or
type from client script, so client scripts can modify existing
world.
* rulesets/Entity.cpp, rulesets/Movement.cpp,
rulesets/Py_Object.cpp, rulesets/Py_Operation.cpp,
rulesets/Py_Oplist.cpp, rulesets/Python_API.cpp,
rulesets/Stackable.cpp, rulesets/Thing.cpp,
rulesets/World.cpp, server/Account.cpp,
server/CommServer.cpp, server/Connection.cpp,
server/Player.cpp, server/ServerRouting.cpp,
server/server.cpp, tools/cycmd.cpp,
tools/cywatchdog.cpp: Code formatting cleanups.
* rulesets/basic/world/objects/tools/Bow.py: Fix up bow so it now
fires correctly.
* ALL: Cleaned up headers into correct order.
* common/log.h, common/log.cpp: Write some logging code which
handles message of different types using syslog or standard
error, depending on whether we are running as a daemon.
* ALL: Switched to using log() for all output.
* server/server.cpp, rulesets/Python_API.cpp, rulesets/Line.cpp,
modules/Location.cpp, client/CreatorClient.cpp:
Removed some obsolete comments.
* server/WorldRouter.h, server/WorldRouter.cpp: Add member to
deliver operation to known entity. Make use if it to avoid
having to recurse in operation() when broadcasting. Ensure
that the container of new entities is managed from here.
* rulesets/Thing.cpp: Tell world to create new entities at the
same position as the creator if no other info is provided.
Do not attempt to handle setting up the default containership
of entity once created, as this is always handled by the
WorldRouter from now on.
* rulesets/Py_World.cpp: Implement getting time info from world.
* rulesets/Py_Location.cpp: Implement handling of the orientation
attribute from python.
* rulesets/MemMap.cpp: Update comments about unimplemented code.
* rulesets/Creator.cpp: Check for string.empty() instead of "".
* rulesets/BaseMind.cpp: Remove reference python code.
Cleanly handle and delete operations returned when savinf mind state.
* client/CharacterClient.cpp: Move delete to the right place.
* TODO: Update on important issues which allow easy DOS attacks.
* client/ClientConnection.cpp, client/ClientConnection.h:
Cleaned up unused code from ClientConnection class.
* client/client.cpp: Removed monitoring section of client
so it simply exits once the world is initialised.
* rulesets/basic/mind/goals/humanoid/werewolf.py:
Started work on dynamic goals for playing werewolf.
* rulesets/werewolf/define_world.py: Added in the mayor, who runs
werewolf games.
* common/BaseEntity.h: Made id of entity private, and implemented
accessors.
Al Riddoch <alriddoch@zepler.org>
* client/CreatorClient.cpp: Fixed processing the response
to a create operation, and cleaned up debugging output.
* client/ObjserverClient.cpp, client/ObserverClient.h,
client/client.cpp: Added setup method, which which handles
connecting, negotiation, logging in and creating character.
* client/Py_CreatorClient.cpp: Added check if make() failed.
* rulesets/Python_API.cpp: Fixed setting the import hooks
list properlly to include the ruleset list in use, instead
of hardcoding it.
* rulesets/acorn/define_world.py: Copied define_world.py script
from client directory for Acorn.
* rulesets/basic/editor.py: Modified to be used from C++ core.
* rulesets/basic/mind/goals/__init__.py,
rulesets/basic/mind/goals/humanoid/werewolf.py:
Added in goals file to contain goals related to werewolf.
* rulesets/basic/mind/panlingua/interlinguish.py:
Added in vote and execute verbs for werewolf.
* rulesets/werewolf: Added in new ruleset for werewolf.
Al Riddoch <alriddoch@zepler.org>
* server/Player.cpp: Arg order of std::string.compare() is
incompatable between recent libstdc++ versions. Switch
back to old version, still in most common use.
* rulesets/Thing.cpp: Set refno on ops handled in game.
* rulesets/Python_API.cpp: Modify Entity() python constructor
so that commonly used attributes from old atlas are translated
to their modern equivalents.
* rulesets/Py_Thing.cpp, rulesets/Py_Mind.cpp: Differentiate
between previously identical error messages in several places.
* rulesets/Py_Object.cpp: Rework conversion of python dict to
Atlas map to be more efficient and clean.
* rulesets/Py_Location.cpp: Rework setting of vector parts of
location so that it can accept vectors from python in more
formats, including lists and tuples.
* rulesets/Creator.h, rulesets/Character.h, common/BaseEntity.h:
Re-order virtual methods declarations to fit a convention.
* common/stringstream.h: Hardcode use of local stringstream class,
as the version provided with older libstdc++ seems to be broken.
* common/database.cpp: Use the common header to pick the right
stringstream implementation.
* common/BaseWorld.cpp, server/Persistance.cpp: Removed unused
stringstream include.
* rulesets/Creator.cpp: Added extra debug output.
* client/define_world.h, client/define_world.cpp, client/CommClient.h:
Use CreatorClient to store Creators mind, instead of BaseMind.
* client/client.cpp,
client/ObserverClient.h, client/ObserverClient.cpp,
client/CreatorClient.h, client/CommClient.h, client/CommClient.cpp:
Modify method names to fit capitalisation conventions.
* client/CreatorClient.cpp: Implement creation of in-game entities,
using creator entity.
* client/CommClient.cpp: Added correct client side monitoring of
creator entity.
* client/ClientConnection.h, client/ClientConnection.cpp: Added
pending method to establish if ops are in the queue. Switched send()
method so we only send ops. Add setting of serialno of sent
ops, starting with an offset of 512.
* client/CharacterClient.h: Removed unused member, opFound.
* client/CharacterClient.cpp: Debugged sendAndWait() method.
Al Riddoch <alriddoch@zepler.org>
* client/CommClient.cpp: Fixed leak of operations.
* client/CharacterClient.h, client/CharacterClient.cpp,
client/CreatorClient.h, client/CreatorClient.cpp:
Added in mind classes for handling creator on client side.
Al Riddoch <alriddoch@zepler.org>