Getting Them Ready

We’re already half-way through the fall Code Club session for 4th graders. Now is the time when they start working on the design of their own project.  Having the opportunity to create their own game is pretty much why they come. My job is to get them ready to be successful in this venture.  To this end, I try to present lessons that help them learn programming concepts that they will want to use in their game design.

After eight Showcases and 108 projects, I feel have an idea of the essential programming concepts students will be using in the games students like to make.  We move fast and don’t get the chance to do more than introduce these concepts – it’s more learning to code than learning computer science.  It’s a start.

Screen Shot 2017-11-16 at 8.06.44 PM

Get the taco to the Scratch cat

Here’s what they will want –  A Sprite they can control with arrow keys to move around their game.  (The maze game).  A Sprite that can chase after them (Cat and Mouse).  Both of these projects introduce sensing as well  – in the maze game you are forever checking if you touch the sides and in both, you are forever checking if you won.

Screen Shot 2017-11-16 at 8.08.34 PM

You’re the banana. Don’t let the monkey eat you.

They might want to keep track of a score or set a time limit.  (Ghostbusters)

Screen Shot 2017-11-16 at 8.01.13 PM

Click on the Sprites when they appear to get points.

Screen Shot 2017-11-17 at 5.25.16 AM.png

From experience, some of them will want a game with gravity. It’s a concept that I don’t usually spend any time on but this year, from talking with the students, I could tell there will be some platform games in the works.

Screen Shot 2017-11-16 at 7.56.40 PM

I used Code Club World’s Flappy Parrot project to introduce gravity.  It also reveals the animation trick of moving the background while the main character stays in the middle.

I wasn’t sure if they would be able to handle this project, but they worked through it well and I felt they were successful.

Screen Shot 2017-11-16 at 7.57.42 PM

Flappy robot costumes – hand drawn wings

This last week we did the virtual pet project from the Scratch Tips.  I printed some of the Scratch cards of the project as well.  Virtual pet introduces broadcast & receive which is an important but difficult concept.  Broadcast & receive is powerful but requires planning and keeping track of your Sprites. This level of thinking is just developing for them.  They struggled with broadcast and receive, but mostly with the motion blocks because they were modifying the placement of Sprites to fit their creative take on a virtual pet but couldn’t translate that to adjust the go-to blocks properly so they got some strange movements they didn’t understand.

All in all, I like this progression of projects: 1) Maze game, 2) Felix & Herbert, 3) Ghostbusters, 4) Flappy Parrot, 5) Virtual Pet. It presents a variety of game types and hits some good basic concepts.  It leaves out a few of my favorites, though, like Chatbot. I also feel they need more basic coordinate knowledge (move, go to, glide).

(The problem with not blogging regularly is that when you do, you have too much to say and the blog gets really long, for which I apologize.)

Advertisements

Scratch Alternative Presentation

In one fourth-grade class students had a US state presentation project as one of the last assignments for school this year. I received the okay from the teacher to allow a student to make his presentation using Scratch.  He was a Code Club member and I knew he had the programming skill and drive to complete all the requirements for the project using Scratch.

While the rest of the class used Google Slides, he made this great Scratch interactive project to share.  He worked hard and I was impressed with the results.Screen Shot 2017-07-02 at 1.30.49 PM

He set the project up like a Chatbot project and used broadcast to change the backdrops. He also asked questions to keep the audience engaged.

I was available to help with the coding, but he worked pretty independently.

Screen Shot 2017-07-02 at 1.47.13 PM

I would have liked to see more picture Sprites. We also discussed recording some audio for a portion of the presentation but ran out of time. He made a bibliography backdrop but it didn’t get included in the version we uploaded. Before he presented this to his class, he made some last minute changes that are saved in his account offline and not published.

He has his own Scratch account now and I know he will continue to code and create in middle school.  That makes me really proud.

Screen Shot 2017-07-02 at 1.39.38 PM

He had a rough end of the year within his classroom and with the dynamics of some of the other students so I was glad to be able to give him some flexibility with this assignment and let him do something he enjoys and show his coding skills.

I would like to think that Scratch would be an acceptable presentation format for other school projects like this.  I have been thinking along these lines for a while and now have proof that it can be done and can show teachers what the results look like.

Your Name in BeetleBlocks

In December my school’s PTO approved my grant for a 3D printer. Yes!  Now we can print 3D artifacts using BeetleBlocks.  My idea for the 4th graders’ first project is to design a 3D model of their name using BeetleBlocks code.

20161210_141806

School name printed by school printer using Beetleblocks code

I started with one of my math enrichment groups first. They were my small group test of the idea. This group has played with BeetleBlocks but most recently had been making math games in Scratch.

It only takes about 5 blocks of code to write your name and make a cuboid to keep all the letters together.  It takes a little bit more time to make decisions about the size of the text, the size of the cuboid and where you want to put the block that keeps the letters together.

screen-shot-2016-12-28-at-6-54-32-am

basic code stub for project

I gave them the constraints that their name had to fit on the BeetleBlocks grid (20 by 20 ) but they could have their name with the support cuboid behind or below.

