Programming Humans with Evil Squash

Main Board Hi Res

I’m gaining a new respect for board game designers. It turns out to be quite difficult to create rules for the games that are unambiguous and easy to understand. Even what I thought was a simple game, Evil Squash, has turned out to have some nasty edge conditions that we have had to think quite hard about.

Of course, a game design is really a “program for humans”. It is a sequence of instructions that involve the processing of data, with decisions and outcomes. The tricky part is that the rules are written in English, which is a language in which it is very hard to make yourself completely clear.

Perhaps as an introduction to programming we could get a bunch of people to design the rules for a game of some kind, and then “debug” it by playing the game. I’m certainly going to invent a new “imaginary” game for each first year programming course from now on, just exploring the rules and getting students to think about how they work has given a nice new dimension to the coursework.

You can find out more about the game itself at www.evilsquash.com.

Building a Robot Army

DSCF5252

Spent some time this morning building robots. Actually I didn’t, students on a hardware interfacing course did all the hard work. They are all Fez Micro Framework powered and great fun. They are based on the same platform as Oscar, who has been all over the place with me over the last couple of years.

Next week we are going to get some C# code into them and get them running around the desks and not falling off the edge. Then we are going to get another Micro Framework board running and see if we can control them via the internet.

Great fun.

Lego Addict

DSCF5243

I think I might have a problem. (actually, I think I might have lots of problems, but I’m not particularly keen to blog about any of those).

Anyhoo, I was taking back some Lego to the toy store because we needed some different prizes for Three Thing Game and I succumbed to the rather nice little truck design. I then spent a happy hour watching Naff Telly (so naff I’ve forgotten the program) and building the vehicle. It is now amongst the other Lego toys collecting dust on a shelf. And Lego keep sending me catalogues, and I keep buying things, and making them.

I wonder if there is an organisation for Lego Addicts. If there is, I hope it is much more than a 12 step program for recovery. I’d hope for at least 150 steps and a nice instruction manual to work through. With pictures.

Filthy Hands

DSCF5207

My hands keep changing colour. They go from a healthy pink to a dingy grey. I was ready to put it down to old age (well, perhaps middle age) the first time I saw it. Then I realised what was happening. My new, nicely trendy, black jeans were dropping some of their colour onto my hands each time put my hands in my pockets.

The other snag with trendy black jeans is that you wash them once and they turn instantly into streaky grey ones. But hopefully they’ll keep my hands cleaner.

Visiting the Iron Duke

DSCF5188

View from the pointy end, which I’m reliably informed is called the “bow”.

We went to see HMS Iron Duke today. This is a warship that has “adopted” the city of Hull and drops by whenever it is passing, although perhaps it is a bit more complicated than that. Anyhoo, we went off to take a look round and grab some pictures. Thanks to the crew for letting a bunch of folks traipse around your decks.

DSCF5181

I love this sign. I just worry that I don’t know what the alarm sounds like…

DSCF5221

The Lord Mayor came to see the ship too. That’s his Jag.

Uncharted 3–Drake’s Deception

image

Bought the third in the Uncharted series of video games today. I must admit I’ve not actually quite finished the second one yet. I got stuck taking on some really nasty crossbow wielding goblin thingies that were very hard to kill. But I was very close to the end.

The third instalment of “Tomb Raider with a bloke” is very much in the same vein as the previous two, but very, very well done. One of the best bits for me is that in this one you usually have a partner with you and they are actually quite useful to have around. Unlike some games, where your comrades stand around getting shot while you solve the puzzle and take out the bad guys, these folks are quite engaged and will even give you problem solving tips if you stagger around dumbly for long enough.

The locations that I’ve been to so far have all been excellent. I feel kind of guilty not taking in the beautifully rendered environments while I’m going for a headshot on the rocket launching zombie on the other side of the valley, but it all looks very nice.

The scenario with its strange maps from the past, underground tombs and “Say, do you think that statue might rotate?” moments is very like the earlier ones, but in a good way.

The stern message at the start says that you should take a break of at least 15 minutes in each hour of gameplay. But this is not a game you can really play in 45 minute chunks. Me, I keep getting dry eyes because I forget to blink during the gameplay.

If you liked the earlier ones you’ll love this. If you’ve always wanted to take part in an Indiana Jones movie, you’ll love it too.

The Best Way to Write Programs

Main Board Hi Res

So, how would you represent the arrows?

The Software Development for the First Year C# Programming course this year is a game I have invented. I’ve called it Evil Squash. It even has its own web site:

www.evilsquash.com

The game is very like Snakes and Ladders, but with a twist that makes it a bit like Ludo as well. At the moment we are working on the player movement, which uses a board like the one above. When a player lands on the tail of an arrow they must then follow it to the destination. We have decided that there are three ways that you can implement this behaviour.

  • A whole bunch of conditions that hard wires the arrows into the program
  • An array with a location for each square that provides a redirection to the destination square.
  • An array of “redirects” that holds the behaviour of the 10 arrows

You might want to consider which is the “best” one. To me, the answer is “you can’t say”. Each of them has advantages and disadvantages. Some of them use less memory, some go quicker. Some are easier to test and some are easier to understand.

One of the things that we try very hard to do in the programming course is to get people to think that often there is no “best” way to solve a problem, merely ones that are better than others against certain criteria. We give extra marks to students who manage to use arrays (I’ve nothing against hard wiring the arrows, but I thing showing you can use an array is something that should be rewarded).

