Community Q&A

Where Wwise users help each other out!

Audiokinetic's Community Q&A is the forum where Wwise users ask and answer questions within the Wwise community. If you would like to get an answer from Audiokinetic's Technical support team, make sure you use the Support Tickets page.

Footstep Sounds

0 votes

Hi Guys! I was wondering if anyone has used the Unity 3D Game Kit with Ellen as the Player Character?
Basically I am using Wwise Audio middleware to implement her sounds and can call other sounds no problem however I need to place this line of code AkSoundEngine.PostEvent ("Footsteps", .gameObject); (Footsteps is the name of my event) in to Ellens C# footstep script) to post her footstep sounds from Wwise in to Unity.

I just don't know where in the script to place the line of code or if I need to change any other line relating to audio?? below also just incase you prefer to  I have highlighted in blue here what I think are two relevant sections in which to place the line but need guidance.

Please can anybody help as I am really stuck??
I would be so grateful if anyone can help me out on this!!!
Thank you
Charlie

public RandomAudioPlayer footstepPlayer; // Random Audio Players used for various situations.

public RandomAudioPlayer hurtAudioPlayer;

public RandomAudioPlayer landingPlayer;

public RandomAudioPlayer emoteLandingPlayer;

public RandomAudioPlayer emoteDeathPlayer;

public RandomAudioPlayer emoteAttackPlayer;

public RandomAudioPlayer emoteJumpPlayer;


 

 

Transform footStepSource = transform.Find("FootstepSource");

if (footStepSource != null)


footstepPlayer = footStepSource.GetComponent<RandomAudioPlayer>();

 

asked Jan 11 in General Discussion by Charlie C. (100 points)

Please sign-in or register to answer this question.

...