Notifications
Clear all
[Closed] Change position of sub-object with using XForm
Jun 15, 2021 11:27 am
Last time I got a method for scaling: XForm,But now I want to move some splines,It doesn’t seem to work at all.
on Move_RotateBtn pressed do ( my_pos = [0,0,0] spl = (getCurrentSelection())[1] num = numSplines spl for i=1 to num do Move_Rotate_BaseSpline spl i my_pos ) fn Move_Rotate_BaseSpline spl id pos = (in coordsys grid( if getCommandPanelTaskMode() != #modify do max modify mode subObjectLevel = 3 setSplineSelection spl #(id) xmode = XForm () modPanel.addModToSelection xmode modPanel.setCurrentObject spl.modifiers[#XForm] subobjectLevel = 1 spl.modifiers[1].gizmo.position = pos collapseStack spl ) )
While XForm works for a single spline, it seems problematic for multiple splines!
Does anyone know exactly how XForm works?I just want to change thescale and position of some splines
or segments in a splineshape. Is there any better way to do this than XForm?