Giving a Character footstep sounds

Footstep sounds are an effective - and simple - way to add atmosphere to your game.

With a character already made, use the Scene Manager to add a new Sound object to the scene:

Parent this new Sound to your character, and attach the Footstep Sounds component to it. It is available under Adventure Creator → Characters → Footstep sounds in the Add component menu:

In this component's Inspector, you can set the number of walking and running sounds, and assign them:

Underneath, assign its own GameObject as the Sound to play from, and the Character it's parented to as the Character:

The simply way to play these sounds is to set the Play sounds field to Automatically, which will cause them to play as the character moves. If this works for you, you're done!

A more involved method, though, is to set this to Via Animation Events, which causes the sounds to only be played when the component's PlayFootstep function is called. This is intended to be called from events in the character's animation, and allows you to precisely sync the sounds when the character's feet touch the ground.

For more on Animation Events, see Unity's documentation here. Just be aware that you'll need to move the Footstep Sounds component to the same GameObject as your character's Animator - though you can leave the Sound and AudioSource components where they are.

Either way, you'll probably want to have different sounds play when the character walks onto a different surface. This can be done by placing a Trigger over that surface, and using it to call the Sound: Change footsteps Action: