implement base Ragdoll::stepRagdollForward()

This commit is contained in:
Andrew Meadows 2014-07-25 15:22:25 -07:00
parent 2ddca4fbf9
commit b2c2cfec79
2 changed files with 8 additions and 1 deletions

View file

@ -21,6 +21,13 @@ Ragdoll::Ragdoll() {
Ragdoll::~Ragdoll() {
clearRagdollConstraintsAndPoints();
}
void Ragdoll::stepRagdollForward(float deltaTime) {
int numPoints = _ragdollPoints.size();
for (int i = 0; i < numPoints; ++i) {
_ragdollPoints[i].integrateForward();
}
}
void Ragdoll::clearRagdollConstraintsAndPoints() {
int numConstraints = _ragdollConstraints.size();

View file

@ -26,7 +26,7 @@ public:
Ragdoll();
virtual ~Ragdoll();
virtual void stepRagdollForward(float deltaTime) = 0;
virtual void stepRagdollForward(float deltaTime);
/// \return max distance of point movement
float enforceRagdollConstraints();