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 stick_penguin · Aug 20, 2013 at 03:30 PM · collidersfrictiontorquewheels

Quick question about wheel colliders

On my vehicle, I have four wheel colliders. I want to be able to delete the colliders on the right side of the vehicle, and still have to vehicle drag itself around on the remaining wheels. However, the vehicle does not move at all if the main body is touching the ground. Any ideas on how to fix this? (I am still setting the right torque and everything for the remaining wheels.

Comment
Add comment
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

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by fred_gds · Aug 21, 2013 at 10:45 PM

Well I am wondering if your wheels are still touching the ground as it seems to me as they might have flipped with car so if you have mesh colliders on the wheel tires the wheel collider might not touch the ground anymore.

If that's not the case i'd guess that in your case the Force of friction is bigger then the force your wheels are applying. Just as in real life. If your car looses two wheels it won't drive anymore.

I see two ways how you could approach your problem. So first would be the make a script which will prevent your car body to touch the ground. But I'm not sure how to approach it. Maybe smth like this:

function OnCollisionEnter() { mainBody.transform.position.y = ground.position.y + 0.0001; }

or smth like this to prevent them from colliding

function Upate() { if(mainBody.transform.position.y < ground.position.y + 0.0001) { mainBody.transform.position.y = ground.position.y + 0.0001;} }

or the other way you could do it which might work is that when you delete the two wheels, you create small wheels which will just fit under the right side of the body so that they prevent the car from touching th ground. I think that this might be the best way to keep the car behavior realistic as you are able to modify the friction and/or brake torque of these "new" wheel(s) to make the car pull to the right side (You can do this too with the first option but I think, that that will be more complicated ).

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 Benproductions1 · Aug 21, 2013 at 10:46 PM 0
Share

Please format your code

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

17 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

Related Questions

Friction Issue with Multiple Colliders Touching 0 Answers

Why vehicle decelerate on steerAngle 0 Answers

How to apply frictional Torque 2 Answers

Fast motion of vehicle 0 Answers

Calculating Sphere vs. Plane Friction 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