; 1957 Simca Aronde 90a Elysee - Stereo
; stereogod@gmail.com
; 
; ; stats
; LxHxW = 4118x1445x1558
; wheelbase = 2443
; 1254 front 1250 rear track '57 (no model specified)
; alt source says 1226 front '56 1300 elysee
; 900 front 880 rear headroom.
car
{
  name=Simca Aronde 90a
  year=1957
  wheels=4
  credits=Modeling&Textures: Stereo 
  comments=Shaders&Audio: Stereo  Driver: Stecki
  id=sarond90a
  version=090
  skid
  {
    sample=skid.wav
  }
  shadow
  {
    texture=aronde-shadow-mark.tga
    width=2.96
    length=5.93
  }
  cg
  {
    x=0	
    y=0
    z=0.055;0.06
  }
}
graphics
{
  shadow
  {
    model
    {
      file=shadow.dof
      use_shaders=0
    }
  }
  generic
  {
    model0 ; Driver.  No offset.
    {
      file=driver.dof
      from_offset=1 1 1
    }
    model1 ; rear axle.
    {
      file=rear_axle.001.dof
      from=wheelpos2
      to=wheelpos3
      fit=1
      scale=0.78
    }
    model2 ; rear leaf spring, left
    {
      file=rear_spring.001.dof
      from=0.50 -0.27 -1.07
      to=wheelpos2
      to_offset=-0.12 -0.1 0
      fit=1
      scale=7.7
    }
    model3 ; rear leaf spring, right
    {
      file=rear_spring.002.dof
      from=-0.50 -0.27 -1.07
      to=wheelpos3
      to_offset=0.12 -0.1 0
      fit=1
      scale=7.7
    }
    model4 ; front lower susp arm, left
    {
      file=front_lower_arm.001.dof
      from=0.24 -0.33 1.36
      to=wheelpos0
      to_offset=-0.06 -0.08 0
      fit=1
      scale=2.78
    }
    model5 ; front lower susp arm, right
    {
      file=front_lower_arm.002.dof
      from=-0.24 -0.33 1.36
      to=wheelpos1
      to_offset=0.06 -0.08 0
      fit=1
      scale=2.78
    }
    model6 ; front upper susp arm, left
    {
      file=front_upper_arm.001.dof
      from=0.40 -0.16 1.36
      to=wheelpos0
      to_offset=-0.06 0.10 0
      fit=1
      scale=4.7
    }
    model7 ; front upper susp arm, right
    {
      file=front_upper_arm.002.dof
      from=-0.40 -0.16 1.36
      to=wheelpos1
      to_offset=0.06 0.10 0
      fit=1
      scale=4.7
    }
    model8
    {
      file=trunk.dof
      ;offset=0 -0.93 0.73 ; what is the syntax? this doesn't work
    }
    model9 ; driver side and passenger side doors
    {
      file=front_door_l.dof
    }
    model10
    {
      file=front_door_r.dof
    }
  }
}
body
{
  ; 940kg, don't know that includes a driver
  ; it has a solid rear axle so the unsprung weight is higher
  ; say 1030kg total - 30kg fr 60kg rear?
  ; 43 litre gas tank
  mass=940
  ;restitution_coeff=0.15
  inertia
  {
    x=1300
    y=1600
    z=300
  }
  model
  {
    file=body.dof
  }
  model_collide
  {
    ; 3D collision model (Newton only)
    file=bound.dof
    offset
    {
    y=0.22
    }
  }
  model_incar
  {
    file=body.dof
  }
  model_braking_l
  {
    ;file=brklights.dof
  }
  width=1.558
  height=1.445
  length=4.118
  manual_box=0
  x=0.0
  y=0.0
  ;z=0.04
}
steer
{
  x=-0.380
  y=0.0
  z=0.233
  radius=10
  xa=14
  lock=250
  linearity=0.96
  model
  {
    ;file=strwheel.dof
  }
}
engine
{
  mass=100
  max_rpm=5600
  idle_rpm=900
  stall_rpm=350
  start_rpm=900
  autoclutch_rpm=1000
  starter=1
  starter_torque=40
  curve_torque=torque.crv
  ; Aronde 1300 Saloon
  ;0-60 23.9 seconds
  ; 86mph top speed (133km/h)
  ; 1290cc na "Flash" engine.
  ; 88 Nm@2700rpm
  ; From manual:
  ; 64.4Ft/Lbs @ 3200RPM = 87.32
  ; 51 CV @ 4800 rpm
  ; discount 10%
  max_torque=80
  reaction=1
  shifting
  {
    automatic=0
    shift_up_rpm=4000
    shift_down_rpm=1600
    ;zmiana
    time_to_declutch=150
    time_to_clutch=150
  }
  inertia
  {
    engine=0.17
    final_drive=0.1
  }
  braking_coeff=1.6
  rolling_friction_coeff=0.6
  sample=engine.wav
  sample_rpm=15000
}
gearbox
{
  ; 4 speed column mounted
  ; 4.44 rear diff
  ; 1st: 16 x 16 = 0.2709
  ;    / 27 x 35
  ; 2nd: 16 x 18 = 0.4267
       / 27 x 25
  ; 3rd: 16 x 23 = 0.6815
       / 27 x 20
  ; 4th: direct  = 1.0
  ; reverse:
  ; 16 x 16 x 18 = 0.2120
  ; 27 x 23 x 35 
  ; final drive: 
  ; Hypoid 9 x 40
  ; (used in 1955+)
  ; = 4.4 repeating
  ; Hypoid 8 x 43
  ; (utility drive)
  gears=5
  gear0
  {
    ratio=-4.717
    inertia=0.9
  }
  gear1
  {
    ratio=3.6914
    inertia=0.07
  }
  gear2
  {
    ratio=2.3436
    inertia=0.05
  }
  gear3
  {
    ratio=1.46735
    inertia=0.04
  }
  gear4
  {
    ratio=1.0
    inertia=0.03
  }
  end_ratio=4.444
}
clutch
{
  max_torque=130
}
handbrakes
{
  wheels=23
}
differential
{
  type=1
  ratio=4.444
  inertia=0.02
  locking_coeff=65
}
aero
{
  body
  {
    center=0 0 0
    cx=0.44
    area=1.69
  }
  wings=1
  wing0
  {
    name=BodyLift
    span=1
    cord=1
    coeff_drag=0
    coeff_down=-6
    center=0 0 0
    angle=0
    angle_offset=1
  }
}
antirollbar
{
   count=2
   arb0
   {
      susp_left=0
      susp_right=1
      k=9000 ;9000
   }
   arb1
   {
      susp_left=2
      susp_right=3
      k=3500 ;3500
   }
}
;Front has A-arm suspension, top ~2x as long.
;Rear is a solid axle, leaf sprung.
susp_bumps
{
  bumpstop_len=0.03
  bumpstop_k=65000
  bumpstop_damping=4000
  reboundstop_len=0.02
  reboundstop_k=55000
  reboundstop_damping=3200
}
susp_front~susp_bumps
{
  y=-.03
  z=1.373
  restlen=.46
  minlen=.19
  maxlen=.32
  ;k=15040
  k=12000
  ;k=1200
  bump_rate=2601 ;7668 crit * .6 / was 3101 
  rebound_rate=3201 ;7668 crit * .9 / was 3601
  roll_center
  {
    x=0
    y=-0.45
    z=0
  }
}
susp_rear~susp_bumps
{
  y=-.06
  z=-1.07
  restlen=.53
  minlen=.20
  maxlen=.31
  ;k=11280
  k=9600
  ;k=800
  bump_rate=2300 ;6640 crit * .6 / was 3384
  rebound_rate=2800 ; 6640 crit * .9 / was 4076
  roll_center
  {
    x=0
    y=-0.31
    z=0
  }
}
susp0~susp_front
{
  x=0.627
}
susp1~susp_front
{
  x=-0.627
}
susp2~susp_rear
{
  x=0.625
  ;y=-0.26
}
susp3~susp_rear
{
  x=-0.625
}
tire_model
{
  relaxation_length_lat=0.91
  relaxation_length_long=.091
  damping_speed=99.15
  damping_coefficient_lat=9.066
  damping_coefficient_long=3.5
}
pacejka
{
; Lateral force
a0=1.350
a1=-46.000
a2=1345.000
a3=1675.000
a4=11.000
a5=0.013
a6=-0.140
a7=0.140
a8=0.019
a9=-0.019
a10=-0.180
a111=-11.000
a112=-0.021
a12=0.480
a13=10.200
a13=-2.400
; Longitudinal force
b0=1.350
b1=-90.000
b2=1425.000
b3=23.300
b4=400.000
b5=0.05
b6=0
b7=0.055
b8=-0.024
b9=0
b10=0
b11=0
b12=0
; Aligning moment
c0=2.10
c1=-3.900
c2=-3.900
c3=-1.260
c4=-8.200
c5=0.025
c6=0.000
c7=0.044
c8=-0.580
c9=0.180
c10=0.043
c11=0.048
c12=-0.003
c13=-0.180
c14=0.140
c15=-1.029
c16=0.270
c17=-1.100
optimal_slipratio=0.14
optimal_slipangle=0.16
}
wheel_brakes
{
  brake_heating=0.003
  brake_dissipation=0.0008
  brake_max_temp=900
}
wheel_front~wheel_brakes
{
  ; Front suspension ideal data, car empty on a flat surface
  ; from manual
  ; Caster: 1.5 to 2.5 degrees, sym. tolerance 0.25 degrees
  ; Camber 1 to 1.5 degrees, sym. tolerance 0.25 degrees
  ; Spindle pivot inclination: 8 to 9 degrees, inclination + camber = 9.25 to 9.75 degrees
  ; Toe-in: -0.20 degrees
  y=0
  z=0
  steering=1
  powered=0
  camber=1.25
  toe=-0.20
  lock=70
  ackerman=1.1
  mass=15
  inertia=1.3
  radius=.32
  rolling_coeff=0.022
  max_braking=950
  braking_factor=0.6
  tire_rate=140000 ; was 300000
  pacejka~pacejka
  {
  }
}
wheel_rear~wheel_brakes
{
  y=0
  z=0
  steering=0
  powered=1
  camber=-1.3
  mass=30
  inertia=1.3
  radius=.32
  rolling_coeff=0.022
  max_braking=550
  braking_factor=0.4
  tire_rate=140000 ; was 300000
  pacejka~pacejka
  {
  }
}
wheel0~wheel_front
{
  toe=0
  model
  {
    file=whlleftu.dof
    ;file=wheel0.dof
	lod0_z=0
	lod1_z=80
	;lod2_z=300
  lod_out=800
  }
  model_brake
  {
    file=front_hub.0.dof
    offset
    {
      x=0
    }
  }
}
wheel1~wheel_front
{
  toe=0
  model
  {
    file=whlrightu.dof
		lod0_z=0
		lod1_z=80
		;lod2_z=300
  lod_out=800
  }
  model_brake
  {
    file=front_hub.1.dof
    offset
    {
      x=.01
    }
  }
}
wheel2~wheel_rear
{
  toe=0
  model
  {
    file=whlleftu.dof
	lod0_z=0
	lod1_z=80
	;lod2_z=300
  lod_out=800
  }
  model_brake
  {
    ;file=caliperright.dof
    offset
    {
      x=-.01
    }
  }
}
wheel3~wheel_rear
{
  toe=0
  model
  {
    file=whlrightu.dof
	lod0_z=0
	lod1_z=80
	;lod2_z=300
  lod_out=800
  }
  model_brake
  {
    ;file=caliperleft.dof
    offset
    {
      x=0.01
    }
  }
}

