2.
- Boids has a group of "birds" that creates a flock. The movement
of the flock is quick and fluid, something fun to shoot at.
3.
- Added Rocket from Asteroids
- Both Boids and Asteroids has a Vector class. Used for
direction. (NOT World or Actor) At first, I was going to integrate
the Vector class so that it would service both Boids and Rocket,
but I realize that the Asteroids in Asteroids use the Vector for
movement. No need. I cheated, wanted a vertical Rocket, made it
rotate 90 degrees upon initialization instead of rewriting code.
Had to copy Asteroid images and sounds over to my project.
4. 5.
- Realized that I wanted to hit the Boids. Which means I had to
make them act like Asteroids. Asteroids creates two smaller
Asteroids upon hit until a certain size, then dies. Boid die upon
hit.
6.
- Rotating the Rocket was weird, wanted left and right on bottom
of screen. So I used the code from Breakout for their Paddle. I
changed the Rocket reaction from "left" and "right" from rotation
to movement instead.
7.
- Hitting the Boids were fun, but and explosion would be funner!
So I took the explosion object from LunarLandder. I needed the
explosion to kickoff when the Boid got hit. Just like how the sound
file for explosion got set off, I wanted the visual as well. Wanted
smaller explosion, revised the number of images to 4 instead of 8.
This was an array of pictures the program goes through. It exploded
everything. Chain reaction, needed to shrink size of explosion and
not explodeOthers()
8.
- I compile every time I made a small change. Otherwise, I would
not be able to resolve larger issues later on. There were many
small changes that had to be done for each part of the integration.
Change variable names, change input parameters, and knowing what
pieces can be integrated. like hit(int damage) was changed to hit()
and the body that dealt with reducing the size of the Asteroid was
commented but kept the explode().
9. Labels BulletDisplay modeled after Explosion It's created in
the world and updated every time a bullet is fired. 10. End Game
Box Different text for winner or loser.Score is based on an
accuracy ratio and how many birds are left. 11. Scoring Algorithm
Tried to make the game competitive by implementing a scoring
factor. I had trouble figuring out a good equation.For now, it's 5
points per panda kill and a plus for accuracy bonus (ratio of
bullets to pandas killed). 12.
- Last but not least. Change graphics. Graphics don't mean much
unless the program works. This is the easy part. Used Inkscape.
Free vector creation software.
13. Backgrounds 14. Don't want to kill birds 15. Other Graphics
16. Music Used the sounds that came with the programs for collision
and movement. got bored and recorded my own eventually. I put in
music for the game, 2 different songs. 17.
18. Made a Button Created an executable button for the game and
customized the icon. 19. Voila!