Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
2 captures
12 Jun 22 - 14 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 GlitchCrew · Oct 26, 2017 at 05:02 AM · car

Increase car controller acceleration

Hi, I want to add a car to my game with a simple arcade-style controls. I'm using the car controller from standard assets but the problem is that if I use default settings, car has pretty slow acceleration so it takes some time to reach desirable speed and stop if I use brakes. I want to have a car with not very high speed but with very high acceleration so that the controls feel more responsive.

So far I've tried increasing full torque over all wheels, reverse torque, top speed, setting car's mass to a low value and tweaking other settings but still, my car feels very heavy. Any advice is appreciated.

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

2 Replies

· Add your reply
  • Sort: 
avatar image
2

Answer by Honorsoft · Mar 17, 2018 at 09:02 PM

If you want to change the car physics(speed, acceleration, torque, etc.) there are settings that can be changed in the hierarchy of the wheels(WheelsHubs), there is also a script in the Scripts folder of the car's assets(CarController.cs). Those can be altered to try to get the results you're looking for.

I'm just working on this now. I originally started by making my own car (body, wheels, colliders, etc), but decided to try out the Standard Asset version of the Car controller and prefabs. At first, I was pleased at all the stuff that was done for me, such as brake lights, skid marks, engine pitch, etc. But after testing it a bit, found bunch of errors, glitches and flaws. Besides the unrealistic acceleration you mentioned, there is the skidding, sliding and spinning of the car when you try to turn, for some reason, Unity's default settings simulate driving a car on an extremely icy surface. There is also another flaw with the controller, if you come to a full stop using the handbrake, the car will 'lock-up' and you won't be able to drive forward until you drive in reverse first. Also the Diffuse texture for the car is missing, the low-deceleration audio clip is not assigned properly, and there's a few more errors that I found and am still finding, but those are the major ones so far. It's a shame, because it is hard to fix this complicated car system without knowing exactly how it works and all the math involved and how it interacts with everything. So you have a lot of work ahead, either spend a lot of time and study to fix Unity's car system, or spend a lot of time and study to make your own.

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 newcolours · May 03 at 01:22 PM 0
Share

Everything you mention here is accurate and baffling.

Did you ever make a solution for the car locking up after using the handbrake?

avatar image
0

Answer by Excelerator · Oct 26, 2017 at 07:53 AM

Add more force. Use an animation curve to map this force along velocity for more control.

Comment
Add comment · Show 2 · 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 GlitchCrew · Oct 26, 2017 at 08:09 AM 0
Share

How exactly can I do that?

avatar image Excelerator · Oct 27, 2017 at 07:22 PM 0
Share

Well it depends. I don't know anything about the car controller or when the force is added. If there is already a script, find where the add force funtion is. If it's only appliedwithin the wheel component, then you probably won't find it. You can still do it anyways with your own script. In your script, you reference your car body rigidbody, then use the rigidbody add force funtion to apply an offset force for each wheel. That offset would be the location of tire contact typically. The direction of force would be forwards or tangent of tire contact. You would then apply any logic to that amount of force depending if the tire is touching or if the throttle is applied. And then map out how much force you want via an animation curve along velocity. You just have to code one thing at a time untill you get what you want. If you choose a poorly made car controller asset, this is going to be more difficult or messy to code. But no matter what, as long as it uses PhysX, you are always allowed to use the add force function on your rigidbodies. You do this in fixed update.

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

74 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

Related Questions

UnitySteer, steering script for Unity3D 1 Answer

New to car race 1 Answer

script help gameobject to playercar 1 Answer

Car headlights effect 1 Answer

Wheel Collider - Mesh/Box Collider Problem 0 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