Question by
Baron98 · Aug 30, 2016 at 09:13 PM ·
3rd person controller
Why this animator script doesn´t work?
This is the script: I attach it to the character and when i try to press W or down arrow the model doesn´t play the Walk animation.I don´t know why.
using UnityEngine;
using System.Collections;
public class YandereContr
oller : MonoBehaviour
{
Animator anim;
// Use this for initialization
void Start ()
{
anim = GetComponent<Animator> ();
}
// Update is called once per frame
void Update ()
{
float move = Input.GetAxis ("Vertical");
anim.SetFloat ("Speed", move);
}
}
Comment