February 25th to March 30th (with a trip to vegas in there!). Thats what the svn log says. Now, that’s just impressive… All graphics (with the exception of some logos and stick animations), all programming, all sound.

It’s actually kind of hard to believe that I’m just finishing up the sound tonight… I’m actually pretty shocked. Anyways, I found myself looking at my svn log comments and thought I’d actually get this blog going with something interesting… The one-month one-game log analysis:  The format is:  revision | date | svn commit message (yes i know my messages are ridiculous)

————————————————————————
r1 | 2010-02-24 23:06:39 -0600 (Wed, 24 Feb 2010) | 1 line | importing project

So yeah. This i guess was pretty much the creation of the project. Checked out the latest cocos2d trunk and started away using Chipmunk as the physics engine. I started with pretty much a similar template to ‘Scuba Guy’, which is currently in development… But not much here, pretty bare bones.

————————————————————————
r2 | 2010-02-24 23:08:22 -0600 (Wed, 24 Feb 2010) | 1 line | in
————————————————————————
r3 | 2010-02-24 23:22:11 -0600 (Wed, 24 Feb 2010) | 1 line | pro
————————————————————————
r4 | 2010-02-25 00:24:20 -0600 (Thu, 25 Feb 2010) | 1 line | new

Ok. So, I can’t really remember where I was at this point from the messages… I assume I was just truckin along hacking away..
————————————————————————
r5 | 2010-02-25 00:29:52 -0600 (Thu, 25 Feb 2010) | 1 line | asdf
————————————————————————
r6 | 2010-02-25 00:32:19 -0600 (Thu, 25 Feb 2010) | 1 line | Test level

Ok. So obviously here, I’ve got some test level stuff done. I essentially ripped the whole build process from ‘Scuba Guy’. Because it’s just awesome and super efficient. 1 photoshop file, 1 level. Export a big file file, and the build chops it up, figures out all the boundaries, and recognizes all the dynamic elements. The test level looked pretty bad as I recall, but it was a start.

————————————————————————
r7 | 2010-02-25 00:33:15 -0600 (Thu, 25 Feb 2010) | 1 line | new
————————————————————————
r8 | 2010-02-25 00:43:51 -0600 (Thu, 25 Feb 2010) | 1 line | new stuff
————————————————————————
r9 | 2010-02-25 00:55:17 -0600 (Thu, 25 Feb 2010) | 1 line | moew
————————————————————————
r10 | 2010-02-25 22:27:41 -0600 (Thu, 25 Feb 2010) | 1 line | build new stuff

I remember what I was doing at this point.. OK, so you know in UIKit or Cocos2d, stuff like [UIImage imageNamed:] or [CCSprite spriteWithFile:]. Ya that’s no good if your Xcode build generates images on the fly. The last part of my build is a script that runs the level generator, which means that none of the images are ‘added’ to the Xcode project. Anyways, I built a framework for accessing these images really easily.. It ends up just using: [[NSBundle mainBundle] pathForResource:] which is where all the level images get put in the end.

————————————————————————
r11 | 2010-02-25 23:01:27 -0600 (Thu, 25 Feb 2010) | 1 line | test
————————————————————————
r12 | 2010-02-25 23:21:05 -0600 (Thu, 25 Feb 2010) | 1 line | fix
————————————————————————
r13 | 2010-03-01 21:47:05 -0600 (Mon, 01 Mar 2010) | 1 line | stuff
————————————————————————
r14 | 2010-03-01 22:00:59 -0600 (Mon, 01 Mar 2010) | 1 line | new
————————————————————————
r15 | 2010-03-01 23:33:10 -0600 (Mon, 01 Mar 2010) | 1 line | test
————————————————————————
r16 | 2010-03-04 20:43:26 -0600 (Thu, 04 Mar 2010) | 1 line | new

I don’t really remember what specifically I was doing at this point. But I remember being in about 50% Xcode and 50% photoshop. Cutting up images is tedious….

————————————————————————
r17 | 2010-03-04 21:19:06 -0600 (Thu, 04 Mar 2010) | 1 line | fix
————————————————————————
r18 | 2010-03-06 14:19:50 -0600 (Sat, 06 Mar 2010) | 1 line | new
————————————————————————
r19 | 2010-03-06 15:41:51 -0600 (Sat, 06 Mar 2010) | 1 line | fix
————————————————————————
r20 | 2010-03-06 16:25:42 -0600 (Sat, 06 Mar 2010) | 1 line | new
————————————————————————
r21 | 2010-03-06 22:12:16 -0600 (Sat, 06 Mar 2010) | 1 line | box2d

Oooooo. Yup. I know exactly what I was doing here. So chipmunk didn’t really work out as a physics engine for this game. The problem? CCD, continuous collision detection. Chipmunk doesn’t have it. And the way I wanted this game has the golf ball really small. With Chipmunk the ball kept passing through the group boundaries. Increasing the cpSegment size wasn’t possible because then it would appear that the ball wasn’t quite touching the ground… Chipmunk, I love ya, but it was time to dive into Box2d..

