I doubt anyone follows this, but

IF you do follow this and if you’re curious why I haven’t posted it’s because I got hired by RealMassive. A company that wants to break the way commercial real estate is done. I’m happy to say I’m the first intern they’ve taken on and hopefully I won’t be an intern 90 days from now.

I might have a post up this weekend. I think I’ll spend Saturday working on a simple game I have had in my head for a while.

On the note of games, DICE+ who makes a really sweet die controller, has gotten back to me and seems to be willing to sponsor a hackathon I will be putting together next month.


An old favorite – Solomon’s Boneyard

Yesterday I watched a short clip (from Touch Arcade) about an iPhone game that released a few years back called iDracula. After watching, I decided to write about a game I liked from a while ago – Solomon’s Boneyard.

Solomon’s Boneyard was a two joy stick arcade style game where you played as your choice of 10 different mages (all having different abilities and skill trees) and you fought off unending mobs of skeletons and ghosts until they overran you. Why? Who knows, I don’t recall the short back story to the madness, but the slaying was all that mattered.

The game was fairly simple from a gamer’s standpoint, but what they did incredibly well was the skill tree. Every time you leveled you got to choose one of three completely random skills available in your tree, or you could spend x gold (increased the more you used it) to be picky about the exact skill you wanted. So leveling up was a bit tricky, because the hordes got stronger and you had no idea if you were going to get the right skill for the job. Although occasionally life got easier, when, you acquired tomes as loot from the relentless undead, and these tomes randomly chose one of your already acquired skills and upgraded it.

So all in all the game was simple, the controls were responsive, and the skill tree was awesome. It was definitely one of my favorites, so check it out sometime.

Monster – Phase Side Project

This math problem tells me who’s turn is when -

For example:
There are 11 attacks.
You attack 8 times and your enemy attacks 3 times.
Determine an attack sequence that’s evenly distributed and consistently repeatable.

In this case:
1. player 1 attacks
2. player 1 attacks
3. player 2 attacks
4. player 1 attacks
5. player 1 attacks
6. player 1 attacks
7. player 2 attacks
8. player 1 attacks
9. player 1 attacks
10. player 1 attacks
11. player 2 attacks
(repeat these 11 steps as long as needed)

I first thought the solution would be best done with division until I ran into 20 walls, so I choose subtraction because it can be reproduced and works better programmatically, instead of creating an attack sequence by division, storing it as an array, and indexing the array each time you need to determine a person’s turn.

My code to do this was:


void whos_turn_is_it (void);

int player_ones_speed = 0;
int player_twos_speed = 0;
int playerTwoWent = 0;

int main(int argc, const char * argv[])
    player_ones_speed = 9;
    player_twos_speed = 2;
    return 0;

void whos_turn_is_it (void)
    int difference = player_ones_speed;
    int index = 0;
    int totalAttempts = player_ones_speed + player_twos_speed;
        if (playerTwoWent == 0)
            difference = difference - player_twos_speed;
        else if (playerTwoWent == 1)
            difference		= player_ones_speed + difference;
            playerTwoWent	= 0;
        if (difference >= 0)
            printf("player 1s turn: %d\n", difference);
        else if (difference < 0)
            if (playerTwoWent == 0)
                printf("player 2s turn: %d\n", difference);
                playerTwoWent = 1;

    while (index != totalAttempts);

Monster – Phase Three

Sorry it’s been a week since my last post. It has been a busy week is all, but I got tons done and put the game’s beta up on TestFlight. I also saw my mentor away to Portland. He’s taught me everything I know about programming and he’ll be greatly missed, but congratulations go to him for his new position.

With a left slash, a right slash, a bite, and a reset button down, I thought I was mostly done, but decided I wanted a Credits screen and a way to turn subtitles and sound on and off. So I slapped another view down, threw on a few text labels for the people involved and switches. Then I ran into a small problem: how do you do a segue? I pulled out two buttons and control clicked to the other view and set the action to push. Well, that was mistake one. As it turns out, to go from one view to another you need the “button style” to be set to “modal.” Okay, that’s not too bad, live and learn, but how was I supposed to have my switches (have BOOL properties of on | off) in creditsView change values in my gameView? My first thought was there must be some type of class that has control over both views. Well, not so much. The way it’s done is by sending a variable through prepareForSegue.

If you are following along with the project or building this yourself the thing to do is:
1. Create BOOL properties in the views you want to pass the values to
2. Look into prepareForSegue
3. If you aren’t using a viewController for each view, it’s time to start because when you prepareForSegue you have to inform the method of which view you are going to, and you need the boolean properties in both views.

Here’s some code as an example:

- (void)prepareForSegue:(UIStoryboardSegue *)segue
    NSLog(@"slashAndBiteViewController prepareForSegue");

    if ([[segue identifier] isEqualToString:@"gameToMenu"])
        MenuViewController * menuDestination = [segue destinationViewController];
        if (self.SubtitlesOff)	menuDestination.SubtitlesOff = YES;
        else			menuDestination.SubtitlesOff = NO;
        if (self.SoundOff)	menuDestination.soundOff = YES;
        else			menuDestination.soundOff = NO;

So another one of my goals was done, but I still craved more…

Monster – Phase Two

Almost immediately I was blown away by running across game-icons.net. Man, oh man! The art was fantastic, so I downloaded a few and sent the artist an email. I had to change a few images a slight bit, so I opened them in Photoshop and deleted the background and a few parts of the images I didn’t need, then exported them as PNGs. Step one was short and sweet.

On to the second, and I found freesound.org. Sweet, in luck again I thought. Then it hit me, I had no idea what a .wav or .aiff were. So I looked them up and became acquainted with the formats, then asked around for a program to help me clip the sounds, which led me to Audacity. After I managed to get the noises chopped up and ready to use, I started looking into audio frameworks for iOS. Apple’s developer documentation mentioned a few choices and I decided to go with AudioToolbox because it seemed simple enough, and it used .aiff which I was able to export from Audacity. Fifteen minutes later and I had sounds.

Here’s how:

@property (nonatomic) SystemSoundID swooshSoundID;
NSURL * swooshURL = [[ NSBundle mainBundle] URLForResource: @"swoosh" withExtension: @".aiff"];

AudioServicesCreateSystemSoundID (( CFURLRef ) CFBridgingRetain ( swooshURL ), &_swooshSoundID);
AudioServicesPlaySystemSound ( self.swooshSoundID );