The issue is that you are trying to pass a list cast into a list of 1 element 
in your setAttr command. Instead you should be passing series of 3 floats.

Instead of 
mc.setAttr((insectGroup)+ '.translate', [center], type="double3”)

Try
mc.setAttr((insectGroup)+ '.translate', center[0], center[1], center[2], 
type="double3")


> On Sep 1, 2017, at 10:39 PM, jettam <[email protected]> wrote:
> 
> Could someone help me with this. I am trying to setAttr Translation of 
> insectGroup.  Looks like I am not plugging in the center varible correctly.
>  
> 
> center = mc.xform(bodyA, q=True, t=True)    ###   Result is 0.0, 2.41, -2.6
> 
> insectGroup = mc.group(empty=True, name='Group_Insect_#')
> 
> mc.setAttr((insectGroup)+ '.translate', [center], type="double3")
> 
> -- 
> 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] 
> <mailto:[email protected]>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/python_inside_maya/ea462c7c-29c5-487b-912d-cf90bb221c8d%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/python_inside_maya/ea462c7c-29c5-487b-912d-cf90bb221c8d%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.

-- 
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/6746D07B-880D-443F-99B5-A447D78471D0%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to