————————————————————————
r22 | 2010-03-06 22:30:28 -0600 (Sat, 06 Mar 2010) | 1 line | remove

Hahaha… I GUARANTEE (without looking at the detail svn) that this commit was changing all the bloody .m extensions to .mm… *facepalm*

————————————————————————
r23 | 2010-03-07 00:45:06 -0600 (Sun, 07 Mar 2010) | 1 line | box 2d
————————————————————————
r24 | 2010-03-07 00:55:13 -0600 (Sun, 07 Mar 2010) | 1 line | box 2d

Ok. prolly more Box2d tweaks here. I did spend ALOT of time trying to figure out why stuff in Box2d wasn’t moving faster… Without getting into the details… PTM_RATIO. Ya, there’s a limit to force and velocities and I was reaching it way too soon.. Applying a stronger impulse to an object, and getting the exact same result… I was running into limits. Scaled all the physics down by a factor of 25, and it was all good from there.

————————————————————————
r25 | 2010-03-07 13:51:58 -0600 (Sun, 07 Mar 2010) | 1 line | c plus plus collision handler

Ok. So now we need collisions handlers right? Well, time to take out those Chipmunk callbacks and write a C++ class… ( I wrote a lot of server software in C++ a few years ago at a different job… not impressed… ).

————————————————————————
r26 | 2010-03-07 14:25:16 -0600 (Sun, 07 Mar 2010) | 1 line | left right boundary walls

Ok. So i added invisible boundary walls here.

————————————————————————
r27 | 2010-03-07 15:13:40 -0600 (Sun, 07 Mar 2010) | 1 line | new
————————————————————————
r28 | 2010-03-07 15:58:11 -0600 (Sun, 07 Mar 2010) | 1 line | intro

This was probably the fade in of the logos.. Most CCScene transitions..

————————————————————————
r29 | 2010-03-07 18:45:43 -0600 (Sun, 07 Mar 2010) | 1 line | new test screens
————————————————————————
r30 | 2010-03-07 19:32:14 -0600 (Sun, 07 Mar 2010) | 1 line | World select scene

OOO.. level select scene. This put some UIKit stuff on top of Cocos2d. Mostly just TableViewController stuff.. Maybe some transitions in there..

————————————————————————
r31 | 2010-03-07 19:39:39 -0600 (Sun, 07 Mar 2010) | 1 line | testing again
————————————————————————
r32 | 2010-03-07 19:40:00 -0600 (Sun, 07 Mar 2010) | 1 line | testing again
————————————————————————
r33 | 2010-03-07 19:40:17 -0600 (Sun, 07 Mar 2010) | 1 line | testing again
————————————————————————
r34 | 2010-03-07 20:04:06 -0600 (Sun, 07 Mar 2010) | 1 line | fixing up menu
————————————————————————
r35 | 2010-03-07 20:08:44 -0600 (Sun, 07 Mar 2010) | 1 line | fixing up menu
————————————————————————
r36 | 2010-03-07 20:56:38 -0600 (Sun, 07 Mar 2010) | 1 line |
————————————————————————
r37 | 2010-03-07 21:03:07 -0600 (Sun, 07 Mar 2010) | 1 line | new image
————————————————————————
r38 | 2010-03-07 21:56:31 -0600 (Sun, 07 Mar 2010) | 1 line | whoop whoop
————————————————————————
r39 | 2010-03-07 22:01:50 -0600 (Sun, 07 Mar 2010) | 1 line | whoop whoop
————————————————————————
r40 | 2010-03-07 22:06:27 -0600 (Sun, 07 Mar 2010) | 1 line | moving
————————————————————————
r41 | 2010-03-07 22:41:46 -0600 (Sun, 07 Mar 2010) | 1 line | images in images folder now

Ok. not sure what I was exactly doing this day. But it looks like from this message that I was tweaking the build a little bit.

————————————————————————
r42 | 2010-03-07 23:32:30 -0600 (Sun, 07 Mar 2010) | 1 line | new level
————————————————————————
r43 | 2010-03-08 00:29:15 -0600 (Mon, 08 Mar 2010) | 1 line | 4 and 5
————————————————————————
r44 | 2010-03-08 00:37:07 -0600 (Mon, 08 Mar 2010) | 1 line | new
————————————————————————
r45 | 2010-03-08 00:53:40 -0600 (Mon, 08 Mar 2010) | 1 line | six
————————————————————————
r46 | 2010-03-08 01:02:28 -0600 (Mon, 08 Mar 2010) | 1 line | ne 6 fix

Right on here we go… looks like we got levels 3 4 5 and 6 going. These are finished levels. One photoshop file. Export. and done.

