Presentation is loading. Please wait.

Presentation is loading. Please wait.

Exploring Computer Science Lesson 4-12

Similar presentations


Presentation on theme: "Exploring Computer Science Lesson 4-12"— Presentation transcript:

1 Exploring Computer Science Lesson 4-12
Timers Exploring Computer Science Lesson 4-12

2 Objectives The students will be able to: Create a timer

3 Timers Timers are simply a variable that counts down (or up).
You already know how to initialize a variable You know how to add or subtract one You know how to “wait” 1 second Bottom line – You know how to make a timer! I don’t need to teach you.

4 Timer Project How to make a timer in Scratch:
Create a variable called timer. When the flag is clicked, initialize the timer to 30. Continually, wait 1 second and subtract one from timer Output the current time either with a sprite or just show the variable Check if the timer = 0 If the timer = 0 make either the background or a huge sprite say “Time’s Up” When the green flag is clicked, everything should start over. Be creative as to what you want your program to look like. Make sure the timer stops at 0 and does not continue into negatives. Extra Credit: When the time’s up, have the sprite or background also say the score.


Download ppt "Exploring Computer Science Lesson 4-12"

Similar presentations


Ads by Google