* modules/Location.cpp, modules/Location.h, rulesets/Python_API.cpp:
Implement a function for determining the horizontal distance
between two locations neglecting height difference, as for
locations on the terrain it is not relevant.
* rulesets/basic/mind/goals/common/move.py: Improve the coding of
the move_me_to_it goal, so distance determination is more effective.
Make distance independant of height.
Relax distances at which character is concidered to have arrived at
its destination.
* rulesets/basic/mind/Goal.py: Modify goal so that it understands
that a subgoal can be unfulfilled, but still not need to take any
action.
* server/WorldRouter.cpp: Fix a problem where entities contained by
other entities had their height adjusted incorrectly.
* rulesets/basic/world/objects/elements/Fire.py: Allow fires to be
moved.
* rulesets/Python_API.cpp: Add constructor for BBox.
* data/mason.xml: Add a torch. Add burn_speed attributes to a
bunch more entity classes.
* rulesets/mason/world/objects/tools/Torch.py: Script for torch.
* rulesets/Python_Script_Utils.h, rulesets/Python_API.h,
rulesets/Python_API.cpp, rulesets/MindFactory.cpp,
server/EntityFactory.cpp: Move functions related to creating
script objects into a new header, to avoid namespace pollution.
* rulesets/Entity.h, rulesets/BaseMind.h: Make scriptSubscribe
virtual so it can be overriden in BaseMind.
* rulesets/Python_API.cpp: Get rid of template for Subscribe_Script
as its no longer necessary now scriptSubscribe is virtual.
* tools/AdminClient.cpp, tools/AdminClient.h, tools/cyaddrules.cpp:
New tool to load new rules into a running server.
* data/mason.xml, rulesets/mason/world/objects/tools/Rope.py:
Experimental type for a rope.
* man/cyclient.sgml, man/cycmd.sgml, man/cyphesis-tools.sgml,
man/cyphesis.sgml: Add SEE ALSO sections to the man pages.
* rulesets/Python_API.cpp: Clean up variable names.
* server/Admin.cpp: Send an info response when types are
installed from the client.
* tools/cyloadrules.cpp: Correct copyright dates.
* rulesets/Python_API.cpp: Re-write the code for extracting operation
subscriptions from python classes so its now more efficient and
picks up methods from base classes.
* rulesets/basic/mind/BaseMind.py, rulesets/basic/mind/NPCMind.py,
rulesets/basic/world/objects/Thing.py: Rename some methods
which have match the signature of operation handlers.
* rulesets/Character.cpp: Include POS from a Use op argument when
building the arg for the resulting op.
* rulesets/Py_Point3D.cpp: Add a print handler.
* rulesets/Python_API.cpp: When constructing Point3D or Vector3D
accept an Atlas list as well as a standard python list.
* rulesets/Py_Operation.cpp, rulesets/Py_Optime.cpp,
rulesets/Py_Optime.h rulesets/Python_API.cpp:
Remove the Optime class from the API and force scripts to use
setFutureSeconds() to modify operation dispatch time.
* rulesets/acorn/world/objects/Weather.py,
rulesets/acorn/world/objects/plants/Tree.py,
rulesets/acorn/world/objects/plants/seeds/Acorn.py,
rulesets/acorn/world/objects/plants/seeds/Apple.py,
rulesets/acorn/world/objects/plants/seeds/Seed.py,
rulesets/basic/mind/NPCMind.py,
rulesets/basic/mind/goals/common/move.py,
rulesets/basic/world/objects/animals/Animal.py,
rulesets/basic/world/objects/buildings/House.py,
rulesets/basic/world/objects/elements/Fire.py,
rulesets/basic/world/objects/plants/Tree.py,
rulesets/basic/world/objects/tools/Bow.py,
rulesets/mason/world/objects/Weather.py,
rulesets/mason/world/objects/plants/seeds/Acorn.py,
rulesets/mason/world/objects/plants/seeds/Apple.py,
rulesets/mason/world/objects/plants/seeds/Fircone.py,
rulesets/mason/world/objects/plants/seeds/Seed.py:
Fix up all the python scripts to use setFutureSeconds on
ops instead of time.sadd.
* rulesets/Py_Vector3D.cpp: Allow setting of Vector3D attributes
x y and z.
* rulesets/Python_API.cpp: Fix bug in calculating orientation
Quaternion for rotation between two unit vectors.
* rulesets/basic/mind/NPCMind.py: Implement a method which calculates
the orientation required to face another entity. Use it to face
a character which wants to buy something.
* rulesets/mason/define_world.py: Tweak orientation of pig merchant
so he doesn't end up upside down.
* server/Makefile.am: Remove cyslave from the build for now, as its
not functional.
* rulesets/Python_API.cpp: Clear up the logging wrappers.
Add python wrapper for squareDistance which is more efficient
in the goal code that distanceTo. Remove some old python functions
which serve no purpose. Move distanceTo and squareDistance into
their own module.
* rulesets/basic/mind/NPCMind.py: Remove obsolete import.
* rulesets/basic/mind/goals/common/misc_goal.py,
rulesets/basic/mind/goals/common/move.py,
rulesets/basic/mind/goals/humanoid/construction.py: Use the new
physics.square_distance where linear distance is required
in goals.
* rulesets/MindFactory.cpp, rulesets/Py_Object.h,
rulesets/Py_Operation.h, rulesets/PythonScript.h,
rulesets/Python_API.cpp: Include Python.h first to avoid some
header conflicts.
* rulesets/Plant.h, rulesets/Plant.cpp: Add handler for chop so
we can chop down vegetation.
* rulesets/basic/world/objects/tools/Axe.py: Modify Axe to comply
with new tool use mechanism.
* rulesets/basic/mind/goals/humanoid/transaction.py,
rulesets/basic/mind/goals/common/misc_goal.py,
rulesets/mason/define_world.py: Update butcher goals to use tool
use mechanism.
* rulesets/Python_API.cpp: Ensure entities created from Python
have an objtype.
* server/WorldRouter.cpp: Add a note to check the code.
* rulesets/basic/mind/goals/humanoid/transaction.py: Remove debug
output.
* rulesets/basic/mind/goals/common/move.py: New goal to accompany
another person.
* rulesets/basic/mind/goals/common/misc_goal.py: Use new accompany
goal for hirelings.
* rulesets/Python_API.cpp: Fix distance_to arg checking error
message.
* rulesets/Py_Vector3D.cpp: Add square magnitude and distance checking
methods.
* modules/Location.cpp, modules/Location.h: Add new function for
usefully calculating the distance vector of another entity.
* tests/distancetest.cpp: Update test to check new distance
function.
* rulesets/Python_API.cpp: Make the new distance vector function
available to python rather than the relative postion function.
* rulesets/basic/mind/Knowledge.py, rulesets/basic/mind/NPCMind.py:
Ensure that Knowledge really does handle arbitrary triples.
* rulesets/basic/mind/goals/common/misc_goal.py: Add new version
of transaction goal for transactions for hirelings.
* rulesets/basic/mind/goals/humanoid/transaction.py: Complete
the implementation of the trigger goal for hirelings.
* rulesets/mason/define_world.py: Move the mercenaries closer to
origin for debugging.
* rulesets/Py_BBox.cpp, rulesets/Py_Location.cpp,
rulesets/Python_API.cpp: Eliminate some raw stderr output,
and replace with python errors, and calls to the log subsystem.
* physics/Vector3D.h, physics/Vector3D.cpp, modules/Location.h,
modules/Location.cpp: Convert to using WFMath::Point instead of
WFMath::Vector for position.
* physics/Collision.h, physics/Collision.cpp: Update collision code
to use new pos type.
* rulesets/Py_Point3D.h, rulesets/Py_Point3D.cpp: New python
wrappers for WFMath::Point.
* rulesets/Py_Location.cpp, rulesets/Py_Vector3D.cpp,
rulesets/Python_API.cpp:
Update python wrappers to take into account new pos type.
Ensure that only apropriate functionality is available for
point and vector.
* rulesets/Character.cpp, rulesets/Entity.cpp, rulesets/Entity.h,
rulesets/Line.cpp, rulesets/Movement.cpp, rulesets/Movement.h,
rulesets/Pedestrian.cpp, rulesets/Pedestrian.h,
rulesets/Plant.cpp, rulesets/Thing.cpp, rulesets/World.cpp,
server/EntityFactory.cpp, server/WorldRouter.cpp,
server/WorldRouter.h: Update the rest of the code for new pos
type, converting all places where entity parenting is changed
to use WFMath toParentCoords() and toLocalCoords() methods,
so that orientation is handled correctly.
* tests/transformtest.cpp: New test to ensure that toParentCoords()
and toLocalCoords() perform as expected.
* tests/Creatortest.cpp, tests/Locationtest.cpp, tests/Worldtest.cpp,
tests/collisiontest.cpp, tests/emergencetest.cpp:
Update the rest of the tests.
* rulesets/Python_API.cpp: Use the Generic operation class for ops
with no hard coded type.
* rulesets/Movement.cpp: Make the time periods used when checking
collisions dependent on the standard tick time.
* rulesets/basic/mind/NPCMind.py, rulesets/BaseMind.cpp,
modules/WorldTime.h: WorldTime now handles time in
integer seconds.
* rulesets/Python_API.cpp: Handle all variations of args with one
call to PyArg_ParseTuple as multiple calls are not
allowed.
* rulesets/Py_Location.cpp, rulesets/Py_Map.cpp, rulesets/Py_Mind.cpp,
rulesets/Py_Object.cpp, rulesets/Py_Operation.cpp,
rulesets/Py_Quaternion.cpp, rulesets/Py_Thing.cpp,
rulesets/Py_Vector3D.cpp, rulesets/Python_API.cpp:
Change some methods to use METH_NOARGS for simplicity.
* rulesets/Python_API.cpp: Clean up use of standard error to go
via the log subsystem.
* rulesets/basic/editor.py, rulesets/basic/mind/NPCMind.py,
rulesets/basic/mind/panlingua/interlinguish.py,
rulesets/mason/define_world.py:
Expand handling of the verb "know" so that knowledge
is a triple, including predicate, so that know can be used
to inform a character of any knowledge. Generalise the client
code, and tweak the client data to include the right information.
* mason.xml: Add new rule for mercenaries.
* rulesets/basic/mind/goals/humanoid/transaction.py: Add new
dynamic goal for NPCs offering their services for hire.
* rulesets/basic/mind/panlingua/interlinguish.py:
Add new words related to hirable NPCs
* rulesets/mason/define_world.py: Start programming up warriors
to be hirable.
* common/Database.cpp, common/globals.cpp, rulesets/Area.cpp,
rulesets/Python_API.cpp, server/Connection.cpp,
server/Persistance.cpp: Ensure that all output goes either via
the log system, or only in debug macros.
* tools/cycmd.cpp: Add new command to enable and disable server
monitoring.
* server/WorldRouter.cpp, common/BaseWorld.h: Add facility to
notify using a SigC signal each type an op is dispatched.
* server/CommClient.h, server/CommClient.cpp: Fix typo in
overridden method which meant it didn't work.
* server/Admin.h, server/Admin.cpp: Add handler for Monitor operation
which turns on and off sending all IG ops to the admin client.
* rulesets/Python_API.cpp, common/types.h, common/Generic.h,
common/BaseEntity.h: Fix Generic op so it can be used, and
clean up its use. Add an enumeration for monitor ops.
* common/Database.cpp: Additional error reporting for bad update
queries.
* rulesets/Plant.h: Add accessor for number of fruits.
* rulesets/Python_API.cpp: Remove experimental Python type code.
* server/Persistor_impl.h: Fix persisting plant fruits, and
character attributes.
* common/const.cpp, common/const.h, common/random.h,
physics/BBox.h, physics/Collision.cpp, physics/Collision.h,
physics/Quaternion.cpp, physics/Quaternion.h, physics/Vector3D.h,
rulesets/Movement.cpp, rulesets/Plant.cpp, rulesets/Python_API.cpp,
tests/collisiontest.cpp: Update variables relating to geometry
from double to float as this is the type used internall by
WFMath.
* physics/Vector3D.cpp, physics/Quaternion.cpp, physics/Quaternion.h:
Remove legacy code.
* server/CommPSQLSocket.cpp: Reformatting.
* client/Py_CreatorClient.cpp, client/Py_CreatorClient.h,
rulesets/Py_BBox.cpp, rulesets/Py_BBox.h, rulesets/Py_Location.cpp,
rulesets/Py_Location.h, rulesets/Py_Map.cpp, rulesets/Py_Map.h,
rulesets/Py_Mind.cpp, rulesets/Py_Mind.h, rulesets/Py_Object.cpp,
rulesets/Py_Object.h, rulesets/Py_Operation.cpp,
rulesets/Py_Operation.h, rulesets/Py_Oplist.cpp,
rulesets/Py_Oplist.h, rulesets/Py_Optime.cpp, rulesets/Py_Optime.h,
rulesets/Py_Quaternion.cpp, rulesets/Py_Quaternion.h,
rulesets/Py_Thing.cpp, rulesets/Py_Thing.h, rulesets/Py_Vector3D.cpp,
rulesets/Py_Vector3D.h, rulesets/Py_World.cpp, rulesets/Py_World.h,
rulesets/Py_WorldTime.cpp, rulesets/Py_WorldTime.h,
rulesets/PythonMindScript.cpp, rulesets/PythonThingScript.cpp,
rulesets/Python_API.cpp:
Clean up python API code, with decent names for types,
decent error reporting, and making the more paranoid checks
only present in debug build.
* common/BaseEntity.cpp, common/BaseEntity.h, server/Account.cpp:
Remove pointless method setRefnoOp, and put it in the body as
an inline method.
* common/BaseEntity.h, common/BaseWorld.cpp, common/Setup.h,
common/Tick.h, common/operations.h, common/custom.cpp,
common/types.h, common/utility.cpp, common/utility.h,
modules/Location.h, physics/Vector3D.h, rulesets/BaseMind.cpp,
rulesets/Script.h, server/EntityFactory.h:
Clean up the dependency trees using more forward declarations.
* common/inheritance.cpp, common/inheritance.h:
Move most of the implementation into the .cpp file as its
not suited to inlining.
* rulesets/MemMap.cpp, rulesets/MemMap.h, rulesets/MemMap_methods.h:
Move contents of MemMap_methods.h into the .cpp file, as it is
not suited to inlining, and remove the file from the build.
* server/Makefile.am: Move cyslave into EXTRAs so that its not
built by default.
* server/CommListener.cpp: Check that listener is open before using
it.
* common/log.h, common/log.cpp: Add log levels for output from
scripts.
* rulesets/Python_API.cpp: Add new python objects which replace
sys.stdout and sys.stderr, and redirect output to the
cyphesis logging mechanism.
* 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.
* rulesets/Py_BBox.cpp, rulesets/Py_Quaternion.cpp,
rulesets/Python_API.cpp, server/Restorer_impl.h:
Add some casts and tweaks so that wrappers and
database code work with wfmath structures.
* server/EntityFactory.cpp, rulesets/Python_API.h,
rulesets/Python_API.cpp, rulesets/PythonThingScript.h,
rulesets/PythonThingScript.cpp, rulesets/PythonMindScript.cpp,
rulesets/Py_World.cpp, rulesets/Py_Thing.h, rulesets/Py_Thing.cpp,
rulesets/Py_Operation.cpp, rulesets/Py_Map.cpp,
rulesets/Py_Location.cpp, rulesets/Movement.h,
rulesets/MemMap_methods.h, rulesets/MemMap.h, rulesets/MemMap.cpp,
rulesets/Entity.cpp, rulesets/BaseMind.cpp,
client/Py_CreatorClient.cpp:
Rename all references from thing to entity, as thing is
no longer the base class for IG entities.
* rulesets/World.h, rulesets/World.cpp, rulesets/Thing.h,
rulesets/Structure.h, rulesets/Stackable.h, rulesets/Stackable.cpp,
rulesets/Plant.h, rulesets/Plant.cpp, rulesets/Missile.h,
rulesets/Line.h, rulesets/Line.cpp, rulesets/Food.h,
rulesets/Food.cpp, rulesets/Creator.h, rulesets/Character.h,
rulesets/Character.cpp, rulesets/Area.h, rulesets/Area.cpp:
Add a typedef for the parent class of all entity classes.
* rulesets/Plant.h, rulesets/Plant.cpp:
Add in code to fully integrate hardcoded attributes.
* client/CommClient.cpp, client/CreatorClient.cpp,
client/ObserverClient.cpp, client/Py_CreatorClient.cpp,
common/BaseEntity.cpp, common/BaseEntity.h,
common/types.h, rulesets/Area.cpp, rulesets/BaseMind.cpp,
rulesets/Character.cpp, rulesets/Entity.cpp,
rulesets/Food.cpp, rulesets/Line.cpp,
rulesets/MemMap.cpp, rulesets/Pedestrian.cpp,
rulesets/Plant.cpp, rulesets/Py_Mind.cpp,
rulesets/Py_Object.cpp, rulesets/Py_Thing.cpp,
rulesets/Python_API.cpp, rulesets/Stackable.cpp,
rulesets/Thing.cpp, rulesets/World.cpp,
server/Account.cpp, server/Admin.cpp, server/CommClient.cpp,
server/CommServer.cpp, server/Connection.cpp,
server/EntityFactory.cpp, server/Lobby.cpp,
server/Persistance.cpp, server/Player.cpp,
server/ServerRouting.cpp, server/WorldRouter.cpp:
Switch to using Element as name for Atlas::Message::Object,
to avoid name clashes on Object, and bring into line with
the way Atlas-C++ will be.