while true do task.wait()for y,k in pairs(car:GetChildren())do if k.Name=="\084\104\114\117\115\116\101\114"then UpdateThruster(k)end end if car.DriveSeat.Occupant then local y=car.DriveSeat.Velocity.magnitude/stats.Speed.Value car.EngineBlock.Running.Pitch=1+y/4 bodyPosition.MaxForce=Vector3.new()bodyGyro.MaxTorque=Vector3.new()else local y,k,S=Raycast.new(car.Chassis.Position,car.Chassis.CFrame:vectorToWorldSpace(Vector3.new(0,-1,0))*stats.Height.Value)if y and y.CanCollide then bodyPosition.MaxForce=Vector3.new(mass/5,math.huge,mass/5)bodyPosition.Position=(CFrame.new(k,k+S)*CFrame.new(0,0,-stats.Height.Value+.5)).p bodyGyro.MaxTorque=Vector3.new(math.huge,0,math.huge)bodyGyro.CFrame=CFrame.new(k,k+S)*CFrame.Angles(-math.pi/2,0,0)else bodyPosition.MaxForce=Vector3.new()bodyGyro.MaxTorque=Vector3.new()end end end
--task.spawn(function()
while true do
	task.wait()
	for i, part in pairs(car:GetChildren()) do
		if part.Name == "Thruster" then
			UpdateThruster(part)
		end
	end
	if car.DriveSeat.Occupant then
		local ratio = car.DriveSeat.Velocity.magnitude / stats.Speed.Value
		car.EngineBlock.Running.Pitch = 1 + ratio / 4
		bodyPosition.MaxForce = Vector3.new()
		bodyGyro.MaxTorque = Vector3.new()
	else
		local hit, position, normal = Raycast.new(
			car.Chassis.Position,
			car.Chassis.CFrame:vectorToWorldSpace(Vector3.new(0, -1, 0)) * stats.Height.Value
		)
		if hit and hit.CanCollide then
			bodyPosition.MaxForce = Vector3.new(mass / 5, math.huge, mass / 5)
			bodyPosition.Position = (CFrame.new(position, position + normal) * CFrame.new(
				0,
				0,
				-stats.Height.Value + 0.5
			)).p
			bodyGyro.MaxTorque = Vector3.new(math.huge, 0, math.huge)
			bodyGyro.CFrame = CFrame.new(position, position + normal) * CFrame.Angles(-math.pi / 2, 0, 0)
		else
			bodyPosition.MaxForce = Vector3.new()
			bodyGyro.MaxTorque = Vector3.new()
		end
	end
end
