File: polytest.kbs

package info (click to toggle)
basic256 2.0.99.10-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 6,888 kB
  • sloc: cpp: 17,185; yacc: 4,025; lex: 1,466; java: 1,091; sh: 39; xml: 33; makefile: 20
file content (39 lines) | stat: -rw-r--r-- 507 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# polytest.kbs
# draw polygons using arrays and direct lists
clg
color gray

dim a(6)
a[0] = 10
a[1] = 30
a[2] = 25
a[3] = 40
a[4] = 0
a[5] = 0

circle (5,5,15)
color blue
poly a[]

# draw red one on top of the blue one
pause 1
color red
poly {10,30,24,40,0,0}

pause 1
color blue
for x = 45 to 55 step 5
 poly {1/x, 2 * x, x-40, x + 30, 7, 8}
next x

# pause and overlay immediate with same polygon from array
pause 1
color red
a[0] = 1/x
a[1] = 2 * x
a[2] = x-40
a[3] = x + 30
a[4] = 7
a[5] = 8
poly a[]