 car
{
  name=BMW M5 E28 535i Drift
  year=1988
  credits=Converted by Priban
  comments=3430cm3, 160.5kW/218PS/215HP, 310Nm
  id=bmw_e28
  version=0655
  wheels=4

shadow
   {
      texture=shadow.tga
      width=1.702
      length=4.191
      offset=0
   }
   cg
   {
      x=0
      y=-0.45
      z=0.5
   }
}
graphics 
{
  shadow 
  {
    texture=shadow.tga
    model
    {
      file=e28.dof
    }
  }

	generic
	{
		model0
		{
		file=console.dof
		offset
    {
    x=0.0
    y=-0.316
    z=0.0
    }  
}
		model1
		{
		file=addon.dof
   		offset
                {
   		x=0.0
    		y=-0.316
    		z=0.0
   		}  
		}
		model2
		{
		file=plates.dof
   		offset
                {
   		x=0.0
    		y=-0.316
    		z=0.0
   		}  
		}
		model3
		{
		file=armrest.dof
   		offset
                {
   		x=0.0
    		y=-0.316
    		z=0.0
   		}  
		}
    		model4
		{
		file=
   		offset
                {
   		x=0.0
    		y=-0.47
    		z=0.0
   		}  
		}
    		model5
    		{
		file=
   		offset
                {
   		x=0.0
    		y=-0.47
    		z=0.0
   		}  
    		}
    		model6
    		{
      		file=
    		}
    		model7
    		{
      		file=
    		}
    		model8
    		{
      		file=
    		}
    		model9
    		{
      		file=
    		}
    		model10
    		{
      		file=
    		}
    		model11
    		{
      		file=
    		}
    		model12
    		{
      		file=
    		}
    		model13
    		{
      		file=
    		}
    		model14
    		{
      		;file=
    		}
    		model15
    		{
      		;file=
    		}
    		model16
    		{
      		;file=
    		}

	}
}
;----------------------------------------------------------------------
;Body:}
body
{
  mass=1370
  restitution_coeff=0.25
  inertia
  {
    x=2510	
    y=2750		
    z=470	
  }
  model
  {
    file=e28.dof
    offset
    {
    x=0.0
    y=-0.47
    z=0.0
    }
  }
  model_incar
  {
    file=e28.dof
offset
    {
    x=0.0
    y=-0.47
    z=0.0
    }  
}
model_reverse_r
  {
    file=reverse.dof
  }
 model_light_l
  {
    file=;lights2.dof
    offset
    {
    x=0.0
    y=0.0
    z=0.0
    }
  }
model_reverse_r
  {
    file=reverse.dof
  }
   model_braking_l
  {
    file=braking.dof
    offset
    {
    x=0.0
    y=-0.47
    z=0.0
    }
  }
  model_reverse_r
  {
    file=reverse.dof
  }
  model_lightroad_l
  {
  file=podsvetleni.dof 
offset
    {
    x=0.0
    y=-0.47
    z=0.0
    }
}
manual_box=1
  }
}
model_reverse_r
  {
    file=reverse.dof
  }
wipers
{
  ; Windscreen wipers
  count=1
  wiper0
  {
    x=-0.28
    y=0.35
    z=-1.64
    xa=-75
    min_angle=5
    max_angle=-85
    model
    {
      file=
    }
  }
}

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

steer
{
  x=0.36
  y=0.22
  z=0.3
  xa=20
  lock=1080
  linearity=0.2
  model
  {
    file=kiera.dof
  }
}


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

engine
{
	mass=120
	max_rpm=8000
	idle_rpm=900
	starter=1
        starter_torque=70
        start_stalled=1
        stall_rpm=550
        start_rpm=900
	autoclutch_rpm=2700
	curve_torque=torque.crv
	max_torque=320
	torque_reaction=1.5
	shifting
	{
		automatic=0
		shift_up_rpm=5000
		shift_down_rpm=1350
		time_to_declutch=0.001
    		time_in_neutral=0.001
    		time_to_clutch=0.001

    		time_to_declutch_down=0.001
    		time_in_neutral_down=0.001
    		time_to_clutch_down=0.001
	}
	inertia
	{
		engine=0.30
	}
	braking_coeff=2.6
}
clutch
{
	max_torque=390
}
gearbox
{
	gears=6
  	gear0
  	{
    		ratio=-4.233
    		inertia=0.10
    		engine_map=1.00
  	}
  	gear1
  	{
    		ratio=3.717
    		inertia=0.01
    		engine_map=1.00
  	}
  	gear2
  	{
    		ratio=2.403
    		inertia=0.02
    		engine_map=1.00
  	}
  	gear3
  	{
    		ratio=1.766
    		inertia=0.04
    		engine_map=1.00
  	}
  	gear4
  	{
    		ratio=1.368
    		inertia=0.06
    		engine_map=1.00
  	}
gear5
  	{
    		ratio=1.16
    		inertia=0.06
    		engine_map=1.00
  	}
}
handbrakes
{
  wheels=23
}
differential
{
  type=0
  ratio=3.07
  inertia=0.02
  locking_coefficient=100
  output0=2
  output1=3
}
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
}
;----------------------------------------------------------------------
;Aero:

