Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

1.1K
Visualizações
Unity: Animation won't play on trigger

Im having trouble to let Unity play my animations. I gave my character an Animator. In this Animator I have this Animations: Animator

The trigger between these Animations are working fine and are running correctly on play. The idle animation it self is played, while i can't get it to play the walk or the jump Animation in the game (both work fine in the inspector). When on play the triggers are triggered, it even shows the blue bar under the walking or the jumping box, but the animation itself just wont be played in the game.

Here is the code I use to call the triggers:

void Update()
    {
        if (Input.GetKey(KeyCode.LeftArrow) || Input.GetKey(KeyCode.RightArrow)|| Input.GetKey(KeyCode.A)||Input.GetKey(KeyCode.D))
        {
            anim.SetBool("isWalk", true);
            
        }
        else
        {
            anim.SetBool("isWalk", false);
        }

        if (Input.GetKey(KeyCode.Space))
        {
            anim.SetBool("isJump",true);
        }
        else
        {
            anim.SetBool("isJump", false);
        }
        
    }

And the Transition Conditions (but these are working fine for me):

idle->jump: isJump =true,
jump->idle: isJump =fals,
idle->walk: isWalk =true,
walk->idle: isWalk =false,

screenshot of idle-> walk:

idle->walk

screenshot of walk->idle:

walk->idle

I hope someone can help me with this and please excuse my possibly bad english...

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

I had the same issue. Solved it by unchecking 'Can Transition To Self' inside the transition pointing to the state that didn't play.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda