
! script name: solids.d/cirdisk
! 3dtopic: construct disk defined by circle

!A
!A NAME:
!A
!A 	Disk: Circle
!A
!A DESCRIPTION:
!A
!A 	This script constructs a disk using the picked circle as the circular
!A 	boundary.
!A
!B INSTRUCTIONS:
!B
!B 	PICK CIRCLE: Pick the circle to be used to define the disk.
!B
!C NOTES:
!C
!C 	The U contours of a disk are the circles and the V contours are the
!C 	radial lines.
!C

Stat=ChangeLabelStr("ScriptNameStatus","Function: disk defined by a circle ")

DIM Destination$[256]
DIM Answer$[256]


ActivateUndo
Cloop:!
Stat=SetInputFormat("n4","")
pcircle=PickSpecificEnt("PICK CIRCLE",WsPickCircles)
IF ExitScript(Destination$) THEN Leave
IF NOT ValidGeometry(pcircle) THEN Cloop


C1=CircleDisk(Pcircle)

ActivateUndo
Stat= AdvanceUndoNumber("disk")
Stat= AddItemToUndo(WsUBCreateMode,C1)
GOTO Cloop

Leave:!
IF NOT LEN(Destination$) THEN
	LOAD "typecontrol"
ELSE
	LOAD Destination$
END IF
END