lights
{
  ; Projected lights
  light0
  {
    texture=light.tga
    ; Field of view (vertical)
    fov=45
    ; Aspect (horizontal)
    aspect=5
    ; Distance to car
    z=1.1
    ; Pitching with respect to car (in degrees)
    pitch=0
    ; Fall-off distance
    far=60
  }
}
flares
{
  ; Front lights
  flare0
  {
    pos=-0.54 0.09 1.92
	;normal=0 0 1
	normal=-0.05 -0.02 0.6
	z_offset=-3000
	size_factor=2
	color=120.0 120.0 110.2
  }
  flare1
  {
    pos=0.54 0.09 1.92
	normal=0.05 -0.02 0.6
	z_offset=-3000
	size_factor=2
	color=120.0 120.0 110.2
  }
  ; Brake lights
  flare2
  {
    rule=brake
    pos=-0.585 0.09 -1.94
	normal=-0.0 0 -0.5
	color=200 .2 0.2
	size_factor=0.7
	z_offset=-1000
  }
  flare3
  {
    rule=brake
    pos=0.585 0.09 -1.94
	normal=0.0 0 -0.5
	color=200 .2 0.2
	size_factor=0.7
	z_offset=-1000
  }
  flare4
  {
    ;rule=brake
    pos=-0.585 -0.03 -1.94
	normal=-0.0 0 -0.5
	color=160 .1 0.1
	size_factor=0.7
	z_offset=-1000
  }
  flare5
  {
    ;rule=brake
    pos=0.585 -0.03 -1.94
	normal=0.0 0 -0.5
	color=160 .1 0.1
	size_factor=0.7
	z_offset=-1000
  }
}
------------------------------------------------
camera0
{
  follow
  {
    pitch=1   ;0
    yaw=1   ;0
    roll=1   ;0
  }
  offset
  {
    x=-0.38   ;-0.36         ;+left/-right
    y=-0.58    ;0.25  ;-up/+down
    z=-0.19    ;0.20  ;+fwd/-back
  }
  angle
  {
    x=0         ; tilt camera +down/-up
    y=-180.0    ;rotate camera +left/-right
    z=-1.000     ;tilt camera +clockwise/-ccw
  }
  fov=75
  ; Type of model to use; 0=outside, 1=inside, 2=none
  model=1
  wheels=0
  view=1
  name=Inside
    ; Source/target inertia
}

