Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Can someone help me to get the steering move faster?

Asked by 5 years ago

Hi I reconstructed a car from a youtube tutorial, but I want that the steering moves faster. I canĀ“t do it because im not good at scripting. I hope someone can help me!

This is the video: https://www.youtube.com/watch?v=hFGVlu-rs50

This is the script of the seat from the car

-- get the specifications local speed = script.speed.Value local accleration = script.acceleration.Value local steeringspeed = script.steeringSpeed.Value local steeringangle = script.steeringAngle.Value

-- set up the shortcuts local vehicle = script.Parent.Parent local seat = script.Parent

-- find the tires local A = vehicle.A -- front left local AA = vehicle.AA -- front right local B = vehicle.B -- back left local BB = vehicle.BB -- back right

-- find the steering mechanism local steerA = vehicle.SteeringA.Servo local steerB = vehicle.SteeringB.Servo

-- set up wheels' motor accerlation A.Motor.MotorMaxTorque = accleration AA.Motor.MotorMaxTorque = accleration B.Motor.MotorMaxTorque = accleration BB.Motor.MotorMaxTorque = accleration

while true do

-- power the wheels
velocity = seat.Throttle * speed -- use the seat's throttle to determine the wheels' action (backward? forward? nothing?)
A.Motor.AngularVelocity     = velocity
AA.Motor.AngularVelocity    = velocity
B.Motor.AngularVelocity     = -velocity
BB.Motor.AngularVelocity    = -velocity

wait()

-- steering
steering = seat.Throttle * speed
steerA.AngularSpeed = steeringspeed
    steerA.ServoMaxTorque = 1000
    steerA.TargetAngle = steeringangle*seat.Steer
steerB.AngularSpeed = steeringspeed
    steerB.ServoMaxTorque = 1000
    steerB.TargetAngle = steeringangle*seat.Steer

end

0
Maybe try editing the "steerA.ServoMaxTorque = 1000" and "steerB.ServoMaxTorque = 1000" to higher than 1k kom297 -4 — 5y

Answer this question