Cocoa Days 2

I’m not too embarrassed by this. It’s a derivative of the first example from Cocoa Programming for Mac OS X, 2nd Edition. I’m not embarrassed because I did it by the book and then trialled and erred my way into producing this.

All it does is give you a random number (seeded by the time) and present it on screen. In big numbers. Between 1 and 100. That could be a BRP dice-roller! I’m going to work on a couple more iterations of this before moving onto the next project. I need to figure out how to call a function… method from within a function because I want the ‘generate random number’ function to fire at start (using the awakeFromNib) and yet I don’t want to duplicate my generate code in there.

That’s something to look at while the nippers are chowing down on something unwholesome.

Join the Conversation

No comments

  1. Nice one Matt! I’m looking forward to seeing you turn this into something you find useful.

    This is a similar level to where my Cocoa skills got to btw.

Leave a comment

Your email address will not be published. Required fields are marked *