2015 CSE/EGR Summer Camps 1 Computer Science Concepts 1. What is an algorithm? 2. Binary information coding 3. Programming concepts via Scratch Designed.

Slides:



Advertisements
Similar presentations
Create a Simple Game in Scratch
Advertisements

Summer Computing Workshop. Introduction to Variables Variables are used in every aspect of programming. They are used to store data the programmer needs.
Create a Simple Game in Scratch
30 min Scratch July min intro to Scratch A Quick-and-Dirty approach Leaving lots of exploration for the future. (5 hour lesson plan available)
Mission Technology Introduction to Scratch! June 2007.
Scratch for Storytelling Dr. Ben Schafer Department of Computer Science University of Northern Iowa.
Pong! “The oldest commercially available game in history” Resources created from the video tutorials provided by David Phillips on
Harry Potter Scratch Game
1 An intro to programming concepts with Scratch Session 3 of 10 sessions Repetition and variations.
Code Club Session 3 Shark Eats Fish. Picture of finished product here.
Write Your First Computer Game!. Coding: Programming Languages Just like you can speak Chinese to someone who understands Chinese to tell them what to.
Mrs. Chapman. Tabs (Block Categories) Commands Available to use Script Area where you type your code Sprite Stage All sprites in this project.
Learn… Create… Program. Manipulation of Multiple Media Connects with youth culture Scratch is a new graphical programming language designed to support.
Session 5 of 10 Review + Multiple Sprites
1 An introduction to programming concepts with Scratch.
An intro to programming concepts with Scratch Session 7 of 10 sessions Working with sounds and sprite communication.
An intro to programming concepts with Scratch Session 2 of 10 sessions I/O, variables, simple computing.
1 An introduction to programming concepts with Scratch (in 5 hours + homework)
1 An intro to programming concepts with Scratch Session 1 of 10 sessions Looks and Motion.
ITEC Winter An intro to programming concepts with Scratch Quick intro for college citizens. George Stockman MSU CSE.
Digital Art in Scratch part 1 Barb Ericson Georgia Tech Oct 2010.
Mr. Wortzman. Tabs (Block Categories) Available Blocks Script Area Sprite Stage All sprites in this project.
2012 CSE-BEACON camp1 Computer Science Concepts 1. What is an algorithm? 2. Binary information coding 3. Programming concepts via Scratch Designed for.
Scratch the Cat. Object Oriented Programing Writing computer programs Based on Objects Instead of Actions Based on Data Instead of Logic.
Scratch Internet- Open Chrome hit “Create” 1.
Code Club Session 2 Dance Party. What will we learn ?  How to change the background  How to create animations  How to make objects talk to each other.
Introduction to Scratch!
Introducing Scratch the Cat
Objects and Methods in Scratch 1. 2 Scratch environment Stage is at upper right (where actors act and information is displayed) Sprite is another name.
2012 CSE-BEACON camp1 Computer Science Concepts 1. What is an algorithm? 2. Binary information coding 3. Programming concepts via Scratch Designed for.
Digital Art in Scratch part 1 Barb Ericson Georgia Tech May 2011.
Creating a Simple Game in Scratch Barb Ericson Georgia Tech June 2008.
Scratch Another computer programming language Developed by MIT in 2003
Create a Halloween Computer Game in Scratch Stephanie Smullen and Dawn Ellis Barb Ericson October 2008.
Computer Programming Modeling a Passive Solar Home.
24 Background Building 25 Computing Terminology, and Speed/Velocity Module 4 Notes: Sensing, Or Operator, Conditional Logic 28 Module 4 Algorithms,
Variables and Random Numbers Computer App Session 4.
Using MIT Scratch for Programming and Control Exercise 1 Creating movement Year 11 DTG 2012.
From last time… Explore the blue commands from the motion menu Find at least three ways to get the sprite to move to the UPPER LEFT corner.
Introduction to Computer Programming - Project 2 Intro to Digital Technology.
Using MIT Scratch for Programming and Control Exercise 4 – Cat and Dog game Year 9 ICT Autumn Term 2007.
Scratch for Interactivity Dr. Ben Schafer Department of Computer Science University of Northern Iowa.
How to create a basic game in Scratch. The Scratch Stage The Scratch stage is 480 pixels wide and 360 pixels high x increasesx decreases.
1 CSC 221: Computer Programming I Fall 2009 Introduction to programming in Scratch  animation sprites  motion, control & sensing  costume changes 
ICT/COMPUTING RULES Only use software allowed by the teacher
Teaching Kids Programming with Chromebook Digital Convergence Lab, NIU.
Creating a Simple Game in Scratch Barb Ericson Georgia Tech May 2009.
Introducing Scratch Learning resources for the implementation of the scenario
Create a Halloween Computer Game in Scratch
Scratch for Interactivity
Madlib-Input, Strings, and Lists in Scratch
Scratch Unit Overview We are going to look at computer programming and how to create your very own computer game The piece of software we will be using.
Spanish Mad libs with Scratch
Unit 2 Getting Started With
Scratch for Interactivity
Introduction to Object-Oriented Programming
Learn… Create… Program
Learn… Create… Program
Scratch for Storytelling
An intro to programming concepts with Scratch
Go to =>
Learn… Create… Program
Learn… Create… Program
Creating a Simple Game in Scratch
CSC 221: Introduction to Programming Fall 2018
Presentation transcript:

2015 CSE/EGR Summer Camps 1 Computer Science Concepts 1. What is an algorithm? 2. Binary information coding 3. Programming concepts via Scratch Designed for learners 10 years old up to 100. Coverage differs according to which camp.

