How do I a volume "slider"?

Get help using Construct 2

Post » Wed May 28, 2014 8:28 pm

Anyone have a capx with an example for me?
I'm trying to do this by myself, but with no results...
Thanks
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Wed May 28, 2014 10:34 pm

I think is a little complicated to understand what I want, so... check this:
Image
If it's still complicated, just tell me.. Thanks
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Wed May 28, 2014 10:59 pm

hi,
you can do it easy.
i havn't C2 installed in this Pc, but i try to help.
just fix the volume min and max.
1. Put the SQUARE in min area and record its X position, assign its volume to zero "0"
2. put the SQUARE in max area and record its X position, assign its volume to max volume (goto help to know it)
3. Add drag drop behavior to the SQUARE and in on drop: compare the current X position and set it's value to volume.

try and tell me the result.
2D Game GUI Designer
B
12
S
4
G
3
Posts: 130
Reputation: 3,778

Post » Thu May 29, 2014 12:41 am

Manarsoft wrote:hi,
you can do it easy.
i havn't C2 installed in this Pc, but i try to help.
just fix the volume min and max.
1. Put the SQUARE in min area and record its X position, assign its volume to zero "0"
2. put the SQUARE in max area and record its X position, assign its volume to max volume (goto help to know it)
3. Add drag drop behavior to the SQUARE and in on drop: compare the current X position and set it's value to volume.

try and tell me the result.

Hi, thank you for the answer :)
I understand this logic, but I really don't know how to implement this on my project. :(
I found this example made by Yann, and sent him a pm for more details..
http://dl.dropboxusercontent.com/u/2355 ... index.html
The first slider is exactly what I want.
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Thu May 29, 2014 1:15 am

You need to compare/check The squares X position.

You will need to calculate the volume of the sound compared to where the square is on your slider.

Double Check what @Manarsoft has written and try what he suggests.It should work fine.
GMO FOOD = DEATH
B
23
S
9
G
5
Posts: 567
Reputation: 6,378

Post » Thu May 29, 2014 1:08 pm

Give me some minutes ti finish your need
2D Game GUI Designer
B
12
S
4
G
3
Posts: 130
Reputation: 3,778

Post » Thu May 29, 2014 1:31 pm

Hei,
i finished your little tutorial.
download and try it, let me know if this solved your problem! :mrgreen:
You do not have the required permissions to view the files attached to this post.
2D Game GUI Designer
B
12
S
4
G
3
Posts: 130
Reputation: 3,778

Post » Thu May 29, 2014 11:14 pm

Manarsoft wrote:Hei,
i finished your little tutorial.
download and try it, let me know if this solved your problem! :mrgreen:

Hehe awesome :mrgreen:
thank you very much, dude :!:
B
20
S
4
Posts: 385
Reputation: 2,270


Return to How do I....?

Who is online

Users browsing this forum: brunopalermo, valefor and 6 guests