def rename_prompt(obj, goz_id, objs):
"""Confirm object rename, trigger create or relink then revise
objlist
"""
gui_message = """%s has a old ZBrush ID, of %s, try to relink?
NOTE! relinking will
remove objects named "%s"
selected mesh as the new one!!
""" % (obj,
goz_id,
goz_id)
choice = pm.confirmDialog(title="ZBrush Name Conflict",
message=gui_message,
button=['Relink', 'Create', 'Skip'])
if choice == 'Relink':
# relink to past gozbruhBrushID
if obj not in objs:
return
new_obj = relink(obj, goz_id)
objs.remove(obj)
if new_obj not in objs:
objs.append(new_obj)
elif choice == 'Create':
# new object for zbrush
create(obj)
评论列表
文章目录