Maya API

41 views
Skip to first unread message

Todd Widup

unread,
Feb 20, 2020, 1:55:10 PM2/20/20
to python_in...@googlegroups.com
hey..what attribute numericData type do you need to you dont get a unit conversion node for rotations?



--
Todd Widup
Creature TD / Technical Artist
todd....@gmail.com

Jesse Kielman

unread,
Feb 20, 2020, 1:56:40 PM2/20/20
to python_in...@googlegroups.com
Im pretty sure it's MAngle

--
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 python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/CABBPk35uF2MYwCcEOpz%2Bfnn6%3DNGc1%2Bk%3DXFCBGPtt51yiZaPiEA%40mail.gmail.com.

Marcus Ottosson

unread,
Feb 20, 2020, 2:11:04 PM2/20/20
to python_in...@googlegroups.com

There’s not enough information in the question. xD

Assuming you mean getting a unit conversion when you connect e.g. polyCube.rotateX to your custom attribute, and that you’re wondering what function set you need to use to create such an attribute without Maya automatically creating such a conversion node, then have a look at MFnUnitAttribute. That’s the one that does any unit-related attributes, including time, distances and angles.

You could also be talking about cmds.addAttr which would be different, and it also depends on when and how you get a conversion node.

A reproducible would help.


Todd Widup

unread,
Feb 20, 2020, 2:22:28 PM2/20/20
to python_in...@googlegroups.com
youre on target with the first one Marcus, thanks

Marcus Ottosson

unread,
Feb 20, 2020, 2:59:46 PM2/20/20
to python_in...@googlegroups.com
Phew, shot in the dark. :) Happy to help!

Reply all
Reply to author
Forward
0 new messages