Can you trigger more than one label in a parameter at a time?

Hi all,

I’ve use FMOD for some game jams over the years and feel like I have just a cursory understanding of it.

I’m working on a game where a sound is triggered by a certain element that the player chooses. For instance, a fire sound happens when there is a fire element, etc. I’m using labeled parameters in a parameter sheet and it works fine. However, is there a way to trigger two labels at once? For instance, if the user choses to make something that contains both the earth and fire element, can it trigger the sounds for both while in the same parameter sheet? Normally I would just draw volumes for everything, but the label thing seems more organized.

If it matters, the programmers are using Godot. I’m not exactly sure what it looks like on their end, but is there a way they can just reference that parameter twice and trigger two labels?

Thanks!

Yes and no.

FMOD Studio events are instanceable, which is to say, there can be many different instances of the same event playing in your project. For example, a cart racing game might have only a single “cart engine noise” event, but attach a separate instance of that event to each cart on the track, so that it sounds like each cart has its own engine.

If an event features a local parameter, each instance of that event has its own state, including its own unique parameter values. For example, in the cart racing game I mentioned earlier, the “cart engine noise” event might have a “current speed” parameter that’s different for each and every cart on the track, to represent the different speeds at which those carts are moving.

So, if you have multiple instances of an event, it’s trivially possible to assign different values to the same parameter in different instances of that event. That cuts both ways, though: If you don’t have multiple instances of an event, it is impossible for one of that event’s parameters to be set to two different values at the same time.

That doesn’t necessarily mean it’s impossible for an event instance to trigger instruments on two different sections of the same parameter at the same time, however. If the instruments are asynchronous and set to play to end when untriggered instead of to cut immediately, changing the parameter value and then immediately changing it again to a different value while the event instance is playing will result in it triggering instruments at both new values. This can be used to trigger multiple instruments.

So, to answer your original question: No, it’s not possible to set a parameter to two different values in the same event instance - but it is possible to set a parameter to two different values in different event instances, or to have an event instance play two different instruments at different positions on the same parameter, provided you know what you’re doing.

All of that aside… While it is possible to use the methods I just described to set a parameter to two different values, it is not a good idea to do so. This is because parameters are supposed to represent variables within your game’s state, and each variable in your game’s state is meant to represent a specific detail of your game world that can only have one state at a time: A light switch can only be on or off, a car can’t drive at multiple different speeds at the same time, and a boat that’s floating on the lake can’t simultaneously be in drydock. Using a single parameter to select which element the player chooses makes sense only if the player can only choose one element to apply; if they can choose whether each individual element should or shouldn’t be used independently, with no limit on how many can be applied to the action, then each of those elements should be controlled by a different parameter.