forked from teamnwah/openmw-tes3coop
Merge remote-tracking branch 'scrawl/master'
This commit is contained in:
commit
4d80bc009a
2 changed files with 3 additions and 6 deletions
|
@ -2,6 +2,7 @@
|
||||||
#include "previewwidget.hpp"
|
#include "previewwidget.hpp"
|
||||||
|
|
||||||
#include <OgreSceneManager.h>
|
#include <OgreSceneManager.h>
|
||||||
|
#include <OgreSceneNode.h>
|
||||||
|
|
||||||
#include "../../model/world/data.hpp"
|
#include "../../model/world/data.hpp"
|
||||||
#include "../../model/world/idtable.hpp"
|
#include "../../model/world/idtable.hpp"
|
||||||
|
|
|
@ -1245,13 +1245,9 @@ void CharacterController::update(float duration)
|
||||||
else //avoid z-rotating for knockdown
|
else //avoid z-rotating for knockdown
|
||||||
world->rotateObject(mPtr, rot.x, rot.y, 0.0f, true);
|
world->rotateObject(mPtr, rot.x, rot.y, 0.0f, true);
|
||||||
|
|
||||||
// always control actual movement by animation unless this:
|
if (mMovementAnimVelocity == 0)
|
||||||
// FIXME: actor falling/landing should be controlled by physics engine
|
|
||||||
if(mMovementAnimVelocity == 0.0f && (vec.length() > 0.0f || mJumpState != JumpState_None))
|
|
||||||
{
|
|
||||||
world->queueMovement(mPtr, vec);
|
world->queueMovement(mPtr, vec);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
movement = vec;
|
movement = vec;
|
||||||
cls.getMovementSettings(mPtr).mPosition[0] = cls.getMovementSettings(mPtr).mPosition[1] = cls.getMovementSettings(mPtr).mPosition[2] = 0;
|
cls.getMovementSettings(mPtr).mPosition[0] = cls.getMovementSettings(mPtr).mPosition[1] = cls.getMovementSettings(mPtr).mPosition[2] = 0;
|
||||||
|
@ -1290,7 +1286,7 @@ void CharacterController::update(float duration)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update movement
|
// Update movement
|
||||||
if(moved.squaredLength() > 1.0f)
|
if(mMovementAnimVelocity > 0)
|
||||||
world->queueMovement(mPtr, moved);
|
world->queueMovement(mPtr, moved);
|
||||||
}
|
}
|
||||||
mSkipAnim = false;
|
mSkipAnim = false;
|
||||||
|
|
Loading…
Reference in a new issue