Please help me. I have no idea what’s wrong with my Mecanim script. I set set up a couple of states in the controller. And I created an integer parameter named “Shuffle”. The program is supposed to increase “Shuffle” by a fixed amount.
Here is the script:
using UnityEngine;
using System.Collections;
public class Wave : MonoBehaviour {
private Animator anim;
void Start () {
anim = GetComponent<Animator>();
}
void Update () {
if (Input.GetKeyDown(KeyCode.Space))
{
anim.SetInteger("Shuffle", 20);
}
}
}
Please help me.