How can I detect a SliderBar object change of value?

Get help using Construct 2

Post » Thu Jun 26, 2014 7:12 am

I want to put a sound on every change of SliderBar object, but using the "On Change" Event the sound play only when the mouse is released...
Any workaround?
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Thu Jun 26, 2014 9:36 am

Put the sound inside the event that changes your sliderbar object. That is the most logical thing I can think of.
B
6
S
1
Posts: 73
Reputation: 571

Post » Thu Jun 26, 2014 8:33 pm

rezagamertag wrote:Put the sound inside the event that changes your sliderbar object. That is the most logical thing I can think of.

Yup.. but, as a said, when I do this the sound play only when the mouse is released :|
Help! :(
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Thu Jun 26, 2014 8:43 pm

hope it helps
You do not have the required permissions to view the files attached to this post.
B
5
S
1
Posts: 51
Reputation: 477

Post » Thu Jun 26, 2014 11:17 pm

trultz wrote:hope it helps

Thank you, dude ^^
It's a cool method, but it have a bug..
when you move the mouse faster, the sounds keep playing for some seconds after the mouse's stopped.
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Fri Jun 27, 2014 1:22 am

lol well the slide bar maximum is a bit much, if you put it to 20 it works pretty good
B
5
S
1
Posts: 51
Reputation: 477

Post » Fri Jun 27, 2014 1:41 am

trultz wrote:lol well the slide bar maximum is a bit much, if you put it to 20 it works pretty good

ok :)
it's weird the "on change" event of the Slider Object work only when the button is released.. don't you think?
It looks like a bug to me... the value change all the time, no just on release.
Anyway, thank you :mrgreen:
B
20
S
4
Posts: 385
Reputation: 2,270

Post » Fri Jun 27, 2014 1:52 am

It's OnChanged not OnChanging so I guess it works as designed. Might have to make your own if you want that behaviour.
B
24
S
9
G
4
Posts: 1,646
Reputation: 6,596


Return to How do I....?

Who is online

Users browsing this forum: Lancifer, newt and 12 guests