Wednesday, May 24, 2017

Day 49: Audio-only Game: Day 24

To start with, I deleted pretty much all the sound code for attacking.


Next, I copy/pasted the if statement. One will be for the crossbow shooting, one for reloading, and one for the sword swing.


This is the first of the three if statements, the one that controls the crossbow shooting:


The second one, which controls the reloading mechanic:


And finally, the sword swish sound:


I added to all of them a condition that the Distance variable must equal 100 for the crossbow sounds, and 3 for the sword sound.


The sword swish sound works perfectly, but the crossbow sounds aren't working yet.

Next class I will be focusing completely on the crossbow sound until it works.






No comments:

Post a Comment