- Home /
Animation script help light problem
Hey , I need to attach to this code At if statement : and operator && To checked if the button is not clicked but how ?!
Hint : there are two animations attached to #player stand and shoot and there is abutton seperated in UI to make an animation to #player I made its animation with onclick with play string and called bombs but when I operate game and press in button made two thing click with mouse and pressed button so the animator controller operate first shoot anime then bombs anime I want to shoot to not operate
void Start () { animvar = GetComponent(); }
public void Update () { reg = GetComponent (); if (Input.GetButtonDown("Fire1")) { animvar.SetInteger ("AnimTrans", 2); } else { animvar.SetInteger ("AnimTrans", 0); } }
Comment