Linetree 1.1

Seçilen bir merkez noktadan seçilen her noktaya çizgi çizer.

Kod:

Option Explicit
'Script written by AM
'Script version Tuesday, 11 April 2009 22:19:49
'Adds line from an origin point to every selected destination point

Call LineTree()
Sub LineTree()

	Dim arrOriginPoint, arrDestPoints
	Dim i

	arrOriginPoint = Rhino.GetPoint("Select origin point")
	If IsNull(arrOriginPoint) Then Exit Sub

	arrDestPoints = Rhino.GetPointCoordinates("Select destination points or [Enter] for coordinates",True)
	If IsNull(arrDestPoints) Then
		arrDestPoints = Rhino.GetPoints()
	End If
	If IsNull(arrDestPoints) Then Exit Sub

	Rhino.EnableRedraw(False)

	For i=0 To UBound(arrDestPoints)
		Rhino.AddLine arrOriginPoint, arrDestPoints(i)
	Next

	Rhino.EnableRedraw(True)

End Sub

Dosyayı indirmek için tıklayın.

[download id=”20″]

Benzer Yazılar

Share Your Thoughts

E-posta hesabınız yayımlanmayacak. Gerekli alanlar * ile işaretlenmişlerdir