home *** CD-ROM | disk | FTP | other *** search
- ' This simple macro draws a 3D Bounding box around the object you select.
- '
- ' This macro works fine in 3D mode, since all lines in 3D
- ' Mode are of zero width. If you use this macro in 2D Mode,
- ' you can get results which you may not expect, since SYS
- ' functions 196-201 use the boundary of the items, NOT their
- ' point locations, and points for wide lines are set in their
- ' middles, not on either side of the wide line, until exploded.
- '
- ' Make sure something is selected before going on
- if Sys(80) = 0 then
- Message "Please select an object before using this macro."
- goto Ender
- endif
- ' Get Values about selected item
- MinX = Sys(196)
- MinY = Sys(197)
- MaxX = Sys(198)
- MaxY = Sys(199)
- MinZ = Sys(200)
- MaxZ = Sys(201)
- ' Draw 3D Box
- >Box
- {
- <Pointxyz [MinX, MinY, MinZ]
- <Pointxyz [MaxX, MaxY, MaxZ]
- }
- Ender:
- End
-