Lesson 22: Pet Giraffe

Overview

Here, students will use Sprite Lab to play with sprites and their properties. Students will use events, behaviors, and custom code to create their very own pet giraffe that gets hungry, playful, and even filthy!

Purpose

Students will use events to make characters move around the screen, change size, and change colors based on user input. This lesson offers a great introduction to events in programming and even gives a chance to show creativity!

Agenda

Warm Up (15 min)

Main Activity (30 min)

Wrap Up (15 min)

View on Code Studio

Objectives

Students will be able to:

  • Identify actions that correlate to input events.
  • Create an animated, interactive game using sequence and events.

Preparation

Links

Heads Up! Please make a copy of any documents you plan to share with students.

For the Teachers

For the Students

Support

Report a Bug

Teaching Guide

Warm Up (15 min)

Introduction

Today students will revisit events in programming.

Review: Ask students questions about the Alien Dance Party.

  • Do you remember what an event is?
  • Can you name any of the events that you used to make the aliens dance? What do they do?
    • when clicked
    • when sprite1 touches sprite2
    • when arrow pressed

Display: Begin by showing Puzzle 1 to your students.

Think/Pair: Ask them to predict what will happen when the code is run, and to discuss with their neighbors. Run the code, and discuss the outcome.

Review of "Personal and Private Information"

Remind students of information that is safe to share online and information that is strictly private.

SAFE - Personal Information UNSAFE - Private Information
Your favorite food
Your opinion
(though it shoud be done respectfully)
First name
(with permission)
Mother's maiden name
Social Security number
Your date of birth
Parents' credit card information
Phone number


Discuss other examples of the two categories above.

Main Activity (30 min)

Goal: Today, students will be creating their own pet giraffe! They’ll begin by reviewing how to put sprites on the screen, then they will assign events that cause actions and behaviors upon interaction.

Teaching Tip

Encourage students with questions/challenges to start by asking their partner. Unanswered questions can be escalated to a nearby group, who might already know the solution. Have students describe the problem that they’re seeing:

  • What is it supposed to do?
  • What does it do?
  • What does that tell you?

Course E Online Puzzles 2018 - Website

Transition: Move students to their machines. Encourage students to follow the instructions for each puzzle. Help them realize that this is a creative activity, intended to help them learn Sprite Lab. It is not an assessment activity of any sort.

Reminder: If puzzles are sharable, remind the students to only share their work with their close friends or family. For more information watch or show the class Pause and Think Online - Video.

Wrap Up (15 min)

Journaling

Having students write about what they learned, why it’s useful, and how they feel about it can help solidify any knowledge they obtained today and build a review sheet for them to look to in the future.

Journal Prompts:

  • What was today's lesson about?
  • How do you feel about today's lesson?
  • What other options would you like to be able to have your pet do?

Standards Alignment

View full course alignment

CSTA K-12 Computer Science Standards (2017)

AP - Algorithms & Programming
  • 1B-AP-10 - Create programs that include sequences, events, loops, and conditionals.
  • 1B-AP-12 - Modify, remix or incorporate portions of an existing program into one's own work, to develop something new or add more advanced features.

Cross-curricular Opportunities

This list represents opportunities in this lesson to support standards in other content areas.

Common Core English Language Arts Standards

SL - Speaking & Listening
  • 4.SL.1 - Engage effectively in a range of collaborative discussions (one-on-one, in groups, and teacher-led) with diverse partners on grade 4 topics and texts, building on others’ ideas and expressing their own clearly.
  • 4.SL.6 - Differentiate between contexts that call for formal English (e.g., presenting ideas) and situations where informal discourse is appropriate (e.g., small-group discussion); use formal English when appropriate to task and situation.
W - Writing
  • 4.W.6 - With some guidance and support from adults, use technology, including the Internet, to produce and publish writing as well as to interact and collaborate with others; demonstrate sufficient command of keyboarding skills to type a minimum of one page in a

Common Core Math Standards

MP - Math Practices
  • MP.1 - Make sense of problems and persevere in solving them
  • MP.2 - Reason abstractly and quantitatively
  • MP.5 - Use appropriate tools strategically
  • MP.6 - Attend to precision
  • MP.7 - Look for and make use of structure
  • MP.8 - Look for and express regularity in repeated reasoning

Next Generation Science Standards

ETS - Engineering in the Sciences
ETS1 - Engineering Design
  • 3-5-ETS1-1 - Define a simple design problem reflecting a need or a want that includes specified criteria for success and constraints on materials, time, or cost.
  • 3-5-ETS1-2 - Generate and compare multiple possible solutions to a problem based on how well each is likely to meet the criteria and constraints of the problem.