# Parameter return to 0 after play

**URL:** https://qa.fmod.com/t/parameter-return-to-0-after-play/16093
**Category:** Unity
**Created:** [August 19, 2020, 4:38pm UTC](https://qa.fmod.com/t/parameter-return-to-0-after-play/16093 "2020-08-19T16:38:14Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![DeqafStudio](https://avatars.discourse-cdn.com/v4/letter/d/b9bd4f/32.png) [@DeqafStudio](https://qa.fmod.com/u/DeqafStudio)
#### Post date: [August 19, 2020, 4:38pm UTC](https://qa.fmod.com/t/parameter-return-to-0-after-play/16093/1 "2020-08-19T16:38:14Z")

</div>

Hello,

I change Parameter  
hero.EventInstance.setParameterByName (“Surfaces”, 1);  
But after one Play parameter return to 0 again.  
How keep this value?

---

<div class="post-metadata">

### Author: ![super8ude](https://avatars.discourse-cdn.com/v4/letter/s/779978/32.png) [@super8ude](https://qa.fmod.com/u/super8ude)
#### Post date: [August 19, 2020, 9:46pm UTC](https://qa.fmod.com/t/parameter-return-to-0-after-play/16093/2 "2020-08-19T21:46:15Z")

</div>

event instances should keep parameter values, unless they stop. You can prevent an event from stopping automatically by setting “Persistant” to ON in FMOD Studio. It’s a setting on the master track of the event.

Other ways to solve this:

if you want 1 to be default, change it to 1 in FMOD Studio, right click and select “Set As Initial Value”

if you want to remember the last value used, you could store it as a variable in unity.

float surfacesValue = 1f;

hero.EventInstance.setParameterByName(“Surfaces”, surfacesValue);

---

<div class="post-metadata">

### Author: ![DeqafStudio](https://avatars.discourse-cdn.com/v4/letter/d/b9bd4f/32.png) [@DeqafStudio](https://qa.fmod.com/u/DeqafStudio)
#### Post date: [August 20, 2020, 8:44am UTC](https://qa.fmod.com/t/parameter-return-to-0-after-play/16093/3 "2020-08-20T08:44:56Z")

</div>

Thanks a lot!
