Hi i just finished making an animation of a person walking and named it “walking”
I also made an animation of a person standing still
if have this code so far but the stand still doesnt work
`var Walk : String = “Walking”;
var stand : String = “stand”;
function Start () {
}
function Update () {
if (Input.GetKeyDown (“w”))
{
gameObject.animation.CrossFade(Walk);
}
else if (Input.GetKeyUp (“w”))
{
gameObject.animation.CrossFade(stand);
gameObject.animation.Play(stand);
}
}`