Sunday, July 13, 2008

Pills, balls, and bibles



I've added a couple of power ups to Extinctathon, cancerballs and bibles. The cancerballs (I should probably come up with a different name for that) shoot out in a straight line, although I might make them bounce like fireballs in Super Mario Bros. The bibles go up in an arc and cut a swath of heavenly destruction through thine enemies (unlike the balls, which are destroyed when they hit an enemy). There's a fair amount of tweaking to be done, but I'm happy with how the power ups have gone so far.

Since the XBox 360 hates in-game object creation, the player's sprite has a pool of five projectile sprites (five being arbitrarily chosen, adding or subtracting from this is as simple as changing a number one time in the code--it feels like a good number, though) from the time of its creation. The sprites are all "dead", so to speak (i.e. this.state == SpriteState.Dead), so they aren't updated or drawn. When the player hits the B button, it cycles through, finds the first dead sprite, and reforms it into the appropriate projectile. If all the projectiles are active, as in there are five bibles being thrown around, no new projectiles will be created. When the projectiles have died (after a couple seconds), new ones can be created. Simply, the player can shoot out up to five of a projectile at any given time.

I also added some pills, which are basically like coins, rings, or any of the other pointless(ly fun) collectible items from every platformer ever. Each pills gets 100 points, and 100 pills get you a brand new life.

The main thing now is to get the blocks to pop out the power ups (I'm manually spawning them with the level creator at the moment, as you can see in the video). I'd also like to make the brick blocks breakable, and make some brick blocks that pop out power ups, pills, 1-ups, stuff like that.

From here on out, I have a couple of big changes remaining:

  • GAME STATE MANAGEMENT! I keep putting this off
  • serious improvements to the collision detection
  • an improved level editor
  • hardcore optimization for the XBox 360
Everything else that's left to do is basically going to be content creation and a whole lot of polish. I need to add a lot of power ups, a bunch more enemies, more block times, more sound effects, more levels. After all that's underway I'd like to start implementing some visual effects, and even possibly some as-yet not fully fleshed out new game mechanics that will appear in the course of the game. The idea here is that you start out playing something very familiar (the first level being almost identical to the opening of Super Mario Bros.) and by the end it's almost unrecognizable. I realize this is a lofty goal, one that I can't guarantee I'll achieve. Nevertheless, I'm feeling really good about where I'm at with this game so far, and I'm feeling VERY good with the level of extensibility I have set up within the game's code to add on ideas in the future. It's certainly not bad for a first time XNA project. I'll post more as the week progresses.

Video:
Extinctathon: Pills, balls, and bibles (720p 19.1mb download)

No comments: