Manually Controlling a Turtle II

Start with the following code. Upon running the code "as is", you will be presented with a window similar to that used in the "Manually Controlling a Turtle" project. This time however, you can type a great number of commands. To see what commands are available, type "help" in the text field and hit the "Do It!" button.

Some of these commands have already been implemented: help, rotate, forward, color, tail-up, tail-down, go-fast, and clear. Experiment with these to see how they work.

Then, complete the code by adding the appropriate methods for the report-heading, polygon, star, and forward-dashed commands -- so that when these commands are used, results similar to the below images can be produced.

(Note: with the exception of adding these methods and uncommenting the appropriate cases in the switch statement, the original starter code should not be altered in any way!)



Note: the report-heading command does not turn the turtle at all,
it merely reports what direction the turtle is currently headed.