include "win64.h" 'include "window2.h"
Window "TURTLE", 600, 600, 2
Font 12,24,0,"courier"
sys_mode=4
float a,b,x2,y2,angle=1,angle_difference=.8
sys counter,color_value=7,difference=2,length=500,x=50,y=550
ClsColor 200,200,248
y2 = y - length
length = length - difference
y = y2
While counter <180
a = sin(rad(angle)) * length
b = cos(rad(angle)) * length
x2 = x + b
y2 = y + a
Line x, y, x2, y2, 1, color_value,color_value,color_value
angle = angle + angle_difference
length = length - difference
a = sin(rad(angle)) * length
b = cos(rad(angle)) * length
x = x2 - a
y = y2 + b
Line x2, y2, x, y, 1, color_value,color_value,color_value
angle = angle + angle_difference
length = length - difference
a = sin(rad(angle)) * length
b = cos(rad(angle)) * length
x2 = x - b
y2 = y - a
Line x, y, x2, y2, 1, color_value,color_value,color_value
angle = angle + angle_difference
length = length - difference
a = sin(rad(angle)) * length
b = cos(rad(angle)) * length
x = x2 + a
y = y2 - b
Line x2, y2, x, y, 1, color_value,color_value,color_value
length = length - difference
angle = angle + angle_difference
counter +=1
color_value += Rand(4,8)
Wend
WaitKey(32)
WinEnd