sooo, i have seen other games implementing a gfeature that changes up the audio when running im not quite sure how to do that.
this is what i have,
var AudioFile : AudioClip;
function Update() {
if (Input.GetKeyDown (KeyCode.W))
{
audio.clip = AudioFile;
audio.Play();
}}
function Update() {
if (Input.GetKeyUp (KeyCode.W))
{
audio.clip = AudioFile;
audio.Stop();
}
}
but what my real question is, how do you require a function to work by pressing two buttons at once?