Forum begins after the advertisement:

 


[Part 1] “Walk” and “Idle” are always triggered at the same time

Home Forums Video Game Tutorial Series Creating a Farming RPG in Unity [Part 1] “Walk” and “Idle” are always triggered at the same time

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #18354
    bao lex
    Level 3
    Participant
    Helpful?
    Up
    1
    ::

    Hello Terresquall, I’m having a problem with my character’s movement, where “Walk” and “Idle” always fire at the same time when I move, and I don’t know how to fix this.

    has upvoted this post.
    #18355
    Tarha Apustaja
    Level 5
    AI Assistant
    (BETA)
    Helpful?
    Up
    0
    ::

    Based on the reference information about animation transitions, the issue likely stems from the animation controller’s transition settings. In the PlayerController script, the velocity magnitude is used to control the “Speed” parameter, which determines walking and idle states.

    To fix this, ensure your animation transitions have proper threshold settings. Specifically:

    • The Idle to Walking transition should have a minimum Speed threshold
    • The Walking to Idle transition should have a maximum Speed threshold

    These thresholds will prevent simultaneous “Walk” and “Idle” states by creating a clear boundary between movement states.

    Can you share a screenshot of your Animator Controller’s transition settings to confirm the specific configuration?

    #18365
    bao lex
    Level 3
    Participant
    Helpful?
    Up
    0
    ::

    I uploaded a video and three pictures. It seems that the AI ​​assistant cannot recognize them at present.

    #18366
    Terence
    Level 31
    Keymaster
    Helpful?
    Up
    0
    ::

    Yup, our AI is not that advanced yet, unfortunately.

    Regarding your issue, notice that your character’s speed fluctuates between 0.006 and 0.012. This is why the character keeps fluctuating between walk and run, because your transition condition is when speed is at 0.01. You can reduce this value to fix the issue in both your Walk -> Idle and Idle -> Walk transition arrows.

    #18384
    bao lex
    Level 3
    Participant
    Helpful?
    Up
    1
    ::

    Thank you so much. Yes, I adjusted the Speed ​​from “Walk” to “Idle” to 0.006, and the problem was solved.

    has upvoted this post.
Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.

Go to Login Page →


Advertisement below: