car
{
	name=Austin Allegro 1.7 Super
        year=1979
        credits=Created by Jerrycbm
        comments=
	id=austinallegrohl
	version=063b
	wheels=4
	skid
	{
		sample=skid.wav
                volume=9
	}
	shadow
	{
		texture=shadow.tga
		width=2.3
		length=5.1
	}
	cg
	{
		x=0
		y=-0.068	;1444mm high, 38% of roof height ~ 55cm CofG
		z=0.2	;59/41
	}
	ff_factor=0.25
}

graphics
{
	intensity=0.3
	shadow
	{
		model
		{
			;file=shadow.dof
			;use_shaders=0
		}
	}
}

body
{
  mass=900
  inertia
  {
    x=2512
    y=2885
    z=488
  }
  model
  {
    file=austinallegro.dof
  }
  model_incar
  {
    file=austinallegro.dof
  }
  model_light_l
  {
    file=lights.dof
  }
  model_braking_l
  {
    file=brakes.dof
  }
  model_lightroad_l
  {
    file=lights.dof
  }
  width=1.96
  height=0.75
  length=4.46
  manual_box=1
}
steer
{
	x=-0.32
	y=0.235
	z=0.25
	xa=20
	lock=940				
	linearity=0.3
	model
	{
		file=mdl_steer.dof
		lod0_z=0
		lod_out=2
	}
}

engine
{
	mass=0
	idle_rpm=830
	max_rpm=7100
	stall_rpm=500
	start_rpm=1200
	start_stalled=0
        reaction=0.45
        starter=1
	starter_torque=75
	autoclutch_rpm=1500

	curve_torque=torque16v.crv
	max_torque=140
	shifting
	{
		automatic=0
		shift_up_rpm=7000 ; Maximum power rpm
		shift_down_rpm=3100
		time_to_declutch=100
		time_to_clutch=80
		time_in_neutral=100
		time_to_declutch_down=135
		time_to_clutch_down=135
		time_in_neutral_down=135
	}
	inertia
	{
		engine=0.295
		final_drive=0.1
	}
	braking_coeff=2.5
	rolling_friction_coeff=0.1
	;sample=
	;sample_rpm=
}
  jitter
  {
    amplitude=1.05
    time_min=300
    time_var=400
    frequency_min=4
    frequency_var=7
  }

; gearbox ratios section

gearbox
{
	gears=6

	gear0
	{
		ratio=-3.909
		inertia=0.02
		linearity=0.5
	}

	gear1
	{
		ratio=3.62
		inertia=0.01
		linearity=1
	}

	gear2
	{
		ratio=2.06
		inertia=0.02
		linearity=1.2
	}

	gear3
	{
		ratio=1.47
		inertia=0.03
		linearity=1.4
	}

	gear4
	{
		ratio=1.09
		inertia=0.04
		linearity=1.6
	}

	gear5
	{
		ratio=0.76
		inertia=0.07
		linearity=1.9
	}
}

differential
{
	type=1
	ratio=5.07
	inertia=0.1
	locking_coeff=25
	output0=0     
	output1=1     
}

clutch
{
	max_torque=400
}

handbrakes
{
	wheels=23
}

aero
{
	body
	{
		center=0 0 0
		cx=0.365
		area=2.06
	}
	wings=1
	wing0
	{
		name=lift
		span=1
		cord=1
		coeff_drag=0
		coeff_down=0
		center=0 0 0
		angle=0
		angle_offset=10
	}
}

antirollbar
{
	count=2
	arb0
	{
		susp_left=0
		susp_right=1
		k=41000
	}
	arb1
	{
		susp_left=2
		susp_right=3
		k=34000
	}
}

susp_front
{
	y=0.025
	z=1.19
	restlen=0.451			;293	395kg
	minlen=0.22
	maxlen=0.46
	k=27000			;@ static load and 1.316 NF SR
	bump_rate=1350		;0.7	1944
	rebound_rate=4600	;0.7	6531
	bump_function=0
	bump_max=1500
	rebound_function=0
	anti_pitch=0.1
	camber_change_per_m=0.067
	roll_center
	{
		x=0
		y=-0.552	;60mm
		z=0
	}
}

susp_rear
{
	y=0.035
	z=-1.42
	restlen=0.420			;305	275kg
	minlen=0.2
	maxlen=0.43
	k=24500			;@ static load and 1.502 NF SR
	bump_rate=1400		;0.75	1852
	rebound_rate=4200	;0.8	5191
	bump_function=0
	bump_max=1500
	rebound_function=0
	anti_pitch=0.1
	camber_change_per_m=0.14
	roll_center
	{
		x=0
		y=-0.504	;120mm
		z=0
	}
}

susp0~susp_front
{
	x=0.68
	camber_change_steering=0.147	;0.25 rad ~ 14.5 degree camber with 1 radian rotation of steering @ 8 degree caster
	caster_offset=-0.0235		;8 degrees static caster -0.0235	
	toe_change_per_m=0
}
susp1~susp_front
{
	x=-0.68
	camber_change_steering=-0.147	;0.25 rad ~ 14.5 degree camber with 1 radian rotation of steering @ 8 degree caster
	caster_offset=-0.0235		;5.78 degrees static caster -0.0235
	toe_change_per_m=0
}

