Cave Mushrooms Postmortem

Posted by
September 1st, 2009 1:02 pm

When I saw “Caverns” I quickly thought MinerVGA and decided to make a sidescrolling game about mining for gold and facing dangers like cave-ins and enemies. I decided that wasn’t going to work for some reason, and went to bed to come up with more ideas. (I always go to bed when I need ideas because late evening and early morning is when the mind is most creative.) The second concept was a sidescroller about shooting at cave formations like stalactites/stalagmites and suspended bridges to make them physics down onto enemies. After thinking about it for a while on Saturday morning, I started to hate that idea. It seemed gimmicky and hard to pull off well.


Several random walks. The final level generation algorithm isn’t much different.

I really wanted a dark cave sort of game where you’re sneaking around shooting evil demons, like a rougelike, so my third concept was a top-down procedural cave shooter with realistic line of sight, styled in cavey gray and brown. I liked this idea and began working on a level generator which was a simple random walk that varied the size and direction of a “brush” at each step. I then did the line of sight by projecting 3D walls towards the camera from the 2D ground, not planning on adding any 3D beyond that. The level generator worked surprisingly well, and I decided not to write code for making rooms like I planned, instead letting the path wind around enough that it made rooms by itself.


I thought the final game would essentially be this.

I felt demotivated all day for various reasons, so progress was slow. By Saturday night I had a square player who ran around in procedural caves. I half-heartedly went back to bed for more ideas. Then, with great disgust, I realized the game was turning out to be another generic shooter, and that there were probably at least five others like it in the competition. Plus, I knew I was bad at coming up with actual content, like interesting enemies and non-abstract graphics.

I needed to have something more to present. If I couldn’t think of a good gameplay mechanic, then the only other option was to dress up a mediocre one as much as I could with crazy colors and special effects (don’t underestimate this strategy). I looked at my 2.5D game and realized that simply pointing the camera forward would give me a first person shooter, something I considered but hand-waved as too difficult and unnecessary. I knew then what I needed to do.


Fog is trivially simple to implement in OpenGL, but is a beautiful effect.

I used a color value that roughly cycles through the rainbow as the basis for most of the visuals. I took care to avoid staying within the 0.0-1.0 clamp for color values. The camera needed to move a lot, so I made it shake, recoil, and bob. Making explosions that feel good was critical to the game, so I added flashes of light with every bullet and enemy death. The enemies started as the most obvious thing I could think of, bouncing diamonds, and didn’t change much after that. The walls and enemies had directional lighting. I turned enemy deaths into laser light shows.

Unfortunately, all of this took up a lot of time, and since I only started Sunday morning, the compo was already nearing its end. I thought about the last compo’s complaints that I didn’t have a proper menu screen in my game. I saw little need for one, but figured as long as I’m going for show I might as well try to make a “real” game. Thinking about whether I should learn how to use fonts in OpenGL, I decided to just hard-code a 3×4 font. Much simpler. I slapped it on the start/pause/win screens, added a HUD, etc etc, and the entry was complete.


Complementary colors create a balanced, high-contrast color scheme.

My biggest regret is probably that I didn’t have time to make the enemies explode into actual debris. That would’ve finished off the visual effects, and is definitely going in the update. Sound and music would’ve made this the best game ever, but I hadn’t done much with sound before so I knew it was going to take too long to do it to my satisfaction. Better to leave it up to the imagination than to pollute the game with shoddy art.

Lessons I’m going to keep in mind for next compo: Everyone complains about polish, but polish takes at least 50% of development time, so make sure to finish the core game in the first 24 hours. This is difficult because good ideas can be a lengthy iterative process, so spend the day before the compo being well-rested and chillin to get into the creative state of mind.

I’m extremely happy with this entry because it’s a good demonstration of what I think big commercial games should be capable of. It’s retro and arcadey and exciting. This is what I want to play.


Leave a Reply

You must be logged in to post a comment.

[cache: storing page]