; TutCar  -  March 18, 2006
; Legal
; This is a RACER car only.
; Legally, I retain all rights to these dof and texture.  Everything, except textures where noted and the engine
; sound, that is included in this package is my own work.  Therefore I retain all rights to the 
; intelectual property. ANY PORTION OF THIS CAR THAT IS COPIED OR UNLAWFULLY DISTRIBUTED STILL BELONGS TO ME. 
; This car was  made in the United States of America and is therefore automatically copyrighted to myself, 
; as a work of art. All related commercial symbols are copyrighted to there respective owners.
;
; Thanks for reading this, and please, have fun
; Robert Hojaboom
;
; Note: Texture images - tire & tread > Hillman Imp and Dunlop, modified by me - racing suit>Sparco - the rest>me
; Note: driver model for Racer was made originally by stecki@quakerally.com  http://stecki.racesimcentral.com.
; He said to use it for whatever and edit it any way you want, both the model and the textures.
; modified by Bob Hojaboom, February 11, 2005
;
; TutCar
; by Bob Hojaboom
; September 2008
car
{
  name=TutCar
  year=2006
  id=tutcar
  credits=Made by myname here
  version=050f
  wheels=4

  shadow
  {
    {
      texture=shadow.tga
      width=4.0   ;adjust width/length to fit
      length=4.5
      offset_z=0.0
      intensity_dark=0.2
      intensity_light=0.2
    }
  }
  cg
  {
    x=0	
    y=-0.5
    z=0.025
  }
}

graphics
{
  ; Car models used
  shadow
  {
    model
    {
      ; Projected shadow model
      file=bodyshdo.dof
      use_shaders=0
       offset
        {
         x=0.0
         y=-0.045
         z=0.0
        }
    }
    intensity=0.4
  }
}
ai
{
  ;understeer_correct=20 don't use slows car down
  ;oversteer_correct=20
  grip_factor=1.3
}


body
{
  mass=800   ; fia min. weight
  width=1.500
  height=0.600
  length=3.830
  manual_box=1
  inertia
  {
    x=1000
    y=1200
    z=300
  }
  model
  {
    file=body.dof
  }
  ; below locates blite from origin 0,0,0
  model_braking_l
  {
    file=blite.dof
    offset
    {
     x=-0.000     ; left/right
     y=-0.000     ; up/down
     z=-0.000     ; fwd/back
    }
  }
}
steer
{
  x=0.3600   ; steeringwheel location left/right
  y=0.2000   ; steeringwheel location +up/down
  z=0.3500   ; steeringwheel location front/back
  radius=10
  xa=5   ;wheel angle
  lock=120
; ================================ adjust for best handling
        linearity=0.35
; ================================
  model
  {
    file=str.dof
  }
}
engine
{
  mass=1
  max_rpm=10000
  idle_rpm=1000
  stall_rpm=500
  start_rpm=600
  autoclutch_rpm=1500
  starter=1
  start_stalled=0
  starter_torque=40
  curve_torque=torque.crv
  max_torque=800
  reaction=1
  shifting
  {
    automatic=0
    autoclutch=1   ;0
    cut_throttle=1   ;0 for no cut
    blip_throttle=2   ;0 for no blip
    shift_up_rpm=9100
    shift_down_rpm=5400
    time_to_declutch=100
    time_to_clutch=100
  }
  inertia
  {
    engine=0.04
    final_drive=0.13
  }
  braking_coeff=0.75
  ; braking coeff = rps/60*coeff= be in nM
  rolling_friction_coeff=0.7
}
gearbox
{
  shifting
  {
   fast=1
  }
  gears=5
  gear0
  {
    ratio=-2.955
    inertia=0.9
  }
  gear1
  {
    ratio=5.55
    inertia=0.11
  }
  gear2
  {
    ratio=3.3
    inertia=0.09
  }
  gear3
  {
    ratio=2.2
    inertia=0.07
  }
  gear4
  {
    ratio=1.56
    inertia=0.05
  }
}
clutch
{
  max_torque=900
}
handbrakes
{
  wheels=23
}
differential
{
  type=1
  ratio=1.8
  locking_coefficient=70
  output0=2
  output1=3
}
aero
{
  body
  {
    center=0 0 0
    cx=0.19
    area=2.4
  }
  wings=4
  wing0
  {
    name=BodyLift
    span=1.039
    cord=0.15
    coeff_drag=0
    coeff_down=-4.3
    center=0 0 0
    angle=5
    angle_offset=0
  }
  wing1
  {
    name=FrontDam
    span=1.039
    cord=0.15
    coeff_drag=0.10
    coeff_down=10
    center=0 -0.1 1.317
    angle=32
    angle_offset=1.8
  }
  wing2
  {
    name=RearWing
    span=1.039
    cord=0.20
    coeff_drag=0.10
    coeff_down=10
    center=0 -0.4 -1.317
    angle=17
    angle_offset=2
  }
  wing3
  {
    name=RearSpoiler
    span=1.039
    cord=0.10
    coeff_drag=0.10
    coeff_down=10
    center=0 -0.3 -1.317
    angle=20
    angle_offset=2
  }
}
susp_front
{
  y=-0.1524    ;0.12    ; moves body position -up/+down
  z=1.2000   ;1.04775   ; - moves body position forward
  restlen=0.35   ; moves body up/down
  minlen=0.20
  maxlen=0.46
  k=95000
; bump and rebound function from racerpages\racer_new\Car physics.htm
; Damper bump function; 0=linear, 1=exp, 2=digressive, 3=sqrt
  bump_function=3
  bump_rate=4000   ;40000
  ; Damper max value (only used if bump_function=digressive)
  ; bump_max=3200
  rebound_rate=7000   ;70000
  rebound_function=3
  anti_pitch=0.6
  roll_center
  {
    x=0
    y=-0.45
    z=0
  }
}
susp_rear
{
  y=-0.1524   ; moves body -up/+down
  z=-1.2000   ; + moves body position backward
  restlen=0.35
  minlen=0.20
  maxlen=0.46
  k=105000
; Damper bump function; 0=linear, 1=exp, 2=digressive, 3=sqrt
  bump_function=3
  bump_rate=4500   ;45000
  ; Damper max value (only used if bump_function=digressive)
  ; bump_max=4600
  rebound_rate=7000   ;70000
  rebound_function=3
  anti_pitch=0.4
  roll_center
  {
    x=0
    y=-0.46
    z=0
  }
}
susp0~susp_front
  {
    x=0.630   ;0.6528   ; adjusts track position
  }
susp1~susp_front
  {
    x=-0.630   ;-0.6528
  }
susp2~susp_rear
  {
    x=0.630   ;0.6439
  }
susp3~susp_rear
  {
    x=-0.630   ;-0.6439
  }
tire_model
{
  relaxation_length_lat=0.91
  relaxation_length_long=0.091
  damping_speed=0.15
  damping_coefficient_lat=50
  damping_coefficient_long=35
}
pacejka
{
    a0=1.6
    a1=-30
    a2=2050
    a3=2400
    a4=8.7
    a5=0.014
    a6=-0.24
    a7=1.0
    a8=-0.03
    a9=-0.0013
    a10=-0.15
    a111=-8.5
    a112=-0.29
    a12=17.8
    a13=-2.4
    b0=1.6
    b1=-60
    b2=1850
    b3=23.3
    b4=350
    b5=0.05
    b6=0
    b7=0.055
    b8=-0.024
    b9=0
    b10=0
    c0=2.2
    c1=-3.9
    c2=-3.9
    c3=-1.26
    c4=-8.2
    c5=0.025
    c6=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.145
}
wheel_front
{
  y=0       ; leave at 0 or get Qlog error
  z=0       ; leave at 0 or get Qlog error
  camber=0
  steering=1
  powered=0
  lock=50   ; best 45
  mass=5
  inertia=1
  radius=0.305   ;0.3086
  rolling_coeff=0.015
  max_braking=2100
  braking_factor=0.4
  max_handbrake_torque=-500
  tire_rate=500000
  skidding
  {
    ; Slip ratio
    long_start=0.2
    long_max=1.0
    ; Negative slip ratio
    long_start_n=0.2
    long_max_n=1.0
    ; Lateral; slip velocity
    lat_start=0.2
    lat_max=2.0
  }
  pacejka~pacejka
  {
  ;a2=1300
  ;b2=1340
  }
  ; Brakedisc temperature  ;0.003
  brake_heating=0.03
  brake_dissipation=0.0005
  brake_max_temp=1000
}
wheel_rear
{
  y=0       ; leave at 0 or get Qlog error
  z=0       ; leave at 0 or get Qlog error
  camber=-0.50
  steering=0
  powered=1
  mass=5
  inertia=1
  radius=0.305   ;.3086
  rolling_coeff=0.015
  max_braking=2100
  braking_factor=0.6
  tire_rate=800000
  pacejka~pacejka
  skidding
  {
    ; Slip ratio
    long_start=0.2
    long_max=1.0
    ; Negative slip ratio
    long_start_n=0.2
    long_max_n=1.0
    ; Lateral; slip velocity
    lat_start=0.2
    lat_max=2.0
  }
  ; Brakedisc temperature  ;0.003
  brake_heating=0.03
  brake_dissipation=0.0005
  brake_max_temp=1000
}
wheel0~wheel_front
{
  powered=0
  power_gearing=0
  ;
  toe=-0.5
  ackerman=1.1
  model
  {
    file=wheel_0.dof
  }
  model_brake
  {
    file=rear_axle_0.dof
  }
}
wheel1~wheel_front
{
  powered=0
  power_gearing=0
  ;
  toe=0.5
  ackerman=-1.1
  model
  {
    file=wheel_1.dof
  }
  model_brake
  {
    file=rear_axle_1.dof
  }
 }
