Hey there, just wanted to drop in and say thanks for this. Recently started doing stuff in Unity and this tutorial was very well put together. Quick, to the point and super easy to understand.
Thank you. Out of the ones I've seen, this tutorial seems the most fitting for my project and it's one of the simplest to do and understand as well. I think I'm gonna use it. It's really relieving to have found something I can work with because when I was given the task to make our car less janky, I was really stuck on how to do it. (At its current state, the car just goes sideways without turning when you press A or D so... It's dire and I didn't have much to work with.)
This is a fantastic video! I used this for my scooter, which has two wheels, and your video was so good and self-explanatory that I was able to make it work anyway.
Moving takes great time and energy i moved too, in start of september, noe finished yett XD :D Nice to see you live still :D This is what i missed and Loved the explanation and showing+testing etc :D i hope you maby do more on this :)
Hey its hard to explain but if you look at some tutorials to add a virtual camera machine its pretty simple and you can have the camera follow your object etc
Woah !!!!! What can I say that's probably has not been said in the comments already? Amazing tutorial, so simple so to the point, so useful. Thanks a lot! I will be going through the rest of your youtubes to see what other amazing tutorials have been missing all my life. Thanks again.
Finally.. a gpod tutorial.. thanks. Could u make a motorbike tutorial aswell? Nothing fancy (no need for humans).. i just wanna know how to get the bike to turn left and right and move forward
Thank for the great video! Helped me to get started very well. Issue I have is that when I place the wheel colliders and press Play, the wheels of my car-model change position (they move outwards a bit and the tire&rim, which are two separate assets, are disconnected. Any idea what the issue is and how to fix this? I can share some screenshots, but don't know how to share in YT comments..
For anyone struggling with the car moving really slow or not even budging (especially for Synty Asset Cars) play around with the wheel collider Y position and radius in game mode, I noticed if it is too large of a radius and or too low to the ground it causes the car to not move. Hope this helps :)
@@skourge891 Then I think u used reduce the size of the collider, I mean if t radius of the cars wheel is let just say 8 then use collider a litter but smaller than that, only a little bit so that it doesn't stuck in ground and also make sure to merge the movement of collider and mesh
@@gabbargamer2007 Yes, so in my original post, that's why I said to play around with the collider in game mode. Has nothing to do with the acceleration.
Hello, I’m around seven minutes in and have an issue regarding the wheel colliders. When I connected the wheel colliders to the serialize field my error said that wheel collider does not contain definition for ‘breakTorque’. Any help would be appreciated thanks. Nvm spelled brake wrong in the script. Jeez that was a headache lol
thanks for your video. The approach I need to take (for an assignment) is to make a two wheeled vehicle (like a box with wheels on left and right). Would this method work?
I have started influencing his vid ideas, soon I will be influencing his major decisions, soon I will take over this channel... all a part of the plan... he... he... he......
why tf the stupid wheel collider is always not in the correct orientation and why it couldn't be rotated? the wheel is always facing the collider by its side and it can't be rotated
this is awesome! thank you so much for making this. it was so cool seeing my car basically come to life thanks to your video. The only thing I'm struggling with is getting the car to move any faster? I've bumped up the acceleration to 5,000 and it barely speeds up. I dropped the mass down to 500. All of the wheels are spinning the correct way. Anyone find a fix for this? I saw someone else in the comments say their car was moving like it's in pudding. That's where I'm at. Once I fix this I'll be in the clear.
Hey Quick Question, when you release the up or down keys, the car still stays the same speed, which makes sense, since you only control the acceleration and not the speed. Is there a way to make the car loose speed when the buttons are released? Thank you very much for the video, it really helped me out!!
If anyone is having trouble getting the car to move, try turning the mass down a bit. I'm using Synty assets and my mass is set to 200. I also adjusted Acceleration to 100 and braking force to 60 but I'll play with those values later on. Also, if anyone wants to use the new update system, just change the currentAccleration = acceleration * Input.GetAxis("Horizontal"); to currentAcceleration = acceleration * inputAction.YourActionMapName.YourVector2BindingName.ReadValue().y;
Hi Travis Thank you for that comment, I actually ran into this issue, the car is moving like a pudding. It hops a little bit forward, but it doesn't stay on the road and just move forwards. Do you have any other advice? I used mass 90, accelleration 100 and breakingForce 60. When putting mass down, then it moves upwards.. Also I wanted to ask you, what do you mean with the new update system? Actually I didn't used the asset from b3agz, I used another car with 4 wheels - much more simple than this one. But should work as well, shouldn't it? Many regards
@@katvivala873 I meant the new input system, not update. Just a typo in my part. Without seeing your code, I couldn’t say what’s going on with your movement. But yes, another car asset should also work, I also used a different one
@@TMosier88 Thanks for replying. Well I used the same code as he did, but maybe there is something else wrong with rigidbody or colliders. I think my issue is, that the wheels are rolling in the wrong way.. the back one's are going backward and the front are moving in front. Do you maybe now how to change it? As the rotation didn't help I'm a little lost. Or maybe you, @b3agz ? Many thanks, Kat
Been following the exact same steps, wheels' location and rotation is 0,0,0 and applied in Blender. Unpacked the mesh. Wheels keep floating 2 meters or so next to where they are supposed to be after I add the UpdateWheel function. I just can't figure out where this bs is misbehaving from :( Other than that, good vid!
Hello! Thank you for the tutorial. I am having trouble with the mesh attaching to the collider, the wheels are connected , but they are rotated 90 degrees compared to how they should be. Is there a fix to this?
Hi, I managed to fix mine. I had to APPLY the rotation on my cars wheels in blender so that all of them where 0, 0, 0. After that I exported it to unity and it was fixed.
First of all, thank you for this video. It's well done. But I have a problem. Everything seems to work fine except that my wheels rotate in big circles around their axis rather than just rotate around their own axis. Any idea how to fix this? I think this is probably an issue within blender rather than unity maybe?
@@allblakesmusic1606 yeah, had to adjust the origin of the wheels. I had it in the center of the car, so I adjusted it to the center of the wheel itself and reimported the model. Worked for me.
At 7:44, how did you add the properties (Front Right, Front Left....) to the Wheel Controller (Script)? When I dragged the WheelController script to the inspection, I couldn't see these properties in mine. I'm stuck here
my wheel meshes ceep snapping on the wrong axis how do i fix that the code works because it worked on other wheels when i tried but the wheels im trying now keep snapping to the wrong axis
I have the same car, same settings, same code and the car is not moving at all. anybody? Mass 1000, wheel collider's radius is much smaller because the model's size I want to use is smaller. What could be the issue? I have already tried to move another car with wheel colliders and did not move at all. Two cars did not move. I have no idea what is wrong.
Hi,I just tried this and works very well but I have a problem,when I press W it goes back and when I press S it goes forward(I put all the colliders right)
Hello b3agz, when i set up my wheel meshes to follow the wheel collider, they went far off to the side and when they are rotated they go in a large circle, please help!
Hi! Thank you for your great work on that tutorial. I have a question - How to deccelerate when verticals are not pressed. Cuz if I press W for like 2 sec car is still running and won't stop. Any advice? Should I add if statement and apply break force if not pressed?
Ok. It's not that case. I've noticed that even doe I'm not pressing W or S the wheels are still spinning round and round. I guess it has to do with friction but for now I can't setup that right...
Thanks man! Only issue what i have is that my car (own model) goes slighty to the left when i go forward (havent messed with the left/right movement)..
Hello! i tried putting the wheels on the new game object we created but it says that i cant move children of a prefab...Do you know how i can fix that?
I'm having an error so far: Non-convex MeshCollider with non-kinematic Rigidbody is no longer supported since Unity 5. If you want to use a non-convex mesh either make the Rigidbody kinematic or remove the Rigidbody component If I check the "Is kinematic" box the car doesn't fall anymore. What do?
If you just wanted it to go forward all the time, remove the if statement where we check for the player pressing the acceleration button and have the code inside just be called every update.
I’m following fine until we add rotation to the wheels. The wheels float well outside the car and spin in big circles to the side, as though they’re orbing the car or rotating around another axis as opposed to in place. Not sure what to do with it, all my code matches up.
For anyone with my issue or a similar one, it’s related to the pivot point of the wheels. I downloaded an asset where all 4 wheels picot around the center of the car, not the center of each wheel. You can fix this by changing the pivot of each wheel. 👍
The mechanics will work the same yeah. You just need to swap out keyboard input for some kind of oculus control. I believe you can get direct axis info from the touch controllers but prob wouldn't be very intuitive if you didn't do something a little more fancy.
Not a lot you can do with that, unfortunately. You can either have the "wheels" be invisible and unconnected to the card (there won't be any visible spin or turning though) or you can crack open Blender and try and separate the wheels. Or use a different model.
This is because he used "break" in a lot of his spelling BUT when calling the application's variables he HAS to use "brakeTorque" NOT "breakTorque" and hence the error when making a call to the physics system.
I set acceleration 50000000f but still my car moving very slow, don't know what the problem is, I didn't change the friction or other things I just follow this video only.
Try creating an empty game object for each wheel and having the code reference the empty object instead of the wheel directly. Then make your wheels children of the respective empty objects and set their local position so they're in the right place.
Hi there ! Trying to follow this as a very first Unity tutorial and I would have loved just a little more basics stuff ! I'm actually struggling to import the car properly into Unity. I don't have all your folders, the wheel meshes and all that and I can't find them in the car folders as well