2D Animation in Unity (Tutorial)

Brackeys · 2.7M views · 2018 · 21:53

Open on YouTube

Game programming & enginesIndie game developmentGame designtutorialdated

Why Stack Overflow recommends it

Stack Overflow users link it as the standard walkthrough for 2D sprite animation and Animator setup in Unity, both as an answer and as the tutorial that askers say they were following.

Recommended by 7 people across 7 different months, 2019 to 2024.

What it is

A Brackeys tutorial that walks through animating a 2D platformer character in Unity. It covers importing sprites, creating animation clips and using the Animator with transitions and conditions for idle, run, jump and crouch. It continues from the same channel's player movement video.

What people said

Recommends Nicholas Bucher · 2019-03 · Stack Overflow · on “How to make a simple progress bar”

For a progress bar You can use the Unity scrollbar object to make what you're looking for. There's a good tutorial on it here [LINK] . Essentially, you add a scrollbar object to your canvas, and then change the slider value from code. For scrolling textures If you want a scrolling texture on your progress bar, then you can animate an image placed on the slider. If you don't want to animate it by hand, then it's a little more complicated. Ideally you could set the texture offset of the image in code to get it to scroll, but after looking it up I don't think that Unity allows you to do that on non-3D objects. If you still want it to scroll and don't want to make a hand-drawn animation for it,

Recommends Oxygenium · 2020-01 · Stack Overflow · on “Unity, animation playing repeatedly without input”

I see you watched the Brackeys tutorial. You probably have not set correct conditions of the transitions. See again the video from this fragment: 2D Animation in Unity (Tutorial) - 16:52 [this video]

Recommends TLSO · 2020-04 · Stack Overflow · on “How to add key frames to a new animation file in Unity?”

I've eventually used the way in this tutorial and it worked fine. It requires you to create the new clip files from the animation menu after you select the sprite object you're animating and then it works. [this video]

Recommends TEEBQNE · 2021-05 · Stack Overflow · on “Trying to cancel sprite animation before the script finishes”

Handling animations this way will cause a lot of issues, one being the issue you are currently facing. I would recommend using the Animation component and animating your object. Here is a Brackey's Tutorial [this video] on the subject. Should help a lot - good luck!

Recommends Horothenic · 2022-10 · Stack Overflow · on “turn sprite list images into single images for use”

Use this BRACKEYS TUTORIAL [this video] You need to make sprite sheets or create the animations in the Unity animation system and then trigger them by code or state machine.

Recommends Yeriwen · 2023-05 · Stack Overflow · on “Unity 2D Platformer: Jump animation breaks when Player Object turned into a Prefab. Any solutions?”

I'm currently working on a 2D Platformer in Unity. I followed along Brackeys Tutorials (will post links below) and everything works like intended, except when I turn my Player Object into a prefab. Then suddenly my Jump Animation breaks for some reason. Does anyone know a solution for this problem, because im not sure whether it's a programming problem or a unity related issue. Tutorials I used: #1 [LINK] #2 [this video] Bugged Animation video: [LINK] The left player character in the video is the prefab with the bugged animation. Would be really awesome if someone can help me :) Kind Regards, Jean-Pierre I've tried changing some of my code, also tried re-animating the Object as a Prefab, and sear

Recommends Austin Yang · 2024-03 · Stack Overflow · on “Unity add property animation dependence”

Please see this video for reference: [this video] Typically, open your animation clip in animation inspector, press record, and switch to the key frame that you want to turned On/Off the box collider. After that, just action it. The action will be recored in animation clip of your operation.

Cites Bridget Kacprzyk · 2019-07 · Stack Overflow · on “I animated my 2D game but my character doesn't move”

@derHugo Thats something I'm working on separate to the issue that I'm currently trying to figure out. Also I followed brackeys tutorial step by step so I set everything up exactly like this video link [this video]

Cites shadowByte · 2019-12 · Stack Overflow · on “Character animations are not playing correctly”

I have just started creating my first very simple 2D platformer. Following this [this video] tutorial I am now adding move animations to my character (move, run, jump e.c.t.). Everything has worked perfectly until I made an edit to my player movement script (as instructed by the tutorial) which solves an animation issue of the player going back to the idle animation state from the crouch animation state when the crouch key was released but the player was still crouching (due to the player not being able to stand up because of an object over its head). When making the modifications to my code and running my game, the player now just constantly plays/unplays the crouch animation regardless of wheth

Cites PabloP · 2020-05 · Stack Overflow · on “Unity3D idle player animation overrides jump animation”

I've followed the brackeys tutorials to make a 2D Player Character jump but having issues with the jump animation. When I hit jump, the Player goes into the air but it'll play the idle animation in the air til I give another keyboard input. If I hit jump again while in the air, it'll play the jump animation and go back to idle when hitting the ground. In the animator I noticed that the jump animation triggers fast and seems to be overridden by the idle animation. I've loaded and compared the working final brackeys project, and rebuilt the animator nodes. The code and everything in the editor are the same but the only thing I can think of is that I'm using different art assets. Here are the t