Simple footsteps?


I am trying to get simple footsteps in my scene. All I have in the scene is a First Person Contoller with an audio source (has the footstep sound attached to it) and a floor. I need the audio to play when the W A S and D keys are pressed. If multiple keycodes are told to play the audio, the sound restarts when you strafe (hold down more than 1 key.) Is there any way to achieve this without the sound restarting? Thanks you SO much for your help!!

Play audio only when it’s not playing, like

If( !audio.isPlaying ) audio.Play();