diff options
author | Porteries Tristan <republicthunderbolt9@gmail.com> | 2015-08-10 15:36:54 +0300 |
---|---|---|
committer | Porteries Tristan <republicthunderbolt9@gmail.com> | 2015-08-10 18:08:11 +0300 |
commit | 3c77822f96e6ef6972c3a87467a4941d7a114744 (patch) | |
tree | 138a4d7d378e0492f070b6068ccb7123b6b7ea1e /source/gameengine/Ketsji/KX_Scene.cpp | |
parent | 0c82ba4213577c1b02b2060888f8c43c265c1637 (diff) |
BGE: Fix T19377 restore dynamics after unparenting object.
Reviewers: scorpion81
Diffstat (limited to 'source/gameengine/Ketsji/KX_Scene.cpp')
-rw-r--r-- | source/gameengine/Ketsji/KX_Scene.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/gameengine/Ketsji/KX_Scene.cpp b/source/gameengine/Ketsji/KX_Scene.cpp index fd709a87def..83126e88ce5 100644 --- a/source/gameengine/Ketsji/KX_Scene.cpp +++ b/source/gameengine/Ketsji/KX_Scene.cpp @@ -584,6 +584,10 @@ KX_GameObject* KX_Scene::AddNodeReplicaObject(class SG_IObject* node, class CVal newctrl->SetNewClientInfo(newobj->getClientInfo()); newobj->SetPhysicsController(newctrl, newobj->IsDynamic()); newctrl->PostProcessReplica(motionstate, parentctrl); + + // Child objects must be static + if (parent) + newctrl->SuspendDynamics(); } return newobj; |