car
{
   name=Volkswagen Passat Variant 2.0 TFSI
  year=2009
  credits=Converted by AmgFan. 0-100km/h in 7.8s, top 231 km/h
  comments=VW 2.0 TFSI DOHC turbocharged 16V, 200hp @ 5100rpm, 280Nm @ 1500-5000rpm
   wheels=4
  id=passat20
  version=090b
  skid
  {
    sample=skid.wav
  }
  shadow
  {
    texture=shadow.tga
    width=2.4
    length=5.06
    offset_z=-0.06
  }
 cg
 {
  x=0
  y=-0.15
  z=0.0
 }
  ff_factor=0.45
}
body
{
  mass=1440
  inertia
  {
    x=2300
    y=2400
    z=475
  }
  model
  {
    file=passat.dof
  }
  model_incar
  {
    file=passat.dof
  }
  model_light_l
  {
  file=lights.dof
  }
	model_braking_l
	{
		file=brakes.dof
	}
 model_lightroad_l
 {
  file=lightsin.dof
 }
  model_reverse_l
  {
    ; Reverse gear indicators
    file=re.dof
  }
  model_reverse_r
  {
    file=re.dof
}
  width=2.145
  height=0.75
  length=4.796
  manual_box=1
}
steer
{
  x=0.45
  y=0.31
  z=0.44
  radius=15
  xa=15
   lock=1080
  linearity=0.3	;0.325	;3 turns lock to lock = 1080 degrees 15.4:1 steering ratio
  model
  {
      file=str.dof
  }
}
particles
{ 
backfire
{
exhaust0
{
pos=0.52 -0.29 -2.37
normal=0 0 -1
} 
exhaust1
{
pos=0.42 -0.29 -2.38
normal=0 0 -1
} 
type=backfire
; type=backfire_long
min_rpm=6800
; min_rpm=0
; suppose car comes from 9000 rpm for example. Then backfiring can happen when max_rpm is reached
max_rpm=7000
; hi2h backfire likeliness for rally cars
likeliness_percentage=130
; likeliness_percentage=100
}
}

flares
{
  ; outer lamps
  flare0
  {
    pos=-0.71 0.1 1.94
    color=1.0 0.8 1.6
	normal=0.05 0 1
	z_offset=-2500
	size_factor=0.7
	intensity=0.7
        hor_scale=0.7
  }
  flare1
  {
    pos=0.71 0.1 1.94
    color=1.0 0.8 1.6
	normal=0.05 0 1
	z_offset=-2500
	size_factor=0.7
	intensity=0.7
        hor_scale=0.7
  }
  flare2
  {
    pos=-0.68 -0.21 2.09
    color=1.0 0.7 0.55
	normal=-0.05 0.1 0.6
	z_offset=-3000
	size_factor=0.6
	intensity=1.0
  }
  flare3
  {
    pos=0.68 -0.21 2.09
    color=1.0 0.7 0.55
	normal=0.05 0.1 0.6
	z_offset=-3000
	size_factor=0.6
	intensity=1.0
  }
  ; Brake lights
  flare4
  {
    rule=brake
    pos=-0.72 0.3 -2.20
	normal=-0.05 0 -0.5
	color=1.0 0.0 0.0
	size_factor=0.8
	intensity=0.8
	z_offset=-1000
  }
  flare5
  {
    rule=brake
    pos=0.72 0.3 -2.20
	normal=0.05 0 -0.5
	color=1.0 0.0 0.0
	size_factor=0.8
	intensity=0.8
	z_offset=-1000
  }
  ; Rear lights
  flare6
  {
    pos=0.5 0.31 -2.28
	normal=-0.05 0 -0.5
	color=1.0 0.0 0.0
	size_factor=0.7
	intensity=0.7
	z_offset=-1000
  }
}

lights
{
  ; Projected lights
  light0
  {
    texture=light.tga
    ; Field of view (vertical)
    fov=65
    ; Aspect (horizontal)
    aspect=3
    ; Distance to car
    z=1.5
    ; Pitching with respect to car (in degrees)
    pitch=-2
    ; Fall-off distance
    far=300
  }
}

engine
{
	x=0
	y=0
	z=0
	size=0
	mass=150
	idle_method=1
	idle_throttle=0.05
	idle_rpm=900
	min_warn_rpm=6700
	max_warn_rpm=7000
	max_rpm=7000
	start_rpm=1300
	stall_rpm=450
	autoclutch=1
	autoclutch_rpm=
	starter=1
	starter_torque=100
	start_stalled=1   ;1
	enable_stall=1
	curve_torque=torque.crv
	max_torque=0.92
	torque_reaction=0.25
	braking_coeff=
	braking_offset=
	braking_torque_curve=braking_torque.crv
	friction=0
	cylinders=4
	cylinder_angle=0
	rumble_amplitude=
	rumble_maxrpm=
	inertia
	{
		engine=0.38
	}
	jitter
	{
		amplitude=0.2
		frequency_min=1
		frequency_var=0.1
		time_min=150
		time_var=10
	}
	shifting
	{
		automatic=1
		blip_throttle=0.3
		cut_throttle=1
		fast=1
		shift_up_rpm=6100
		shift_down_rpm=2600
		time_to_declutch=55
		time_in_neutral=75
		time_to_clutch=55
		time_to_declutch_down=75
		time_in_neutral_down=75
		time_to_clutch_down=75
	}
}