susp2~susp_rear
{
	x=0.68
}
susp3~susp_rear
{
	x=-0.68
}

;----------------------tyres----------------------

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.4	
  a1=-46	;ps (from pacejkaseries.txt, 205/55 R16)
  a2=1350 ;1280
  a3=2000
  a4=11
  a5=0.015
  a6=-0.25
  a7=1.0
  a8=-0.03
  a9=-0.001
  a10=-0.15
  a111=-4.32	;ps
  a112=-0.29
  a12=17.8
  a13=-2.4

  b0=1.5
  b1=-92	;ps doubled
  b2=1340 ;1260
  b3=23.3
  b4=325
  b5=0.08
  b6=0.0
  b7=0.05
  b8=-0.024
  b9=0.015
  b10=0.25
  b11=-86
  b12=0.0
  
  c0=2.3
  c1=-3.8
  c2=-3.14
  c3=-1.0
  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.04
  c15=-1.029
  c16=0.27
  c17=-1.1

  optimal_slipratio=0.12
  optimal_slipangle=0.22
}

skidding_default
{
	long_start=0.1
	long_max=1.0
	long_start_n=0.1
	long_max_n=1.0
	lat_start=0.1
	lat_max=1.0
}

;----------------------wheels----------------------

wheel_front
{
	y=0
	z=0
	steering=1
	powered=1
	lock=60
	mass=35
	inertia=1.4
	radius=0.31045
        width=0.195		
	rolling_coeff=0.010
	max_braking=1600
	braking_factor=1
	tire_rate=250000
	pacejka~pacejka
	{
	}
}

wheel_rear
{
	y=0
	z=0
	steering=0
	powered=0
	mass=35
	inertia=1.35
	radius=0.31045
        width=0.195
	rolling_coeff=0.010
	max_braking=650
	braking_factor=1
	max_handbrake_torque=3400
	tire_rate=230000
	pacejka~pacejka
	{
		optimal_slipratio=0.11
		optimal_slipangle=0.155
	}
}

wheel0~wheel_front
{
	x=0
	ackerman=1.15
	toe=-0
	camber=0.007	;-0.6
	model
	{
		file=leftwheel.dof
	}
	model_brake
	{
		file=flb.dof
	}
}

wheel1~wheel_front
{
	x=0
	ackerman=1.15
	toe=0
	camber=0.007
	model
	{
		file=rightwheel.dof
	}
	model_brake
	{
		file=frb.dof
	}
}

wheel2~wheel_rear
{
	x=0
	toe=-0.21	;toe in, goes to out under bump like M3 Z axle
	camber=-0.588	;-1.5
	model
	{
		file=leftwheel.dof
	}
	model_brake
	{
		file=flb.dof
	}
}

wheel3~wheel_rear
{
	x=0
	toe=0.21	;toe in, goes to out under bump like M3 Z axle
	camber=-0.588
	model
	{
		file=rightwheel.dof
	}
	model_brake
	{
		file=frb.dof
	}
}

;	------------------ Artyfishul Intellygents -----------------
     
ai
{
	grip_factor=1.1
}

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

audio
{
  skid
  {
    smp0
    {
      sample=skid.wav
      attack=0.3
      decay=1
      min=0.4
      max=20
    }
    smp1
    {
      sample=SkidRoadHeavyMajor.wav
      attack=0.2
      decay=1
      min=0.7
      max=20
    }
  }
  horn
  {
    sample=horn.wav
  }
  acc_all
  {
    attack=1000
    decay=1000

  }
  
;	throttle_off
;	{
;	smp0~audio.acc_all
;		{
;		sample=-wastegate.wav
;		natural=30000
;		volume=1
;		min=0
;		max=7800
;		}
;
;	}
  accelerate_out
  {
    smp0~audio.acc_all
    {
     sample=idle.wav
     min=250
     attack=1000
     decay=55
     max=1000
     natural=760
     volume=0.6
    }
    smp1~audio.acc_all
    {
      sample=7000.wav
      min=1000
      max=9000
      natural=4060
      volume=0.9
    }
    smp2~audio.acc_all
    {
     sample=engine.wav
     min=1000
     max=9000
     natural=5000
     volume=0.1
    }
  }
    accelerate_in
  {
     smp0~audio.acc_all
    {
     sample=idle.wav
     min=250
     attack=1000
     decay=55
     max=1000
     natural=760
     volume=0.4
    }
    smp1~audio.acc_all
    {
      sample=7000.wav
      min=1000
      max=9000
      natural=4060
      volume=0.6
    }
    smp2~audio.acc_all
    {
     sample=engine.wav
     min=1000
     max=9000
     natural=5000
     volume=0.1
    }
  }
  decelerate_out
  {
    smp0~audio.acc_all
    {
     sample=idle.wav
     min=250
     attack=1000
     decay=55
     max=1000
     natural=760
     volume=0.6
    }
    smp1~audio.acc_all
    {
      sample=7000decc.wav
      min=1000
      max=9000
      natural=4060
      volume=0.9
    }
    smp2~audio.acc_all
    {
     sample=engine.wav
     min=1000
     max=9000
     natural=5000
     volume=0.1
    }
  }
    decelerate_in
  {
     smp0~audio.acc_all
    {
     sample=idle.wav
     min=250
     attack=1000
     decay=55
     max=1000
     natural=760
     volume=0.4
    }
    smp1~audio.acc_all
    {
      sample=7000decc.wav
      min=1000
      max=9000
      natural=4060
      volume=0.6
    }
    smp2~audio.acc_all
    {
     sample=engine.wav
     min=1000
     max=9000
     natural=5000
     volume=0.1
    }
  }
  wind
  {
    volume=1.5
    pitch_scale=1
    pitch_offset=50
    smp0
    {
      sample=wind1.wav
      min=27
      max=28
      attack=33
      decay=33
      natural=80
    }
    smp1
    {
      sample=wind2.wav
      min=50
      max=51
      attack=33
      decay=33
      natural=80
    }
    smp2
    {
      sample=wind3.wav
      min=75
      max=76
      attack=33
      decay=33
      natural=80
    }
  }
}

