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 birns92 · Apr 25, 2016 at 07:32 PM · animationgameobjecttransformchildmesh collider

Mesh Collider Does not rotate with Mesh

The Mesh collider I assigned does not rotate with the mesh during animation.

alt text

Here is a picture before animation has been played showing the collider is placed properly.

alt text

As shown in the picture, the mesh collider is assigned to the deltoid, which is a child of a larger game object (YogaCharacter). From what I have researched Online this may pose a problem since the mesh's transform and rotation is based on its parent, which at least in my case causes a problem with the collider. I have tried replacing with a box collider to test if a simpler collider would rotate, but no cigar. How can I fix this problem?

EDIT: I imported the mesh and the animation from Maya. I feel like that must be part of the problem. If I create a sphere in unity, create an animation for that sphere. and make the sphere a child of a gameobject everything works fine!

mesh-collider-1.jpg (226.4 kB)
mesh-collider-2.jpg (207.2 kB)
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 Raresh · Apr 25, 2016 at 07:36 PM 0
Share

Pretty sure you need to modify the transform in order to modify the collider. I am not sure if animations will do what you are looking for.

2 Replies

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

Answer by birns92 · Apr 26, 2016 at 03:52 AM

I figured out a simple solution to get it to work. I moved the mesh to be a child of it's counterpart in the character Rig.

alt text

alt text

I realized that if it is a child of the Rig, the mesh Collider will inherit the Rotation of the Rig Animation. This is a very tedious process since I have hundreds of bones and muscle objects. Does Anyone know a faster route?


mesh3.jpg (209.7 kB)
mesh4.jpg (203.0 kB)
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 UDN_30011711-3d42-4608-a55a-5bf3a3109e16 · Feb 02, 2017 at 08:13 AM

Add colliders on joints. It worked for me. Definitely not mesh colliders , you can use box , capsule or any other collider that is appropriate .

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 Jeremy-Borton · Apr 29, 2017 at 09:21 PM 0
Share

I agree. It's seems easy to me to just create child objects to each bone with sphere colliders which only take 1 line of code (1 call) ins$$anonymous$$d of a box collider with 4 if statements (4 calls). If I do them directly on each bone, I can't position them perfectly, so with empty child objects I can position each bone allowing me to move the positions around without affecting the bone positions.

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

85 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

Related Questions

Finding Children question 3 Answers

Error code CS0029. 1 Answer

Properly Rotating Child Objects by Script 1 Answer

Can't Return the Tag of a Child Object 4 Answers

The Weirdest Bug Ever: GameObject Transform Appears in Editor to Be in One Spot but Instantiates and Registers in Another 2 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