Video Game Coding

Thursday, July 1, 2010

Video: Zelda DS - Enemy AI, Spawning, and More

It's that time again! It has been a while since the last video was posted, and I've made lots of changes since then. Here are the new things to pay attention to while watching the video:

- Fade in from black at start

- Music and sound: the music you hear is a piece written by Justus Johnston, written for the original Zelda PC we were working on back in 1998! As for sound, you will sometimes hear the sword swishing sound - I say "sometimes" because currently the music takes up way too many channels at times, which overrides the sound channels.

- Enemy AI: the Goriya walks around, stops and throws boomerangs, while the Rope (snake) slithers around, and upon seeing the player, bolts for her until it collides.

- Enemy Spawning: as I change from screen to screen near the end, you'll notice that for each screen, the same enemies spawn at the same place. This replaces the random spawning of enemies I was doing before.

- Collision Bounds: near the end of the video, I enable the rendering of collision bounds on tiles and sprites. One thing you'll notice is how the bounds for tiles only surround the top-half of the actual tiles (for example, the bushes); this is so that the player can move over the bottom half, giving a pseudo-3D look to the game.