Microsoft Small Basic
Program Listing: LZF101
A1 = 1
new:
n = 1
A1 = A1 +1
MAXF = 30
sz = Math.GetRandomNumber(20)
sz = sz + 20
p1 = Math.GetRandomNumber(400)
p2 = Math.GetRandomNumber(400)
If A1 > 30 Then
Goto End1
EndIf
start:
n = n +1
If n > 150 Then
GraphicsWindow.brushColor = "Brown"
GraphicsWindow.fillEllipse(p1-((sz/2)/2),p2-((sz/2)/2),sz/2,sz/2)
GraphicsWindow.brushColor = "BROWN"
newshape = Shapes.AddEllipse(sz*2,sz*2)
Shapes.SetOpacity(newshape,10)
Shapes.Move(newshape,p1-(sz),p2-(sz))
GraphicsWindow.fillEllipse(p1-((sz/2)/2),p2-((sz/2)/2),sz/2,sz/2)
Goto new
EndIf
num1 = Math.GetRandomNumber(sz)
pos = Math.SquareRoot((sz*sz)-(num1*num1))
may1 = Math.GetRandomNumber(2)
may2 = Math.GetRandomNumber(2)
If may1 = 1 then
pos = (0-pos)
EndIf
If may2 = 1 then
num1 = (0-num1)
EndIf
num1 = num1 + (p1)
pos = pos + (p2)
colp = Math.GetRandomNumber(4)
col[1] = "yellow"
col[2] = "gold"
col[3] = "orange"
col[4] = "darkorange"
GraphicsWindow.PenColor = col[colp]
GraphicsWindow.DrawLine(num1,pos,p1,p2)
Goto start
END1:
TextWindow.Pause()