Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErwin Coumans <blender@erwincoumans.com>2006-11-21 15:26:05 +0300
committerErwin Coumans <blender@erwincoumans.com>2006-11-21 15:26:05 +0300
commit8ad6d7f401b5160cf1a762a27b844c7dd42be8a7 (patch)
treee9dd49d734df0f964ad0e724628f5c8a8f3aad6b /source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
parent318b98fc9a8fe31a6b71c6e71eb0f486fd59b25a (diff)
more Bullet 2.x upgrading. fair amount of functionality is now restored, not all yet.
Diffstat (limited to 'source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp')
-rw-r--r--source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
index d637df95756..ca75b77dfec 100644
--- a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
+++ b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
@@ -889,12 +889,7 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
CcdConstructionInfo ci;
class PHY_IMotionState* motionstate = new KX_MotionState(gameobj->GetSGNode());
- if (objprop->m_ghost)
- {
-
- ci.m_collisionFlags |= btCollisionObject::CF_NO_CONTACT_RESPONSE;
- }
if (!objprop->m_dyna)
{
@@ -973,7 +968,7 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
halfExtents /= 2.f;
- bm = new btConeShape(objprop->m_boundobject.c.m_radius,objprop->m_boundobject.c.m_height);
+ bm = new btConeShapeZ(objprop->m_boundobject.c.m_radius,objprop->m_boundobject.c.m_height);
bm->calculateLocalInertia(ci.m_mass,ci.m_localInertiaTensor);
break;
@@ -1078,10 +1073,15 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
gameobj->SetPhysicsController(physicscontroller,isbulletdyna);
physicscontroller->setNewClientInfo(gameobj->getClientInfo());
+ btRigidBody* rbody = physicscontroller->GetRigidBody();
if (objprop->m_disableSleeping)
- physicscontroller->GetRigidBody()->setActivationState(DISABLE_DEACTIVATION);
+ rbody->setActivationState(DISABLE_DEACTIVATION);
+ if (objprop->m_ghost)
+ {
+ rbody->setCollisionFlags(rbody->getCollisionFlags() | btCollisionObject::CF_NO_CONTACT_RESPONSE);
+ }
if (objprop->m_dyna && !objprop->m_angular_rigidbody)
{
/*