I can't make transition from actual animation to previous one

Evening! I have some trouble at calling transition. I can make the transition from up to down but i cant go from down to up. As you can see in Nest picture i make all transition, but only those who came from up are able to be called.


The script I’m using is here :

using UnityEngine;
using UnityEngine.UI;
using System.Collections;

public class AnimatorController : MonoBehaviour
{

    int pagNr = 1;
    int BackPag=99;
    public Animator anim;

   

    void Start()
    {
        anim = GetComponent<Animator>();
        Debug.Log(BackPag);
        Debug.Log(pagNr);
    }

    // Update is called once per frame
    void Update()
    {
       

        if (Input.GetKeyDown(KeyCode.KeypadEnter) || Input.GetKeyDown(KeyCode.Space) || Input.GetKeyDown(KeyCode.RightArrow))
        {
           
                pagNr++;
                BackPag++;
                anim.SetInteger("PAg", pagNr);
                Debug.Log(BackPag);
                Debug.Log(pagNr);
                //anim.SetTrigger("EnterPag1");}

            

           

        }
        if (Input.GetKeyDown(KeyCode.LeftArrow))
            {
               
                    BackPag--;
                   pagNr--;
            anim.SetInteger("PAg", pagNr);
            anim.SetInteger("BackPag", BackPag);
            Debug.Log(" ");
            Debug.Log(BackPag);
            Debug.Log(pagNr);
            Debug.Log(" ");

        }
    }
   
}

Please try to respond as fast as you can!

Thanks in advance!

NOTE: PAg is trigger for up-down transitions and BackPag is for down-up transition!

P.S. Sorry for my english, I’m not so good at it :slight_smile:

Serju

@Serju

It should not make a difference but try this (You may want to make a backup of your project first). Delete all your transitions. Than create your transitions like this

  1. EnterHS → EnterP1

  2. EnterP1 → EnterHS

  3. EnterP1 → P2Enter

  4. P2Enter → EnterP1

  5. P2Enter → P3Enter

  6. P3Enter → P2Enter

  7. P3Enter → P4Enter

  8. P4Enter → P3Enter

  9. P4Enter → P5Enter

  10. P5Enter → P4Enter

  11. P5Enter → P6Enter

  12. P6Enter → P5Enter

  13. P6Enter → P7Enter

  14. P7Enter → P6Enter