Jet Pack Eternal – 2nd iPhone game

“Jet Pack Eternal” is a jet pack action/strategy/puzzle game. A sort of walkthrough video is online. Video is v1.0 – curr ver.: 1.1:


The initial release is just 0.99 USD on app store and has 20 levels; should take about 30-60 minutes to get through for a seasoned gamer, and a bit more time if you want to get three stars on each level.

I’m hard at work creating another 20 levels as a free-update which will be out soon. Full version has 40 levels, 0.99

Try the free version with 20 levels: App store link


smaller size .caf files

.caf files roughly the same size as the original mp3 for use with SimpleAudioEngine

afconvert -f caff -d LEI16@22100 -c 1 ./”source music.mp3″ ./bg-music.caf

cocos2d box2d zoom in/out on movement

CGRect rect = [self contentRect];
b2Vec2 currentVelocity = player_.body->GetLinearVelocity();
float currentLength = currentVelocity.Length();
if(currentLength >0 && currentLength < 5) {

	float newScale = 1.0 - (currentLength/20);
	[self runAction:[CCScaleTo actionWithDuration:1.5 scale:newScale]];
	CCFollow *action = [CCFollow actionWithTarget:hero_ worldBoundary:rect];
	[action setTag:kGameNodeFollowActionTag];
	[self runAction:action];


CGPoint pos = ccpMult(position_, self.scale);
[self setPosition:ccp(pos.x+cameraOffset_.x,pos.y+cameraOffset_.y)];

cocos2d progress bar example

A progress bar implementation for my second game’s HUD layer to show how much rocket fuel is left:

	CCSprite * progressBorder = [CCSprite spriteWithFile: @ "progressbarborder.png"];
	[progressBorder setPosition:ccp(s.width/2 + 0.5 - 45, s.height - 20.5f)];
	[self addChild: progressBorder z:1]; 

	CCProgressTimer* progressBar = [CCProgressTimer progressWithFile:@"progressbar.png"];
	progressBar.type = kCCProgressTimerTypeHorizontalBarLR;

	[progressBorder addChild:progressBar_ z:1];
	[progressBar setAnchorPoint: ccp(0,0)];

To change the progress amount:

        CCProgressTo *progressTo = [CCProgressTo actionWithDuration:10 percent:100];
	[progressBar runAction:progressTo];

To use a callback after completion:

        CCCallFunc *cbDecrFinished = [CCCallFunc actionWithTarget:self selector:@selector(decreaseProgressBarFinished:)];
	CCProgressFromTo *progressToZero = [CCProgressFromTo actionWithDuration:10 from:100 to:0];
	CCSequence *asequence = [CCSequence actions:progressToZero, cbDecrFinished, nil]; 

	[progressBar runAction:asequence];

where decreaseProgressBarFinished may be defined as:

        - (void) decreaseProgressBarFinished:(id)sender;

First iPhone game – hop hop rider

Free on the iTunes store: