rename and negate DISABLE_PYTHON --> WITH_PYTHON
[blender.git] / source / gameengine / Expressions / FloatValue.h
index 33f05f1d7f2103ac34bf01e923adb9c0010ade52..83b9ff1db5e0c4721fe8ed10de6267953aed322a 100644 (file)
@@ -23,12 +23,12 @@ class CFloatValue : public CPropValue
 public:
        CFloatValue();
        CFloatValue(float fl);
-       CFloatValue(float fl,STR_String name,AllocationTYPE alloctype=CValue::HEAPVALUE);
+       CFloatValue(float fl,const char *name,AllocationTYPE alloctype=CValue::HEAPVALUE);
 
        virtual const STR_String & GetText();
 
        void Configure(CValue* menuvalue);
-       virtual float GetNumber();
+       virtual double GetNumber();
        virtual void SetValue(CValue* newval);
        float GetFloat();
        void SetFloat(float fl);
@@ -36,12 +36,20 @@ public:
        virtual CValue* GetReplica();
        virtual CValue* Calc(VALUE_OPERATOR op, CValue *val);
        virtual CValue* CalcFinal(VALUE_DATA_TYPE dtype, VALUE_OPERATOR op, CValue *val);
+#ifdef WITH_PYTHON
        virtual PyObject*       ConvertValueToPython();
+#endif
 
 protected:
        float m_float;
        STR_String* m_pstrRep;
 
+
+#ifdef WITH_CXX_GUARDEDALLOC
+public:
+       void *operator new(size_t num_bytes) { return MEM_mallocN(num_bytes, "GE:CFloatValue"); }
+       void operator delete( void *mem ) { MEM_freeN(mem); }
+#endif
 };
 
 #endif // !defined _FLOATVALUE_H