<?xml version="1.0" encoding="ISO-8859-1"?>

<PropertyList>

  <path>dr400.ac</path>

  <!-- MP sound call -->
  <sound>
    <path>Aircraft/DR400/Sounds/mp-sound.xml</path>
  </sound>

  <nasal>
    <load>
      var livery_update = aircraft.livery_update.new("Aircraft/DR400/Models/Liveries", 10);
    </load>
    <unload>
      livery_update.stop();
    </unload>
  </nasal>

  <animation>
    <!-- Objets opaques -->
    <object-name>fuselage</object-name>
    <object-name>bouchon_reservoir</object-name>
    <object-name>ailes</object-name>
    <object-name>aileronG</object-name>
    <object-name>aileronD</object-name>
    <object-name>voletG</object-name>
    <object-name>voletD</object-name>
    <object-name>trimprof</object-name>
    <object-name>profondeur</object-name>
    <object-name>direction</object-name>
    <object-name>bol</object-name>
    <object-name>toitverriere</object-name>
    <object-name>axeA</object-name>
    <object-name>axeG</object-name>
    <object-name>axeD</object-name>
    <object-name>cacheA</object-name>
    <object-name>cacheG</object-name>
    <object-name>cacheD</object-name>
    <object-name>tourverriere</object-name>
    <object-name>antennes</object-name>
    <object-name>poignees_bas</object-name>
    <object-name>poignees_haut</object-name>

    <!-- Details -->
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_vis</object-name>
    <object-name>vis_sabotAB</object-name>
    <object-name>vis_sabotAH</object-name>
    <object-name>vis-bol</object-name>
    <object-name>vis_sabotG</object-name>
    <object-name>vis_sabotD</object-name>
    <object-name>vis_profondeur</object-name>

    <object-name>tringleG</object-name>
    <object-name>tringleD</object-name>
    <object-name>helice</object-name>
    <object-name>troucacheA</object-name>
    <object-name>roueA</object-name>
    <object-name>troucacheG</object-name>
    <object-name>roueG</object-name>
    <object-name>troucacheD</object-name>
    <object-name>roueD</object-name>
    <object-name>echappe</object-name>
    <object-name>trous</object-name>
    <object-name>axeflapsG</object-name>
    <object-name>axeflapsD</object-name>
    <object-name>tringleaileronG</object-name>
    <object-name>tringleaileronD</object-name>
    <object-name>lampe_aile</object-name>

    <!-- Objets transparents -->
    <object-name>verriere</object-name>
    <object-name>verriereAR</object-name>
    <object-name>lampe</object-name>
    <object-name>lampeG</object-name>
    <object-name>lampeD</object-name>
    <object-name>strobetrs</object-name>
    <object-name>propdisc</object-name>
    <object-name>propblur</object-name>
    <!-- HDR mode -->
    <object-name>HDRverriere</object-name>
    <object-name>HDRverriereAR</object-name>
    <object-name>HDRlampe</object-name>
  </animation>

  <animation>
    <type>material</type>
    <object-name>fuselage</object-name>
    <object-name>bouchon_reservoir</object-name>
    <object-name>ailes</object-name>
    <object-name>aileronG</object-name>
    <object-name>aileronD</object-name>
    <object-name>voletG</object-name>
    <object-name>voletD</object-name>
    <object-name>trimprof</object-name>
    <object-name>profondeur</object-name>
    <object-name>direction</object-name>
    <object-name>bol</object-name>
    <object-name>toitverriere</object-name>
    <object-name>axeA</object-name>
    <object-name>axeG</object-name>
    <object-name>axeD</object-name>
    <object-name>cacheA</object-name>
    <object-name>cacheG</object-name>
    <object-name>cacheD</object-name>
    <object-name>tourverriere</object-name>
    <object-name>antennes</object-name>
    <object-name>poignees_bas</object-name>
    <object-name>poignees_haut</object-name>
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_vis</object-name>
    <object-name>vis_sabotAB</object-name>
    <object-name>vis_sabotAH</object-name>
    <object-name>vis-bol</object-name>
    <object-name>vis_sabotG</object-name>
    <object-name>vis_sabotD</object-name>
    <object-name>vis_profondeur</object-name>
    <object-name>tringleG</object-name>
    <object-name>tringleD</object-name>
    <object-name>helice</object-name>
    <object-name>troucacheA</object-name>
    <object-name>roueA</object-name>
    <object-name>troucacheG</object-name>
    <object-name>roueG</object-name>
    <object-name>troucacheD</object-name>
    <object-name>roueD</object-name>
    <object-name>echappe</object-name>
    <object-name>trous</object-name>
    <object-name>axeflapsG</object-name>
    <object-name>axeflapsD</object-name>
    <object-name>tringleaileronG</object-name>
    <object-name>tringleaileronD</object-name>
    <object-name>lampe_aile</object-name>
    <object-name>verriere</object-name>
    <object-name>verriereAR</object-name>
    <object-name>lampe</object-name>
    <object-name>lampeG</object-name>
    <object-name>lampeD</object-name>
    <object-name>strobetrs</object-name>
    <object-name>propdisc</object-name>
    <object-name>propblur</object-name>
    <object-name>HDRverriere</object-name>
    <object-name>HDRverriereAR</object-name>
    <object-name>HDRlampe</object-name>

    <property-base>sim/model/livery</property-base>
    <texture-prop>texture</texture-prop>
    <texture>texture.png</texture>
    <specular>
      <red-prop>specular/red</red-prop>
      <green-prop>specular/green</green-prop>
      <blue-prop>specular/blue</blue-prop>
    </specular>
  </animation>

  <effect>
    <inherits-from>Aircraft/DR400/Models/Effects/Bump/bumpspec</inherits-from>
    <object-name>fuselage</object-name>
    <object-name>bouchon_reservoir</object-name>
    <object-name>ailes</object-name>
    <object-name>aileronG</object-name>
    <object-name>aileronD</object-name>
    <object-name>voletG</object-name>
    <object-name>voletD</object-name>
    <object-name>trimprof</object-name>
    <object-name>profondeur</object-name>
    <object-name>direction</object-name>
    <object-name>bol</object-name>
    <object-name>toitverriere</object-name>
    <object-name>axeA</object-name>
    <object-name>axeG</object-name>
    <object-name>axeD</object-name>
    <object-name>cacheA</object-name>
    <object-name>cacheG</object-name>
    <object-name>cacheD</object-name>
    <object-name>tourverriere</object-name>
    <object-name>antennes</object-name>
    <object-name>poignees_bas</object-name>
    <object-name>poignees_haut</object-name>
    <!-- Details -->
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_vis</object-name>
    <object-name>vis_sabotAB</object-name>
    <object-name>vis_sabotAH</object-name>
    <object-name>vis-bol</object-name>
    <object-name>vis_sabotG</object-name>
    <object-name>vis_sabotD</object-name>
    <object-name>vis_profondeur</object-name>
  </effect>

  <!-- working for Compositor -->
  <effect>
    <inherits-from>Effects/Glass/glassrain</inherits-from>
    <object-name>verriere</object-name>
    <object-name>verriereAR</object-name>
    <object-name>lampe</object-name>
  </effect>

  <effect>
    <inherits-from>Effects/Glass/glass</inherits-from>
    <object-name>HDRverriere</object-name>
    <object-name>HDRverriereAR</object-name>
    <object-name>HDRlampe</object-name>
  </effect>

  <!-- Sélection des vitres en fonction de HDR ou pas -->
  <animation>
    <type>select</type>
    <condition>
      <!-- <property>sim/rendering/hdr/hdr-enabled</property> -->
      <property>sim/multiplay/generic/bool[2]</property>
    </condition>
    <object-name>HDRverriere</object-name>
    <object-name>HDRverriereAR</object-name>
    <object-name>HDRlampe</object-name>
  </animation>

  <animation>
    <type>select</type>
    <condition>
      <!-- <not><property>sim/rendering/hdr/hdr-enabled</property></not> -->
      <not><property>sim/multiplay/generic/bool[2]</property></not>
    </condition>
    <object-name>verriere</object-name>
    <object-name>verriereAR</object-name>
    <object-name>lampe</object-name>
  </animation>

  <effect>
    <inherits-from>Effects/model-transparent</inherits-from>
    <object-name>lampeG</object-name>
    <object-name>lampeD</object-name>
    <object-name>strobetrs</object-name>
    <object-name>propdisc</object-name>
    <object-name>propblur</object-name>
  </effect>

  <model>
    <path>Interior/interior.xml</path>
  </model>

  <model>
    <path>Immat/immat.xml</path>
  </model>

  <model>
    <path>Effects/ground/all-ground.xml</path>
  </model>

  <model>
    <path>Effects/cranking/all-crankings.xml</path>
  </model>

  <model>
    <path>light/all-lights.xml</path>
  </model>

  <!-- Détails -->
  <animation>
    <name>Details</name>
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_vis</object-name>
    <object-name>vis_sabotAB</object-name>
    <object-name>vis_sabotAH</object-name>
    <object-name>vis-bol</object-name>
    <object-name>vis_sabotG</object-name>
    <object-name>vis_sabotD</object-name>
    <object-name>vis_profondeur</object-name>
  </animation>

  <animation>
    <type>select</type>
    <object-name>Details</object-name>
    <condition>
      <!-- <property>sim/model/config/details-high</property> -->
      <property>sim/multiplay/generic/bool[1]</property>
    </condition>
  </animation>

  <!-- L'hélice -->
  <animation>
    <name>HeliceComplete</name>
    <object-name>propdisc</object-name>
    <object-name>propblur</object-name>
    <object-name>helice</object-name>
    <object-name>bol</object-name>
    <object-name>vis-bol</object-name>
  </animation>

  <!-- Séléction de l'objet visible en fonction des rpm -->
  <animation>
    <type>select</type>
    <object-name>propdisc</object-name>
    <condition>
      <greater-than>
        <property>engines/engine[0]/rpm</property>
        <value>1500</value>
      </greater-than>
    </condition>
  </animation>

  <animation>
    <type>select</type>
    <object-name>propblur</object-name>
    <condition>
    <and>
      <greater-than>
        <property>engines/engine[0]/rpm</property>
        <value>600.000</value>
      </greater-than>
      <less-than>
        <property>engines/engine[0]/rpm</property>
        <value>1500.001</value>
      </less-than>
    </and>
    </condition>
  </animation>

  <animation>
    <type>select</type>
    <object-name>helice</object-name>
    <condition>
      <less-than>
        <property>engines/engine[0]/rpm</property>
        <value>1500</value>
      </less-than>
    </condition>
  </animation>

  <animation>
    <type>spin</type>
    <object-name>HeliceComplete</object-name>
    <property>engines/engine[0]/rpm</property>
    <factor> 1 </factor>
    <center>
      <x-m> -3.274 </x-m>
      <y-m>  0.000 </y-m>
      <z-m>  0.029 </z-m>
    </center>
    <axis>
      <x> -1 </x>
      <y>  0 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <!-- Gouverne de profondeur -->
  <animation>
    <name>ProfondeurComplete</name>
    <object-name>profondeur</object-name>
    <object-name>trimprof</object-name>
    <object-name>vis_profondeur</object-name>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>ProfondeurComplete</object-name>
    <!-- <property>controls/flight/elevator</property> -->
    <property>surface-positions/elevator-pos-norm</property>
    <interpolation>
      <entry><ind> -0.75 </ind><dep> -12.0 </dep></entry>
      <entry><ind>  0.00 </ind><dep>   0.0 </dep></entry>
      <entry><ind>  0.75 </ind><dep>   9.5 </dep></entry>
    </interpolation>
    <center>
      <x-m> 2.543 </x-m>
      <y-m> 0.000 </y-m>
      <z-m> 0.154 </z-m>
    </center>
    <axis>
      <x> 0 </x>
      <y> 1 </y>
      <z> 0 </z>
    </axis>
  </animation>

  <!-- Gouverne de direction -->
  <animation>
    <type>rotate</type>
    <object-name>direction</object-name>
    <!-- <property>controls/flight/rudder</property> -->
    <property>surface-positions/rudder-pos-norm</property>
    <interpolation>
      <entry><ind> -0.75 </ind><dep> -25 </dep></entry>
      <entry><ind>  0.00 </ind><dep>   0 </dep></entry>
      <entry><ind>  0.75 </ind><dep>  25 </dep></entry>
    </interpolation>
    <axis>
      <x1-m>  2.878 </x1-m>
      <y1-m>  0.000 </y1-m>
      <z1-m> -0.193 </z1-m>
      <x2-m>  3.093 </x2-m>
      <y2-m>  0.000 </y2-m>
      <z2-m>  1.096 </z2-m>
    </axis>
  </animation>

  <!-- Animations des ailerons -->
  <animation>
    <type>rotate</type>
    <object-name>aileronG</object-name>
    <property>surface-positions/left-aileron-pos-norm</property>
    <interpolation>
      <entry><ind> -0.75 </ind><dep> -15 </dep></entry>
      <entry><ind>  0.00 </ind><dep>   0 </dep></entry>
      <entry><ind>  0.75 </ind><dep>  10 </dep></entry>
    </interpolation>
    <axis>
      <x1-m> -1.031 </x1-m>
      <y1-m> -4.331 </y1-m>
      <z1-m> -0.002 </z1-m>
      <x2-m> -0.430 </x2-m>
      <y2-m> -2.751 </y2-m>
      <z2-m> -0.390 </z2-m>
    </axis>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>aileronD</object-name>
    <property>surface-positions/right-aileron-pos-norm</property>
    <interpolation>
      <entry><ind> -0.75 </ind><dep> -15 </dep></entry>
      <entry><ind>  0.00 </ind><dep>   0 </dep></entry>
      <entry><ind>  0.75 </ind><dep>  10 </dep></entry>
    </interpolation>
    <axis>
      <x1-m> -0.430 </x1-m>
      <y1-m>  2.751 </y1-m>
      <z1-m> -0.390 </z1-m>
      <x2-m> -1.031 </x2-m>
      <y2-m>  4.331 </y2-m>
      <z2-m> -0.002 </z2-m>
    </axis>
  </animation>

  <!-- Volets -->
  <animation>
    <name>LesVolets</name>
    <object-name>voletG</object-name>
    <object-name>voletD</object-name>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>LesVolets</object-name>
    <property>surface-positions/flap-pos-norm</property>
    <factor> 60 </factor>
    <center>
      <x-m> -0.211 </x-m>
      <y-m>  0.000 </y-m>
      <z-m> -0.396 </z-m>
    </center>
    <axis>
      <x> 0 </x>
      <y> 1 </y>
      <z> 0 </z>
    </axis>
  </animation>

  <!-- Compression -->
  <animation>
    <name>RoueAvant</name>
    <object-name>roueA</object-name>
    <object-name>cacheA</object-name>
    <object-name>troucacheA</object-name>
    <object-name>vis_sabotAB</object-name>
  </animation>

  <animation>
    <type>translate</type>
    <object-name>RoueAvant</object-name>
    <!-- <property>gear/gear[0]/compression-norm</property> -->
    <property>sim/multiplay/generic/float[10]</property>
    <interpolation>
      <entry><ind> 0 </ind><dep>  0.04 </dep></entry>
      <entry><ind> 1 </ind><dep> -0.25 </dep></entry>
    </interpolation>
    <axis>
      <x> -0.029387 </x>
      <y>  0.000000 </y>
      <z> -0.155914 </z>
    </axis>
  </animation>

  <animation>
    <name>RoueGauche</name>
    <object-name>roueG</object-name>
    <object-name>cacheG</object-name>
    <object-name>troucacheG</object-name>
    <object-name>vis_sabotG</object-name>
  </animation>

  <animation>
    <type>translate</type>
    <object-name>RoueGauche</object-name>
    <!-- <property>gear/gear[1]/compression-norm</property> -->
    <property>sim/multiplay/generic/float[11]</property>
    <interpolation>
      <entry><ind> 0 </ind><dep>  0.04 </dep></entry>
      <entry><ind> 1 </ind><dep> -0.25 </dep></entry>
    </interpolation>
    <axis>
      <x> -0.029387 </x>
      <y>  0.000000 </y>
      <z> -0.155914 </z>
    </axis>
  </animation>

  <animation>
    <name>RoueDroite</name>
    <object-name>roueD</object-name>
    <object-name>cacheD</object-name>
    <object-name>troucacheD</object-name>
    <object-name>vis_sabotD</object-name>
  </animation>

  <animation>
    <type>translate</type>
    <object-name>RoueDroite</object-name>
    <!-- <property>gear/gear[2]/compression-norm</property> -->
    <property>sim/multiplay/generic/float[12]</property>
    <interpolation>
      <entry><ind> 0 </ind><dep>  0.04 </dep></entry>
      <entry><ind> 1 </ind><dep> -0.25 </dep></entry>
    </interpolation>
    <axis>
      <x> -0.029387 </x>
      <y>  0.000000 </y>
      <z> -0.155914 </z>
    </axis>
  </animation>

  <!-- Rotation de la roue avant en fonction de la gouverne de direction -->
  <animation>
    <name>TrainAvant</name>
    <object-name>axeA</object-name>
    <object-name>cacheA</object-name>
    <object-name>roueA</object-name>
    <object-name>troucacheA</object-name>
    <object-name>vis_sabotAH</object-name>
    <object-name>vis_sabotAB</object-name>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>TrainAvant</object-name>
    <!-- <property>gear/gear[0]/caster-angle-deg</property> -->
    <property>sim/multiplay/generic/float[9]</property>
    <factor> -0.6 </factor>
    <center>
      <x-m> -2.560 </x-m>
      <y-m>  0.000 </y-m>
      <z-m> -0.980 </z-m>
    </center>
    <axis>
      <x> 0 </x>
      <y> 0 </y>
      <z> 1 </z>
    </axis>
  </animation>

  <!-- Rotation des roues lors du roulage -->
  <animation>
    <type>spin</type>
    <object-name>roueA</object-name>
    <!-- <property>gear/gear[0]/rollspeed-ms</property> -->
    <property>sim/multiplay/generic/float[5]</property>
    <factor> 30 </factor>
    <center>
      <x-m> -2.560 </x-m>
      <y-m>  0.000 </y-m>
      <z-m> -0.980 </z-m>
    </center>
    <axis>
      <x>  0 </x>
      <y> -1 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>spin</type>
    <object-name>roueG</object-name>
    <!-- <property>gear/gear[1]/rollspeed-ms</property> -->
    <property>sim/multiplay/generic/float[6]</property>
    <factor> 30 </factor>
    <center>
      <x-m> -1.020 </x-m>
      <y-m> -1.236 </y-m>
      <z-m> -0.980 </z-m>
    </center>
    <axis>
      <x>  0 </x>
      <y> -1 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>spin</type>
    <object-name>roueD</object-name>
    <!-- <property>gear/gear[2]/rollspeed-ms</property> -->
    <property>sim/multiplay/generic/float[7]</property>
    <factor> 30 </factor>
    <center>
      <x-m> -1.020 </x-m>
      <y-m>  1.236 </y-m>
      <z-m> -0.980 </z-m>
    </center>
    <axis>
      <x>  0 </x>
      <y> -1 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <!-- Canopy -->
  <animation>
    <type>pick</type>
    <object-name>verriere</object-name>
    <object-name>toitverriere</object-name>
    <object-name>tourverriere</object-name>
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_verriere</object-name>
    <object-name>HDRverriere</object-name>
    <visible>true</visible>
    <action>
      <button>0</button>
      <repeatable>false</repeatable>
      <binding>
        <condition>
          <and>
            <property>gear/gear[0]/wow</property>
            <property>gear/gear[1]/wow</property>
            <property>gear/gear[2]/wow</property>
            <less-than>
              <property>gear/gear[0]/rollspeed-ms</property>
              <value>10</value>
            </less-than>
          </and>
        </condition>
        <command>nasal</command>
        <script>doors.crew.toggle();</script>
      </binding>
    </action>
  </animation>

  <animation>
    <type>translate</type>
    <object-name>verriere</object-name>
    <object-name>toitverriere</object-name>
    <object-name>tourverriere</object-name>
    <object-name>ecrous-canopy</object-name>
    <object-name>ecrous_verriere</object-name>
    <object-name>HDRverriere</object-name>
    <!-- <property>sim/model/door-positions/crew/position-norm</property> -->
    <property>sim/multiplay/generic/float[0]</property>
    <interpolation>
      <entry><ind> 0 </ind><dep> 0.0 </dep></entry>
      <entry><ind> 1 </ind><dep> 0.8 </dep></entry>
    </interpolation>
    <axis>
      <x> -1 </x>
      <y>  0 </y>
      <z>  0 </z>
    </axis>
  </animation>

</PropertyList>
