Sound Bugging Up

Get help using Construct 2

Post » Sun Apr 28, 2013 5:11 am

Hello guys and girls, I'm somewhat-new to Construct 2, and I've been making something. A lot of it is complete, and sounds work fine, but when previewing them, they seem to act all glitched (shooting sound gets cut off, explosions don't play, etc). Why is this?

http://www.mediafire.com/?k8j0wn9gqb79txa

There is the link to my Capx. Anyone know why it's doing this?
B
3
Posts: 7
Reputation: 197

Post » Sun Apr 28, 2013 7:41 am

Hi, what is happening is that you have certain conditions that are cancelling each-other out. I made a few changes to your title screen code and it works - the two buttons were muting eachother out after the first collision so if you disable that and make a few other adjustments you'll get it working correctly. Because the sounds that the buttons make when hovered over are only short there's no need to mute the sound when the cursor isn't over them - you can make sure that the sound only plays once by using "trigger once while true" see screenshot
B
47
S
16
G
3
Posts: 135
Reputation: 4,984

Post » Mon Apr 29, 2013 11:32 pm

Thank you, that worked for the title screen. But I am still not understanding. How do I fix the buggy sounds ingame? When I shoot a projectile, sometimes the sound doesn't play, or gets cut off early. Other times, sounds like explosions don't play either. Another thing is, when I die, I get sent back to the main menu. When I push the Play Button again, the music plays for a split second then stops, and is never heard on the second playthrough. Please help!
B
3
Posts: 7
Reputation: 197

Post » Tue Apr 30, 2013 9:12 am

There's a line at the bottom of your game field event sheet that Says "If cursor isn't over continue box set audio to muted" - this is what is cutting your sounds out - right click this code block (17) and select "toggle disabled" then run your game, it should work. You can fix this up in the same way I fixed your title screen - the "set muted" action isn't necessary so you can just get rid of it. That should hopefully fix your audio issue. I've noticed though that your game is very big, and it doesn't need to be - you will be able to get it running much better if you use a "tiled background" instead of multiple sprites as your backdrop. Try those things and see how you go, if you need any other optimization tips let me know.
B
47
S
16
G
3
Posts: 135
Reputation: 4,984

Post » Tue Apr 30, 2013 12:26 pm

Okay, so, I disabled that, and it fixed my title screen sounds. Ingame sounds like blasts and explosions still don't appear to be working. They either play halfway and get cut off, play all the way through, or don't play at all. I removed all instances of "mute audio" in my event pages, but it doesn't seem to fix the issues.

Here's an updated capx with the sounds so you could test it yourself and see what I am talking about.

https://www.dropbox.com/s/lpv6m3wy099tmw6/PixelBurst.rar?v=0mcng

Please help, I plan to have this fixed when Ludum Dare judging is over, but I really would like to get it out of the way.
B
3
Posts: 7
Reputation: 197

Post » Tue Apr 30, 2013 2:20 pm

I'm downloading your new version, but it's massive and will take over an hour (I'm about to go to sleep). I will look at it tomorrow if I have time. In the version you uploaded the other day, all I had to do to get the sound to work in game was change one thing - see screenshot below. I guess your game has changed quite a bit since then, but with your old version changing this last line made all the sounds, shooting explosions etc work.

B
47
S
16
G
3
Posts: 135
Reputation: 4,984

Post » Thu May 02, 2013 2:37 am

Sorry about that. I believe there's something I'm not doing right. Changing it in the old copy doesn't seem to work either. Anyway, I apologize for it being so large, I've kind of expanded on it in the process. But thank you for taking the time to help me, I patiently await your assistance!
B
3
Posts: 7
Reputation: 197

Post » Thu May 02, 2013 8:39 am

Hey, sorry it took a bit to get back to you. Try deleting the block of code highlighted in the screenshot below - this block constantly tries to set the volume to muted so sounds play for a split second, but then when this block is processed they are muted and this is what seems to be causing your audio issues.

B
47
S
16
G
3
Posts: 135
Reputation: 4,984

Post » Thu May 02, 2013 11:07 pm

Thank you, tried it, it worked perfectly.
B
3
Posts: 7
Reputation: 197


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 15 guests