zbw_messageMapper.py 文件源码

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

项目:zTools 作者: zethwillie 项目源码 文件源码
def zbw_mmChangeConnectAttr(base, attr, obj, *args):
    #get that from the text field
    newAttr = cmds.textFieldGrp("zbw_mmChangeAttrTFG", q=True, tx=True)
    #delete old attr
    cmds.deleteAttr(attr)
    #create new attr
    cmds.addAttr(base, at="message", ln=newAttr)
    #create connection to obj in new attr
    cmds.connectAttr((obj+".message"), (base+"."+newAttr), f=True)

    #when you delete, then run the whole proc again afterwards (to clean up the nums)
    cmds.deleteUI('zbw_mmChangeAttrUI', window=True)
    cmds.windowPref('zbw_mmChangeAttrUI', remove=True)
    cmds.deleteUI("mmRCListLayout")
    zbw_mmListCurrentMessages("mmListMessages")
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号