[Suggestion] About sounds

Discussion and feedback on Construct 2

Post » Sun Sep 23, 2012 6:39 pm

How about Family for Sounds? It make easy setup ambiance, FX and other system sounds with easy.

Another thing I'm missing a lot is a global volume.
ImageImageImageImageImageImage
B
92
S
19
G
12
Posts: 1,192
Reputation: 18,276

Post » Sun Sep 23, 2012 7:01 pm

With global volume I assume you mean "master" volume? As in it affects both sounds and music?

I actually thought about this a few days ago and came up with a solution.

I'd have variables for "sound", "music" and "master". Sound and music goes from 0 to 100 while master goes from 0 to 1.

Then when you set the volume for say sound you do this:
"lerp(0,sound,master)" (you can add round(...) to the expression too if you want)

Now the sound variable will scale according to the master variable.
B
73
S
20
G
10
Posts: 524
Reputation: 9,896

Post » Sun Sep 23, 2012 7:04 pm

I'm doing this way too, but it don't update the playing sounds, only new sounds.
ImageImageImageImageImageImage
B
92
S
19
G
12
Posts: 1,192
Reputation: 18,276

Post » Sun Sep 23, 2012 7:21 pm

But the volume not updating properly isn't what you were asking about.
Tags is pretty much families for sounds. You can add more than one tag to a sound using '&'.
B
73
S
20
G
10
Posts: 524
Reputation: 9,896

Post » Sun Sep 23, 2012 7:36 pm

[QUOTE=inkBot] But the volume not updating properly isn't what you were asking about.
Tags is pretty much families for sounds. You can add more than one tag to a sound using '&'.
[/QUOTE]

What I'm saying is that if you use, global, local or instance variables will not update the sound volume, it will only setup the volume for sounds triggered after the setup... You can call global volume as master volume, it's only a name, but the function I was asking for is that to update the sound volume of all sounds, running or not, the same for the family.

With a specific family would be easier than setup using tags and &..&..&..&..&..&..& when you're dealing with thousand of sounds, also, easy to import or clear a sound on the list.
ImageImageImageImageImageImage
B
92
S
19
G
12
Posts: 1,192
Reputation: 18,276

Post » Sun Sep 23, 2012 8:15 pm

I just tested changing the volume of "sound" in my own project using the same method, and it works nicely. The sounds all played with the specified volume. I tried triggering the sounds after and before I lowered the volume. It worked as intended in both cases.
I'd hazard a guess that it's your events that are at fault.

I cannot see why you would need so many tags for any individual sound. At most I'd have a tag for what type of volume (sound/music) and enemy type (if I wanted to be specific).

What are you doing that requires so many tags? And if you really need so many tags, wouldn't you just be replacing having a lot of tags with having a lot of families?inkBot2012-09-23 20:17:12
B
73
S
20
G
10
Posts: 524
Reputation: 9,896

Post » Sun Sep 23, 2012 8:52 pm

I jsut learned something new reading through this. Thanks InkBot, the variable idea for the sounds actually was cool. Im adding that to my game now.
Image
B
57
S
14
G
6
Posts: 493
Reputation: 11,253

Post » Sun Sep 23, 2012 9:54 pm

[QUOTE=inkBot] I just tested changing the volume of "sound" in my own project using the same method, and it works nicely. The sounds all played with the specified volume. I tried triggering the sounds after and before I lowered the volume. It worked as intended in both cases.
I'd hazard a guess that it's your events that are at fault.

I cannot see why you would need so many tags for any individual sound. At most I'd have a tag for what type of volume (sound/music) and enemy type (if I wanted to be specific).

What are you doing that requires so many tags? And if you really need so many tags, wouldn't you just be replacing having a lot of tags with having a lot of families?[/QUOTE]

We are talking about different things for different purposes. Thanks anyway.
ImageImageImageImageImageImage
B
92
S
19
G
12
Posts: 1,192
Reputation: 18,276

Post » Sun Sep 23, 2012 10:10 pm

What do you mean by a family of sounds? I think you need to explain your idea in more detail because I can't think what you mean by that.
Scirra Founder
B
359
S
214
G
72
Posts: 22,946
Reputation: 178,478

Post » Mon Sep 24, 2012 12:38 am

@NotionGames - Cool. :)

@Ashley - Since the topic is about audio/sounds, there're two things that I'm wondering.

First, when adding tags we can type '"music" & "title_loop"' in the Tags expression field, but when doing this I can't access either tag when trying to change the volume and such.

Is this because we can really only have one tag for a sound, or is it a bug?

Second, (this is kinda unrelated so little bit of thread hijack here) when looping music or switching between songs there's a notable gap when the music loops/switches.

I'd like the loop/switch to be as seamless as possible, can this be improved somehow?

I made a little test title screen for fun and in it I switch between one song and another, as well as loop the second song. It's all supposed to be seamless, but isn't due to the forementioned gaps. LinkinkBot2012-09-24 00:41:06
B
73
S
20
G
10
Posts: 524
Reputation: 9,896

Next

Return to Construct 2 General

Who is online

Users browsing this forum: Aphrodite, artbava, blackant, Bleenx and 10 guests