Sniff is a "Scratch-like" programming language that's designed to help Scratchers move gently from Scratch to more conventional languages. They can start writing programs, without having to learn a new language because Sniff is based on Scratch. They learn a little more about variables, compiling, syntax errors (!), and they can have fun controlling real hardware while they're doing it.

Monday, 9 February 2015

Adventure Games part 3

I recently got the chance to run a series of workshops on coding where we used the Sniff Adventure game code to make some simple games. We had 4x2hour sessions with a mixed age group, and while there were a few bits that didn't go exactly as planned, overall it was pretty successful.

In the first session we played one of the Level 9 adventures - there are apps to let you play all the level 9 games on pretty much any modern computer. The big gamble of the whole project was that kids (average age about 9) would think that games without graphics were a dumb idea, but they caught on pretty quick, and and there was much excitement as each pair of kids found something new and the shouted their discovery to the rest of the group. In part this was designed as a fun intro to the genre
, but it also re-enforced the requirement for accuracy - if commands aren't clear and correct then they simply get the reply "I don't understand that". We then moved on to Scratch, and wrote a simple game loop, "asking" what next, and checking the answer. Depending on the command the cat could do simple actions.

In week two we started with the Sniff demo game. This only has 7 locations, so we could map it all out, and give each room a number. Once we had the idea that a room number represented a location, we could go back to their own code, and make the look command print out a description appropriate to that room by making a list of descriptions. Depending on the coding experience of the kids you can also make a list of east exits, and so on. Then we moved on to the fun bit - making our own maps, and talking though what rooms and objects we'd need to make a game of their own.

Week three was one of the most successful. We showed how they could add/change room descriptions in the Sniff demo game by just editing text files (with the right name). Once they'd descirptbed a few rooms, we showed them how to connect them up, and they were off!! Details of how to do this are in an older post. As they were able to work at their own pace, they older kids produced some quite large and complex maps, that worked well. However even the youngest sucsessfully produced something they could walk around.

For the final week we split into two groups. The younger group used a new version of the Sniff demo game, which supports graphics, and collected and prepared images for their locations and objects. Adding images to the game is really easy as you simply need a 320x240 bmp file with the right name, in the right folder, and it gets used, along with the descriptions and room connections from the regular version of the game. One pair of kids decided to use images of minecraft for all their rooms, and objects which looked great. This version of the code will be included in Sniff release 15 onwards.

The older kids are shown how to add rules to the Sniff code to create puzzles in their game. This was challenging, but with some help they managed to get some more or less working games. They had all used scratch, but were new to text based coding. As such it was a leap for them to "write" code, but they had no problems understanding quiet complex conditions written in Sniff.

Most importantly the majority of the kids said they had fun, and wanted to come back and do more. We didn't do a lot of coding, but they created some fairly elaborate data structures (even if they don't know what that means yet!!) and produced something playable. The objective was to show them a game, and show them that it was made from code - to "open the box", and connect coding with something that they might actually want to make.

No comments:

Post a Comment