aero
{
  body
  {
    center=0 0 0
    cx=0.30
    area=1.75
  }
  wings=2
  wing0
  {
    name=rearspoiler
    span=1
    cord=1
    coeff_drag=2.8
    coeff_down=28
    center=0 0.15 -1.25
    angle=1
    angle_offset=0
  }
}
;----------------------------------------------------------------------
;Antirollbar

antirollbar 
{
  count=2
  arb0
  {
    susp_left=0
    susp_right=1
    k=12400
  }
  arb1
  {
    susp_left=2
    susp_right=3
    k=6100
  }
}

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

susp_front   
{
  y=0.115
  z=1.29
  restlen=0.475
  minlen=0.30
  maxlen=0.60
  k=39200
  bump_rate=6600
  rebound_rate=6600
  anti_pitch=0.15
  roll_center
  {
    x=0
    y=-0.53
    z=0
  }
}

susp0~susp_front
{
  x=0.65
}

susp1~susp_front
{
  x=-0.66
}

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


susp_rear  
{
  y=0.195
  z=-1.33
  restlen=0.495
  minlen=0.30
  maxlen=0.60
  k=37000
  bump_rate=6600
  rebound_rate=6600
  anti_pitch=0.15
  roll_center
  {
    x=0
    y=-0.53
    z=0
  }
}

susp2~susp_rear
{
  x=0.65
}

susp3~susp_rear
{
  x=-0.66
}

;----------------------------------------------------------------------
;Tire model:


