Fix BGE bug #7532: TrackTo Actuator does not work correctly if it has a Vertex Parent...
[blender.git] / source / gameengine / Ketsji / KX_GameObject.h
index b83d63e26bfa7d70b47f19f68997a6b630bb0293..5dae59d1d63c012ea757d577d3d869fc83a8a1a1 100644 (file)
@@ -368,7 +368,15 @@ public:
        { 
                return m_bDyna; 
        }
-       
+
+       /**
+        * Check if this object has a vertex parent relationship
+        */
+       bool IsVertexParent( )
+       {
+               return (m_pSGNode && m_pSGNode->GetSGParent() && m_pSGNode->GetSGParent()->IsVertexParent());
+       }
+
        bool RayHit(KX_ClientObjectInfo* client, MT_Point3& hit_point, MT_Vector3& hit_normal, void * const data);