How do I set a unique texture for each cloned 3D model in Director?


hi,

 

i using 3d world built 3ds max, contains 2 boxes, in director have set boxes move along path , when out of camera shot boxes reset along z axis , new texture if applied (generated via text member), far good.

now if user clicks button clone boxes , have each box display own texture own text member. @ moment cloned boxed use texture last textured box, assume inheritance issue, not know how make each texture unique box.

 

any ideas?

 

thanks in advance!

 

sherv.

hi , welcome,

 

you need create shader every texture.

example:

 

w = member("w3d_name")

shad1 = w.newshader("shad1",#standard)

tex1 = w.newtexture("tex1",#fromcastmember,member("text1"))

shad1.texture = tex1

shad2 = w.newshader("shad2",#standard)

tex2 = w.newtexture("tex1",#fromcastmember,member("text2"))

shad2.texture = tex2

...

 

after that, have apply shader desired model:

 

w.model("cube1").shader = w.shader("shad3")

w.model("cube2").shader = w.shader("shad1")

...

 

cheers



More discussions in Director


adobe

Comments

Popular posts from this blog

How to set the order of FAQs instead of alphabetical

Thread: Get UK Keyboard working

how do I change the e-mail address for my merchant account