Using UE 5.1
Much easier to play the sound at the player location. Having said that, if you could get it to exactly follow the player, it would have the same effect as just using âplay sound 2dâ, so why not use that?
Can you share more specifics about your scenario? Where is the spline in relation to the player?
So I used this video as a guide to construct the spline and attach audio to it: Spline Based Audio For Unique Shapes | How To Add SFX To A River - Unreal Engine Tutorial - YouTube
Basically my ThirdPersonController is running along a river, and Iâm trying to detect the playerâs location and have the sound cue (playing a river sound) follow the player as he runs alongside it.
I know the video is in UE4, and Iâm wondering if thatâs the reason why itâs not working. Should I have used UE5âs water plugin instead?
The water you use shouldnât matter since the audio spline the tutorial has you create is just being placed over the top of the river. I donât think thereâs anything that needs to be different for UE5 from the tutorial.
Can you describe whatâs not working? Is the sound not playing at all? Is the sound playing but not moving along the spline?
You just need to drop some sound cues of the water flowing, at regular intervals along the river.
The sound cue is working, itâs just not following the player as heâs walking alongside the river. Iâve copied the blueprint in the video, so Iâm not sure what the issue is.
Can you share a screenshot of your blueprints?
Here is an image of the event graph.
Spline is the spline component, and Water is the audio component.
On the âFind Location Closest to World Locationâ node, Iâve switched coordinate space between Local and World; neither worked.
Your âSetWorldLocationâ node isnât connected properly. It should be connected to the red âMoveAudioâ custom event on the left, not the blue event call node.
Thatâs it! Thanks so much.