diff options
author | Mitchell Stokes <mogurijin@gmail.com> | 2011-06-23 23:09:09 +0400 |
---|---|---|
committer | Mitchell Stokes <mogurijin@gmail.com> | 2011-06-23 23:09:09 +0400 |
commit | 2d2aa95227e3b00f9dc42293d4231af3dc5a99b9 (patch) | |
tree | cfc159562c6e0f48957d702104dd18f7d2cc05af /source/gameengine/Converter/BL_DeformableGameObject.h | |
parent | 413bc87e4f18bb46eeb2f2f52b5278d182b51de8 (diff) |
BGE Animations: Making shape actions work again:
* BL_DeformableGameObject is no longer responsible for handling keys, BL_ShapeDeformer is
* BL_ShapeDeformer also creates a copy of the key on construction and puts it back on the mesh when destructed. This avoids us permanently modifying Blender data.
* I'm not too fond of clearing out the key every frame, but this works and I can't think of another alternative at the moment (something may be possible with some key juggling)
Diffstat (limited to 'source/gameengine/Converter/BL_DeformableGameObject.h')
-rw-r--r-- | source/gameengine/Converter/BL_DeformableGameObject.h | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/source/gameengine/Converter/BL_DeformableGameObject.h b/source/gameengine/Converter/BL_DeformableGameObject.h index 615bb84ac2b..3ba55664007 100644 --- a/source/gameengine/Converter/BL_DeformableGameObject.h +++ b/source/gameengine/Converter/BL_DeformableGameObject.h @@ -82,23 +82,6 @@ public: bool SetActiveAction(class BL_ShapeActionActuator *act, short priority, double curtime); bool GetShape(vector<float> &shape); - Key* GetKey() - { - if(m_pDeformer) { - BL_MeshDeformer *deformer= dynamic_cast<BL_MeshDeformer *>(m_pDeformer); // incase its not a MeshDeformer - if(deformer) { - return deformer->GetMesh()->key; - } - -#if 0 // TODO. shape keys for softbody, currently they dont store a mesh. - KX_SoftBodyDeformer *deformer_soft= dynamic_cast<KX_SoftBodyDeformer *>(m_pDeformer); - if(deformer) { - return deformer->GetMesh()->key; - } -#endif - } - return NULL; - } virtual void SetDeformer(class RAS_Deformer* deformer); virtual class RAS_Deformer* GetDeformer() |