# Failing to manipulate StudioEventEmitter volume

**URL:** <https://qa.fmod.com/t/failing-to-manipulate-studioeventemitter-volume/19810>\
**Category:** Unity\
**Tags:** unity, csharp\
**Created:** [January 31, 2023, 3:50pm UTC](https://qa.fmod.com/t/failing-to-manipulate-studioeventemitter-volume/19810 "2023-01-31T15:50:16Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![solain12](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/solain12/32/4569_2.png) [@solain12](https://qa.fmod.com/u/solain12)\
**Post date:** [January 31, 2023, 3:50pm UTC](https://qa.fmod.com/t/failing-to-manipulate-studioeventemitter-volume/19810/1 "2023-01-31T15:50:16Z")

</div>

Hi!

I’ve been trying to make a mod for a game where I allow the user to adjust volumes of various objects. For most of the sounds, the game uses their own FMOD\_CustomEmitter, which I’m perfectly able to control the volume. But when trying to adjust the volume of FMOD\_StudioEventEmitter, it just… doesn’t work?

I’ve tried looking through the API and guides and examples, but it’s been hard finding any information on what I could be doing wrong. Here’s what I’ve tried:

```csharp
public static void FixVolume(FMOD_StudioEventEmitter studioEmitter)
{
    studioEmitter.evt.setVolume(myVolume);
    studioEmitter.GetComponent<EventInstance>().setVolume(myVolume);
}

```

I’m not sure what I’m doing wrong, so any pointers would be great!

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [February 1, 2023, 2:38am UTC](https://qa.fmod.com/t/failing-to-manipulate-studioeventemitter-volume/19810/2 "2023-02-01T02:38:52Z")

</div>

Hi.

The function you are looking for is attached to the `Event Instance` its full function list is under [FMOD API | Studio API Reference](https://fmod.com/docs/2.02/api/studio-api-eventinstance.html#studio_eventinstance_setvolume). To access the `Event Instance` from the `Emitter` is:

```auto
public static void FixVolume(FMODUnity.StudioEventEmitter studioEmitter)
{
    studioEmitter.EventInstance.setVolume(myVolume);
}

```

This is using FMOD’s `Emitter` so you might have to change to code accordingly.  
If you can do that is it possible to get the `FMOD_StudioEventEmitter` code you are referencing?

Hope this helps!
