CircleFill 320, 320, 320, -1
FOR x
= 0 TO 639:
FOR y
= 0 TO 639 'Paint the clock our wooden texture to make it pretty...
CircleFill 250, 40, 20, Black
Numbers(100) = TextToImage("00", 16, Black, 0, 0)
CIRCLE (320, 320), i
- j
, Black
n = 0
n = n + 1
x
= 320 + (i
- 15) * COS(_D2R(j
- 90)) y
= 320 + (i
- 15) * SIN(_D2R(j
- 90)) DisplayImage Numbers(n), x, y, 0, 0
Spinner = ScaleImage(Minute, 1.3, 1)
DisplayImage Spinner, 320, 320, x, 0
x = x + move
move = move - 1
DisplayImage Spinner, 320, 320, x, 0
_LIMIT 360 'one full rotation per second
_LIMIT 30 'no need to use CPU power while just idling for a mouse click
'Image is the image handle which we use to reference our image.
'x,y is the X/Y coordinates where we want the image to be at on the screen.
'angle is the angle which we wish to rotate the image.
'mode determines HOW we place the image at point X,Y.
'Mode 0 we center the image at point X,Y
'Mode 1 we place the Top Left corner of oour image at point X,Y
'Mode 2 is Bottom Left
'Mode 3 is Top Right
'Mode 4 is Bottom Right
px(0) = -w \ 2: py(0) = -h \ 2: px(3) = w \ 2: py(3) = -h \ 2
px(1) = -w \ 2: py(1) = h \ 2: px(2) = w \ 2: py(2) = h \ 2
px(0) = 0: py(0) = 0: px(3) = w: py(3) = 0
px(1) = 0: py(1) = h: px(2) = w: py(2) = h
px(0) = 0: py(0) = -h: px(3) = w: py(3) = -h
px(1) = 0: py(1) = 0: px(2) = w: py(2) = 0
px(0) = -w: py(0) = 0: px(3) = 0: py(3) = 0
px(1) = -w: py(1) = h: px(2) = 0: py(2) = h
px(0) = -w: py(0) = -h: px(3) = 0: py(3) = -h
px(1) = -w: py(1) = 0: px(2) = 0: py(2) = 0
sinr
= SIN(angle
/ 57.2957795131): cosr
= COS(angle
/ 57.2957795131) x2 = (px(i) * cosr + sinr * py(i)) + x: y2 = (py(i) * cosr - px(i) * sinr) + y
px(i) = x2: py(i) = y2
_MAPTRIANGLE (0, 0)-(0, h
- 1)-(w
- 1, h
- 1), Image
TO(px
(0), py
(0))-(px
(1), py
(1))-(px
(2), py
(2)) _MAPTRIANGLE (0, 0)-(w
- 1, 0)-(w
- 1, h
- 1), Image
TO(px
(0), py
(0))-(px
(3), py
(3))-(px
(2), py
(2))
' CX = center x coordinate
' CY = center y coordinate
' R = radius
' C = fill color
RadiusError = -Radius
X = Radius
Y = 0
LINE (CX
- X
, CY
)-(CX
+ X
, CY
), C
, BF
RadiusError = RadiusError + Y * 2 + 1
LINE (CX
- Y
, CY
- X
)-(CX
+ Y
, CY
- X
), C
, BF
LINE (CX
- Y
, CY
+ X
)-(CX
+ Y
, CY
+ X
), C
, BF
X = X - 1
RadiusError = RadiusError - X * 2
Y = Y + 1
LINE (CX
- X
, CY
- Y
)-(CX
+ X
, CY
- Y
), C
, BF
LINE (CX
- X
, CY
+ Y
)-(CX
+ X
, CY
+ Y
), C
, BF
w2 = w * xscale: h2 = h * yscale
_PUTIMAGE (0, 0)-(w2
- 1, h2
- 1), Image&
, NewImage&
, (0, 0)-(w
- 1, h
- 1) ScaleImage = NewImage&
'text$ is the text that we wish to transform into an image.
'font& is the handle of the font we want to use.
'fc& is the color of the font we want to use.
'bfc& is the background color of the font.
'Mode 1 is print forwards
'Mode 2 is print backwards
'Mode 3 is print from top to bottom
'Mode 4 is print from bottom up
'Mode 0 got lost somewhere, but it's OK. We check to see if our mode is < 1 or > 4 and compensate automatically if it is to make it one (default).
'print the text lengthwise
'print the text vertically
'Print text forward
'Print text backwards
temp$ = ""
temp$
= temp$
+ MID$(text$
, LEN(text$
) - i
, 1) 'Print text upwards
'first lets reverse the text, so it's easy to place
temp$ = ""
temp$
= temp$
+ MID$(text$
, LEN(text$
) - i
, 1) 'then put it where it belongs
fx
= (w&
- _PRINTWIDTH(MID$(temp$
, i
, 1))) / 2 + .99 'This is to center any non-monospaced letters so they look better 'Print text downwards
fx
= (w&
- _PRINTWIDTH(MID$(text$
, i
, 1))) / 2 + .99 'This is to center any non-monospaced letters so they look better