Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • 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 /
avatar image
0
Question by Draze · Jun 10, 2014 at 05:27 AM · animation2dsprite

How to make a sprite stay at a consistant baseline during animation?

So I have an interesting problem concerning animation. I know exactly what is happening but I don't know how to fix it. I am using a sprite sheet (yes its from Tales of Phantasia and yes I know it's copyrighted and all) with an attack animation that has a sword that goes below the sprite. This causes the animation to actually raise the player part of the sprite when animating because the sprite itself is reading the bottom of the sword as the bottom of the sprite when in reality the sprite is higher. The only way I can think to currently fix is to animate the entirety of the object along with it (the collider, my checkers, etc.). I feel like this will be very, very difficult to change all of this every single frame. Is there a way you can set the baseline of a sprite or a quick fix for this sort of thing? I feel like it will come up a lot in the future.

Sprite Sheet

cless combat sheet.png (5.0 kB)
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

1 Reply

· Add your reply
  • Sort: 
avatar image
3
Best Answer

Answer by IvovdMarel · Jun 10, 2014 at 05:43 AM

Unity2D Sprite has the 'Pivot' option which allows you to create a custom pivot point.

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 Draze · Jun 16, 2014 at 12:31 AM 0
Share

This works, but to expand on your answer in order to give other readers more clarity on how this actually fixes it. I went into the sprite editor and moved the pivot point on my sprites to a consistent location on the sprite itself. In my case, the first animation had it near the mouth and left eye. So, in order to maintain the consistent animation I had to move the pivot point to that location on each sprite even though it wasn't the "middle" of the entire sprite. I did it by eyeball as I could not think of a helpful math equation or anything to help out, as the pivot point can only be set in terms of the sprite(0.0-1.0). Thanks again!

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.

Follow this Question

Answers Answers and Comments

22 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

Related Questions

Using same animation with different sprite sheets 0 Answers

Simultaneous Animation for an Object 0 Answers

I cannot make AnimationClip changing some Sprites without AnimationController. 0 Answers

Sprites: Project Sprite to Mesh, allow for bending of sprites for 3d environments 0 Answers

Object not moving after changing animator parameter 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