Screen Shot 2016-12-28 at 7.25.50 AM.png

Name on grid with support cuboid below

The technically difficult part was getting the STL files saved where I could access them and that only had to do with the way our computers are networked.

20161216_204842

3D print of name with cuboid behind

The students were really excited about everything and just wanted to sit around the printer and watch it print.

20161216_142746

I was able to print three names at a time. I would have been able to print all nine students names in the time allowed, but I got cocky and changed filament in the middle and that caused a jam that I was not able to resolved before the end of the day.

20161216_213419

3D prints in MakerGeek’s Crystal blue PLA 

You have to understand that the printer arrived at school on Monday and we were printing this project on Friday. On Monday, the 4th graders voted on the filament color for their grade (Crystal blue, by the way) and on Friday, during the middle of printing, the filament arrived!

Based on this experience, I made a one page handout 3d-model-your-name-in-beetleblocks for the next time.  The next group to try this will be the rest of the students in this class.  These first nine will be my experts and help the rest of their class code and export their models.  My goal is to have all three 4th grade classes code and print a 3D model of their name.  Then I’ll try it with the 3rd graders.

The only curious thing I’ve found with BeetleBlocks is the rotational changes that I have to either code up front or adjust in Cura (printer software) to get the correct orientation for printing.

screen-shot-2016-12-11-at-8-36-21-pm

Strangely, when I save the model on the left, it will import into Cura with correct orientation for printing.

 

Details about our 3D printer:  The grant was for a $400 Printrbot Play.  It is a small printer with a small print bed size – 100 x 100 x 120 mm.   The Play received a few nods from MakeMagazine and 3Dprint.com 3D printer guides. I also have 2 years of experience with Printrbot printers – we have a personal Printrbot Simple at home.

20161216_141121.jpg

Change in Plans

I’ve been thinking about a comment I heard from a student at the Showcase of projects earlier this month.  He was testing his game out before the parents arrived and said, “It isn’t how I imagined it would be, but I like it.”  I think that explains many coding projects. You start with an idea, plan it out but during the coding of it you end up with behaviors you didn’t expect, or you have to make compromises to fit the limitations of the language or your ability to code in that language. You might even like the results better than what you had planned.

I went back and looked at their game design document, and he’s right.  The finished game is not what they (he and his partner) had originally planned.  They did want an adventure game where there would be Sprites to avoid and a “boss” Sprite to defeat.  It was going to be two levels – one in space and one underwater.  There were going to be coins to collect.

Screen Shot 2016-05-31 at 8.26.20 PM

In the end, they were able to code one Sprite that you have to avoid – the Cheetos monster and one “boss” Sprite – the Apple guy.  You, the unicorn, has to jump on top of the Apple guy to get points.  They call their project IDK Adventure.   In their presentation they said their favorite part was the Cheetos monster and that if they had more time they would add a different background and add more Cheetos.

Screen Shot 2016-05-31 at 8.40.09 PM

It doesn’t look like a lot of code, but it was quite challenging for them.  They spent one Code Club just working out “gravity” where the logic was to only “fall” (change y) when not on “touching” the “gray” moon.   Then to get the points for defeating the Apple guy, you have to jump on the top “touch the brown color” part of the stem.  The Apple guy hides when you touch him, so it is a challenge to win.

They weren’t the only pair to have to settle for something less than they were hoping to complete, but they seemed happy with the project they were able to finish.

Screen Shot 2016-05-31 at 8.48.03 PM

Their Game Design Document had them designing a wrestling game where you play against the computer. If you jump on your opponent, you go to the next level. I think they changed their minds about what they wanted from one week to the next, or they weren’t sure if they wanted a 2 player or 1 player game.  In the end, they weren’t able to get the fight behaviors to work the way they wanted. Screen Shot 2016-05-31 at 8.54.37 PM

While you do get to pick the player you want to be, there’s not a lot of animation of the wrestling match.  There’s a bit of smack talk. In the end their favorite part is the cloning. I don’t know how this became part of their project, but they’re right.  It makes a great addition to Daboomdocbros,  even if it wasn’t planned in the beginning.

These are two examples of projects that did not turn out exactly as originally imagined.  As with many creative processes, the end results doesn’t always match your original idea.  I don’t consider this failure, and I’m glad my students don’t either.  I’m hoping their flexibility in working with the design process will serve them as well as their introduction to coding.

 

 

Point of View

I am quite pleased with the variety of projects that my Code Club students are creating for our showcase in May. Everything from a maze, pong, virtual pet, dress-up to adventure and sports games.  There’s even a game of games project idea that will be interesting to see develop.

One duo was wanting to make a game where the hero stays mostly in the center and the background scrolls before he gets to the edge.  Something like Power Pete (or Mighty Mike) from Pangea Software  (those were good times, hours wasted)

maxresdefault

At first I recalled the scrolling demo project from Colleen Berekey. There are over 50 remixes of this project.  I showed the pair this project but it wasn’t quite what they had in mind.

Screen Shot 2016-04-23 at 9.29.11 PM

