arc3
01-22-2005, 03:20 PM
Hello--
I am new to programming and very new to maxscript, and I need some help. I am bringing in building footprint data from AutoCad. The data comes in as 'linked shapes'. I need to convert these to editable splines, and then weld the vertices for each individual shape so that I can extrude them capped.
I have searched the forums and gotten part way ('Script for sorting out splines' was very helpful). I've come up with the following routine that works on a single spline shape, but when multiple shapes are selected only the last shape's vertices are welded. (the script works on each shape up to the point of welding verticies):
max modify mode
splines = for obj in selection collect obj
for s in splines do
(
convertTo s SplineShape
select s
subobjectLevel=1
max select all
splineOps.weld $
splineOps.weld $
)
I've noticed others have had the same issue, but I can't sort out how to fix it. Even if it cannot be fixed, I would very much like to know why it will not work for multiple shapes.
Thanks
I am new to programming and very new to maxscript, and I need some help. I am bringing in building footprint data from AutoCad. The data comes in as 'linked shapes'. I need to convert these to editable splines, and then weld the vertices for each individual shape so that I can extrude them capped.
I have searched the forums and gotten part way ('Script for sorting out splines' was very helpful). I've come up with the following routine that works on a single spline shape, but when multiple shapes are selected only the last shape's vertices are welded. (the script works on each shape up to the point of welding verticies):
max modify mode
splines = for obj in selection collect obj
for s in splines do
(
convertTo s SplineShape
select s
subobjectLevel=1
max select all
splineOps.weld $
splineOps.weld $
)
I've noticed others have had the same issue, but I can't sort out how to fix it. Even if it cannot be fixed, I would very much like to know why it will not work for multiple shapes.
Thanks
