Computer Science Canada playing with turing graphics

Author:  nelson [ Wed Dec 31, 2003 5:28 pm ]
Post subject:  playing with turing graphics

heh it's pretty cool

^^
 code: var a, b, x, y : int := 1 var a1, b1, x1, y1 : int := 1 var radius, xx, yy : int var c, cc : int := 104 var ch : string (1) randomize cc := 1 proc abc     loop         % randint (c, 20, 103)         drawline (x, y, x1, y1, black)         xx := floor ((x1 + x) / 2)         yy := floor ((y1 + y) / 2)         radius := floor (sqrt ((x1 - x) ** 2 + (y1 - y) ** 2))         drawoval (xx, yy, radius, radius, c)     %  <---- try change colour here         if x > maxx or 1 > x then             a := (a1) * -1         end if         if x1 > maxx or 1 > x1 then             a1 := (a1) * -1         end if         if y > maxy or 1 > y then             b := (b) * -1         end if         if y1 > maxy or 1 > y1 then             b1 := (b1) * -1         end if         delay (5)         drawline (x, y, x1, y1, white)         x := x + a         x1 := x1 + a1         y := y + b         y1 := y1 + b1         c := c + cc         if c > 254 then             cc := -1         end if         if c < 104 then             cc := 1         end if         exit when hasch     end loop     getch (ch)     return end abc loop     put "press anykey to start a new one"     delay (500)     randint (x, 1, maxx)     randint (y, 1, maxy)     randint (x1, 1, maxx)     randint (y1, 1, maxy)     abc     delay (500)     cls end loop

 Author: Boarder16 [ Thu Jan 01, 2004 9:29 pm ] Post subject: its one of teh ugliest things i've ever seen in turing ..... but it's till somewhat complicated programming so its not all that bad........ MUAHAHAHAHHAHAHAHH!!! ahahahahhahahahahaa        Author: DanShadow [ Fri Jan 02, 2004 1:32 pm ] Post subject: ...lol, I think I remember myself doing the exact same thing when I got bored one day. Although the program is simple, I kind of like how when the line hit the edge, it would do this (slightly) 3D looking spin thing, heh.

 :