<?xml version="1.0" encoding="UTF-8"?>

<!-- ########################################

 # DR400-jsbSim by PAF team
 # April 2012 : Modified by PAF team
 # http://equipe-flightgear.forumactif.com

##########################################-->

<PropertyList>
  <path>Lights.ac</path>
  <nopreview/>

  <animation>
    <type>select</type>
    <!--<object-name>light-volume</object-name>-->
    <object-name>red-light-plate</object-name>
    <object-name>green-light-plate</object-name>
    <object-name>white-light-plate</object-name>
    <object-name>blue-light-plate</object-name>
    <!--<object-name>lnd-light-plate</object-name>-->
  </animation>

  <effect>
    <inherits-from>Effects/model-transparent</inherits-from>
    <object-name>lnd-light-plate</object-name>
  </effect>

  <animation>
    <type>select</type>
    <object-name>lnd-light-plate</object-name>
    <condition>
      <and>
        <property>sim/multiplay/generic/int[11]</property>
        <greater-than>
          <property>sim/multiplay/generic/float[8]</property>
          <value>8</value>
        </greater-than>
      </and>
    </condition>
  </animation>

  <animation>
    <type>material</type>
    <object-name>lnd-light-plate</object-name>
    <emission>
      <red>   0.027 </red>
      <green> 0.027 </green>
      <blue>  0.027 </blue>
      <factor-prop>sim/multiplay/generic/float[5]</factor-prop>
    </emission>
  </animation>

   <animation>
    <type>light</type>
    <light-type>spot</light-type>
    <object-name>light-volume</object-name>
    <position>
      <x> 0 </x>
      <y> 0 </y>
      <z> 0 </z>
    </position>
    <direction>
      <x> -0.998 </x>
      <y>  0.000 </y>
      <z>  0.125 </z>
    </direction>
    <ambient>
      <r>  0.3 </r>
      <g>  0.3 </g>
      <b>  0.3 </b>
      <a>  1.0 </a>
    </ambient>
    <diffuse>
      <r>  0.8 </r>
      <g>  0.8 </g>
      <b>  0.8 </b>
      <a>  1.0 </a>
    </diffuse>
    <specular>
      <r>  0.5 </r>
      <g>  0.5 </g>
      <b>  0.5 </b>
      <a>  1.0 </a>
    </specular>
    <dim-factor>
      <!--<property>systems/electrical/outputs/landing-lights</property>-->
      <property>sim/multiplay/generic/float[5]</property>
      <!-- optional begin -->
      <factor>0.04</factor>
      <offset>0</offset>
      <min>0</min>
      <max>1</max>
      <!-- optional end -->
    </dim-factor>
    <attenuation>
      <c>  0.200 </c>
      <l>  0.000 </l>
      <q>  0.002 </q>
    </attenuation>
    <exponent> 24.0 </exponent>
    <cutoff>   60.0 </cutoff>
    <near-m>    2.5 </near-m>
    <far-m>   240.0 </far-m>
  </animation>

  <animation>
    <type>select</type>
    <object-name>light-volume</object-name>
    <condition>
      <greater-than>
        <property>sim/multiplay/generic/float[5]</property>
        <value>9</value>
      </greater-than>
    </condition>
  </animation>

<!-- If you need to change scale of the light source, use and adapt : -->
  <animation>
    <type>scale</type>
    <object-name>light-volume</object-name>
    <x-offset> 8.0 </x-offset>
    <y-offset> 8.0 </y-offset>
    <z-offset> 8.0 </z-offset>
  </animation>

</PropertyList>