;----------------------driving aids----------------------
abs
{
  enable=1
  max_velocity_ratio=1.09 
  min_velocity_ratio=1.08
  min_velocity=1
}
traction_control
{
  	enable=0
  	min_velocity=3
  	max_velocity_ratio=1.050
  	min_velocity_ratio=1.300

}
flares
{
  ; Front lights
  flare0
  {
    pos=-0.57 0.08 1.75
	;normal=0 0 1
	normal=-0.05 -0.02 0.6
	z_offset=-3000
	size_factor=1 
  }
  flare1
  {
    pos=0.57 0.08 1.75
	normal=0.05 -0.02 0.6
	z_offset=-3000
	size_factor=1 
  }
flare2
  {
    pos=0.405 0.08 1.75
	;normal=0 0 1
	normal=-0.05 -0.02 0.6
	z_offset=-3000
	size_factor=1 
  }
flare3
  {
    pos=-0.405 0.08 1.75
	;normal=0 0 1
	normal=-0.05 -0.02 0.6
	z_offset=-3000
	size_factor=1 
  }
}
;---------------------------------------------
;Cameras
;---------------------------------------------
camera0
{
  name=Driver
  fov=65
  model=1
  view=0
  wheels=0
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=-0.36
    y=-0.53
    z=-0.350
  }
  offset_to
  {
    x=0.37
    y=-0.2
    z=10
  }
  angle
  {
    x=0
    y=180
    z=0.000000
  }
}
camera1
{
  name=Driver, left
  fov=65
  model=1
  wheels=0
  view=1
   offset
  {
    x=-0.379
    y=0.53
    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.379
    y=0.53
    z=-0.30
  }
  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.17
    y=0.55
    z=-0.50
  }
  offset_to
  {
    x=-1
    y=0.5
    z=-10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.1
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera4
{
  name=Chase
  fov=60
  model=0
  wheels=0
  view=0
  offset
  {
    x=0
    y=-0.5
    z=-5
  }
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  angle
  {
    x=15
    y=180
    z=0
  }
}
camera5
{
  name=Chase rear
  fov=60
  model=0
  wheels=0
  view=0
  offset
  {
    x=0
    y=-0.5
    z=-5
  }
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  angle
  {
    x=15
    y=0
    z=0
  }
}
camera6
{
  name=Free exterior
  fov=60
  model=0
  wheels=0
  view=0
  offset
  {
    x=0
    y=-0.5
    z=-5
  }
  follow
  {
    pitch=0
    yaw=0
    roll=0
  }
  angle
  {
    x=10
    y=180
    z=0
  }
}
camera7
{
	name=Side
	fov=60
	model=0
	wheels=0
	view=0
	offset
	{
		x=1.267185
		y=0.129164
		z=-2.6
	}
	angle
	{
		x=1.361085
		y=-165.972626
		z=1.298599
	}
	follow
	{
		pitch=0
		yaw=1
		roll=1
	}

}
camera8
{
  name=Driver2
  fov=70
  model=1
  wheels=0
  view=1
  offset
  {
    x=0.35
    y=0.47
    z=0.05
  }
  offset_to
  {
    x=0.43
    y=-0.5
    z=10
  }
  src
  {
    mass=1
    k=250
    damping=25
    maxdist=0.3
  }
  dst
  {
    mass=1
    k=0
    damping=0
    maxdist=0
  }
}
camera9
{
	name=Bonnet
	fov=60
	model=0
	wheels=0
	view=0
	offset
	{
		x=0.356
    		y=-0.75
    		z=0.55
	}
	follow
	{
		pitch=1
		yaw=1
		roll=1
	}
	angle
	{
		x=5
		y=180
		z=0
	}
}
