I'd like to change the property speed
of an animation from the animator. For example, I'd like the player to be able to reload faster with upgrades. So I have a basic reload animation on the gun animator, and I would like to change its speed depending on the reload speed level the player has. But I can't find how to change this property in C#.
Here is what I have so far :
void Start() {
gunAnim = gun.GetComponent<Animator> ();
}
void Update() {
if (Input.GetKeyDown (KeyCode.R)) {
gunAnim.Play("reload");
reloadSound.Play();
}
}