mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-20 12:53:51 +00:00
fix the fall bug when using ToggleCollision
This commit is contained in:
parent
25b3cf9359
commit
8f9b8749d4
4 changed files with 13 additions and 0 deletions
|
@ -140,6 +140,10 @@ btKinematicCharacterController::~btKinematicCharacterController ()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void btKinematicCharacterController::setVerticalVelocity(float z)
|
||||||
|
{
|
||||||
|
m_verticalVelocity = z;
|
||||||
|
}
|
||||||
|
|
||||||
bool btKinematicCharacterController::recoverFromPenetration( btCollisionWorld* collisionWorld )
|
bool btKinematicCharacterController::recoverFromPenetration( btCollisionWorld* collisionWorld )
|
||||||
{
|
{
|
||||||
|
|
|
@ -101,6 +101,7 @@ public:
|
||||||
|
|
||||||
~btKinematicCharacterController ();
|
~btKinematicCharacterController ();
|
||||||
|
|
||||||
|
void setVerticalVelocity(float z);
|
||||||
|
|
||||||
///btActionInterface interface
|
///btActionInterface interface
|
||||||
virtual void updateAction( btCollisionWorld* collisionWorld, btScalar deltaTime )
|
virtual void updateAction( btCollisionWorld* collisionWorld, btScalar deltaTime )
|
||||||
|
|
|
@ -76,6 +76,7 @@ namespace Physic
|
||||||
void PhysicActor::setGravity(float gravity)
|
void PhysicActor::setGravity(float gravity)
|
||||||
{
|
{
|
||||||
mCharacter->setGravity(gravity);
|
mCharacter->setGravity(gravity);
|
||||||
|
//mCharacter->
|
||||||
}
|
}
|
||||||
|
|
||||||
void PhysicActor::enableCollisions(bool collision)
|
void PhysicActor::enableCollisions(bool collision)
|
||||||
|
@ -83,6 +84,11 @@ namespace Physic
|
||||||
mCharacter->mCollision = collision;
|
mCharacter->mCollision = collision;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void PhysicActor::setVerticalVelocity(float z)
|
||||||
|
{
|
||||||
|
mCharacter->setVerticalVelocity(z);
|
||||||
|
}
|
||||||
|
|
||||||
bool PhysicActor::getCollisionMode()
|
bool PhysicActor::getCollisionMode()
|
||||||
{
|
{
|
||||||
return mCharacter->mCollision;
|
return mCharacter->mCollision;
|
||||||
|
|
|
@ -68,6 +68,8 @@ namespace Physic
|
||||||
|
|
||||||
void setGravity(float gravity);
|
void setGravity(float gravity);
|
||||||
|
|
||||||
|
void setVerticalVelocity(float z);
|
||||||
|
|
||||||
void enableCollisions(bool collision);
|
void enableCollisions(bool collision);
|
||||||
|
|
||||||
bool getCollisionMode();
|
bool getCollisionMode();
|
||||||
|
|
Loading…
Reference in a new issue