Can anyone help me? I want to create a sliding volume control
through action scripting. Control should be the same as we have in
Windows Media Player. When I drag to the left, the volumme should
decrease and when draged to thr right, the volume should increase.
the exact coding depends upon the registration point of your
scrubber or slider and whether your control is vertical or
if the slider has its reg point at the left and is
horizontal, start a loop with your onPress (and startDrag() ), and
set the volume of the sound you want to control according to the
position of the slider.
you'll want the volume to be zero when the slider's _x
property is zero and you'll want the volume to be 100 when the
slider's _x property is the controls._width-sliders._width.
this gives two equations in two unknowns. solve for the
unknowns and you have your equation to give the volume for any