- Home /
Where are unitys scripts stored?
The wheel collider component doesn't cut the mustard for what I want to achieve so I am creating my own wheel collier script, however there are some components of the wheel collier script i want to keep such as the ray collision acting as a collider and I am not sure how this is done and could take me ages to work this out. So I want to be able to look at the wheel collider script so I can take the parts from it that I need. However where are the default unity scripts stored as I cant find them.
Does anyone know how to get their hand on them.
thanks Ken
Answer by Kryptos · Oct 10, 2012 at 09:29 AM
Components are not scripts. There are part of the engine. The WheelCollider class is merely an interface to code written inside the engine (which implementation is almost completely in C++ and hidden).
You cannot extract part of a component. If WheelCollider does not fit your needs, you will have to rewrite the whole thing. As you pointed out, this can take a while and is prone to bugs that will be difficult to solve.
I suggest you try to learn more about WheelCollider and find a way to make it match your needs. WheelCollider does offer a lot of variables that can be played with. And you can also add constraints using the other Physics components.
Thanks i guessed as much :(. i need my wheels to cope with multiple contact points so i cant see how i can get the original wheel collider to work like this.
Do the car tutorial. WheelCollider is not a collider like SphereCollider or BoxCollider. Its goal is only to simulate a spring.
Of course you will need other colliders on your vehicle such as spheres of the wheels and/or capsules on each side to simulate collision.
yeh i have, the problem is wheel collier cant cope with something touching multiple points on a wheel as it points in a given direction
Yes because it is not its purpose. Despite its name WheelCollider is not a collider. It is more like a raycast that is used to compute a torque. It simulates a point collision, because this is how wheel are simulated in physics system (non-penetrating collision between a circle and anything is always a point).
For collision detection, you will need to use additional "regular" colliders.
Answer by MarkFinn · Oct 10, 2012 at 08:46 AM
ProjectSaveDirectory\Assets\SamePathAsInEditor
Eg. In my project "Mapmaker" saved on the H: drive in "Unity Projects", the Character Controller Scripts from Standard Assets are in
H:\Unity Projects\MapMaker\Assets\Standard Assets\Character Controllers\Sources\Scripts
the wheel collider isn't like the standard assets that you can import into your project, its a component that you can add to an object so it not in the assets folder, im looking for the script behind this component.
Ah, sorry, I should have read more carefully. I suspect you are asking the impossible on this one. Such Unity components are not written in scripts, and the source for the engine containing them is not commonly available to developers in groups smaller than Cartoon Network.
Answer by Psyco · Oct 10, 2012 at 11:53 AM
my asset store items are in my c/users/roaming or local :P
Your answer
Follow this Question
Related Questions
My server wont start! 0 Answers
I have a problem with OnTriggerEnter 2 Answers