Hey guys,
welcome to Day 19 of 100 Days of Code. Today
we're going to be learning more about turtle graphics,
but we're also going to look at event listeners, higher order functions, state,
and multiple instances of an object.
And we're going to be using this knowledge to build a whole bunch of games. We're
going to be making Etch-a-Sketch, one of my favorite childhood toys.
And this game is going to allow us to use the up and down arrows to move our
turtle forwards and back
and then we can turn our turtle clockwise and anticlockwise to continue
drawing.
So we can use this to create circles or to create lines.
And we can basically create drawings using our turtle program.
In addition,
we're also going to be making a turtle racing game where we will get to bet on
the color of a turtle who will win the race.
And then once we click okay to the popup,
then all of our turtles go to the starting line and they start moving at a
random pace.
And then once the first turtle hits the right edge of the screen,
it will be declared the winner and we will get to see if our turtle won or not.
So at the moment, the red turtle is not looking like it's going to make it.
1: I think the orange is probably-- Oh, the yellow's overtaking it.
0: And there we go. We lose. The purple turtle
was the winner of the race. So I hope you're
as excited as I am to build these projects together. Once you're ready,
head over to the next lesson and let's learn about how we can listen to key
strokes on the keyboard.