-1
Good afternoon guys I’m having the following doubt, I created animations on Unity Animator
doubt is as follows as I access the methods cracked in the Imator via script like the Grounded there and the Animation id, I saw that way on the internet but it seems that n works
using System.Collections; using System.Collections.Generic; using Unityengine;
public class aulaScript : Monobehaviour{
private Animator playerAnimator;
public bool Grounded;
public int idAnimation;
// Start is called before the first frame update
void Start(){
playerAnimator = GetComponent<Animator>();
}
// Update is called once per frame
void Update(){
playerAnimator.setBool("grounded", Grounded);
}
}
Assets Scripts aulaScript.Cs(19,24): error CS1061: 'Animator' does not contain a Definition for 'setBool' and no accessible Extension method 'setBool' Accepting a first argument of type 'Animator' could be found (are you Missing a using Directive or an Assembly Reference?)
– Dhonatan Silva
Sorry case is Setbool no setBool I will edit the answer
– Andeton Feitosa