wheel2~wheel_rear
{
  ; 4WD test
  powered=1
  power_gearing=0.50
  ;
  toe=0
  model
  {
    file=wheel_0.dof
  }
  model_brake
  {
    file=rear_axle_0.dof
  }
}
wheel3~wheel_rear
{
  ; 4WD test
  powered=1
  power_gearing=0.50
  ;
  toe=0
  model
  {
    file=wheel_1.dof
  }
  model_brake
  {
    file=rear_axle_1.dof
  }
}
camera0
{
  offset
  {
    x=0.059375
    y=-0.700001
    z=-4.715009
  }
  angle
  {
    x=6.666651
    y=-180.729126
    z=0.000000
  }
  name=Close behind
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  fov=35
}
camera1
{
  offset
  {
    x=0.029688
    y=-0.904162
    z=-6.870018
  }
  angle
  {
    x=6.000
    y=180.000
    z=0.000000
  }
  name=Behind
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  fov=35
}
camera2
{
  offset
  {
    x=0
    y=-0.7
    z=0.83
  }
  angle
  {
    x=2
    y=180
    z=0.000000
  }
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  fov=35
}
camera3
{
  follow
  {
    pitch=
    yaw=1
    roll=
  }
  offset
  {
    x=0.221878
    y=0.508334
    z=-6.635028
  }
  angle
  {
    x=16.388876
    y=-56.944256
    z=1.302094
  }
  name=Wheels
  fov=40
}
camera4
{
  offset
  {
    x=-0.410   ;+left/-right
    y=-0.650   ;-up/+down
    z=-0.700   ;+fwd/-back
  }
  angle
  {
    x=0.000000
    y=145   ;180.000000
    z=0.000000
  }
  follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  fov=50
  model=0
  wheels=0
  view=0
  name=Passenger Cam
}
camera5
{
  follow
  {
    pitch=0
    yaw=1
    roll=0
  }
  offset
  {
    x=0.198437
    y=0.464583
    z=-6.320009
  }
  angle
  {
    x=9.444325
    y=-268.750336
    z=0.086801
  }
  name=High
  fov=40
}
camera6
{
  follow
  {
    pitch=1
    yaw=1
    roll=0
  }
  offset
  {
    x=-0.037500
    y=0.489584
    z=-4.555015
  }
  angle
  {
    x=86.527802
    y=-308.854156
    z=11.718752
  }
  fov=45   ;60
}
camera7
{
  offset
  {
    x=-0.151565
    y=0.489580
    z=-6.395005
  }
  angle
  {
    x=7.083300
    y=-143.576736
    z=3.298599
  }
  follow
  {
    pitch=0
    yaw=1
    roll=1
  }
  fov=35
}
camera8
{
  front   ;follow
  {
    pitch=1
    yaw=1
    roll=1
  }
  offset
  {
    x=0.000002
    y=-0.918743
    z=1.600000   ;0.430004
  }
  angle
  {
    x=6.944441
    y=360.000000   ;-361.249451
    z=0.000000
  }
  fov=75
}
camera9
{
  offset
  {
    x=0.3600   ;+left/-right
    y=-0.55   ;-up/+down
    z=-0.1600   ;+fwd/-back
  }
  angle
  {
    x=-2.5   ; tilt camera +down/-up
    y=180    ;rotate camera +left/-right
    z=0.0   ;tilt camera +clockwise/-ccw
  }
  name=Inside Driver
    fov=65
  ; Type of model to use; 0=outside, 1=inside, 2=none
  model=0
  wheels=0
  view=2
}
audio
{
  skid
  {
    sample=skid.wav
    sample2=skid2.wav
  }
  skid
  {
   skidding
   {
    ; slip ratio
    long_start=1.01
    long_max=10.9
    ; negative slip ratio
    long_start_n=1.01
    long_max_n=10.9
    ; lateral slip velocity
    lat_start=10
    lat_max=30
    }
   } 
   shiftin
  {
    sample=shift.wav
  }
  shiftout
  {
    sample=shift.wav
  }
  horn
  {
    sample=horn.wav
  }
 acc_all
  {
    attack=1000
    decay=1000
  }
  accelerate_out
  {
    smp0~audio.acc_all
    {
      volume=1
      sample=engine.wav
      min=0
      max=10000
      natural=4000
    }
  }
  decelerate_out
  {
	smp0~audio.acc_all
	{
         volume=1
         sample=engine.wav
	   min=0
	   max=10000
	   natural=4000
	}
  }
  gearwhine
  {
    ; Volume determination
    volume=0.1   ; range 0-1
    volume_scale=1
    ;volume_offset=0
    ; Pitch input is shaft rotational velocity in radians/sec
    pitch_scale=0.9
    pitch_offset=1
    ; Acceleration; outside of the car
    smp0
    {
      ; All engine samples depend on engine RPM, this one on car velocity S/B RPM
      sample=gearwhine.wav
      min=0
      max=9999
      natural=2
    }
  }
  wind
  {
    ; Volume determination
    volume=0.1   ; range 0-1
    volume_scale=1
    ; volume_offset=0
    ; Pitch determination
    pitch_scale=0.01
    pitch_offset=0
    smp0
    {
      sample=wind.wav
      ; Speeds in m/s
      min=0
      max=9999
      natural=10
    }
  }
}