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
0
Question by Panopolos · Dec 10, 2012 at 05:53 AM · physicsrigidbodygravityscalingunits

What should my gravity be if I've modeled in feet and inches in Max?

Hi all,

I've been doing modelling in 3DS Max for a while now, mostly dealing with special effects and architecture. As a result, I've been modelling things in real world American scale, feet and inches with units set to 1 unit = 1 inch.

I know in Unity, units only matter when physics are involved. I want to use the physics engine, so I'm wondering what I need to set my gravity to if I want it all to work swimmingly. Any thoughts?

Additional information: Oddly, even though things are set to real-world scale, when I import them into Unity, everything is weird. A 5'4" human comes up to be about a third of a unit in Unity rather than closer to two units as expected. In FBX export, if I change the Units setting from Automatic to Meters, my human comes in super, super tiny. Maybe a couple of relative inches. I don't know exactly what's happening to my scaling here, either.

Comment
Add comment · Show 2
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 Fattie · Dec 10, 2012 at 08:25 AM 1
Share

you will save yourself an incredible amount of trouble, if you model in meters and kilograms

(note that I feel "the metric system is for idiots who can't divide by 12" and I only use the British Imperial system in day to day life. Nevertheless, you're just hurting yourself by not using meters and $$anonymous$$G in Unity.)

in feet, gravity is of course 32.174 ft/s2

regarding importing scale, it is an endless problem for everyone. you may not have noticed there are various "scale" thingies on the "import" panel, inspector. if you click on the asset - sometimes but not always that helps :O

avatar image Panopolos · Dec 10, 2012 at 05:24 PM 0
Share

I don't see that happening, to be honest.

1, because I don't want to have to keep switching back and forth between units systems when I do architectural work.

2, because doing so with current models requires me to scale them down and when it comes to CAT-rigged models, even scaling with the rig resizer can be a huge headache with stretching and bones getting out of place. Ugh.

3, because I have almost no mental concept of how long meters are. I know, it's approximately 3 feet. But I'm going to have to relearn my sense of distance and scale if I do this.

And this is from a guy who thinks the US should exclusively use the metric system moving forward :P

However, thank you for the other leads. I did fix my problem by writing an editor script to set my default import scale for FBX to 0.054, which I settled on after a little trial-and-error and a little maths. Now everything is co$$anonymous$$g in at a "close enough" size and should work famously for the physics system, as my 5'4" character's collider surrounds her closely with a height of 1.63 units, or 163 theoretical centimeters.

Thanks!

3 Replies

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

Answer by Paulius-Liekis · Dec 10, 2012 at 11:06 AM

You can adjust size of imported object by changing import scale. I would recommend doing that - it will be easier to set up physics.

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 Panopolos · Dec 10, 2012 at 05:27 PM 0
Share

Yes, thank you. This is exactly what I needed to do.

I also wrote an editor script to make sure the import scale is uniform across all imported objects by changing the default.

Here's the script in case anyone is having the same issue. It's in C# and goes in Assets/Editor.

avatar image
0

Answer by Panopolos · Dec 10, 2012 at 06:12 PM

 using UnityEditor;
 
 public class FBXScaleFix : AssetPostprocessor
 {
     public void OnPreprocessModel()
     {
         ModelImporter modelImporter = (ModelImporter) assetImporter;                    
         modelImporter.globalScale = 0.054f;          
     }   
 }
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
0

Answer by Imankit · Dec 25, 2012 at 03:20 PM

I don't think you have to change any gravity hee.. Gravity only produces acceleration towards ground and is regardless of you model's metres or inches... It depends upon the mass of the object...

And in unity whenever a fbx is imported it automatically scales to 0.01.. Change it to 40 if you want inches to be in metres..

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

11 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

Related Questions

Physics gravity appears very weak 2 Answers

How to make a object jump constantly at y and move to the next position to z (perfectly) 0 Answers

How can I turn on/off Rigidbody.useGravity? 0 Answers

How to make rigidbodies on each side of a cube fall towards the cube? [multiple gravity / addForce] 0 Answers

My objects keep falling through 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