camera1
{
  offset
  {
    x=0.059375
    y=-0.900001
    z=-4.240005
  }
  angle
  {
    x=6.666651
    y=-180.729126
    z=0.000000
  }
  name=Side view
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  fov=50
}

camera2
{
  offset
  {
    x=0
    y=-0.886249
    z=0.4
  }
  angle
  {
    x=9.444441
    y=179.340210
    z=0.000000
  }
  follow
  {
    pitch=0.5
    yaw=1
    roll=1
  }
}

camera3
{
  follow
  {
    pitch=
    yaw=
    roll=
  }
  offset
  {
    x=0.475003
    y=0.316667
    z=-3.305010
  }
  angle
  {
    x=37.361118
    y=-64.062294
    z=2.430566
  }
  name=Wheels
  fov=65
}

camera4
{
  offset
  {
    x=-0.043751
    y=0.272918
    z=-5.149995
  }
  angle
  {
    x=14.444427
    y=128.645737
    z=0.260415
  }
}

camera5
{
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  offset
  {
    x=-0.087501
    y=0.029167
    z=-5.289999
  }
  angle
  {
    x=7.360988
    y=-269.792023
    z=0.086801
  }
  name=High
  fov=30
}

camera6
{
  follow
  {
    pitch=1
    yaw=1
    roll=0
  }
  offset
  {
    x=-0.273437
    y=0.539583
    z=-3.650010
  }
  angle
  {
    x=23.194437
    y=-357.986633
    z=19.357632
  }
  fov=60
}

