I get this error, and haven't been able to find the source of it. Is it way 
Python interprets the numbers for Y & Z? 


# RuntimeError: setAttr: Error reading data element number 1: 
[(24.1303752966691, 1.4210854715202004e-13, 5.329070518200751e-15)] #


Here's the method that generates it:


def FKstretch(self,limb,side,ctrlAttr,rigJnt,axis):
        
        # create attribute
        mc.addAttr(ctrlAttr,ln="stretch",at="double",min=0.1, max=3, dv=1,k=
True)
        mc.setAttr(ctrlAttr+".stretch")
        
        # get primary axis length value
        
        jntLength=mc.getAttr("{0}.t{1}".format(rigJnt,axis))
        
                
        setFkMdn=mc.shadingNode("multiplyDivide", au=True,n="{0}_MDN".format
(ctrlAttr))
        mc.setAttr(setFkMdn+".operation",1) #set to multiply, just in case
        mc.setAttr(setFkMdn+".input1X",jntLength)
        
        mc.connectAttr(ctrlAttr+".stretch", setFkMdn+".input2X")
        mc.connectAttr(setFkMdn+".outputX",rigJnt+".t{0}".format(axis))


The strange thing is that this method works perfectly fine when called by 
the legs joints, but not by the arms. The code is identical for both.

thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/da4bdd60-bb7c-4e98-bee7-ade06a63a58c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to