+Vorticon Posted October 13, 2011 Share Posted October 13, 2011 Hi. I'm looking for an XB sound routine that generates the sound of a cannon. I am terrible at this sort of stuff, so if anyone here has something along these lines, would you mind sharing it? I also need one with sounds of swords clashing, but if I recall correctly, 99'er magazine had a sound article that included this very particular sound pattern. I'll see if I can locate it. In case you're wondering, I've decided to create a new XB game between now and Faire time so I can have something interesting to present because unfortunately it does not look like Ultimate Planet is going to make it in time (not even close). It's going to be quite a squeeze, but I think I can make it given how speedy XB programming can be. Forth would have been nice, but I don't have a good grasp of it yet... Quote Link to comment Share on other sites More sharing options...
Willsy Posted October 13, 2011 Share Posted October 13, 2011 Can you bring what you have so far of Ultimate Planet? I'm sure plenty of people would like a proper demo of it, myself included! Mark Quote Link to comment Share on other sites More sharing options...
+adamantyr Posted October 13, 2011 Share Posted October 13, 2011 (edited) I'm looking for an XB sound routine that generates the sound of a cannon. I am terrible at this sort of stuff, so if anyone here has something along these lines, would you mind sharing it? The best way to craft sounds is to think about what they're made up of. A cannon is an explosive "whuf" sound, followed by a high-pitched whine of the cannon ball, going from high to low as it approaches the target. The explosion can be done just using the noise generator: 100 FOR I=0 TO 30 STEP 5 110 CALL SOUND(-200,-7,I) 120 NEXT I The high-pitched whine is a little more difficult, as BASIC will tend to stutter a bit... try this: 130 FOR I=1 TO 10 140 CALL SOUND(-500,2000-(I^3),0) 150 NEXT I The trick here is to start at a very high sound, but descend at an exponential rate, but still only have around 10-20 sound changes to make it fairly fast. Or you can just forgo the whine sound and stick with the explosion too, maybe add a reverb effect to it instead. I also need one with sounds of swords clashing, but if I recall correctly, 99'er magazine had a sound article that included this very particular sound pattern. I'll see if I can locate it. Yes, I've read the same article, but it's easy to recreate here. What you need is to use the multiple voices at high pitches, each slightly different, and have it fade over time: 100 FOR I=0 TO 30 STEP 6 110 CALL SOUND(-100,3000,I,2000,I,1000,I) 120 NEXT I The fun of sound effects is playing around until you find the right ones! Adamantyr Edited October 13, 2011 by adamantyr Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted October 13, 2011 Author Share Posted October 13, 2011 Can you bring what you have so far of Ultimate Planet? I'm sure plenty of people would like a proper demo of it, myself included! Mark Sure. Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted October 13, 2011 Author Share Posted October 13, 2011 I'm looking for an XB sound routine that generates the sound of a cannon. I am terrible at this sort of stuff, so if anyone here has something along these lines, would you mind sharing it? The best way to craft sounds is to think about what they're made up of. A cannon is an explosive "whuf" sound, followed by a high-pitched whine of the cannon ball, going from high to low as it approaches the target. The explosion can be done just using the noise generator: 100 FOR I=0 TO 30 STEP 5 110 CALL SOUND(-200,-7,I) 120 NEXT I The high-pitched whine is a little more difficult, as BASIC will tend to stutter a bit... try this: 130 FOR I=1 TO 10 140 CALL SOUND(-500,2000-(I^3),0) 150 NEXT I The trick here is to start at a very high sound, but descend at an exponential rate, but still only have around 10-20 sound changes to make it fairly fast. Or you can just forgo the whine sound and stick with the explosion too, maybe add a reverb effect to it instead. I also need one with sounds of swords clashing, but if I recall correctly, 99'er magazine had a sound article that included this very particular sound pattern. I'll see if I can locate it. Yes, I've read the same article, but it's easy to recreate here. What you need is to use the multiple voices at high pitches, each slightly different, and have it fade over time: 100 FOR I=0 TO 30 STEP 6 110 CALL SOUND(-100,3000,I,2000,I,1000,I) 120 NEXT I The fun of sound effects is playing around until you find the right ones! Adamantyr Thanks! I'll try these out tonight. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.