Archive for July 30th, 2008

I was speaking to Mr Daniels today and waxing lyrical, as is my wont, about the lovely messaging system in objective C. He commented that something I said was a really nice metaphor so I thought I’d post it here.

Objective C, as you might know, uses square braces (these []) as part of its syntax for sending messages. For example:

[myObject init];

Well, it occurred to me that those square brackets make the object and the message look like they’re in a wee box - so when you ask an object for an answer, the question just kinda falls out of the box. Like this:

theAnswer = [myObject whatsYourFavouriteColor];

That’s all it was - but he’s right enough - it helps to make things easy. You drop the question into the box beside the object and the answer falls out the other end :)

Look up there! At the top! Where the page links are! See that one with ‘PressGang’? Well, that’s a new page that is. I’m currently adding Cocoa/Objective-C to my ever-lengthening list of programming languages and, as it usual for me, I’m writing something useful while learning it. It seems to make it all easier.

PressGang will (eventually) be an Army List Creator for tabletop wargames of the Warhammer Fantasy / 40K / Lord of the Rings ilk, although I’m hoping to keep it modular enough to support arbitrary wargames via a plugin system. 

Anyway, more information (and a link to an announce mailing list) can be found on the page at the top and development posts will be listed in the shiny new ‘Mac Development’ category.

All content (C) 1996-2008 John Dow