Real help needed with sounds

For questions about using Classic.

Post » Tue Jan 17, 2012 3:53 pm

Im interested in making game in construct classic. As an experiment, i begin with a very basic flash game that is basically a mashup of tennis and pong. It was all going great till...i started working on sound. It litereally seems impossible for me. Every attempt to put sound fails im pretty sure that fault is mine though so i want u guys to correct me: Here is the method i follow(in this case, its about a "tik" sound when ball hits the racket:

event: On collision between ball and racket

--> new action --> xaudio22 --> Autoplay File -->write "D:\Game Design\Game\UC Tenispong\Music_05.wav" in the box.

Besides autoplay, i also tried Loadfile, but nothing works. There is no error, its just that sound doesnt play.

I also tried another thing. It was this:

On collision between ball and racket --> (new action) --> System --> Play Sound(For apps), and then add the file path "D:\Game Design\Game\UC Tenispong\Music_05.wav" in the box. THis worked just fine except for the fact that game was paused for all the while music played. In simple sound like a "tik" voice, the while paused is fairly small but it all makes the game look glitchy. besides i also plan to add music files that could be up to 3 seconds long and game would look stupid if it stops everytime music plays. Thanks in advance and if this game is complete, il make quite a few games and might buy construct 2 as well
B
3
Posts: 9
Reputation: 418

Post » Tue Jan 17, 2012 4:52 pm

Yeah, when I tried to put music in, it was really confusing. What I did was make a folder for my game. In that folder I put the .cap for my game, and a folder for all of my music named "Music", and a folder for all my sound effects called "Sounds" like this http://dl.dropbox.com/u/56653097/Games/Example.jpg

When I put in music, I did
Start of Layout--->XAudio2--->Play music from file---> AppPath & "Music\Saria's Song.mp3"

When I put in sound effects, I did for example
On collision between Link and Octorock--->XAudio2--->Autoplay file---> AppPath & "Sounds\Young Link Grunt 1.wav"

But remember to put the "Music" folder, and "Sounds" folder in the same folder as you .cap, or else it won't play the music. :)
B
5
Posts: 18
Reputation: 386

Post » Tue Jan 17, 2012 5:10 pm

did u need a pluggin/audio driver to hear the audio? and could you hear audio when u run demo or did u had to export it to exe file?
B
3
Posts: 9
Reputation: 418

Post » Tue Jan 17, 2012 5:51 pm

btw is it nesecery that the sound is in wav format?
B
3
Posts: 9
Reputation: 418

Post » Tue Jan 17, 2012 5:59 pm

Worked. thnk u very much. love u :p
B
3
Posts: 9
Reputation: 418

Post » Tue Jan 17, 2012 6:24 pm

Your welcome! :) I'm pretty sure there is a better way to do it, but this way worked pretty good for me lol. When you do export it as a .exe to share with your friends, make sure you include your music, and sounds folder in the same folder as your .exe just like you did with the .cap, and you will be jut fine. You may want to put everything it in a .zip folder after you export it, just to keep everything nice and tidy!

Oh! As an extra note, when you do share it, they will have them download the dxwebsetup application in the Construct folder so that they can actually play your game. :P

This is what it looks like.
http://dl.dropbox.com/u/56653097/Games/Dxwebsetup.jpg

So it is best to make a copy of that, and put it in the folder with your game too, so others can play it.
Hopefully I made sense. :)
B
5
Posts: 18
Reputation: 386

Post » Thu Jan 19, 2012 7:44 pm

ok il take care thanks for telling. But im facing a whole new problem now. When i create exe directly it works, but when i create setup file, it disappears after being exported
B
3
Posts: 9
Reputation: 418

Post » Thu Jan 19, 2012 7:49 pm

Also, i would apreciate if u could tell me there is a way to put links in the game for example is someone clicks "visit developers site" my website opens in browser
B
3
Posts: 9
Reputation: 418

Post » Thu Jan 19, 2012 8:54 pm

You might want to take a look at Audiere Plugin
B
83
S
21
G
15
Posts: 1,039
Reputation: 15,134

Post » Fri Jan 20, 2012 10:19 am

@7Soul bro thanks for telling me but this problem is solved, i would appreciate if you could answer my last 2 coments though
B
3
Posts: 9
Reputation: 418

Next

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests