Footstep Audio playing?

I am giving a footstep audio to my enemy in the scene. The problem is that the audio is played always and irrespective of the main players distance from the enemy. How do i correct it?
I want to make the footstep audible only when the player is close to enemy.

It’s because the sound you’re using are 2D sound…
Try to look at this post:

Thanks it helped :slight_smile: