svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r22717:22875
[blender.git] / source / gameengine / Ketsji / KX_ClientObjectInfo.h
index 74d463fbf208526ca1da9e902d5c1e0031cdd2a5..74647dd47fdae460a1828f941d53cfbb38413960 100644 (file)
@@ -30,9 +30,6 @@
 #define __KX_CLIENTOBJECT_INFO_H
 
 /* Note, the way this works with/without sumo is a bit odd */
-#ifdef USE_SUMO_SOLID
-#include <SM_Object.h>
-#endif //USE_SUMO_SOLID
 
 #include <list>
 
@@ -42,34 +39,26 @@ class KX_GameObject;
  * Client Type and Additional Info. This structure can be use instead of a bare void* pointer, for safeness, and additional info for callbacks
  */
 struct KX_ClientObjectInfo
-#ifdef USE_SUMO_SOLID
-  : public SM_ClientObject
-#endif
 {
        enum clienttype {
                STATIC,
                ACTOR,
                RESERVED1,
                SENSOR,
-               OBSENSOR
+               OBSENSOR,
+               OBACTORSENSOR
        }               m_type;
        KX_GameObject*  m_gameobject;
        void*           m_auxilary_info;
        std::list<SCA_ISensor*> m_sensors;
 public:
        KX_ClientObjectInfo(KX_GameObject *gameobject, clienttype type = STATIC, void *auxilary_info = NULL) :
-#ifdef USE_SUMO_SOLID
-               SM_ClientObject(),
-#endif
                m_type(type),
                m_gameobject(gameobject),
                m_auxilary_info(auxilary_info)
        {}
        
        KX_ClientObjectInfo(const KX_ClientObjectInfo &copy) :
-#ifdef USE_SUMO_SOLID          
-                 SM_ClientObject(copy),
-#endif
                  m_type(copy.m_type),
                  m_gameobject(copy.m_gameobject),
                  m_auxilary_info(copy.m_auxilary_info)
@@ -84,7 +73,14 @@ public:
        }
        
        bool isActor() { return m_type <= ACTOR; }
-       bool isSensor() { return m_type >= SENSOR && m_type <= OBSENSOR; }
+       bool isSensor() { return m_type >= SENSOR && m_type <= OBACTORSENSOR; }
+       
+       
+#ifdef WITH_CXX_GUARDEDALLOC
+public:
+       void *operator new( unsigned int num_bytes) { return MEM_mallocN(num_bytes, "GE:KX_ClientObjectInfo"); }
+       void operator delete( void *mem ) { MEM_freeN(mem); }
+#endif
 };
 
 #endif //__KX_CLIENTOBJECT_INFO_H