No sound on my unity game.

I’ve been working on my first game, adding flashlights, walking then proceding with the sounds. As i’m trying to make the walking sounds work i’ve tried making a little script with a tutorial. It doesn’t seem to work but where the tutorial maker has theirs working, i really need to know what i’m doing wrong.

The main camera (first person controller camera) has the audio listener, can anyone help?

var ground : AudioClip[];

private var step : boolean = true;
var audioStepLengthWalk : float = 0.45;

function OnControllerColliderHit (hit : ControllerColliderHit) {
var controller : CharacterController = GetComponent(CharacterController);

if (controller.isGrounded && controller.velocity.magnitude < 7 && controller.velocity.magnitude > 5 && hit.gameObject.tag == "Ground"  && step == true || 
controller.isGrounded && controller.velocity.magnitude < 7 && controller.velocity.magnitude > 5 && hit.gameObject.tag == "Untagged" && step == true ) {
		WalkOnGround();	
	}
}
function WalkOnGround() {
	step = false;
	audio.clip = ground[Random.Range(0, ground.length)];
	audio.volume = .1;
	audio.Play();
	yield WaitForSeconds (audioStepLengthWalk);
	step = true;
}
@script RequireComponent(AudioSource)

var scare : GameObject;
var played = false;
var trig = false;

var scareSound: AudioClip;
function Start () {
	trig = false;
	scare.renderer.enabled = false;
	}
function OnTriggerEnter (other : Collider) {
	trig = true;
}
function Update () {
	if (trig == true) {
		scare.renderer.enabled = true;
		removeovertime ();
		makehimscream ();
	}
}
//// timer ////
function removeovertime () {
	yield WaitForSeconds (0.8);
	scare.renderer.enabled = false;
	Destroy(this.gameObject);
	
}
//// sound /////
function makehimscream () {
	if (!played) {
		played = true;
		audio.PlayOneShot(scareSound);
	}
}

First, find your audio source in your project folder and click on play in the preview window to see if you can hear it, if so. in the import settings, click on the 2D Checkbox, this way, if you have audio from walking, we know it is a distance/3d issue. So after you switched it to 2D sound and applied, test the game again. If you do not hear the audio, ad a Debug.Log(“Playing Foot step sound”); just before you play an audio and run the game again, if you do not see the Debug.Log, your code never gets to the part that is supposed to trigger the sound. This should find the source of the problem for you. Make sure you add the debug.log along with the audio.Play / audio.PlayOneShot that would play the 2D sound.

make sure have only one Audio Listener on the scene, else no sound at all.