# StudioEventEmitter SetParameter() GC

**URL:** <https://qa.fmod.com/t/studioeventemitter-setparameter-gc/23512>\
**Category:** Unity\
**Created:** [October 24, 2025, 10:48am UTC](https://qa.fmod.com/t/studioeventemitter-setparameter-gc/23512 "2025-10-24T10:48:58Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![SonarSoundSB](https://avatars.discourse-cdn.com/v4/letter/s/f475e1/32.png) [@SonarSoundSB](https://qa.fmod.com/u/SonarSoundSB)\
**Post date:** [November 5, 2025, 8:26am UTC](https://qa.fmod.com/t/studioeventemitter-setparameter-gc/23512/3 "2025-11-05T08:26:24Z")

</div>

Thanks Cameron!

Ahh okay makes sense, we are using StopEventsOutsideMaxDistance but I assumed if the event is being stopped outside it’s max distance then it would have been released and therefore the parameter changes won’t affect that instance anyway, isn’t that the case?

I see there’s a cache solution to this problem here, should I implement something like this?

> [@StudioEventEmitter.SetParameter creates Garbage](https://qa.fmod.com/t/studioeventemitter-setparameter-creates-garbage/13177/6):
>
> Here is the dirt simplest way. Just install a cache between the parameters public static class FmodFix { private static Dictionary\<string, byte[]\> StringTable = new Dictionary\<string, byte[]\>(); public static byte[] Encode(string name) { byte[] results; if (!StringTable.TryGetValue(name, out results)) { results = Encoding.UTF8.GetBytes(name + Char.MinValue); StringTable[name] = results; } return results; } } public RESULT setParameterValue(string name, float value) { …

Thanks Cameron

---

_[View the full topic](https://qa.fmod.com/t/studioeventemitter-setparameter-gc/23512)._
