Week 1 Scripting Update

Option Explicit
‘Script written by mark.bearak
‘Script copyrighted by dtls.Architecture
‘Script version Tuesday, October 21, 2008 1:08:31 PM

Call Main()
Sub Main()
Dim arrPlane, i, j, strCrv(), strInnerCrv()
Dim intWidth : intWidth  = 8
Dim intMatWidth : intMatWidth = .25
Dim intTopWid : intTopWid = intWidth – 2
For j = 0 To 5
For i = 0 To 10
ReDim Preserve strCrv(i)
ReDim Preserve strInnerCrv(i)
arrPlane = Rhino.PlaneFromPoints (Array(0,j*25,i*(j+1)), Array(1,j*25,i*(j+1)), Array(0,j*25+1,i*(j+1)))
If i < j+3 Then
strCrv(i) = Rhino.AddCircle (arrPlane, intWidth)
strInnerCrv(i) = Rhino.AddCircle (arrPlane, intWidth-intMatWidth)
strCrv(i) = Rhino.AddCircle (arrPlane, intWidth-intTopWid)
strInnerCrv(i) = Rhino.AddCircle (arrPlane, intWidth-intTopWid-intMatWidth)
End If
Call Rhino.AddLoftSrf (strCrv,,,1)
Call Rhino.AddLoftSrf (strInnerCrv,,,1)
Call Rhino.deleteobjects (strCrv)
End Sub


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s