car
{
  name=Mercedes Vario
  year=1999
  credits=Converted from GTA SA by Priban.
  comments=4.2L 129 HP  
  id=mercedes_vario
  version=0655
  wheels=4

  skid
  {
    sample=skid.wav
  }

  shadow
  {
    texture=shadow.tga
    width=1.92
    length=5
    offset_z=0.1
  }

 cg
 {
  x=0
  y=-0.22
  z=0.1
 }
  ff_factor=0.45
}


;----------------------------------------------------------------------
;Body:}
body
{
  mass=3200	
  restitution_coeff=0.1
  inertia
  {
    x=3000
    y=3900
    z=640
  }
  model
  {
    file=vario.dof
  }
  model_incar
  {
    file=
  }
  model_light_l
  {
    file=l
  }
  model_braking_l
  {
    file=
  }
  width=1.81
  height=1.18
  length=6.5
  manual_box=1
}

;----------------------------------------------------------------------
;Steer:

steer
{
  x=0.570
  y=0.56
  z=1.90
  radius=0 ;15
  xa= 50 ;15
  lock=940
  linearity=0.85
  model
  {
    file=stw.dof
  }
}


;----------------------------------------------------------------------
;Engine:

engine
{
  mass=0
  idle_rpm=650
  max_rpm=3000
  max_torque=400        
  
  sample=acc-320.wav
  sample_rpm=4800

  curve_torque=torque.crv
  autoclutch_rpm=0
  starter=1
  starter_torque=65
  start_stalled=1
  stall_rpm=200
  start_rpm=650
  reaction=0
  shifting
  {
    automatic=0
    shift_up_rpm=5450
    shift_down_rpm=2400
    time_to_declutch=90
    time_to_clutch=10
  }
 inertia
 {
  engine=0.45
 }
 braking_coeff=3.2
 rolling_friction_coeff=1.9
 sample=idle.wav
 sample_rpm=8300
}

;----------------------------------------------------------------------
;Gearbox:

gearbox
{
  gears=6
  gear0
  {
    ratio=-3.68
    inertia=0.2
  }
  gear1
  {
    ratio=3.55
    inertia=0.1
  }
  gear2
  {
    ratio=2.24
    inertia=0.08
  }
  gear3
  {
    ratio=1.54
    inertia=0.06
  }
  gear4
  {
    ratio=1.00
    inertia=0.04
  }
  gear5
  {
    ratio=0.79
    inertia=0.02
  }
  end_ratio=2.81
}

;----------------------------------------------------------------------
;Clutch:

clutch
{
  max_torque=550
}

abs
{
   max_velocity_ratio=1.7
   min_velocity_ratio=1.3
   enable=1
}
traction_control
{
  max_velocity_ratio=1.1
  min_velocity_ratio=1.09
  enable=0
}

;----------------------------------------------------------------------
;handbrakes:

handbrakes
{
  wheels=23
}

;----------------------------------------------------------------------
;Differential:

differential
{
  type=1
  ratio=4.25
  inertia=0.1
  locking_coeff=350
  locking_coeffient=350
  output0=2
  output1=3
}

;----------------------------------------------------------------------
;Aero:

aero
{
  body
  {
    center=0 0 0
    cx=0.33		;sourced
    area=2.06		;measured
  }
  wings=1
  wing0
  {
    name=overall body lift
    span=1
    cord=1
    coeff_drag=0
    coeff_down=-5.3	;18kg lift @ 200 km/h
    center=0 0 0.0
    angle=0
    angle_offset=1
  }
}

antirollbar
{
 count=2
 arb0
 {
  susp_left=0
  susp_right=1
  k=35000
 }
 arb1
 {
  susp_left=2
  susp_right=3
  k=35500
 }
}

;----------------------------------------------------------------------
;Suspension front

susp_front   
{
  y=-0.50
  z=2.34
 restlen=0.4015
 minlen=0.25
 maxlen=0.41
 k=57500
 bump_rate=3200
 rebound_rate=6300
 bump_function=0
 rebound_function=0
 ;anti_pitch=0.4
 roll_center
 {
  x=0
  y=-0.5
  z=0
 }
}

susp0~susp_front
{
  x=1.00
    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.017		;5.78 degrees static caster -0.017!
}

susp1~susp_front
{
  x=-1.00
    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.017		;5.78 degrees static caster -0.017!
}

