View Full Version : Detach with edit poly modifier

02 February 2009, 08:55 AM
Hi guys!

Iīm new in this forum, and Iīve got some problems with a script. I was searching by the forum and I found a thread with a script to detach a element sub-object of edit.poly modifier, but Iīve got some problems yet.

This is the code

detached = #()
selectedObjs = getCurrentSelection()

for obj in selectedObjs do
--obj = selection[1]
puppet = undefined
max modify mode
modPanel.setCurrentObject obj.modifiers[#Puppet]
max select all
nameParts = filterString "_"
puppetName = substituteString nameParts[3] "puppet"
--obj.modifiers[#Puppet].ButtonOp #DetachFace
obj.modifiers[#Puppet].DetachToObject puppetName
puppet = execute ("$" + puppetName)
print puppet
append detached puppet


print detached
select detached


I need detach the element of edit poly, introduce it in an array, and move the pivot of these news object to 0,0,0 position.

But when I evaluate the script, detach the object, and the script delete all modifiers of the bone ( the edit modifier it is in a bone ), and I donīt no why.

I was searching a solution too for move the pivot of the object detached, because when I detach the object, catch the properties of the bone, and a bone you canīt move the pivot. I think need attach the new element detached to box converted in a edit poly ( for example) and delete the box in subobject mode.

If anybody have got any idea, o can help me, I will be grateful.

Thanks you in advance people!!

CGTalk Moderation
02 February 2009, 08:55 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.