I already posted a mini-postmortem in my submission screen, but here’s my expanded version.
First up, I want to give a big shout out to everybody who contributed to Ludum Dare, and to those who made this entire site and contest a reality. It’s great to see so many people active a community focused on game development. While this was my first Ludum Dare 48, I’ve participated in community-driven game competitions before and it’s always been a blast. LD48 was no exception.
Here’s a summary:
- Lack of working debugger/inspector meant much gnashing of teeth.
- Unfamiliarity with Flixel library/AS3 specifics cost me time.
- Spent too much time getting art into a state that was usable.
- Generally spent too much time arguing with my tools, and not enough refining gameplay.
Friday:
The islands theme sort of threw me for a loop. I wasn’t expecting it, and in fact had down-voted it. But, in retrospect, I admit it’s a good theme. It’s open enough that people were able to do some really cool and interesting things with it.
After grousing over the theme for a bit and finally having a flash of inspiration, I sat down and sketched up concept art. I half-expected it to end up as my final art, so I spent more time on than I might normally. Later, I’m glad I did this.
Now I had a gameplay idea, concept, and a bit of art. The next step was dumping the art into separate sprites and making sure they were properly configured to work in Flixel. This part cost me a fair amount of time. My original idea to use Cosmigo’s ProMotion and do strict pixel art would have been easier on my mouse-hand.
I then created a project in FlashDev and made sure that all of my assets would load up properly via Flixel. After that, I coded the scrolling background. My original sketch had everything on one screen, but I felt a bit constrained so I enabled a larger, scrolling playfield in order to make the game level more expansive. However, I wasn’t able to properly enable the off-screen indicators for enemy islands/fireballs, so I felt that hurt the gameplay in the end by making the game a little confusing. It would have just been simpler to keep everything on-screen; Most of the levels I designed did this anyway.
The final bit I accomplished before turning in for the first day was to sketch the little animated islanders in Photoshop. Photoshop is not meant for pixel art, I’ve found. It’s incredibly annoying to use for this task. More time wasted! But once I was done, I had idle, running, swimming, burning, and praying animations. This is all I needed from the little guys, so I could at least sign off on them.
After writing the Native class and making sure the little guys spawned properly, I decided to call it a night.
Saturday:
Ugh! Nasty storms! They kept me offline until later in the day. Boo!
Once I finally was able to get back into my form, I started work on the most critical aspect of the game; Animated fireballs that could be launched at the other islands. This part was fun, but my unfamiliarity with Flixel started to rear its ugly head. This resulted in some digging in Flixel code in order to grok the purpose of the FlxEmitter class and how to bend it to my needs.
Then, more time tweaking it so that I could have a dozen fireballs onscreen without grinding my system to a halt. At the time, I was unaware of the profiling functions in Flixel, so I could have cut out some of the guesswork with this.
Next I finished the animation state code for the islanders. They convincingly milled about on my islands, and occasionally went to their knees and prayed, but at the time this was just a visual effect.
The final thing I completed before calling it a night as implement the fireball arc code, so that they fell convincingly, and the collision code, so that the fireballs landed on the islands. The collision code kept me up for a while. There was some silly little overlooked error that prevented the fireballs from exploding properly. I don’t even remember what it was, exactly.
Sunday:
Hoo boy! Down less than 12 hours, I didn’t have a working game at all. I just had pieces.
The spawning code for islands worked. You could launch fireballs and they would impact the other islands, set natives into poofs of flame. This was all fun, and such, but not a real game.
First up was writing the prayer-power system. Islanders prayed, increasing power, which powered the fireballs. I also coded the health/power bar system and drew two little Tiki heads to represent the gods. Unfortunately, I didn’t have enough time to add in an expanded graphic of your islanders worshiping your Tiki (the horned red-eyed god), which would have clued a player in which of the two sets of islands they controlled. (Hence the odd left gap in the dialog boxes, and the confusion some pointed out about where to aim the fireballs. :))
This was all cute, but disaster struck! Sometimes, when destroying an island, my islanders would swim to a nearby island and join it (as intended). However, they wouldn’t stop joining. The game quickly crawled to a halt when over 50,000 sprites were rendered. Oops! A lack of a Flash debugger really hurt me here. I wasn’t aware that the Flex SDK comes with fdb, so I had to debug the old fashioned way: Hack and slash until the problem went away. I eventually narrowed it down to a bug in the abandonment routine, which checked to make sure the islanders were swimming towards a still-existing island.
The final pieces were falling into place, but I was quickly running out of time. I wrote a very simple AI, which simply only had one job due to unfinished game mechanics: Select where to aim on the screen. That wasn’t too difficult, but a subtle bug would later come to bite me concerning AI aiming…
There were two components left for what I considered a”complete” game: The bumper code, which is my term for things like overall game state transition, level changes, and so on. And the construction of at least three levels.
The bumper code wasn’t hard to write. Just simple state transitions, a quick five minute title/won-the-game screen. But this is when the subtle bug reared its ugly head. I had less than 15 minutes to the deadline, but when you switched levels, the AI pulled a brilliant move of randomly flinging fireballs instead of aiming at the player-controlled islands! Argh!
I went ahead and submitted the game as-is, not realizing that we are given a chance to fix such game-breaking bugs after the deadline.
I managed to find the cause of the bug a mere five minutes after I hit submit; When changing level states, I wasn’t clearing the AI targeting parameters. As simple as the AI was, it just targeted the same (now non-existent) island location as before.
This was due to oversight caused by my rushing. Instead of taking the sane route of simply switching game-states between levels (and storing persistent info elsewhere), I tried to cram everything into the same state and just cleared the commonly data structures between levels. I mean, the game isn’t that complicated, right? This is where having no working runtime inspector/debugger really hurt me.
In Closing
All-in-all I had a blast! And the resultant game is, IMHO, worthy of pursuing as its own complete project entirely outside of LD48 even if it doesn’t come close to winning. I couldn’t ask for more!
See all of you next time. 
Tags: LD17, postmortem
I might be tired.