coderdojo athenry beginners

36
CoderDojo Athenry Code and notes by Michael Madden and Martha Fahy, 2013 Beginners

Upload: others

Post on 15-Oct-2021

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CoderDojo Athenry Beginners

CoderDojo Athenry

Code and notes by Michael Madden and Martha Fahy, 2013

Beginners

Page 2: CoderDojo Athenry Beginners

Every week: Sign in at the door If you are new: Fill in Registration Form Ask a Mentor how to get started

Make sure you are on the Athenry Parents/Kids Google Group: email [email protected]

CoderDojo Athenry

"Above all, be cool"

Wifi password: coderdojowireless

Page 3: CoderDojo Athenry Beginners

Today's Ninja Challenge: Write Your First Computer Game!

Page 4: CoderDojo Athenry Beginners

Today's Big Ideas

What is Coding?

Who Writes Code?

What is Scratch?

How Can We Write Code?

Page 5: CoderDojo Athenry Beginners

Programming Languages • Tell computer how to perform tasks

• C, C++, Java, Visual Basic, Python, JavaScript, PHP, HTML5

Some Java Code

Page 6: CoderDojo Athenry Beginners

Programming Languages

• E.g. text, numbers

Input, Output & Store Data

• E.g. add numbers, change text

Operate on Data

• Repeat commands several times

Loops

• Do something IF something else is true

Decisions

Page 7: CoderDojo Athenry Beginners

Scratch http://scratch.mit.edu

• Free & Open Source

• Windows, Linux, Mac

• Palette of Commands

• Games & Animation

• Encourages Sharing

Page 8: CoderDojo Athenry Beginners

Scratch's Interface

Stage

Sprite

Script for Sprites

Palette of Commands

Page 9: CoderDojo Athenry Beginners

The Stage

Library Paint File Camera

Full Screen Starts/Stop

Page 10: CoderDojo Athenry Beginners

The Sprites (your characters)

Library Paint File Camera

Page 11: CoderDojo Athenry Beginners

Main Menu

Page 12: CoderDojo Athenry Beginners

Cursor Tools

Duplicate Grow

Shrink Delete

Tips

Page 13: CoderDojo Athenry Beginners

Palette of Commands

Page 14: CoderDojo Athenry Beginners

Motion

Page 15: CoderDojo Athenry Beginners

Looks

Page 16: CoderDojo Athenry Beginners

Sound

Page 17: CoderDojo Athenry Beginners

Pen

Page 18: CoderDojo Athenry Beginners

Data

2x+1=7

Page 19: CoderDojo Athenry Beginners

Event

Page 20: CoderDojo Athenry Beginners

Control

Do that 10 times

Page 21: CoderDojo Athenry Beginners

Sensing

Page 22: CoderDojo Athenry Beginners

Operator

Page 23: CoderDojo Athenry Beginners

More Blocks

Page 24: CoderDojo Athenry Beginners

How to Get Started

• Think first!

• Start simple: add more later

Plan the Design

• Design it: appearance & behaviours

• Write script (Code) to control its behaviours

Create First Character

• Any bugs? (Not working as expected)

• Debug and Improve

Test It

• More Characters, More Behaviours, More Testing!

Extend It

Page 25: CoderDojo Athenry Beginners

How to Make Progress

Our Creative Coding Rule: There's More Than One Way to Do It!

Try things out and iterate

Save copies: go back if it doesn't work

Talk to others, share ideas, learn from their ideas, improve on their ideas!

Examine other people's code on the Scratch website & upload your code

Page 26: CoderDojo Athenry Beginners

Steps To Make Our Game

Create Jaws: what will he look like?

Code to control him with arrow keys

Change the Stage: Choose a background

Create Diver

Code to make him move randomly

Page 27: CoderDojo Athenry Beginners

Create a Sprite

New Sprite: Select from existing designs

Tip: Default size is big relative to stage: this shrinks it

Name him:

Page 28: CoderDojo Athenry Beginners

Make it Move Under Your Control

x

y

Axis

Page 29: CoderDojo Athenry Beginners

Make it Move Under Your Control

Moves 10 Steps to the Right

Page 30: CoderDojo Athenry Beginners

Make it Move Under Your Control

Moves 10 Steps to the Right Moves 10 Steps to the Left

Mov

es

10 S

teps

Up

Mov

es

10 S

teps

dow

n

Page 31: CoderDojo Athenry Beginners

Make it Move Under Your Control

Page 32: CoderDojo Athenry Beginners

Degrees – Full Circle

Page 33: CoderDojo Athenry Beginners

Create Another Sprite that Moves at Random

Page 34: CoderDojo Athenry Beginners

Change the Background

Library Paint File Camera

Page 35: CoderDojo Athenry Beginners

At the End … Upload your project to the Scratch Website

user: cdathenry password: athenry

Access it

from home

Improve it

Show your

friends!

Page 36: CoderDojo Athenry Beginners

Keep In Touch!

[email protected]

@coderdojoathenr

zen.coderdojo.com/dojo/53