Tuesday, March 9, 2010

Projectiles and destructible tiles

We have projectiles! Not fully implemented yet, but I took my old abstract projectile class and derived "standard shot" class from my previous game attempt and fit them into the new game with map collision. The character editor really helps out here because, with my new updates to it, I am able to specify a starting location for the projectile relative to the character animation. In my previous game, I had to hard code that per character which is annoying and messy. With a few updates to the hero's run and fire animations, he is able to shoot while standing idle or while running now. The other nifty update is destructible tiles. In my previous game, I hard coded the destruction animation so every time you blew up a tile, it crumbled the same exact way. That was ok, but this time around I decided to kick it up a notch and create a particle system for destructible tiles. Now whenever a tile is destroyed, the image is broken into 16 smaller pieces that are randomly blasted away from the center in varying directions, speed, and rotation, with gravity acting on all of them. For demoing and testing purposes, I added functionality for me to add destructible tiles to the map while I'm playing so I'll always have something to blow up =) Check out the video below:



No comments:

Post a Comment