• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
2
Question by RemDust · Dec 15, 2015 at 12:09 PM · animation2dframes

How to align frames/pivot point in 2D animation

Hi guys, I don't really know how to get a consistent animation in a "pivot point" standpoint.I mean, my animation are drawn frame by frame, and ingame it seems like the frames are not aligned well !

But how can I have a consistent pivot point when the size of the caracter needs to change ? For exemple : when my hero is jumping, his legs are getting closer to his body so the player is getting smaller. What can I do to avoid those weird movement between frames ?

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

3 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by punixer · Jul 09, 2018 at 10:08 AM

Well, it does @Farresto.

thank you.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
1

Answer by Farresto · May 06, 2017 at 07:59 PM

Setting up a custom pivot point might not be the right approach, specially if you re-combine sprites multiple times. A pivot that works for one combination might not work for another.

The easiest way I found was to manually set the animation frame by frame to look the way I want, and then in the Animation Tab, at the bottom you'll find "Dopesheet" and "Curves".

  1. Go to "Curves", and then in there, there will be a little diamond icon in the frame in question.

  2. Click on it, and a smaller grayish diamond will appear.

  3. Move that diamond all the way up so it's vertically aligned with the frame diamond.

You will see now that instead of smoothing the transition between frames, it "snaps", getting rid of those weird movement between frames you were talking about.

I know it's been a long time, but it might help someone out there.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Rockaso · Dec 10, 2018 at 02:00 AM 0
Share

Thank you for the suggestion, I found the combination of custom pivot through the multiple sprite editor and the curves at the animator window really handful because the animator is a way of setting a general offset for all frames inside an animation.

avatar image
2

Answer by Drakonno · Feb 02, 2016 at 06:27 PM

Hello @RemDust,

Since You did not post information, wheter You managed to solve Your problem, or not, and 66 people are following, I would share with my recent solution.

I was trying to prototype something with that sprite sheet as You can see, almost each frame is different size, and sometimes "center of mass" of character is also changing.

  1. We can just drag and drop our sprite-sheet to Unity.

  2. Then click it, in inspector select SpriteMode and set to Multiple.

  3. Apply, open SpriteEditor.

Now in left top corner we can set how sheet should be sliced. Automatic one is quite good, but sets also automatically pivot point. Best pivot is probably left-bottom or center. Hit slice and You will have frames.

Here, we can click each frame, select in right bottom menu "pivot", and set it to "custom". In X, and Y we set value, where should be our pivot for selected frem. In my sprite-sheet I set manually left leg as pivot in most frames. For running, bottom center. For jumping just center. And so on.

Hope it helped, at least a bit.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image alestesta50 · Jun 27, 2021 at 01:18 PM 0
Share

Really useful! Thanks!

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

67 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

2D Spine Animation not playing 0 Answers

Import animation from Adobe Animate(JSON) 1 Answer

Professional shortcuts/functions for Animators in the Unity 0 Answers

2D Animation,Limbs do not follow the body 0 Answers

Should weapons be different sprites? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges