Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 Joseph-Ferano · Sep 19, 2011 at 10:47 AM · animationattackblendingcrossfadeidle

Animations wont CrossFade

I have a combo system and I am recommending my animators to have one continuous attack instead of different separate attacks that all return to idle, then breaking them apart so that they can be linked if the player continues the attack. This plan can only work however if the animations CrossFade back to the idle pose. I have an idle animation and the animations are longer than 0.3 seconds. For some reason, Attack2 does not want to CrossFade and it just jumps abruptly to the idle animation. Does anybody know why this is happening? Is this an issue with 3ds Max or with something I'm doing with the programming?

Comment
Add comment · Show 1
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 Joseph-Ferano · Sep 20, 2011 at 12:31 AM 0
Share

bump, I could really use some help here.

I'm calling animations from two different scripts and the second one is using transform.parent.GetComponent() to control the animations, does accessing the component from two different skips affect any?

Edit: I just tested it and it doesn't seem to matter if call the animations from two different scripts. It just calls the same stuff.

2 Replies

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

Answer by save · Sep 20, 2011 at 12:48 AM

Have you tried setting the animations to theAnimation.blendMode = AnimationBlendMode.Additive;? Also try to put them in different layers to separate the motions.

Make sure to use animation.CrossFade("the animation", crossfadeTime); on them while an attack goes on and return to an idle state (still using CrossFade).

Comment
Add comment · Show 4 · 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 Joseph-Ferano · Sep 20, 2011 at 01:02 AM 0
Share

Thanks for the help. What exactly does Additive do? I tried it and the attack animation just goes nuts and becomes a giant mess with the bones just going in all kind of crazy directions.

Also, how does the crossfadeTime help? There is a quick snapping when I CrossFade like there is no blend at all, maybe it's happening too fast?

avatar image Joseph-Ferano · Sep 20, 2011 at 04:25 AM 0
Share

Ok, I just played around with the CrossFade crossfadeTime, and it works with other stuff and I definitely see the effect. However, in my case, there just isn't any kind of blend at all, so no matter how long I make the CrossFade, it just snaps back to the idle animation.

avatar image Joseph-Ferano · Sep 21, 2011 at 02:12 AM 0
Share

bump, any more help?

avatar image Joseph-Ferano · Sep 21, 2011 at 04:46 AM 0
Share

The bit you said about "while an attack goes on" is what I didn't realize I was doing wrong. Obviously the animation has to be playing for it to CrossFade, my animations were stopped before the CrossFade was being called. I'll figure it out from here, thanks.

avatar image
5

Answer by Stardog · Jun 21, 2013 at 12:54 PM

You need to set the animation to Loop, or it won't CrossFade.

Even if it's an attack animation that has a finite length, you still have to set it to Loop.

You will have to manually jump to a previous state by checking the "animation[animAttack.name].length", then end it manually when the 1st loop is finished using WaitForSeconds.

Comment
Add comment · Show 2 · 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 Darioszka · Jun 15, 2016 at 12:18 PM 0
Share

Thank You that was my big problem from a long time!

avatar image Master-Frog · Aug 24, 2016 at 05:34 AM 0
Share

Rock n' roll dawg

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

6 People are following this question.

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

Related Questions

Crossfade Quickening 0 Answers

More Animations = More Screwed Up? 0 Answers

Revert back to Idle animation Smoothly 0 Answers

Play an animation just on some parts of the body 1 Answer

Shaking skinned mesh animations 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