fuel
{
	bsfc=6.5e-5
	max=70
	type=0
}
gearbox
{
   gears=7
   gear0
   {
      ratio=-3.938
      inertia=0.1
   }
   gear1
   {
      ratio=3.36
      inertia=0.01
   }
   gear2
   {
      ratio=2.09
      inertia=0.02
   }
   gear3
   {
      ratio=1.47
      inertia=0.03
   }
   gear4
   {
      ratio=1.1
      inertia=0.04
   }
   gear5
   {
      ratio=1
      inertia=0.05
   }
   gear6
   {
      ratio=0.93
      inertia=0.04
   }
}
clutch
{
   max_torque=500
}
handbrakes
{
   wheels=23
}
differential
{
	type=1
	ratio=3.5
	inertia=0.05
	locking_coeff=0
          	output0=0
	output1=1
}
aero
{
  body
  {
    center=0 0 0
    cx=0.30
    area=2.29		
  }
  wings=1
  wing0
  {
    name=Overall aerodynamic effect R
    span=1
    cord=0.1
    coeff_drag=0
    coeff_down=8.5
    center=0 0.03 -1.38
    angle=0
    angle_offset=1
  }
}
antirollbar
{
  count=2
  arb0
  {
    susp_left=1
    susp_right=0
    k=21000 ;36600
  }
  arb1
  {
    susp_left=3
    susp_right=2
    k=16000  ;21800
  }
}
susp_front                    
{
  y=-0.015
  z=1.36
  restlen=0.332		;245mm,288.2kg/2826N, 12.5cm ground clearance
  minlen=0.17
  maxlen=0.34
  k=41000 	;k=m(nf/0.159)sq NF ~ 1.7 ~ 36936N/m
  bump_rate=1300	;1283*1.0
  rebound_rate=4950	;6163*0.8
  bump_function=0
  bump_max=1300
  rebound_function=0
  anti_pitch=0.09
  camber_change_per_m=0
  roll_center
  {
    x=0
    y=-0.78	;-1.5cm
    z=0
  }
}
susp_rear
{
  y=0
  z=-1.354
  restlen=0.331		;255mm, 366.8kg/3597N
  minlen=0.125
  maxlen=0.34
  k=50000 	;k=m(nf/0.159)sq NF ~ 1.8 ~ 58036N/m
  bump_rate=1800	;1814*1.0
  rebound_rate=6650	;8305*0.8
  bump_function=0
  bump_max=1800
  rebound_function=0
  anti_pitch=0.14
  camber_change_per_m=0.45	;2.3 degree per 0.1m deflection!
  roll_center
  {
    x=0
    y=-0.731		;6.5cm
    z=0
  }
}
susp0~susp_front
  {
    x=0.84
    toe_change_per_m=0.029		;-0.23 static toe. 0.13 degrees change with 0.078m travel. Bump out to ~0.1 toe.!
    camber_change_steering=0.1062	;using caster angle 5.78 degrees @ max_lock, outside wheel camber wrt y axis = 3.54 degrees!
    caster_offset=0		;5.78 degrees static caster -0.017!
    
  }
susp1~susp_front
  {
    x=-0.84
    toe_change_per_m=-0.029		;-0.23 static toe. 0.13 degrees change with 0.078m travel. Bump out to ~0.1 toe.!
    camber_change_steering=-0.1062	;using caster angle 5.78 degrees @ max_lock, outside wheel camber wrt y axis = 3.54 degrees!
    caster_offset=0		;5.78 degrees static caster -0.017!
  }
susp2~susp_rear
  {
    x=0.84
    toe_change_per_m=0.019		;-0.27 static toe. 0.1 degrees change with 0.09m travel. Bump out to ~0.2 toe.!
  }
susp3~susp_rear
  {
    x=-0.84
    toe_change_per_m=-0.019		;-0.27 static toe. 0.1 degrees change with 0.09m travel. Bump out to ~0.2 toe.!
  }
tire_model_front
{
  damping_predict_lat=0
  damping_predict_long=0
}
tire_model_rear
{
  damping_predict_lat=0
  damping_predict_long=0
}
pacejka
{
    a0=1.2
    a1=-25
    a2=1200
    a3=2000
    a4=9
    a5=0.015
    a6=-0.25
    a7=0
    a8=-0.03
    a9=-0.001
    a10=-0.15
    a111=-8.5
    a112=-0.29
    a12=17.8
    a13=-2.4
    b0=1.3
    b1=-40
    b2=1250
    b3=20
    b4=325
    b5=0.08
    b6=0
    b7=0.05
    b8=-0.025
    b9=0.015
    b10=0.4
    b11=-50
    b12=0
    c0=2.2
    c1=-4
    c2=-3
    c3=-1
    c4=-7
    c5=0.0
    c6=0.0
    c7=0.044
    c8=-0.58
    c9=0.18
    c10=0.043
    c11=0.048
    c12=-0.0035
    c13=-0.18
    c14=0.14
    c15=-1.029
    c16=0.27
    c17=-1.1

    optimal_slipratio=0.12
    optimal_slipangle=0.173
}
wheel_front
{
  y=0
  z=0
  steering=1
  lock=55
  mass=30
  inertia=1.5
  radius=0.31
  width=0.205
  powered=1
  rolling_coeff=0.0180
  friction_road=1
  max_braking=1700
  braking_factor=1
  tire_rate=265000
  pacejka~pacejka
  {
  }
}
wheel_rear
{
  y=0
  z=0
  steering=0
  mass=30
  inertia=1.5
  radius=0.31
  width=0.205
  powered=0
  rolling_coeff=0.0205
  friction_road=1
  max_braking=500
  max_handbrake_torque=1900
  braking_factor=1
  tire_rate=265000
  pacejka~pacejka
  {

  }
}
wheel0~wheel_front
{
  x=0
  ackerman=1.1
  toe=-0.36
  camber=-0.2
  model
  {
    file=lf.dof
  }
  model_brake
  {
    file=caliper_left.dof
  }
}
wheel1~wheel_front
{
  x=0
  ackerman=1.1
  toe=0.36
  camber=-0.2
  model
  {
    file=rf.dof
  }
  model_brake
  {
    file=caliper_right.dof
  }
}
wheel2~wheel_rear
{
  x=0
  toe=-0.37
  camber=-.1
  model
  {
    file=lf.dof
    offset
    {
    x=-0.014
    }
  }
  model_brake
  {
    file=caliper_left1.dof
  }
}
wheel3~wheel_rear
{
  x=0
  toe=0.37
  camber=-.1
  model
  {
    file=rf.dof
    offset
    {
    x=0.014
    }
  }
  model_brake
  {
    file=caliper_right1.dof
  }
}
camera0
{
  name=Driver
  fov=74
  model=1
  view=0
  wheels=0
  offset
  {
    x=0.45
    y=0.56
    z=-0.10
  }
  offset_to
  {
    x=0.38
    y=-0.2
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera1
{
  name=Driver, left
  fov=65
  model=1
  wheels=0
  view=1
  offset
  {
    x=0.45
    y=0.56
    z=-0.10
  }
  offset_to
  {
    x=10
    y=0.5
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera2
{
  name=Driver, right
  fov=55
  model=1
  wheels=0
  view=1
  offset
  {
    x=0.45
    y=0.56
    z=-0.10
  }
  offset_to
  {
    x=-10
    y=0.5
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera3
{
  name=Driver, rear
  fov=-65
  model=1
  wheels=0
  view=0
  offset
  {
    x=-0.15
    y=0.56
    z=-0.10
  }
  offset_to
  {
    x=-1
    y=0.5
    z=-10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera4
{
  name=Chase
  fov=60
  model=0
  view=0
  wheels=0
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  offset
  {
    x=0
    y=-0.8
    z=-6
  }
  angle
  {
    x=10
    y=180
    z=0
  }
}
camera5
{
  name=Exterior
  fov=60
  model=0
  view=0
  wheels=0
  follow
  {
    pitch=0
    yaw=0
    roll=0
  }
  offset
  {
    x=0
    y=-0.5
    z=-5
  }
  angle
  {
    x=10
    y=130
    z=0
  }
}
camera6
{
  name=Rear chase
  fov=60
  model=0
  view=0
  wheels=0
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  offset
  {
    x=0
    y=-0.8
    z=-6
  }
  angle
  {
    x=10
    y=0
    z=0
  }
}
camera7
{
  name=FrontWheel
  fov=60
  model=0
  view=0
  wheels=0
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=1.4
    y=0.06
    z=-0.5
  }
  angle
  {
    x=-2.25
    y=-161
    z=3.3
  }
}
camera8
{
  name=Far
  fov=20
  model=0
  view=0
  wheels=0
  follow
  {
    pitch=0
    yaw=0
    roll=0
  }
  offset
  {
    x=0
    y=-0.5
    z=-20
  }
  angle
  {
    x=10
    y=50
    z=0
  }
}
camera9
{
  name=Hood
  fov=60
  model=0
  wheels=0
  view=0
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=0
    y=-1.0
    z=0.1
  }
  angle
  {
    x=5
    y=180
    z=0
  }
}

;	------------------ 5.1 ALPHA AUDIO COMPATABILTY -----------------

audio
{
  skid
  {
    sample=skid.wav
  }
  acc_all
  {
    attack=1000
    decay=1000
  }
  accelerate_out
  {
    smp0~audio.acc_all
    {
      sample=idle.wav
      volume=0.45
      min=300
      max=1500
      attack=50
      decay=800
      natural=800
    }
    smp1~audio.acc_all
    {
      sample=ajv8_2000.wav
      min=1000
      max=7000
      natural=4000
      attack=1000
      decay=1000
      volume=0.15
}
    smp2~audio.acc_all
    {
      sample=7000.wav
      min=1000
      max=7000
      natural=5500
      attack=1000
      decay=1000
      volume=0.3
}
    smp3~audio.acc_all
    {
      sample=turbo2.wav
      min=2700
      max=3901
      natural=1500
      volume=0.1
    }
    smp4~audio.acc_all
    {
      sample=turbo3.wav
      min=4000
      max=8501
      natural=2500
      volume=0.1
    }
  }
     }  
  decelerate_out
  {
    smp0~audio.acc_all
    {
      sample=idle.wav
      volume=0.45
      min=300
      max=1500
      attack=50
      decay=800
      natural=800
    }
    smp1~audio.acc_all
    {
      sample=ajv8_2000.wav
      min=1000
      max=7000
      natural=4000
      attack=1000
      decay=1000
      volume=0.25
}
    smp2~audio.acc_all
    {
      sample=7000decc.wav
      min=1000
      max=7000
      natural=5500
      attack=1000
      decay=1000
      volume=0.2
}
    smp3~audio.acc_all
    {
      sample=turbo2.wav
      min=2700
      max=3901
      natural=1500
      volume=0.1
    }
    smp4~audio.acc_all
    {
      sample=turbo3.wav
      min=4000
      max=8501
      natural=2500
      volume=0.1
    }
}       
  accelerate_in
  {
    smp0~audio.acc_all
    {
      sample=idle.wav
      volume=0.45
      min=300
      max=1500
      attack=50
      decay=800
      natural=800
    }
    smp1~audio.acc_all
    {
      sample=ajv8_2000.wav
      min=1000
      max=7000
      natural=4000
      attack=1000
      decay=1000
      volume=0.45
}
    smp2~audio.acc_all
    {
      sample=7000.wav
      min=1000
      max=7000
      natural=5500
      attack=1000
      decay=1000
      volume=0.5
}
    smp3~audio.acc_all
    {
      sample=turbo2.wav
      min=2700
      max=3901
      natural=1500
      volume=0.1
    }
    smp4~audio.acc_all
    {
      sample=turbo3.wav
      min=4000
      max=8501
      natural=2500
      volume=0.1
    }
  }  
  decelerate_in
  {
    smp0~audio.acc_all
    {
      sample=idle.wav
      volume=0.45
      min=300
      max=1500
      attack=50
      decay=800
      natural=800
    }
    smp1~audio.acc_all
    {
      sample=ajv8_2000.wav
      min=1000
      max=7000
      natural=4000
      attack=1000
      decay=1000
      volume=0.45
}
    smp2~audio.acc_all
    {
      sample=7000decc.wav
      min=1000
      max=7000
      natural=5500
      attack=1000
      decay=1000
      volume=0.5
}
    smp3~audio.acc_all
    {
      sample=turbo2.wav
      min=2700
      max=3901
      natural=1500
      volume=0.1
    }
    smp4~audio.acc_all
    {
      sample=turbo3.wav
      min=4000
      max=8501
      natural=2500
      volume=0.1
    }
  }  
  gearwhine
  {
    smp0~audio.acc_all
    {
      sample=tw-extonhigh.wav
      volume=0.05
      min=1
      max=2
      decay=1000
      natural=500
    }
  }
  wind
  {
    smp0~audio.acc_all
    {
      sample=wind.wav
      volume=0.8
      min=11
      max=150
      attack=10
      natural=50
    }
  }
 skid
  {
    volume=1
    smp0
    {
      volume=1
      sample=skid.wav
      min=0.4
      max=1
      attack=0.35
      decay=1.0
    }
    smp1
    {
      volume=1
      sample=skid.wav
      min=0.9
      max=20
      attack=.7
      decay=0
    }
  }
}
abs
{
  enable=1
  max_velocity_ratio=1.09 
  min_velocity_ratio=1.08
  min_velocity=1
}
traction_control
{
  	enable=1
  	min_velocity=1.667
  	max_velocity_ratio=1.050
  	min_velocity_ratio=1.300

}