Turtle Graphics

From JSXGraph Wiki
Revision as of 18:13, 19 December 2008 by A WASSERMANN (talk | contribs)
Jump to navigationJump to search

This is a very basic implementation of turtle graphics with JSXGraph.

List of commands

There is a predefined turtle object t. Therefore, all commands start with t, like t.fd(100);

  • t.forward(len); or t.fd(len);
  • t.back(len); or t.bk(len);
  • t.right(angle); or t.rt(angle);
  • t.left(angle); or t.lt(angle);
  • t.penUp();
  • t.penDown();
  • t.clean();
  • t.setPos(x,y);

Snowflake Example