цПСООШ ОНКЭГНБЮРЕКЕИ Autodesk

# мЮОХЯЮМХЕ ТСМЙЖХХ command-ended - ВЮЯРЭ 2

;; to convert the coordinate data into lists of

;; ((x y) (x y) ...) points. Otherwise, use the

;; xyzList->ListOfPoints function that deals

;; with 3d points, and converts the coordinate data into

;; ЯОХЯНЙ ((x y z) (x y z) ... ) РНВЕЙ.

(setq CurrentPoints

(if (= (vla-get-ObjectName *polytochange*) "AcDbPolyline")

(xyList->ListOfPoints coordinateValues)

(xyzList->ListOfPoints coordinateValues)

)

)

;; Send this new information to RedefinePolyBorder -- this

;; will return the new Polyline Border

(setq NewReactorData

(gp:RedefinePolyBorder CurrentPoints reactorData)

)

;; Get all the border Points and ...

(setq newpts (list (cdr (assoc 12 NewReactorData))

(cdr (assoc 13 NewReactorData))

(cdr (assoc 14 NewReactorData))

(cdr (assoc 15 NewReactorData))

)

)

;; ...update the outline of the polyline with the new points

;; calculated above. If dealing with a lightweight polyline,

;; convert these points to 2D (since all the points in

;; newpts are 3D), otherwise leave them alone.

(if (= (cdr (assoc 4 NewReactorData)) "LIGHT")

(setq newpts (mapcar '(lambda (point)

(3dPoint->2dPoint Point)

)

newpts

)

)

)

;; Now update the polyline with the correct points.

(vla-put-coordinates

*polytochange*

;; For description of the list->variantArray see utils.lsp.

(gp:list->variantArray (apply 'append newpts))

)

;; Now use the current definition of the NewReactorData,

;; which is really the same as the garden path data

;; structure. The only exception is that the field (100)

;; containing the list of tiles is nil. This is OK since

;; gp:Calculate-and-Draw-Tiles does not require this field

;; to draw the tiles. In fact this function creates the tiles

;; and returns a list of drawn tiles.

(setq tileList (gp:Calculate-and-Draw-Tiles

;; path data list without correct tile list

NewReactorData

;; Object creation function

;; Within a reactor this *MUST* be ActiveX

"ActiveX"

)

)

;; Now that you have received all the tiles drawn, rebuild

яНДЕПФЮМХЕ  мЮГЮД  бОЕПЕД