getorient
(getorient [point] [prompt])
The getorient function prompts the user to enter an angle.
Arguments
point
The point argument specifies a 2D base point in the current CCS to compute the angle. If the argument is supplied, the user specifies the angle by entering or identifying a second point.
If point is not specified or is nil, the user must specify two points, where the first point entered is assumed to be the base point for the angle inquiry.
To visualize the angle specification, the function draws a "rubber band" from the base point to the current cursor position.
prompt
If the optional argument prompt contains a text string, it is displayed in the Command Window; otherwise, no prompt is displayed.
Note: The angle can be entered in a format recognized by the angtof function.
The getorient function works similar to getangle, but the angle returned is always measured as zero degrees to the right (east). The getangle function recognizes the local system variable ANGBASE (Angle Base), whereas getorient ignores it.
Like getangle, the getorient function uses the system variables ANGDIR and ANGBASE. The returned value adds the setting of ANGBASE to the result. For example: If ANGDIR is set to 0 and ANGBASE is set to 90 degrees, the function returns an angle of 90 degrees as 3.14159 in radians (180 degrees).
If ANGDIR is set to 1 and ANGBASE is set to 0 degrees, the function returns an angle of 90 degrees as 4.7124 in radians.
The getorient function interprets an angle entered via the keyboard using the local system variable AUNITS (Angle Units).
Return Value
The function returns the computed orientation in radians with respect to the current construction plane.
: (getorient)
90
1.5708
: (getorient "Specify angle: ")
Specify angle: 45
0.7854
: (getorient)
0,0
0,1
1.5708
initget, getangle, angtof