Next week we are going to get the player and the “Evil Squash” behaviour sorted, on the way to making a complete game and maybe even some AI powered opponents.

I’m keeping the domain in case we get some good ones (maybe even phone based) that we might want to distribute.

Don’t Take Your iPad to Meetings

University Trees

I took my iPad to a meeting today. I do love the device to bits (although the battery life seems to have taken a bit of a hit since I upgraded it to the latest operating system) as it is a great way to consume content. Unfortunately I was reminded again of how hard it is to make good use of it to take notes. While some of those around me were confidently tapping text into their netbooks and laptops I was trying to persuade the shift key to do what I wanted and writing “auto-corrected” rubbish. If I had remembered to bring the Bluetooth keyboard to type text in things might have been easier, but as it was I ended up with a few lines of garbled text. Oh well.

Windows Phone Event at Hull University

DSCF5126

Microsoft are coming to Hull on Wednesday the 16th of November for some intensive Windows Phone Development action.  The event will run from 1:15-5:00pm in Lecture Theatre D in the Robert Blackburn Building. It includes an afternoon tea break, and takeaway pizza at the end.

If you want to find out how you can take your C# skills and apply them the phone, sell you applications and maybe even make some money, then you you should come along.

Spaces are limited so register on EventBrite for free here: http://hullwindowsphonecamp.eventbrite.com/

October Three Thing Game Winners

Survivors
These folks are the true survivors.

[Cross posted from www.threethinggame.com/]

Well, we lost a few on the way. The effects of fatigue and the lure of Halloween parties meant that some of our teams didn’t make it to the finish line. However, a good time was had by all and I’ve never seen so much pizza eaten by so many so quickly. The pizza company had to send two cars to deliver all 40. And it all got eaten…

This morning at 7:30 Simon and I went around with a camera and got presentations from all the teams of their games. The videos will be up tomorrow so you can see for yourself how just how good they are. We had some especially impressive solutions from First Year teams who, with only five or so weeks of C# under their belt, produced some highly playable results. Then, at 9:00 sharp the three judges, Warren, Neil and Simon watched the top ten teams and picked the winners. Which was so difficult we had to award two second prizes.

DSCF5104
Judges and videos

DSCF5113
You’d think they’d look pleased with prizes of this quality….

This is the team that won the award for best interpretation of their Three Things.  “Tactical Nuclear Penguins”, made up of Josh Crowther, Alex Beamer and Dan Burns had to make something from “Funky, Robot, goes underground”. And make something they did. An underground exploring robot agent working down through caverns to fight the devil no less. Hooked up with great dance move beat matching action and coming to Windows Phone Marketplace near you soon.

DSCF5106

The first Second Place team, if you see what I mean, “The Double A's”. Anthony Quinn and Aaron Ridge produced a fast moving, pretty much market ready for Windows Phone take on “Extreme Hamster in a Graveyard”. Great work, even if they couldn’t keep their eyes open at the end.

DSCF5108

This is the second, Second Placed, team. “I chose this weekend over Battlefield 3” , aka Lindsay Cox, Devon Hansen, David Hart and Michael Bumby. Their game based on “Gun-toting, Volcano, in Space” combined Bejewelled style action with a sideways blast-em-up which had the player matching threes to arm Space Marines attacking the Volcano.  Lots of guns, and lots of toting.  Great work guys. And don’t worry, we’ll have Lego prizes for all of you once we’ve been down to ToysRUs.

DSCF5110
The Winners, with their prizes.

The Winners were praised by the judges for producing a game for Windows Phone that was good enough to sell right now, with delightful graphics, a well honed mechanic and good adherence to the theme. And you could slice the moon in half. These guys are making a bit of a habit of winning,  having nabbed the prizes in the last competition too. “The Infamous Two Sirs”, Christophe Lionet and Robert Marshall produced a game based on “Tomb, Ninja, Travelodge” that looks excellent and plays great. Well done guys.

The next Three Thing Game will be on the weekend of 17th and 18th March 2012. Start planning now.

Whatever Happened to Flickr

DSCF4802

This is a bit of cautionary tale I guess. I’ve been using Flickr for many years as a host for my pictures. I found the service so good that I’ve even been paying for it. Until now. Suddenly uploads are going like treacle, the web editing doesn’t work properly and other photo sharing sites are powering ahead with innovations that make Flickr look pretty long in the tooth. Snag is, I’ve got thousands of pictures up there, many of which are linked through to my blog – like the one above of Scarborough harbour.

So, do I stick with Flickr, and hope that their parent, Yahoo, decides that it is worth investing in, or do I jump ship to another company which might go the same way in five years? The cloud is a great place to put stuff, but I think we need to remember that not all clouds stay the same forever.

Windows Phone Blue Book Available

WP7 Text

The Windows Phone Blue Book Mango Version is now available. This is for Version 7.5 (Mango) of the phone and 7.1 of the tools.

You can download it from here.

The file is quite big, around 130M. This is because you don't just get the book, you also get a complete course including sample code, Powerpoint decks and labs.

Important: When you unzip the files there are some quite long file paths in the sample code. This is because a Windows Phone project can have quite a few subfolders beneath it. You can avoid this problem by unzipping to somewhere quite high up the directory hierarchy on your disk, perhaps c:\WP7 for example.