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
1
Question by Abacab · May 06, 2015 at 09:38 PM · c#unity 5rigidbody

Upgrading to Unity 5 messed up my Rigidbody Center of masses

Hello!

I recently upgraded my Unity to Unity 5 and with it the Rigidbodies changed to GetComponent.

Now my rigidbody center of masses are messed up. :(

 Vector3 temp = GetComponent<Rigidbody>().centerOfMass;
 temp.y = 0f;
 GetComponent<Rigidbody>().centerOfMass = temp;
Comment
Add comment · Show 10
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 RLin · May 07, 2015 at 01:16 AM 0
Share

What do you mean by "messed up?" What is wrong with the center of mass?

avatar image Abacab · May 07, 2015 at 05:38 AM 0
Share

$$anonymous$$y car seems to be kind of "floating" and not s$$anonymous$$dy at all. It is not stationary on the ground but rather looking like an inflatable bouncing castle.

avatar image Abacab · May 10, 2015 at 07:10 AM 0
Share

Did anybody have similar issues when upgrading to Unity 5?

avatar image tanoshimi · May 10, 2015 at 07:26 AM 0
Share

Not explicitly with centre of mass but, yes, I have a physics-heavy project that didn't upgrade nicely to 5.x. The Unity car tutorial doesn't either.

avatar image tanoshimi · May 10, 2015 at 09:01 AM 1
Share

I would personally never recommend anyone upgrade Unity versions midway through a project...

Show more comments

1 Reply

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

Answer by RLin · May 10, 2015 at 07:15 PM

The problem isn't your center of mass, it's that your rigidbody doesn't have enough mass. Unity 5 wheelcolliders require realistic values to function correctly. Your car is only 300kg; a real car is generally not too far above or below 1500kg. Using mass values that are too low is causing the bouncing.

Comment
Add comment · Show 11 · 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 Abacab · May 10, 2015 at 07:18 PM 0
Share

Same problem occurs with 1500.

alt text

alt text

screen-shot-2015-05-10-at-221750.png (20.5 kB)
screen-shot-2015-05-10-at-221833.png (52.3 kB)
avatar image Abacab · May 10, 2015 at 07:29 PM 0
Share

$$anonymous$$y wheel colliders look like this. Increasing the mass to 100 and 1000 didn't solve the problem.

alt text

screen-shot-2015-05-10-at-222831.png (36.4 kB)
avatar image RLin · May 10, 2015 at 09:10 PM 0
Share

Your suspension spring is way too low; the default values of 35000 spring should be used. $$anonymous$$eep the rigid body mass at 1500, change all the springs to 35000 spring and 6400 damper, and see what happens.

avatar image Abacab · May 10, 2015 at 09:13 PM 0
Share

Well now it just looks ridiculous, but I think that we are going in the right direction!

alt text

screen-shot-2015-05-11-at-001407.png (99.7 kB)
screen-shot-2015-05-11-at-001235.png (49.4 kB)
avatar image RLin · May 10, 2015 at 09:19 PM 0
Share

You can change the local y position of the wheelcolliders, and how far they extend downward so that it won't look "ridiculous."

Show more comments

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

21 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

Related Questions

RigidBody immediately stops after AddForce 1 Answer

the object of type rigidbody has been destroyed 3 Answers

How does instantiate connect to rigidbody?,How does instantiate userigidbody without getcomponent? 1 Answer

How can I pragmatically move a navmesh rigid body when changing scenes? 0 Answers

Rigidbody player keeps moving after AddForce has stopped? 3 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