link an object to another object

Hello,
I was wondering if I can get some help writing a script. I am new to this so hopefully someone can help me.
I am trying to write a simple script that populate a drop down list with some dummies I have selected in the scene. These dummies have some different transformation keyframes (position and rotation only). I want to be able to pick a dummy from drop down list and link an object to it.
Thanks.

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
sable806's picture

Linking Objects

Hello, You could try to add a pickbutton to your interface, so that you could select a dummy in your dropdown list, then click on the pickbutton and pick another dummy in the scene to link it. You want to parent them or another type of link ?

dropdownlist ddlist_Dummies "Dummies" items:...
pickbutton pbtn_Children "Children"
 
on pickbutton picked obj do
(
pbtn_Children.object.parent = dummyArray[ddlist.selection]
 
--You probably have an array which contains your dummies, this is where you use selected items in your dropdown array to choose whick dummy to link--
 
)

Feel free to give some feedback if not working or if i misunderstood.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.