tire_model_front
{
  damping_predict_lat=0.492
  damping_predict_long=0.018
}
tire_model_rear
{
  damping_predict_lat=0.504
  damping_predict_long=0.020
}
pacejka
{
    a0=1.2
    a1=-25
    a2=1500
    a3=1000
    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=1950
    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:

wheel_front
{
  y=0
  z=0
  camber=-4
  steering=1
  powered=0
  lock=82
  ackerman=1.1
  mass=15
  inertia=1.05
  width=.205
  radius=0.31
  rolling_coeff=0.015
  friction_road=1.7
  max_braking=1900
  braking_factor=1
  tire_rate=240000
  pacejka~pacejka
  { 
  }
}

wheel0~wheel_front
{
  x=0
  toe=0
  model
  {
    file=left.dof
  }
  model_brake
  {
    file=
  }
  pacejka~pacejka
  {
  }
}

wheel1~wheel_front
{
  x=0
  toe=0
  model
  {
    file=right.dof
  }
  model_brake
  {
    file=
  }
  pacejka~pacejka
  {
  }
}

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

wheel_rear
{
  y=0
  z=0
  camber=-4
  steering=0
  slide=0.1
  powered=1
  mass=15
  inertia=0.95
  radius=0.31
  width=.205
  rolling_coeff=0.015
  friction_road=1.7
  braking_factor=1
  max_braking=1050
  max_handbrake_torque=3000
  tire_rate=270000
  pacejka~pacejka
  {
  }
}

wheel2~wheel_rear
{
  x=0
  toe=0
  model
  {
    file=left.dof
  }
  model_brake
  {
    file=
  }
  pacejka~pacejka
  {
  }
}

wheel3~wheel_rear
{
  x=0
  toe=0
  model
  {
    file=right.dof
  }
  model_brake
  {
    file=
  }
  pacejka~pacejka
  {
  }
}

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

camera0
{
  name=Driver
  fov=60
  model=1
  view=0
  wheels=0
  offset
  {
    x=0.355
    y=0.53
    z=-0.26
  }
  offset_to
  {
    x=0.34
    y=-0.0
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.2
  }
  dst
  {
    mass=0
    k=0
    damping=0
    maxdist=0
  }
}
camera1
{
  name=Left
  fov=65
  model=1
  view=0
  wheels=0
  offset
  {
    x=0.355
    y=0.5
    z=-0.20
  }
  offset_to
  {
    x=15.4
    y=0
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.2
  }
  dst
  {
    mass=0
    k=0
    damping=0
    maxdist=0
  }
}
camera2
{
  name=Right
  fov=65
  model=1
  view=0
  wheels=0
  offset
  {
    x=0.355
    y=0.5
    z=-0.20
  }
  offset_to
  {
    x=-10.6
    y=0.
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.2
  }
  dst
  {
    mass=0
    k=0
    damping=0
    maxdist=0
  }
}
camera3
{
  name=Rear
  fov=-70
  model=0
  view=0
  wheels=0
  offset
  {
    x=0.1
    y=0.5
    z=-0.2
  }
  offset_to
  {
    x=-2
    y=0.8
    z=-10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.1
  }
  dst
  {
    mass=0
    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.5
    z=-5
  }
  angle
  {
    x=10
    y=180
    z=0
  }
}
camera5
{
  name=Exterior free
  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=120
    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.5
    z=-5
  }
  angle
  {
    x=10
    y=0
    z=0
  }
}
camera7
{
  name=Passenger seat
  fov=70
  model=1
  view=0
  wheels=0
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=-0.3
    y=-0.5
    z=-0.4
  }
  angle
  {
    x=10
    y=170
    z=0
  }
}
camera8
{
  name=FrontWheel
  fov=60
  model=0
  view=0
  wheels=0
  offset
  {
    x=1.4
    y=0.06
    z=-0.6
  }
  angle
  {
    x=-2.25
    y=-161
    z=3.3
  }
  follow
  {
    pitch=0
    yaw=1
    roll=1
  }
}
camera9
{
  name=Hood
  fov=60
  model=0
  view=0
  wheels=2
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=0
    y=-0.7
    z=0.50
  }
  angle
  {
    x=5
    y=180
    z=0
  }
}
audio
{
  acc_all
  {
    attack=4600
    decay=4600
   
  }
 
accelerate_out
  {

smp15~audio.acc_all
    {
      sample=1216.wav
      min=500
      max=7100
      volume=0.1
 }
    smp14~audio.acc_all
    {
      sample=1306.wav
      min=950
      max=1567
      volume=0.17
}
    smp13~audio.acc_all
    {
      sample=1577.wav
      min=1317
      max=1850
      volume=0.37

   }
    smp12~audio.acc_all
    {
      sample=1872.wav
      min=1600
      max=2113
      volume=0.4
}
    smp11~audio.acc_all
    {
      sample=2103.wav
      min=1863
      max=2376
  volume=0.5

 }
    smp10~audio.acc_all
    {
      sample=2398.wav
      min=2126
      max=2740
      volume=0.69
}
    smp9~audio.acc_all
    {
      sample=2831.wav
      min=2490
      max=3190
      volume=0.8
}
    smp8~audio.acc_all
    {
      sample=3298.wav
      min=2940
      max=3690
      volume=0.8
}
    smp7~audio.acc_all
    {
      sample=3832.wav
      min=3440
      max=4202
      volume=0.8
}
    smp6~audio.acc_all
    {
      sample=4322.wav
      min=3952
      max=4713
      volume=0.8
 }
    smp5~audio.acc_all
    {
      sample=4853.wav
      min=4463
      max=5299
      volume=0.8
}
    smp4~audio.acc_all
    {
      sample=5494.wav
      min=5049
      max=5829
      volume=0.8
 }
    smp3~audio.acc_all
    {
      sample=5913.wav
      min=5579
      max=6291
      volume=0.8
}
    smp2~audio.acc_all
    {
      sample=6419.wav
      min=6041
      max=6868
      volume=1

}
    smp1~audio.acc_all
    {
      sample=7067.wav
      min=6618
      max=7325
      volume=1

}
    smp0~audio.acc_all
    {
      sample=7333.wav
      min=7075
      max=20000
      volume=1


	 }
  decelerate_out
  {

smp15~audio.acc_all
    {
      sample=1216.wav
      min=500
      max=7100
      volume=0.1
 }
    smp14~audio.acc_all
    {
      sample=1306.wav
      min=950
      max=1567
      volume=0.17
}
    smp13~audio.acc_all
    {
      sample=1577.wav
      min=1317
      max=1850
      volume=0.37

   }
    smp12~audio.acc_all
    {
      sample=1872.wav
      min=1600
      max=2113
      volume=0.4
}
    smp11~audio.acc_all
    {
      sample=2103.wav
      min=1863
      max=2376
  volume=0.5

 }
    smp10~audio.acc_all
    {
      sample=2398.wav
      min=2126
      max=2740
      volume=0.69
}
    smp9~audio.acc_all
    {
      sample=2831.wav
      min=2490
      max=3190
      volume=0.8
}
    smp8~audio.acc_all
    {
      sample=3298.wav
      min=2940
      max=3690
      volume=0.8
}
    smp7~audio.acc_all
    {
      sample=3832.wav
      min=3440
      max=4202
      volume=0.8
}
    smp6~audio.acc_all
    {
      sample=4322.wav
      min=3952
      max=4713
      volume=0.8
 }
    smp5~audio.acc_all
    {
      sample=4853.wav
      min=4463
      max=5299
      volume=0.8
}
    smp4~audio.acc_all
    {
      sample=5494.wav
      min=5049
      max=5829
      volume=0.8
 }
    smp3~audio.acc_all
    {
      sample=5913.wav
      min=5579
      max=6291
      volume=0.8
}
    smp2~audio.acc_all
    {
      sample=6419.wav
      min=6041
      max=6868
      volume=1

}
    smp1~audio.acc_all
    {
      sample=7067.wav
      min=6618
      max=7325
      volume=1

}
    smp0~audio.acc_all
    {
      sample=7333.wav
      min=7075
      max=20000
      volume=1
}
}
}