orientjoints.py 文件源码

python
阅读 25 收藏 0 点赞 0 评论 0

项目:cmt 作者: chadmv 项目源码 文件源码
def offset_orient(joints, amount, axis):
    """Offsets the orient by the given amount

    @param joints: Joints to orient.
    @param amount: Amount to offset by.
    @param axis: Which axis X, Y or Z
    """
    for joint in joints:
        children = _unparent_children(joint)
        attribute = '{0}.jointOrient{1}'.format(joint, axis)
        orient = cmds.getAttr(attribute)
        orient += amount
        cmds.setAttr(attribute, orient)
        _reparent_children(joint, children)

    if joints:
        cmds.select(joints)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号