camera7
{
  offset
  {
    x=1.267185
    y=-0.07
    z=0.110008
  }
  angle
  {
    x=12.361085
    y=-165.972626
    z=3.298599
  }
  follow
  {
    pitch=0
    yaw=1
    roll=1
  }
  fov=60
}

camera8
{
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=-0.021873
    y=-0.639575
    z=0.045004
  }
  angle
  {
    x=6.944441
    y=-361.249451
    z=0.000000
  }
  fov=75
}

camera9
{
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=0.28
    y=-0.583326
    z=-0.17
  }
  angle
  {
    x=7.499987
    y=-179.305542
    z=0.000000
  }
  fov=65
  ; Type of model to use; 0=outside, 1=inside, 2=none
  model=1
  wheels=0
  view=2
  name=Inside Driver
}

audio
{
  skid
  {
    ; Old style
    ;sample=skid.wav
    ;sample2=skid_lon.wav
    ; New style (multiple samples mixed)
    ; Master volume for this set
    volume=1
    ; Acceleration; outside of the car
    smp0
    {
      volume=1.0
      sample=skid.wav
      min=0.1
      max=0.6
      attack=0.09
      decay=1.0
    }
    smp1
    {
      volume=1.0
      sample=skid_lon.wav
      min=0.3
      max=20
      attack=0.2
      decay=0
    }
  }
  acc_all
  {
    attack=1300
    decay=1300
  }
  accelerate_out
  {
    smp0~audio.acc_all
    {
      sample=engine_lo2.wav
      min=500
      max=10001
      natural=1312
      volume=0.6
    }
  }
  decelerate_out
  {
    smp0~audio.acc_all
    {
      sample=engine_lo2.wav
      min=500
      max=10001
      natural=1312
      volume=0.4
      attack=1300
      decay=800
    }
  }
  wind
  {
    volume=15
    pitch_scale=1
    pitch_offset=50
    smp0
    {
      sample=wind1.wav
      min=25
      max=26
      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
    }
  }
}