• 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
Question by giorgik63 · Feb 04, 2019 at 08:56 PM · helloworld

How to use 1 animation controller for a character and an animated object ?

Hello everyone. How do you use 1 animation controller for a character (with its animations) and an animated object synchronized to the character ? In particular I have as character the animation of an archer without a bow and as an object a bow with its animation. I would like the archer to hold the bow in its hand and that the 2 animations activate at the same time (for example with the use of a trigger). It's possible ?

Comment

People who like this

0 Show 0
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

2 Replies

  • Sort: 
avatar image

Answer by MartinIsla · Feb 05, 2019 at 04:53 AM

Sure. I think what you want here is to use animator layers (that's the keyword, google it!)

Create a new animator layer for the bow. Drag the animation clips of the bow to that layer. Now connect the states so they respond to the same parameters as the player. Be happy. Get coffee. Think of me while drinking that coffee.

Comment

People who like this

0 Show 0 · 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

Answer by giorgik63 · Feb 05, 2019 at 12:37 PM

Thank Tiiiincho, until then I had arrived too, but the problem is to match the movement of the hand that takes the string of the bow and the curtain, with the animation of the string that stretches (which would be the second animation, the one you suggested to do).

Comment

People who like this

0 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 MartinIsla · Feb 05, 2019 at 12:47 PM 0
Share

Yes! If you use the same parameters in the animator to trigger both the bow and the hand animation states, they should trigger at the same time and therefore be synchronized.

I’m thinking you should also sync the bow layer to the hand layer (you do that with the tiny gear next to the Bow Layer in the layers list).

Say you have a bool IsAiming and Idle -> Aiming transitions in both the hand and the bow layer, with the condition set to “IsAiming = true”. When you call anim.SetBool(“IsAiming”, true) in your script, each layer would set the right state. The hand would do the movement and the string in the bow would be stretched

Keep me posted!

avatar image giorgik63 · Feb 05, 2019 at 04:43 PM 0
Share

Tiiiincho, I'll explain to you my situation better. I downloaded the character Erika Archer Bow with Arrow from MIXAMO and the animation of Erika that pulls the arrow but with the bow of the bow. What I want to do and create the animation of the bow that bends when Erika executes the shot and then the hand of Erika who takes the bow and pulls it (as in the animation I downloaded, but that does not take the rope, but mimics the action).

The question is: can you change the animation to do what I want and how ?

Unity Answers is in Read-Only mode

Unity Answers content will be migrated to a new Community platform and we are aiming to launch a public beta by June 9. Please note, Unity Answers is now in read-only so we can prepare for the final data migration.

For more information and updates, please read our full announcement thread in the Unity Forum.

Follow this Question

Answers Answers and Comments

98 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 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

How to save project into the portable hard drive 1 Answer

UI- Rotational Inventory,Where to begin? 2 Answers

Why is going one direction faster 2 Answers

Trying to disable the Script below on trigger or the closest thing 0 Answers

when i build the game from unity for test the start button doesn t work however it s work at unity engine 0 Answers


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