View Full Version : Attaching an object to the vertex of another object
Murf_Miser 06-25-2003, 05:48 AM I ran across a problem today and am curious if the formentioned problem is posible? I don't want to use the default select and link because than simply links the first object to the second objects pivit point. Thanks for help
|
|
Dave Black
06-25-2003, 05:58 AM
Well, you can attach a vertex to an object using a linked XForm modifier.
I honestly can't recall how to link an object to a vertex. I mean, it kinda depend on whether to object is deforming. You could easlily setup a link using dummies and such.
Hmmm...it's late. I'm sorry I can't remember how to do this the "special" way.
-3DZ
:D
I don't know what kind of objects behaviour you're trying to achieve, but why don't you constraint the object to the desired position on the other object with an Attachment Constraint?
I mean, something like this: (see picture below)
just position it. unless it has to be perfect for some reason
Murf_Miser
06-25-2003, 02:03 PM
Well i would prefer it to be absoulutly stuck only to the vertex, the main reason being that an object(a) is usally stuck to the pivit point of another object(b), and if a modifer like noise is done on the object(b) then the pivit point for that object(b) will remain at the same exact point and not move at all while the verticies will. I would like to keep object(a) attached to a specific vertex of object(b) so that throughout the noise modifier animation the object(a) will animate to the vertex and not the pivit point of object(b). I hope you can understand that :D And thanks again for your replies
magicm
06-25-2003, 03:56 PM
Like AXE said, the Attachment Controller is what you need.
MCage
06-25-2003, 06:27 PM
Try this simple script..
Create an object, and with editmesh select a vertex,and remember the number of it.. then create a dummie and add a position script controller..
----------------------------------
es
pos = getvert $Box01 2
------------
" pos = getvert $OBJ_TO_LINK N OF vertex do u whant to link to"
--------------
END
BYe Bye McAge
Murf_Miser
06-26-2003, 05:09 AM
Ok, i figured out how to link the position to the vertex, but is there any way i can also get the rotation? This is my position script controler
Position Script Controler
---------
dependson $Tube
getvert $Tube 1
---------
Now for the rotation, i was thinking perhaps this:
Test Rotation Script Controler (FAILS)
---------
dependson $Tube
(getvert $Tube 1).x_rotation
(getvert $Tube 1).y_rotation
(getvert $Tube 1).z_rotation
----------
but that doesn't work, does it want it in a array or matrix or something. Any help?
Thanks
magicm
06-27-2003, 12:11 AM
Murf_Miser,
have you tried the attachment-controller? It can ofcouse also be done with scripting, but why re-invent the wheel?
the attachment-controller lets you specify which face (and the exact location on that face) you want to align to..
- Martijn
Murf_Miser
06-27-2003, 12:51 AM
Ok, i saw where it was at :lightbulb, i was thinking that it was going to be under the main Transform Group, but i found it under the subgroup, Position. It is just what i needed, thank you all. And i hope you can forgive my stupidity :blush: Should have looked harder...
NotSoFro
06-27-2003, 08:15 AM
How do i snap a pivot point to a vertex. I know how to shift my pivot point around but i don't know how to move it precisely. Any clues?
magicm
06-27-2003, 09:11 AM
Originally posted by NotSoFro
How do i snap a pivot point to a vertex. I know how to shift my pivot point around but i don't know how to move it precisely. Any clues?
open the snap-menu and check both 'Pivot' and 'Vertex'.. Also, you might want to turn to 3D-snapping and turn off 'Transform Constraints' (shift-rightclick)
- Martijn
CGTalk Moderation
01-15-2006, 12:00 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.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.