' your screen height is 800. So, let say, one colored quad height is 10. So you need draw 80 colored quads:
'why DIM: if is needed many variables, you can write: A1 = 10, A2 = 20... A1000 = 70. OR A(number for A) = value
'why _UNSIGNED LONG: 32 bit colors used on 32 bit screens use this _UNSIGNED LONG type values.
'set random colors:
Quads
(set
) = _RGBA32(255, RND * 255, RND * 255, RND * 255) ' _RGBA32 (Alha transparency 0 to 255, 255 is full visible, red 0 to 255, green 0 to 255, blue 0 to 255) Y(set) = (set - 1) * 10 'set start Y coordinate
'your choice is starting with full screen. So first step - placing quads to screen:
LINE (0, Y
(P
))-(1199, Y
(P
) + 10), Quads
(P
), BF
' LINE (startX, startY) - (endX, endY (quad size is 10 pixels)), Unsigned Long color value, BF = filled quad Y(P) = Y(P) + 10 'increase Y position for quad
IF Y
(P
) > 800 THEN Y
(P
) = 0 'if is Y on bottom, return it to above
'SLEEP
'if you place here SLEEP, you can see program start