之前为头发动力学做的属性关联的表达式记录一下
import maya.cmds as mc
all = mc.ls(sl=1)
hairsystem = all[0]
control = all[1]
ep_name = all[0]+"_EP"
mc.expression(s = """%(aa)s.solverDisplay = %(bb)s.chainCollideGround; \n
%(aa)s.simulationMethod = %(bb)s.DYNAMIC; \n
%(aa)s.startCurveAttract = %(bb)s.chainStartCurve; \n
%(aa)s.mass = %(bb)s.chainGravity; \n
%(aa)s.collideWidthOffset = %(bb)s.chainWidthExtremity;"""
%{'aa':hairsystem,"bb":control},o = hairsystem, n = ep_name, ae=1,uc = "all")