import rhinoscriptsyntax as rs allobjs = rs.AllObjects () rs.DeleteObjects(allobjs) initial = "S" hgt = 24 size =40 # draw a closed curve in Rhino mytext = rs.AddText (initial, (0,0,0), height=size, font="Arial") crv = rs.ExplodeText (mytext,True) [0] rs.SelectObject (crv) #extrude the curve (###note the correction: DelteInput=Yes ! ) rs.Command("_ExtrudeCrv Solid=No DeleteInput=Yes {} Enter".format(hgt)) srf = rs.FirstObject (select=True) """ rs.Command ("_Curve Degree=2 0,0,0 20,-1,0 20,12,0 0,10,0 0,0,0 Close_Enter") crv = rs.FirstObject (select=True) # extrude the curve rs.Command("_ExtrudeCrv Solid=No DeleteInput=Yes {} Enter".format(hgt)) srf = rs.FirstObject (select=True) """ # use handles to change NURBS shape rs.Command("-_Rebuild UPointCount=10 VPointCount=4 UDegree=3 DeleteInput=Yes_Enter") rs.EnableObjectGrips(srf, True) """ pointlist = rs.ObjectGripLocations(srf) print. pointlist for i, pt in enumerate(pointlist): cmd = "-Dot {} {} _Enter" .format(str(i) , str(pt)) rs.comand(cmd,False) """ rs.SelectObjectGrip(srf,23) rs.SelectObjectGrip(srf,35) rs.Command("-_Move 0,0,0 0,10,0 _Enter") rs.UnselectAllObjects() rs.SelectObjectGrip(srf,23) rs.Command("-_Move 0,0,0 15,0,0 _Enter") rs.UnselectAllObjects() rs.SelectObjectGrip(srf,20) rs.Command("-_Move 0,0,0 -15,0,0 _Enter") rs.UnselectAllObjects() rs.EnableObjectGrips(srf, False) # create contourlines in Z-direction and extrude them (floor plates) rs.SelectObject(srf) rs.Command ("_Contour 0,0,0 0,0,1 3.0 _Enter") rs.Command("-_ExtrudeCrv Solid=Yes 0.3 Enter") # create contourlines in X-direction and use the pipe command (vertical support ) rs.SelectObject(srf) rs.Command ("_Contour 0,0,0 1,0,0 2.0 _Enter") rs.Command ("_Pipe 0.2 _Enter") rs.DeleteObject(srf) rs.UnselectAllObjects() initial = "W" hgt = 24 size =40 # draw a closed curve in Rhino mytext = rs.AddText (initial, (40,0,0), height=size, font="Arial") #rs.MoveObject(mytext, (50,0,0)) crv = rs.ExplodeText (mytext,True) [0] rs.SelectObject (crv) #extrude the curve (###note the correction: DelteInput=Yes ! ) rs.Command("_ExtrudeCrv Solid=No DeleteInput=Yes {} Enter".format(hgt)) srf = rs.FirstObject (select=True) """ rs.Command ("_Curve Degree=2 0,0,0 20,-1,0 20,12,0 0,10,0 0,0,0 Close_Enter") crv = rs.FirstObject (select=True) # extrude the curve rs.Command("_ExtrudeCrv Solid=No DeleteInput=Yes {} Enter".format(hgt)) srf = rs.FirstObject (select=True) """ # use handles to change NURBS shape rs.Command("-_Rebuild UPointCount=10 VPointCount=4 UDegree=3 DeleteInput=Yes_Enter") rs.EnableObjectGrips(srf, True) """ pointlist = rs.ObjectGripLocations(srf) print. pointlist for i, pt in enumerate(pointlist): cmd = "-Dot {} {} _Enter" .format(str(i) , str(pt)) rs.comand(cmd,False) """ rs.SelectObjectGrip(srf,23) rs.SelectObjectGrip(srf,35) rs.Command("-_Move 0,0,0 0,10,0 _Enter") rs.UnselectAllObjects() rs.SelectObjectGrip(srf,23) rs.Command("-_Move 0,0,0 15,0,0 _Enter") rs.UnselectAllObjects() rs.SelectObjectGrip(srf,20) rs.Command("-_Move 0,0,0 -15,0,0 _Enter") rs.UnselectAllObjects() rs.EnableObjectGrips(srf, False) # create contourlines in Z-direction and extrude them (floor plates) rs.SelectObject(srf) rs.Command ("_Contour 0,0,0 0,0,1 3.0 _Enter") rs.Command("-_ExtrudeCrv Solid=Yes 0.3 Enter") # create contourlines in X-direction and use the pipe command (vertical support ) rs.SelectObject(srf) rs.Command ("_Contour 0,0,0 1,0,0 2.0 _Enter") rs.Command ("_Pipe 0.2 _Enter") rs.DeleteObject(srf) rs.UnselectAllObjects()