2 Programming concepts via Scratch; Quick Intro GET YOUR OWN Free download of software available at Video tutorials for learning available at Learn a lot on your own later CSE/EGR Summer Camps

3 What can we do with Scratch? Learn some computing concepts. Learn some practical algorithms. Use Scratch as computing tool. Have fun with Scratch creating stories, games, art. – it’s multimedia 2015 CSE/EGR Summer Camps

4 Start scratch and let’s go! In the lab, Click on the cat icon Scratch programming environment comes up First try simple things (then build richer stuff) 2015 CSE/EGR Summer Camps

5 Explore Scratch environment Stage is at the right (where actors act and information is displayed) Sprite is another name for actor. Instruction menus at left (instructions for the actors) A script is another name for program or method; a script tells the actor what to do. Programming area in center; here is where we construct scripts for sprites 2053 CSE/EGR Summer Camps

6 The LOOKS menu Instructions for setting the color, size, and visibility of a sprite. Costumes will be used later CSE/EGR Summer Camps

7 The “hello” script (program) Choose the Looks menu Click on the “say hello” block Check your sprite behavior at the right Then click “say hello for 2 secs” Your very first Scratch program! 2015 CSE/EGR Summer Camps

8 Try some other looks operations (click on the menu items) Change color effect by 25 Change color by 25 again Hide Show Change size by 10 Change size by 10 again Set size to 100% 2015 CSE/EGR Summer Camps

9 Let’s write a script to Say “hello” for 2 seconds Then change color by 25 Then think “Hmm..” for 4 seconds Then change color by 75 Then change size by 200 Drag each instruction from the menu to the center script area. Connect them into a single block. Edit the parameters to get the numbers we want CSE/EGR Summer Camps

10 Our script (program) 2015 CSE/EGR Summer Camps

11 A sequence or block is a simple script or program The first instruction is done first The second instruction is done second The last instruction is done last. (if any one instruction is done, then every one of them is done, and just once) 2015 CSE/EGR Summer Camps

12 The WAIT instruction WAIT is needed to slow down the acting so we can see or hear it properly (computers are too fast sometimes) Get the wait instruction from the CONTROL menu. Ignore the other menu options for now. Insert a wait in our looks script 2015 CSE/EGR Summer Camps

13 3 second pause between changing color and size 2015 CSE/EGR Summer Camps

14 Student exercise: script your sprite to do … Double the size of the sprite Wait 2 seconds Change the color of the sprite to green Wait 4 seconds Change the whirl effect to 100 Say “My nose is tired!” 2015 CSE/EGR Summer Camps

15 The MOTION menu How to locate and orient a sprite; and how to move it CSE/EGR Summer Camps

16 Position on the stage Using the Looks menu, shrink our cat to 25%. Click on the Motion menu. Click to check the box for x- position and y- position Drag your cat around and note its x-y position CSE/EGR Summer Camps

17 Exercises: goto instruction (do you know about coordinates?) In the Motion menu, drag the “goto xy” instruction to the script panel. Edit the coordinates and click to see the sprite’s position A) goto x=200, y=0 B) goto x=-200, y=0 C) goto x=200, y=-100 Where does the cat go? 2015 CSE/EGR Summer Camps

18 The “glide-to” instruction Drag the “glide-to” instruction into your script panel. Edit the coordinate values and click to see where your sprites goes CSE/EGR Summer Camps

19 Exercise Create a script to glide the sprite along the sides of a triangle. The first vertex of the triangle is (-100, -100). The second vertex is (200, -100). The third vertex is (50, 100). Make sure you complete the triangle. Change the speed of gliding and run again. New feature: click on Pen Down in the Pen Menu and run it again 2015 CSE/EGR Summer Camps

Tracing a square: 4 sides 2015 CSE/EGR Summer Camps20

REPEAT move and turn 4x 2015 CSE/EGR Summer Camps21

Detroit Tiger runs the bases Import the baseball park background Put your tiger at home plate (how?) Have it glide to first base Have it glide to 2 nd base Then 3 rd and home Make it do a flip Make it say “Home run!” 2015 CSE/EGR Summer Camps22 Cat on 1 st base [-149, -48]

Bat flying example Bat seems to move randomly 2 costumes create motion Press keys to control program Left arrow moves bat left Right arrow moves bat right 2015 CSE/EGR Summer Camps23

Exercise: bat flying randomly 2015 CSE/EGR Summer Camps24 Make a bat fly by flapping between 2 bat “costumes”. Use random values of coordinates x and y. Use arrows keys to control the bat’s position. * Use a forever loop to make the bat continue to fly when the flag is clicked. * See if you can create a “score” variable and use it to count how many times the user clicks on the bat.

Adding new features Create a score variable. Increase score by 2 when user clicks on the bat. Decrease the score by 1 when the user misses clicking on the bat. Add a bat sound to the game. Change the sound when the user clicks on the bat CSE/EGR Summer Camps25

Learn from others: Scratch Library of Examples Click on “File” Click on “Open” Click on “Examples” Then “Stories” Then Madlib Run it; study the code; change the code 2015 CSE/EGR Summer Camps26

Do the story and study the scripts 2013 CSE/EGR Summer Camps27 Study other examples. Change the scripts to change them.

Exercise: find the MIN of a list Explore how to create a list variable Explore how to input numbers to the list Explore how to pass through the list to set a variable MIN to the minimum in the list Remember: can help your learningwww.learnscratch.org 2015 CSE/EGR Summer Camps28