Hi everyone,
I work in film industry as a sound editor and decided to learn FMOD and how it integrates with UE4 in my spare time.
So far it’s going okay-ish, the main deference for me is the fact in film you cut sounds to what you see on the screen but sound in games is 3D and operates differently, as it is triggered by different events and conditions.
So I created a first person template project in UE4 and started to work on it. So far, I’ve managed to add ambience sound, footsteps, slow and fast breaths and a gunshot sound.
Also, I’ve created various surfaces in my project and attached them to cubes, walls, floor. And I’ve attached different surfaces to the cubes. Then I’ve made impact events in FMOD with various impact sounds for different surfaces, e.g. Impact_Glass, Impact_Wood, Impact_Metal etc. Then I managed to setup “FirstPersonProjectile” blueprint in the way that every time the ball hit any surface, it plays correct surface impact sound, e.g. when I shoot in the cube with glass surface, it plays Impact_Glass sound. And as FMOD events have “Distance Attenuation” set up by default, the volume of the impact sound is louder or quieter depending on how far or close I’m to the object when the ball hits it.
However, I don’t want to use “Distance Attenuation” and instead, as the ball collides, account for how hard it’s impacting. So if I shoot from the distance the strength of the impact will be low but if I shoot standing next the an object, it will hit the object with max strength. Therefore the volume of the impact sound will be different, depending on the strength of the impact.
I’ve setup a parameter “Strength” in FMOD. Range is from 0 to 10. Setup volume automation, so at 0 it’s -70.0 dB and at 10 it’s +10dB.
Then I created a new float variable in Unreal, called “Strength” and set the value range from 0 to 10.
Then I connected “Play Event at Location” to “Event Instance Set Parameter” and “Value” of the “Event Instance Set Parameter” to “Strength” flow variable.
However, it doesn’t work as the the value of “Strength” doesn’t change automatically. Obviously, I did something wrong but at this stage I don’t really understand what exactly and as I only started with FMOD and UE4 last week, I don’t know how to solve the problem.
Can someone help please?
Maybe I’m overthinking? Maybe the best and simplest way to account for how hard it’s impacting as it collides is to use “Distance Attenuation”, so the further I’m from an object when the ball hits it the quieter the impact sound will be played and therefore it kind of says that the impact wasn’t heavy?
Thanks in advance for any help!