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 LilRoseJJS · Feb 05, 2017 at 06:35 AM · rigidbody2drigidbody physics

How to use Automass?

Hi everyone,

I'm sure that I'm missing something very simple, but I can't get auto mass to work in my 2D game. I know that auto mass is density times area of the collider. This is what I have. I always get that mass value of 1. How do I find my auto mass value?

alt text

screenshot-71.png (33.5 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 oStaiko · Feb 05, 2017 at 08:15 AM 0
Share

Have you tried changing the value for Density yet...? I just made a new scene with the same set up, and changing the density also changed the mass. I$$anonymous$$O, unless you got some real complex stuff going on like random generation, just use regular mass.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by MelvMay · Feb 05, 2017 at 10:31 AM

A Collider2D set to be a trigger does not affect the center-of-mass or rotational inertia and as such doesn't affect the calculated mass. This has always been the case for both 2D and 3D.

From your image, the only collider you have is to set be a trigger therefore it's not part of any auto-mass calculation so the mass defaults to 1 (the same as if no collider were added). You'll also notice in the Rigidbody2D 'Info' roll-out that the center-of-mass and rotational inertia are at defaults.

Try temporarily turning off the IsTrigger and you should then see that the Collider2D.density property appears and that the Rigidbody2D.mass is calculated accordingly.

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

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

How to instantly accelerate a falling game object to the maximum fall speed? 2 Answers

Rigidbody2D.position and Rigidbody2D.MovePosition() 0 Answers

Kinematic vs. non-kinematic movement over a curve 0 Answers

Rigidbody2D constraints checked for x and y but still moves when character jumps on it from distance 0 Answers

How to fix bouncing, jittery effect between two dynamic objects in 2D 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