Hi, I am very new to scripting and thought it would be a good test for me to try and write a script to help with creating a simple site from an imported AutoCAD drawing. Basically I am extruding curves (selected by their layer name) through a surface (user defined), and spliting the surface using the extrusion as a cutting object. Then taking the split surface and offsetting it up to create a curb/sidewalk/grass area etc…
The problem is that when it splits the brep(surface) it does not do it clean. so the new split surface does not match up with the surface below it. and many times that shows through to upper surface.
I am not sure I explained that well at all, but either way here is the code:
import rhinoscriptsyntax as rs Surface = rs.GetObject("Select Surface",8) LayerData = [["--CURB",.5],["--SIDEWALK",.6],["--GRASS",.7]] for Item in LayerData: CrvList = rs.ObjectsByLayer(Item,True) ExtList =  SplitList =  rs.EnableRedraw(False) for Curves in CrvList: Ext = rs.ExtrudeCurveStraight(Curves,[0,0,0],[0,0,-1000]) Split = rs.SplitBrep(Surface,Ext,False) rs.DeleteObject(Split) SplitList.append(Split) rs.DeleteObject(Ext) rs.OffsetSurface(Split,Item,None,False,True)
I am guessing I should be doing this in a much different way. Any help is much appreciated!