;----------------------------------------------------------------------
;Suspension rear


susp_rear  
{
  y=-0.47
  z=-2.41
 restlen=0.4205
 minlen=0.23
 maxlen=0.42
 k=55000
 bump_rate=3000
 rebound_rate=4800
 bump_function=0
 rebound_function=0
 roll_center
 {
  x=0
  y=-0.49
  z=0
 }
}

susp2~susp_rear
{
  x=1.00
    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=-1.00
    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.5
    a1=-35
    a2=1200
    a3=1870
    a4=9
    a5=0.015
    a6=-0.25
    a7=1.0
    a8=-0.03
    a9=-0.001
    a10=-0.15
    a111=-8.5
    a112=-0.29
    a12=17.8
    a13=-2.4
    b0=1.6
    b1=-70
    b2=1500
    b3=20
    b4=325
    b5=0.08
    b6=0
    b7=0.05
    b8=-0.025
    b9=0.015
    b10=0.25
    b11=-80
    b12=350
    c0=2.3
    c1=-3.8
    c2=-3.14
    c3=-1.16
    c4=-7.2
    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.11
    optimal_slipangle=0.159
}
;----------------------------------------------------------------------
;Wheel front:

wheel_front
{
  y=0
  z=0
  camber= -0.2
  steering=1
  powered=0
  lock=67
  ackerman=1.1
  mass=38
  	inertia=1.5
  	radius=0.430
  	rolling_coeff=0.015
	friction_road=1
  	max_braking=3000
  	braking_factor=1
  	tire_rate=200000
  pacejka~pacejka
  {
  }
}

wheel0~wheel_front
{
  x=0
  toe=0.05
  ackerman=1.2
  model
  {
    file=leve_predni.dof
  }
  model_brake
  {
    ;file=caliper_l1.dof
    offset
		{
		x=-0.01
		}
  }

}

wheel1~wheel_front
{
  x=0
  toe=-0.05
  ackerman=-1.2
  model
  {
    file=prave_predni.dof
  }
  model_brake
  {
    ;file=caliper_r1.dof
	offset
		{
		x=-0.01
		}
  
  }
}

;----------------------------------------------------------------------
;Wheel rear:

wheel_rear
{
  y=0
  z=0
  camber=0
  steering=0
  powered=1
 mass=42
  	inertia=1.5
  	radius=0.430
  	rolling_coeff=0.015
	friction_road=1
  	max_braking=1800
  	braking_factor=1
 	max_handbrake_torque=750
  	tire_rate=200000
  pacejka~pacejka
  {
  a2=1525
  a3=2100
  a4=9.5
  b2=1700
  b4=350
  optimal_slipratio=0.1
  optimal_slipangle=0.171
  }
}

wheel2~wheel_rear
{
  x=0
  toe=0
  model
  {
    file=leve_zadni.dof
  }
  model_brake
  {
    ;file=caliper_l.dof
	offset
		{
		x=0.01
		}
  }

}

wheel3~wheel_rear
{
  x=0
  toe=0
  model
  {
    file=prave_zadni.dof
  }
  model_brake
  {
    ;file=caliper_r.dof
	offset
		{
		x=-0.01
		}
  }

}

;-----------------------------------------------------------------------
;-----------------------------------------------------------------------
;Camera

