lo
lake the
p'ace
Ql
the angie,
even
though
you
don't
want
the
box
rotated This
ts
so
your
computer
reads
the
comma
as
the
DEFAULT
value,
which
means
that
It
interprets
your
lack
ot
response
as
an
instruction
II
you
don't Include the
comma,
the
1
at
the
end
ol
the
line
Is
read as
the
angle
lor
the
box
to
be
rotated.
Some
typical
forms
of
the
BOX
command
are:
Command
Effect
BOX
on.
column
1
,
row
1
,
column
2,
row
2
BOX
on,
col
1
.
row
1
,
col
2,
row
2,
angle
BOX
on.
col
1
,
row
l
,
col
2,
row
2,
.
fill
BOX
off,
col
t
,
row
i
,
col
2,
row
2.
angle.
Ill
Outline
Rotated
Solid
box
Erase area
of
screen
Column
1
,
row
1
,
etc.
are
screen
positions of
endpolnts
that
you
specify.
Column
1
,
row
1
is
the
upper
left
corner
of the
box
while
row
and column
2
is
the
bottom
right
corner
Here
Is
a
program
that
illustrates
the
BOX
command
(line
60)
10
COLOH
0,1
20
COLOR
1,2
30
GRAPHIC
2,1
40
A
=
RND(1)'20+
10
50
FOR L=0
TO
359
STEP
A
60
BOX
1,
100, 30, 220, 130,
L
70
NEXT
L
80
FOR L«
1
TO
2000:
NEXT
L
90
GRAPHIC
0,1
Drawing
Circles
Your
Commodore
16
also
has
commands
lor
drawing
circles
Uke
the
BOX
command,
you can
vary the
shape
of
the
circle
(to
form an
oval
or
an
ellipse),
and
you
can
rotate
the
oval.
You can
also
just
draw
a
section
ol
me
shape
(called
an
arc).
78
1
1
i
i
'
r
i
i
!
1
1
1
I
1
1
1
1
1
I
I
I
1
I
1
'
1
1
l
1
!
1
1
1
i
(
1
1
1
!
1
(
1
1
I
I
(
I
The
usual forms
of
the
CIRCLE command
are:
Commam!
Effect
CIRCLE
on. centre
column,
centre row, radius
CIRCLE
on,
c-col,
c-row,
width, height
CIRCLE
on,
c-col,
c-row, wid,
hi, start,
finish
CIRCLE
on,
c-col,
c-row,
wtdth,
height.,
.angle
CIRCLE
on.
c-col.
c-row. wid,
ht....
point
angle
circle
wa
arc
rotated oval
polygon
This
commano
draws
a
circle
in
the
centre
of
the screen:
CIRCLE
1,
160, 100,50. This
tells
your
computer
lo
draw
a
circle
with
its
centre
at
column 160 and row
100. with
a
radius of 50.
This
may
actually
produce an
oval,
since the dots
on
some
TV's
and
monitors
(
American
ones,
lor
example)
are
taller
than they are wide.
To
change
this
to
a
real circle
you must
add
a
separate
number
to
tell
that
the height
is
different
from
the width,
Uke
this:
CIRCLE
1,160,100,50,42.
Drawing
Polygons
Your
Commodore
16
can
also
draw a
square, u-angle
or
other
polygon
using
the
CIRCLE
command.
Just
tell
the
computer
how many
degrees
to
go between
points
on
the
circle, like
Ihis.
CIRCLE
1,160, 100,50,42,,,. 120. This
command
draws
a
triangle,
since
each
side
is
1
20
degrees
(Remember
that
omitting
number
values while
including
commas
in
a
graphic
command
causes
your
computer
to
read
standard
default
values
lor
the
missing number.)
A
simple (ormula
to
get the angle
lor
a polygon
with
N
sides
is
360/N
Here's
a
quick
program
lor
drawing
polygons:
10
GRAPHIC
2,1
20
INPUT-HOW
MANY
SIDES";A
30 IF
A <
2
OR
A >
100
THEN
PRINT
"DONT
BE RIDICULOUS":
GOTO
20
40
CIRCLE
l.I60.80,40,33„ M
360/A
50
GOTO
20
You can choose
to
draw
only
an
arc Instead
o>
a whole
circle.
The
CIRCLE command
accepts
the
starting
and
ending angles
In
degrees,
79
Need help?
Do you have a question about the 16 and is the answer not in the manual?