So I went home and thought about it and consulted my consultant – my spouse who’s a software engineer.  Like with other tricks to animation, coding this was a matter of changing perspective and looking at the problem from a different point of view.

If your Sprite stays in the middle, the background and chaser Sprites will have to move with the arrow keys. Or more specifically, against the arrow keys.

Here’s my quick take on the point of view problem.Screen Shot 2016-04-23 at 9.12.04 PM

Scratch Cat stays in the center and only points in the direction of the arrow key.  The stars move in the opposite direction briefly and then move back to center.  This took some fiddling with to get it to look half way decent.  In addition the octopus has to move in the opposite direction while still moving forward towards Scratch Cat.

Screen Shot 2016-04-23 at 9.12.28 PM

Octopus moves in the opposite direction of the arrow key pressed while still forever chasing Scratch Cat

Screen Shot 2016-04-23 at 9.12.47 PM

For added fun I included additional bad guy clones.

Defining Initial Conditions and Sprite Senses

The second week of my two Code Clubs went better than the first week and some fun, creative Scratch projects were made.  I am pleased.

Screen Shot 2015-10-18 at 6.36.00 PM

Wednesdays’ club made maze games using Scratch 2 Offline editor.

Screen Shot 2015-10-18 at 6.37.50 PM

I talked about defining initial conditions.  If you are going to move the Sprite through the maze you’ll need to set up where you want the Sprite to start.  I was able to reinforce this notion with those who set up other items for the maze runners to touch and then have those item “hide”.  If you change the way the Sprite looks (hide), you’ll need to set up the way the Sprite starts off looking (show).

Screen Shot 2015-10-18 at 6.36.19 PM

I also talked about conditionals and ways Sprite can “sense” things.  They’ll get more practice with this concept again with next week’s project.

Screen Shot 2015-10-18 at 6.37.08 PM

Most students were successful and their maze games were very creative.  I think a number of students were surprised by their success. Unfortunately a number of the games weren’t saved or saved “temporarily” on their desktop which isn’t permanent in student profiles. We will go over this again.  One student noticed this on Friday but was able to re-create her game during her free time that day.

Screen Shot 2015-10-18 at 6.38.29 PM

One thing I noticed that would make our time together even better is if the students relied more on each other’s help.  I mentioned to the student that this is a club and we are going to work together to learn, but I’m going to re-iterate that next week  and specifically have them ask an elbow partner first, then ask for help from me or Josh, my high school volunteer.  This will help later when they will be doing their individual or pair projects and will need to be more independent.

Thursday’s club went better, too. They tried Felix and Herbert from Code Club World’s archived Scratch projects.  Of course they all put their own spin on things, being a creative bunch.

Screen Shot 2015-10-18 at 6.43.46 PMI also talked about conditionals and ways Sprite can “sense” things. They were also more successful although it took them a bit longer to buy into to the project even though I showed them the example working project.

Screen Shot 2015-10-18 at 7.24.45 PM

They were really interested in getting the costumes to change to simulate walking or flying.  They also wanted to learn to add a score.  They weren’t phased at all by switching to Scratch 2 Offline editor.

Screen Shot 2015-10-18 at 6.44.17 PM

One student said he had been playing with Scratch all week whenever he had a chance.  Two others said their parents had downloaded Scratch at home.  This group showed a more collaborative spirit.  I helped one student get a “soundtrack” to play in the background and he helped others add the code to their projects.

Screen Shot 2015-10-18 at 7.28.38 PM

Another student announced he knew how to add a timer and was willing to show others.Screen Shot 2015-10-18 at 6.41.04 PM

They are a bit exuberant bunch for a group of twelve, and I still don’t know all of their names or have complete control at all times, but I asked them if they had a good time when they were lined up for release and they all very enthusiastically replied, “Yes!”

Screen Shot 2015-10-18 at 7.55.41 PM

I do enjoy this, you know. Just saying.

A New Plan

(I know, 3 blogs in one week.  Bear with me. This one is short)

I spent some time over the weekend hashing out the project plan and learning objectives for my two code clubs.  I feel better with a plan and ideas in mind and on paper.

I also revised my expectations for last week.  My learning objective for the students last week was to get to know Scratch and the code blocks that include Events, Motion, Looks and Sound.  I have to remember there’s also a new costume editor they will have to get a feel for as well as the notion of the Stage and Sprites and how they are different.  That’s actually a lot. I think the majority of the students have got a grasp on some of those concepts. (If they haven’t forgotten them in the meantime)

One student came up to me today and said, “I wish Code Club was everyday!!” What an awesome sentiment.

This week I’d like to focus on Initial Conditions, Conditionals and Sensing blocks. To that end, I’ve updated the maze project to use for Scratch 2.0. And we will try it out tomorrow.

Screen Shot 2015-10-12 at 8.39.24 AM Screen Shot 2015-10-12 at 8.57.42 AM

Scratch 2 Maze Project – Google Docs

I wonder if I’ll have time to mention the “Think like a Programmer” ideas of make one change, test it, make another change, test it?

Then next week both clubs can work on the same project.