First Time Here. I wish to create a driving game where I sit behind the steering wheel. I searched this forum for messages related to driving games but most of the driving games have views outside of the car. I tried Unreal Development Kit (UDK) but it’s too hard for me. Any suggestions?
Do you know the basics of Unity?
I searched for tutorials on creating driving games and downloaded a few driving games. One tutorial showed me how to import a 3D model of a car into Unity Editor but it doesn’t show me how to add a camera to the car to simulate me sitting behind the steering wheel and the 3D model doesn’t have interior.
First go here:
http://www.gotow.net/andrew/blog/?page_id=78
and download the tutorial file. Then, remove the smooth follow script from the main camera and make the camera a child of the Player car. Move the camera to the proper location (just above the hood) and Bob’s your uncle.
Better yet: create a new camera and position that one as described and then use the switch camera script (from the Unify Wiki) to be able to switch back and forth from first person to second person perspective.
Bob, Thanks for helping me. Is it possible for me to turn the camera to simulate the driver looking left and right for traffic at stop signs?
Add the mouse look script to the camera. The player will be able to look around with the mouse while controlling the car with the wasd keys. Play with the max/min X and Y until it looks good.
Oh and the name is Brad, not Bob.
What about putting a transmission in the car so that I have to press keys to put the car in “Drive”, “Neutral”, and “Reverse” before I can drive the car?
Find wherever you are getting your key inputs for wasd and add a AND statement. For example:
If (Input.GetButton (“w”) (shiftTrans == “f”)
The bigger question from the player’s view is - Why would you want to do this? Does it add to the fun?
“Oh shit, I forgot to put it in reverse” is not fun. Plus, if the player is already using the directional keys to steer and the mouse to look around, what hand would they use to shift?