camera0
{
  offset
  {
    x=0.5700000
    y=-0.870000
    z=1.40000
  }
  angle
  {
    x=-0.555556
    y=180.000000
    z=0.000000
  }
  name=Hood
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
}
camera1
{
  offset
  {
    x=0.308750
    y=-0.33
    z=-1.45000
  }
  angle
  {
    x=2.500002
    y=180.000000
    z=0.000000
  }
  name=Driver
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  fov=60
  model=1
  view=1
}
camera2
{
  offset
  {
    x=0.000000
    y=0.004167
    z=2.590002
  }
  angle
  {
    x=0.166667
    y=180.000000
    z=0.045139
  }
  name=Bumber
  follow
  {
    pitch=0
    yaw=1
    roll=1
  }
}
camera3
{
  follow
  {
    pitch=
    yaw=1
    roll=
  }
  offset
  {
    x=0.000000
    y=0.012501
    z=-8.860028
  }
  angle
  {
    x=10.833322
    y=-180.000000
    z=0.000000
  }
  name=Behind
  fov=40
}
camera4
{
  offset
  {
    x=0.000000
    y=-0.012501
    z=-6.160028
  }
  angle
  {
    x=10.833322
    y=0.000000
    z=0.000000
  }
  name=Front
  follow
  {
    pitch=
    yaw=1
    roll=
  }
}
camera5
{
  follow
  {
    pitch=0
    yaw=0
    roll=0
  }
  offset
  {
    x=0.810937
    y=-0.208334
    z=-4.760015
  }
  angle
  {
    x=8.055448
    y=-405.903503
    z=0.086801
  }
  name=Front corner
}
camera6
{
  follow
  {
    pitch=
    yaw=1
    roll=
  }
  offset
  {
    x=0.050000
    y=-0.295829
    z=-4.805018
  }
  angle
  {
    x=14.166677
    y=-90.000000
    z=0.173612
  }
  name=Side
}
camera7
{
  offset
  {
    x=-0.476565
    y=0.008330
    z=-6.395005
  }
  angle
  {
    x=7.083300
    y=-143.576736
    z=3.298599
  }
  follow
  {
    pitch=0
    yaw=1
    roll=1
  }
  name=Side
  fov=35
}
camera8
{
  follow
  {
    pitch=
    yaw=1
    roll=
  }
  offset
  {
    x=-0.143748
    y=-0.568743
    z=-6.039991
  }
  angle
  {
    x=7.916664
    y=-319.236206
    z=-1.128471
  }
}
camera9
{
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=-0.054685
    y=-0.373326
    z=-1.155004
  }
  angle
  {
    x=16.527781
    y=-206.735992
    z=-0.434028
  }
  name=Inside
}
audio
{
  skid
  {
    sample=skid.wav
  }
  starter
  {
    sample=starter.wav
  }
  horn
  {
    sample=horn.wav
  }
  wind
  {
    volume=2
    pitch_scale=0
    pitch_offset=50
    smp0
    {
      sample=sfx/wind.wav
      min=25
      max=100
      attack=33
      decay=120
      natural=80
    }
  }
  acc_all
  {
    attack=1000
    decay=1000
  }
  accelerate_in
  {
    smp0
    {
      sample=sfx/IDLE - OUT.wav
      volume=1
      min=300
      max=3000
      natural=750
      attack=300
      decay=500
    }
    smp1
    {
      sample=sfx/4000 - ACC - IN.wav
      volume=0.5
      min=2000
      max=3000
      natural=2500
      decay=1000
      attack=1000
    }
    smp2
    {
      sample=sfx/6000 - ACC - IN.wav
      volume=1
      min=3000
      max=6000
      natural=6000
      attack=1000
      decay=1000
    }
  }
  decelerate_in
  {
    smp0
    {
      sample=sfx/IDLE - OUT.wav
      volume=0.5
      min=300
      max=2000
      natural=750
      attack=300
      decay=500
    }
    smp1
    {
      sample=sfx/4000 - ACC - IN.wav
      volume=0.5
      min=2000
      max=3000
      natural=2500
      decay=1000
      attack=1000
    }
    smp2
    {
      sample=sfx/6000 - ACC - IN.wav
      volume=0.75
      min=3000
      max=6000
      natural=6000
      attack=1000
      decay=1000
    }
  }
  accelerate_out
  {
    smp0
    {
      sample=sfx/IDLE - OUT.wav
      volume=2
      min=300
      max=1500
      natural=750
      attack=300
      decay=500
    }
    smp1
    {
      sample=sfx/4000 - ACC - OUT.wav
      volume=1
      min=2000
      max=4000
      natural=2500
      decay=1000
      attack=1000
    }
    smp2
    {
      sample=sfx/6000 - ACC - OUT.wav
      volume=1
      min=4000
      max=6000
      natural=6000
      attack=1000
      decay=1000
    }
  }
  decelerate_out
  {
    smp0
    {
      sample=sfx/IDLE - OUT.wav
      volume=2
      min=300
      max=1500
      natural=750
      attack=300
      decay=500
    }
    smp1
    {
      sample=sfx/4000 - ACC - OUT.wav
      volume=0.75
      min=2000
      max=4000
      natural=2500
      decay=1000
      attack=1000
    }
    smp2
    {
      sample=sfx/6000 - ACC - OUT.wav
      volume=0.75
      min=4000
      max=6000
      natural=6000
      attack=1000
      decay=1000
    }
  }
}
