Create Your Own World

I don’t usually blog in the summer, but I’m running a weekly summer code club at the library in July and I’m being a bit reflective about the monthly one that I helped lead this last year.

Earlier in the year, I introduced a new (to me, too) project to the Lebanon Library Creative Coders. We decided to take two of our monthly meetings, February and March, to work on the Create Your Own World project from Code Club World.  I knew this middle school age group would enjoy creating a platform game. One of them even continued to work on it for a third month and was able to add a lot of detail like hit points, inventory list, and bad guys.

 

Screen Shot 2018-06-29 at 8.05.47 AM

World detailed with inventory, hp, weapon and bad guys.

The first meeting we focused on setting up the player movement.  We remixed Code Club Rik’s Resources for this project so we could jump right in with the coding.  When I was prepping for our meeting, I went ahead and changed the character from a square to an overhead view of a guy walking.  One of my original groups of students created Showcase projects called Tomb of Terror and Shadow Swamp with Hatty McWalker.  That’s who I was thinking of with this guy.

Screen Shot 2018-06-29 at 7.49.15 AM

Overhead view of my player.  I added a costume with the mirror image and a “next costume” block in my code to make him look like he is walking.

The Creative Coders were certainly creative with the movement options.  I’m used to using arrow keys for movement, but these middle schoolers liked ASWD and this creative ghoulish option with side arrows for turning and up for forward:

 

I’m finding it useful to look at the code more closely.  There are some interesting, creative coding going on and I’m seeing some misconceptions that will help me help them debug their code.

Screen Shot 2018-06-29 at 7.27.01 AM

Well coded ASWD movement and wall checking

I’ve seen this forever-forever coding before. Something is not working like they expect and they try to solve it with nested forever loops.

Screen Shot 2018-06-29 at 7.27.37 AM

Nested infinite (practically) loops didn’t fix the problem – switching to the “play sound until done” block did.

Or they are checking for an event and forget to put in the forever loop:

Screen Shot 2018-06-29 at 7.55.25 AM

One time event checking?

This wall checking code has been separated from the key-press event giving no response.

Screen Shot 2018-06-29 at 8.02.31 AM

If touching wall move in all directions at once.

A couple of the coders explored more blocks where you can define your own.  This led to a teaching moment for me to explain how these function blocks worked.  It turned out less useful than my right-click to duplicate code suggestion.

 

 

All in all, they impressed me. In the moment I’m not always sure what is going on with everyone and even at the end when we stop to share what we’ve accomplished I don’t always know how they did.

Some of them didn’t want to continue what they had started the month before, but they were self-motivated and independent enough to work on their own projects.

I love that this crew is supportive of each other and willing to share their ideas and compliments.

Screen Shot 2018-06-29 at 7.23.54 AM

I appreciate good, supportive commenting

Some of the same students have signed up for the summer session. I’m looking forward to it.

Advertisements

Spring Code Club Session Begins

Code Club session #8 met for the first time on Wednesday.  There are eighteen 4th graders and two high school volunteers.  This is the second time I’ve had a mixture of students from both elementary schools in my city in one club.  Another thing that is cool about the Spring session is that I have returning Code Club members, or, as we call them, “experts”.  Only 5 students are new to Code Club and there was only one student I didn’t know.

screen-shot-2017-03-02-at-6-56-38-am

A New Scratcher’s take on Maze game

After introductions, I asked the “experts” what favorite project they had from the last session of Code Club.  They remembered and liked the Maze game, Space Junk and Chatbot from CodeClubWorld. They also enjoyed the projects they had created themselves, not surprisingly.    I like starting with the Maze game and had already chosen that project for our first meeting.  It’s a simple game with many ways to make it more exciting and complex.

We started out by reviewing the maze design and refreshing our programming vocabulary.  What was the object of the game? How does the Sprite move (arrow keys or follow the mouse were options)?  What happens when you touch the edge of the maze?  How do you win?  Then we talked briefly about ways to make it more exciting – more levels, obstacles, villains, etc.

screen-shot-2017-03-02-at-7-08-28-am

Then they got to it. They were fairly independent coders, for the most part, and they helped each other a bit, too. My high school volunteers and I think we will be able to try some more complex coding  projects this round.  It was a really fun 75 minutes.

Thinking ahead, here are some goals for this session of Code Club:

  • Encourage more animation: We have some artists, so I’d like to share with them and encourage more creative uses of costumes for animation effects.

Screen Shot 2017-03-02 at 7.00.49 AM.png

  • Explore “more blocks”: someone is already exploring defining their own blocks.  I’d like to encourage more of this.  As well as random numbers.

Screen Shot 2017-03-02 at 7.02.18 AM.png

  • Clearing up misconceptions: We will have to revisit some concepts like the forever block and support better debugging habits
screen-shot-2017-03-02-at-7-03-35-am

Find the glitch in this code.

screen-shot-2017-03-02-at-9-58-30-pm

It seems this “expert” puts everything in forever blocks.

  • And finally – I want to use MakeyMakey‘s this time. I told them I want to use them with our projects – especially our final projects. Those couple of students who have played a bit with MakeyMakey’s were quite excited. I’m really excited (and a bit nervous). I don’t have much experience using MakeyMakey devices, with or without students.  Luckily that won’t stop me.

Forever, Until Done

I’ve been noticing interesting uses, or misuses, of Scratch’s ‘forever’ block.  I applaud Scratch for it’s fail soft policy and understanding the desire of 10 year olds to test things, especially to their limits.

screen-shot-2017-01-12-at-5-52-13-am

Nested forever loops will get the job done

The ‘forever’ block seems pretty self-explanatory and perhaps that means I don’t introduce it properly. My students tend to use it in 3 ways: repeating actions, for event listeners and for looping background music.

screen-shot-2017-01-12-at-6-18-45-am

Repeating an action forever

I introduce the forever block after introducing the repeat block.  Once they know about it, there is no going back!

In many games you wait for a certain action to happen to respond to it. One way to do that is to code some ‘if statements’ and set them in a forever loop, like an event listener in other coding languages.

screen-shot-2017-01-12-at-6-15-12-am

Listening for the win condition

Many, many students want use it for play background music for their games.

screen-shot-2017-01-12-at-5-54-27-am

Two dance tracks in a forever loop.  Both seem to work, together.

And I think it is with the ‘play sound’ block where things gets confusing.  I am a proponent of ‘play sound until done’ in a forever loop, and the Scratch Wiki concurs, but it seems to work without the ‘until done’ if it is the only thing in the forever loop.

screen-shot-2017-01-12-at-6-18-55-am

Even without the ‘until done’ this code plays the whole song in an infinite loop

Other things I’ve seen makes me wonder. Why did the Scratcher feel the need to use the forever block?  Was some other code interfering with their action?

screen-shot-2017-01-12-at-5-57-33-am

What would cause the need for show in a forever loop?

Or are they just testing things to see what works and what fails.

screen-shot-2017-01-12-at-5-52-59-am

Forever and ever and ever and ever, just in case repeating 10 to the power of 109 times isn’t enough!

Thanks Scratch for not failing them.