————————————————————————
r47 | 2010-03-08 20:08:21 -0600 (Mon, 08 Mar 2010) | 1 line | whoop whoop, new slow
————————————————————————
r48 | 2010-03-08 21:16:40 -0600 (Mon, 08 Mar 2010) | 1 line | shifty
————————————————————————
r49 | 2010-03-08 21:55:13 -0600 (Mon, 08 Mar 2010) | 1 line | two more levels booya son
————————————————————————
r50 | 2010-03-08 22:55:01 -0600 (Mon, 08 Mar 2010) | 1 line | final level booya

Looks like the first course was done here. ‘Loftstrom Links’. With a minor fix later, I think this was actually complete here…

————————————————————————
r51 | 2010-03-08 23:06:30 -0600 (Mon, 08 Mar 2010) | 1 line | new finished scene
————————————————————————
r52 | 2010-03-08 23:30:37 -0600 (Mon, 08 Mar 2010) | 1 line | a new finished scene
————————————————————————
r53 | 2010-03-09 00:42:21 -0600 (Tue, 09 Mar 2010) | 1 line | putting angle
————————————————————————
r54 | 2010-03-09 00:46:13 -0600 (Tue, 09 Mar 2010) | 1 line | collision group static bodies
————————————————————————
r55 | 2010-03-09 20:14:29 -0600 (Tue, 09 Mar 2010) | 1 line | finally water

Ahhhhhh.. YES. Definitely remember this. Implemented the ‘water hazards’ in the game. Needed some definate tweaks to the level processor script, and some Box2d sensors, but other than that, not too much! A custom graphic for each course which is the water hazard graphic and thats it!

————————————————————————
r56 | 2010-03-09 20:23:56 -0600 (Tue, 09 Mar 2010) | 1 line | water slowness booya
————————————————————————
r57 | 2010-03-09 20:25:39 -0600 (Tue, 09 Mar 2010) | 1 line | water slowness booya

Heehee.. Slowing down the ball when it hits the water…

————————————————————————
r58 | 2010-03-12 23:52:05 -0600 (Fri, 12 Mar 2010) | 1 line | new world

Alright. So, started creation of the second course here…

————————————————————————
r59 | 2010-03-13 00:28:19 -0600 (Sat, 13 Mar 2010) | 1 line | level 2
————————————————————————
r60 | 2010-03-13 13:27:17 -0600 (Sat, 13 Mar 2010) | 1 line | more tweaks and updates
————————————————————————
r61 | 2010-03-13 13:28:00 -0600 (Sat, 13 Mar 2010) | 1 line | fix
————————————————————————
r62 | 2010-03-13 14:57:18 -0600 (Sat, 13 Mar 2010) | 1 line | water haz and more stuff
————————————————————————
r63 | 2010-03-13 15:06:52 -0600 (Sat, 13 Mar 2010) | 1 line | backgrounds fix. fixing up par hud display
————————————————————————
r64 | 2010-03-13 15:38:39 -0600 (Sat, 13 Mar 2010) | 1 line | nother level
————————————————————————
r65 | 2010-03-13 15:59:24 -0600 (Sat, 13 Mar 2010) | 1 line | a level6
————————————————————————
r66 | 2010-03-13 16:17:49 -0600 (Sat, 13 Mar 2010) | 1 line | Level 7
————————————————————————
r67 | 2010-03-13 16:48:56 -0600 (Sat, 13 Mar 2010) | 1 line | another two levels
————————————————————————
r68 | 2010-03-13 17:00:08 -0600 (Sat, 13 Mar 2010) | 1 line | more

OK. There you go. A course in ONE day. I remember doing these… I hammered through these course designs. All that time building that level processor pays off..
————————————————————————
r69 | 2010-03-13 17:40:13 -0600 (Sat, 13 Mar 2010) | 1 line | new world
————————————————————————
r70 | 2010-03-13 20:47:59 -0600 (Sat, 13 Mar 2010) | 1 line | sand traps and new level

OK. So it looks like I added the sand trap feature here.. Pretty simple as it’s very similar to the water hazard.. Just needs different logic on the sensor.

————————————————————————
r71 | 2010-03-13 20:55:59 -0600 (Sat, 13 Mar 2010) | 1 line | sand edges and restitutions
————————————————————————
r72 | 2010-03-13 21:09:08 -0600 (Sat, 13 Mar 2010) | 1 line | whoop whoop… sand son
————————————————————————
r73 | 2010-03-13 22:21:47 -0600 (Sat, 13 Mar 2010) | 1 line | more tweaks
————————————————————————
r74 | 2010-03-14 11:43:47 -0600 (Sun, 14 Mar 2010) | 1 line | nother level
————————————————————————
r75 | 2010-03-14 12:33:27 -0600 (Sun, 14 Mar 2010) | 1 line | levels
————————————————————————
r76 | 2010-03-14 12:59:41 -0600 (Sun, 14 Mar 2010) | 1 line | querky level
————————————————————————
r77 | 2010-03-14 13:13:30 -0600 (Sun, 14 Mar 2010) | 1 line | level 8
————————————————————————
r78 | 2010-03-14 13:46:48 -0600 (Sun, 14 Mar 2010) | 1 line | finals

OK. So it looks like I finished the third course here…