def add_curves_to_hair_system():
sel = cmds.ls(sl=True, dag=True, leaf=True, long=True)
if len(sel) < 2:
cmds.warning('Select a bunch of curves and a hairSystem node.')
return
curves = sel[:-1]
hair_system = sel[-1].split('|')[-1]
if cmds.nodeType(hair_system) != 'hairSystem':
cmds.warning(hair_system + ' is not a hairSystem.')
return
for curve in curves:
add_curve_to_system(curve, hair_system)
评论列表
文章目录