Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Voting for the Unity Awards are OPEN! We’re looking to celebrate creators across games, industry, film, and many more categories. Cast your vote now for all categories
    Dismiss Notice
  3. Dismiss Notice

Animation (Jump + Fall + Landing)

Discussion in '2D' started by Nograe, Jun 29, 2018.

  1. Nograe

    Nograe

    Joined:
    Mar 25, 2018
    Posts:
    3
    Hello everyone,
    I'm trying to realise my first game in unity but I'm struggling with the animation.
    Here is what I want:
    - When the player is not grounded, display falling animation, then landing animation.
    - When the player is grounded and jumps, display jump animation, then falling animation, and then landing.

    I've joined a capture of what I've done.
    It is not working because the falling animation is calling each frame and not playing completely.
     

    Attached Files:

  2. JoeStrout

    JoeStrout

    Joined:
    Jan 14, 2011
    Posts:
    9,840
    Please consider this article on 2D animation methods. For a 2D game like this, I find using Unity's Animation Controller system in the standard way to be the most difficult approach. But in the article above you can compare three approaches, and see for yourself. You can also download a demo project with working run, jump, fall, and land.
     
  3. TheDodgerUk1

    TheDodgerUk1

    Joined:
    Dec 3, 2013
    Posts:
    61
    can you point out were this demo is plaese
     
  4. JoeStrout

    JoeStrout

    Joined:
    Jan 14, 2011
    Posts:
    9,840
    It's at the bottom of the article at the link you quoted.