screen 18 for i = 0 to 15 color ,i cls print "color- "; i sleep 2000 next i end
screen 18 cls const pi = atn(1) * 4 const radius = 200 for i = 1 to 15 color i,0 dim angleFrom as double, angleTo as double, angleMid as double angleFrom = (i - 1) * (2 * pi / 15) angleTo = i * (2 * pi / 15) angleMid = angleFrom + (angleTo - angleFrom) / 2 ' When we reach end of circle angleTo becomes 0 so we make it 2pi instead if angleTo < angleFrom then angleTo = angleTo + 2 * pi LINE (320, 240) - (320 + cos(angleFrom) * radius, 240 - sin(angleFrom) * radius) CIRCLE (320, 240), radius, , angleFrom, angleTo LINE (320, 240) - (320 + cos(angleTo) * radius, 240 - sin(angleTo) * radius) PAINT (320 + cos(angleMid) * radius / 2, 240 - sin(angleMid) * radius / 2) print "color- "; i sleep 100 next i sleep end
hahaha, no one likes a show off. Just kidding, thats a badass code!!! The reason i put this one here was so pie could check which colors are which, hence the 'color pie'. But that example you put here is the difference between night and day!!! Credit is given where credit is due.
Hehe i was bored so i downloaded the FBIde bundle to try out rickclark58's demo. So since i had FB installed i thought i should try to make something, and woala… Sorry, I didn't intend to "steal your thunder" i just figured it might motivate you :)
Gosha, maybe someone should write a sin/cos tutorial :)