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:
Diffstat (limited to 'source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp')
-rw-r--r--source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
index bde50588fd3..16513a97d60 100644
--- a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
+++ b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
@@ -435,6 +435,11 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
shapeInfo->Release();
gameobj->SetPhysicsController(physicscontroller,isbulletdyna);
+
+ // record animation for dynamic objects
+ if (isbulletdyna)
+ gameobj->SetRecordAnimation(true);
+
// don't add automatically sensor object, they are added when a collision sensor is registered
if (!isbulletsensor && objprop->m_in_active_layer)
{
@@ -493,6 +498,11 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
gameobj->getClientInfo()->m_type =
(isbulletsensor) ? ((isActor) ? KX_ClientObjectInfo::OBACTORSENSOR : KX_ClientObjectInfo::OBSENSOR) :
(isActor) ? KX_ClientObjectInfo::ACTOR : KX_ClientObjectInfo::STATIC;
+
+ // should we record animation for this object?
+ if (objprop->m_record_animation)
+ gameobj->SetRecordAnimation(true);
+
// store materialname in auxinfo, needed for touchsensors
if (meshobj)
{