Hi,
I hope this is the right section. I’ve been trying to make some cars driveable. The problem with these cars is that their forward direction is set to Y instead of Z so the cars go forwards when I reverse and they go backwards when I accelerate. It is fixed by making the car GameObject a child object of an empty GameObject and rotating the car GameObject by 180 degrees. This rotation affects the wheels too, but only in play mode.
I tried that but they remain the same. It’s like the wheels locked to the same rotation as the car object.
Edit: interchanging the wheels seems to solve it. Now the wheels turn in in editor mode and look normal in play mode, but I’m sure that there is a more professional way to solve it, so I’m open to other ideas.
I see what you mean, that could work but I’m not quite sure where to change the script. I think the CalculateRevs method should be rewritten, I checked the documentation about the vector3.back, but I’m just way too new to coding and I can’t find out how to rewrite it to work properly (trust me I tried, I had pretty weird results, when I didn’t get errors). If you could help me a little further I would really appreciate it.
Sorry, that script sounds waaaaaay more complicated (calculate revs before calculating movement force?) than I’m up to. I’m just starting to code this year myself so atm I just play around with the simple bits. As a rule I don’t use other people’s scripts unless I understand everything they are doing as that way I know I will be able to tweak it as needed. Normally I just play around with building my own. It’s slow but I know what each bit is doing.
Maybe find where the keys are being called & swap them around e.g if they are using the arrow keys find where it is using keycode.downarrow & change it to up & vice versa
Oh, so you are a beginner too :). Well, it is a good approach to learn and most of the time I try to write my own scripts, it just seemed easier to grab the scripts from the Standars Assets. Probably I will never be able to write a physics script like that, but I wouldn’t have any problem with it if the cars had the right forward direction in the first place… Anyway, thank you for your time and help, I really appreciate it.