标签:
import c4d from c4d import utils def main(): settings = c4d.BaseContainer() # Settings2 settings[c4d.MDATA_EXTRUDE_OFFSET] = 50.0 # Length of the extrusion res = utils.SendModelingCommand(command = c4d.ID_MODELING_EXTRUDE_TOOL, list = [op.GetObject()], mode = c4d.MODELINGCOMMANDMODE_POLYGONSELECTION, bc = settings, doc = doc) c4d.EventAdd() if res is False: print "Something went wrong." elif res is True: print "Command successfull." elif isinstance(res, list): print "Here you get the newly created object(s)."
参数list不能直接放op,默认取到的可能是标签。要取对象。。
查了一下午,最后在参数说明里找到了原因
关于SendModelingCommand官方例子执行不成功的原因
标签:
原文地址:http://www.cnblogs.com/hont/p/4716050.html