And with just a couple rolls added look what you get. Note the BETA version did not have "Fill" 3D enabled yet. The original code was not orientation independent (i.e. it would not work if you issued say a rt 5 before drawing it). I modified the code to snapshot the orientation (heading) before starting and use the difference. Of course I MSWLogoized it to RGB. I also had a few rounding errors I'm working on which I worked around. But the basicly the code still runs even when the turtle is standing on his head :-) to chess :size :level if :level<1[stop] repeat 4[draw] setfloodcolor ifelse 0=remainder round (heading-:startheading+360) 180[[255 0 0]][[0 0 0]] fill_it setpc [255 255 0] ; lines color end to draw fd :size rt 90 chess :size/2 :level-1 end to fill_it pu rt 45 fd 10 pd fill ; brown or blue pu bk 10 lt 45 pd end to main ; Chessboard cs perspective setturtle -1 setxyz -200 -200 200 setturtle 0 make "startheading heading chess 128 4 rr 90 make "startheading heading chess 128 4 rt 90 lr 90 make "startheading heading chess 128 4 end -- =============================================================== George Mills email: mills@softronix.com http://www.softronix.com The www page contains some very powerful educational software. Our single most important investment is our kids.
Global SchoolNet Foundation -
Linking Kids Around the World!
Copyright GSN - All Rights Reserved
- Comments
& Questions
Visit GSN's
Global
Schoolhouse for more exciting learning resources!
Search our Site
-
Home