# Changing a parameter with a UI Slider in Unity

**URL:** https://qa.fmod.com/t/changing-a-parameter-with-a-ui-slider-in-unity/13429
**Category:** Unity
**Created:** [September 14, 2017, 7:34am UTC](https://qa.fmod.com/t/changing-a-parameter-with-a-ui-slider-in-unity/13429 "2017-09-14T07:34:30Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Gryvix](https://avatars.discourse-cdn.com/v4/letter/g/53a042/32.png) [@Gryvix](https://qa.fmod.com/u/Gryvix)
#### Post date: [September 14, 2017, 7:34am UTC](https://qa.fmod.com/t/changing-a-parameter-with-a-ui-slider-in-unity/13429/1 "2017-09-14T07:34:30Z")

</div>

Hello,

I have a slider and I want it to change a parameter with it, I’m not much of a programmer, and couldn’t really find a good tutorial on how to do it.

Could someone help me with a script and a tutorial?  
(I used the example project fmod and the footsteps event and called the slider Foot, the only thing I changed in the sliderscript setting is max value 3 (since the footsteps event goes from 0 to 3)  
I’m getting kinda frustrated after trying for 4 hours being so stupid to not figure it out…

---

<div class="post-metadata">

### Author: ![cameron-fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/cameron-fmod/32/261_2.png) [@cameron-fmod](https://qa.fmod.com/u/cameron-fmod)
#### Post date: [September 17, 2017, 11:37pm UTC](https://qa.fmod.com/t/changing-a-parameter-with-a-ui-slider-in-unity/13429/2 "2017-09-17T23:37:57Z")

</div>

[https://docs.unity3d.com/ScriptReference/UI.Slider-onValueChanged.html](https://docs.unity3d.com/ScriptReference/UI.Slider-onValueChanged.html)

Using the example above, you can link a slider to your script which allows you to access the current value.  
You could also add a reference to a FMODStudioEventEmitter and use the SetParameter function with the value from the slider.
