The BFOIT Introduction to Programming Class
Turtle Graphics in Java
drawBoard.java


Here is the source code for my drawBoard() method and a Java Applet that demonstrates what happens when it is executed.

alt="Your browser understands the <APPLET> tag but isn't running the applet, for some reason." Your browser is completely ignoring the <APPLET> tag!

void drawBoard()
{
   setheading( 0 );
   penup();
   setxy( -50, -150 );
   pendown();
   forward( 300 );
   penup();
   setxy( 50, -150 );
   pendown();
   forward( 300 );
   setheading( 90 );
   penup();
   setxy(-150, -50 );
   pendown();
   forward( 300 );
   penup();
   setxy( -150, 50 );
   pendown();
   forward( 300 );
   penup();

} // end drawBoard()



Table of Contents