Align selected object to object "A" (XYZ) and then to object "B" (Y)
Hello! basically I have a dummy object "X" and 2 geometry objects "A" and "B".
I need to align the selected Dummy "X" firstly to "A" on all of its axes, and then to "B" only on its Y axis.
I have found the following line which aligns the selected object to all axes XYZ (oddly it squashes the Dummy's bounding box)
$.transform = (getNodeByName "A").transform
$.transform = (getNodeByName "B").transform
and what I need is for the second line of code to constrain the transform operation to the Y axis.
The normal way of doing this is by using the ALIGN tool twice (first on A and then on B disabling X and Z), but I need to automate this. Any help is highly appreciated!
Comments
Apologies, I have managed to
Apologies, I have managed to solve this over the weekend. For anyone interested the code is (it was way simpler than I thought):
$Dummy.pos.x = $A.pos.x
$Dummy.pos.z = $A.pos.z
$Dummy.pos.y = $B.pos.y