PDA

View Full Version : xform duplication script


thehive
03-18-2006, 01:57 PM
here is my script im tryin to apply an xfrom to a bunch of object sparately


mapped function .pos

global ChunksArray = $bricks_* as array

(

NumChunks = ChunksArray.count

for i = 1 to NumChunks collect

modPanel.addModToSelection (XForm ()) ui:on





on Release do

(



(

(


this is the error i get

-- Syntax error: at ., expected name

-- In line:

1967

#(OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, OK, ...)

-- Type error: Call needs function or class, got: true

-- Compile error: Unexpected end-of-script

-- In line: 

thehive
03-20-2006, 12:49 PM
i ran the script it makes starts to duplicates but it dosent look like its attachin to the objects,

still cold use some help thanks guys

j-man
03-20-2006, 02:08 PM
ok,

you want to apply a different xform modifier to a selection of objects?


sel=selection as array
for s in sel do addmodifier s (xform())


or are you tring to do something else...

J.

thehive
03-20-2006, 03:44 PM
yea i want to apply an xfrom to a bunch of objects i see what you wrote but i dont see how to tie it into what i wrote, the prob is i cant reset the xform on the object so i want to atemp to wirte s simple script that applies the modeifier to practice

j-man
03-20-2006, 03:49 PM
hmmm,

I don't know what to say. Your snippet of code tells me nothing about what you're trying to achieve so it's hard to help. It looks like you've cut and pasted it from the macrorecorder.
Can you supply some more information?



CGTalk Moderation
03-20-2006, 03:49 PM
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.