* physics/Vector3D.h, physics/Vector3D.cpp: Move a bunch of inline
functions in the header to be non-inline in the body. Use
the forward declaraions in wfmath/const.h instead of having to
include the full headers.
* rulesets/Motion.cpp, rulesets/Motion.h, rulesets/Movement.h,
rulesets/Py_Point3D.h, rulesets/Py_Vector3D.h: Include wfmath
headers as required.
* 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.
* 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.
* 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/Persistance.cpp, server/Connection.cpp, server/Admin.cpp,
server/Account.cpp, rulesets/Thing.h, rulesets/Thing.cpp,
rulesets/Stackable.cpp, rulesets/Py_Location.cpp,
rulesets/Entity.h, rulesets/Entity.cpp, rulesets/Creator.cpp,
rulesets/Character.cpp, common/BaseEntity.h, common/BaseEntity.cpp:
Get rid of flags used to determine object type, and get rid
of use of C style casts to cast between object pointers.
Replace both with dynamic casts. Clean up some stray casts
left behind from older versions of object structure.
* physics/Vector3D.cpp: Added note explaining when to use
Vector3D::relMag() instead of mag().
by readline on some systems.
* physics/Vector3D.cpp: Added definition of static consts members.
I really don't understand why these are required, and as far
as I can tell this does not conform to the C++ spec.
* server/Makefile.am, aiclient/Makefile.am: Re-ordered linking so
that physics is picked up.
Al Riddoch <alriddoch@zepler.org>
* Substantial re-work of object model. Moved many attributes out
of BaseEntity class. Changed WoldRouter so it now handles
objects in terms of Entity, rather than BaseEntity.
* Code cleanups, including removing reduntant includes, and
getting rid of C style comments.
* Fixed the way attributes are handled in Set operations and
when merging from an Atlas::Message::Object. This fixed
problem with setting gender of characters.
* rulesets/Pedestrian.*, rulesets/Movement.*: Re-named
Movement variables to make them clearer. Added in
separate handling for collisions from moving to
target position. Modified collision handling so
objects can slide next to each other.
* rulesets/Thing.cpp, rulesets/Character.cpp: Cleaned up and
rationalised movement code. Much shorter, faster and
more compact than before.
* Made better use of iterators throughout, eliminating unnecessary
lookups, and copying of data.
* Moved all virtual functions out of header files, making
less work for the linker.
* Made more use of const references to avoid the need to copy
data before being able to inspect it.
Al Riddoch <alriddoch@zepler.org>
functions to work out when an entity inside a box will hit the
outside.
* rulesets/Character.cpp: Added check in collision code to see when
entity will leave the bouding box of its current parent.
Al Riddoch (alriddoch@zepler.org)
* */*: Fixed mistake in copyright statement.
* tools/cypasswd.cpp: Fixed usage message.
* tools/cycmd.cpp: Added tools for sending administrative commands
to server.
* server/server.cpp: Send terminate instruction to metaserver on
server shutdown.
Al Riddoch (alriddoch@zepler.org)
* Throughout entire code base:
Removed all obsolete code and commented out code relating to porting
from python. Removed interim data types bad_type and None. Added
const throughout where apropriate. Change various flags to bool
type. Removed unused members.
* Added TODO list.
Al
log.
* Added in lots of deletes to sort memory leaks.
* More python tweaks.
* Implemented status attributes of thing.
* Re-wrote some code which needlessly creates objects in the
free store.
Very nearly all works now.
TODO:
Tidy some of the rest of the leak handling, including all of the stuff
to deal with connections going down.
Sort out how mind gets its attributes set and updated.
Sort out iritating python error in init of Vector3D
delete oplists in OplistObjects. The pointers are never passed back.
Al
atlas is correctly.
Implemented most of the mind<->body interaction required for Character(),
and most of the operation handling for Thing(). Entities should now be
able to do stuff in the world.
Left to do, I need to work out how to implement the set operation,
and then work out a mechanism for returning multiple operation from
a function.
Al
botched attempt to add support for optimised non-string object ids.
Modified the idle routine so it now delivers all the waiting operations
rather than only one per cycle.
Al