Sliders for Glenys

Adding sliders to the New turtle code

Log in to post a comment.

// Forked from "New turtle with Sliders" by rupertxrussell

// You can find the Turtle API reference here:

// Global code will be evaluated once.
const offsetX=-92; //min=-200 max=200 step=1
const offsetY=-53; //min=-200 max=200 step=1
const size=100; //min=5 max=200 step=1
const angle=144; //min=1 max=360 step=1
const number=4; //min=1 max=3600 step=1

const turtle = new Turtle();
turtle.goto(offsetX, offsetY); // change the starting position


// The walk function will be called until it returns false.
function walk(i) {
    turtle.forward(size); // change the size
    return i < number;