From da913434dbcf80a2eaa51084a4e3b395fe3784eb Mon Sep 17 00:00:00 2001 From: Michel Selten Date: Tue, 8 Jul 2003 20:06:00 +0000 Subject: [PATCH] * Forgot to update the Object.name variable functionality. Had a bug in it to return the first 2 identifying characters too - which it shouldn't. --- source/blender/python/api2_2x/Object.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/source/blender/python/api2_2x/Object.c b/source/blender/python/api2_2x/Object.c index a9910c7a39b..ec5fd12b770 100644 --- a/source/blender/python/api2_2x/Object.c +++ b/source/blender/python/api2_2x/Object.c @@ -698,9 +698,6 @@ static PyObject *Object_getEuler (BPy_Object *self) static PyObject *Object_getInverseMatrix (BPy_Object *self) { float inverse[4][4]; - Object * ob; - - ob = self->object; Mat4Invert (inverse, self->object->obmat); @@ -1363,7 +1360,7 @@ static PyObject* Object_getAttr (BPy_Object *obj, char *name) if (StringEqual (name, "drawMode")) return (Py_BuildValue ("b", object->dtx)); if (StringEqual (name, "name")) - return (Py_BuildValue ("s", object->id.name)); + return (Py_BuildValue ("s", object->id.name+2)); /* not an attribute, search the methods table */ return Py_FindMethod(BPy_Object_methods, (PyObject *)obj, name);