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

<!--
  ELT based on an Artex ELT (now Cobham)
  Author: Pavel Cueto
  License: GPL

  Designed to work with the "ELTmessage.nas" file provided in the instrument folder.
  Be sure to link the Nasal in your -set file, typing:
  <nasal>
    <ELT>
      <file>YOUR/INSTRUMENT/FOLDER/ROUTE/HERE/ELTmessage.nas</file>
    </ELT>
  </nasal>
  Update : BARANGER Emmanuel 11/2024
-->
<PropertyList>

  <path>elt.ac</path>

  <animation>
    <!-- Objets opaques -->
    <object-name>fond</object-name>
    <object-name>SwitchUp</object-name>
    <object-name>SwitchDown</object-name>
    <object-name>Light-ON</object-name>
    <object-name>Light-OFF</object-name>
    <object-name>texte</object-name>
  </animation>

  <animation>
    <type>noshadow</type>
    <object-name>fond</object-name>
    <object-name>SwitchUp</object-name>
    <object-name>SwitchDown</object-name>
    <object-name>Light-ON</object-name>
    <object-name>Light-OFF</object-name>
    <object-name>texte</object-name>
  </animation>

  <animation>
    <type>material</type>
    <object-name>SwitchUp</object-name>
    <object-name>SwitchDown</object-name>
    <object-name>Light-ON</object-name>
    <object-name>texte</object-name>
    <condition>
      <property>controls/electric/battery-switch</property>
    </condition>
    <emission>
      <factor-prop>controls/lighting/instruments-norm</factor-prop>
      <red>   0.50 </red>
      <green> 0.40 </green>
      <blue>  0.30 </blue>
    </emission>
  </animation>

  <animation>
    <type>pick</type>
    <object-name>SwitchUp</object-name>
    <visible>true</visible>
    <action>
      <button>0</button>
      <repeatable>false</repeatable>
      <binding>
        <command>property-toggle</command>
        <property>instrumentation/elt/armed</property>
      </binding>
      <binding>
        <command>property-toggle</command>
        <property>instrumentation/elt/on</property>
      </binding>
      <binding>
        <command>property-toggle</command>
        <property>sim/model/click</property>
      </binding>
    </action>
  </animation>

  <animation>
    <type>pick</type>
    <object-name>SwitchDown</object-name>
    <visible>true</visible>
    <action>
      <button>0</button>
      <repeatable>false</repeatable>
      <binding>
        <command>property-assign</command>
        <property>instrumentation/elt/test</property>
        <value type="bool">true</value>
      </binding>
      <binding>
        <command>property-assign</command>
        <property>instrumentation/elt/armed</property>
        <value type="bool">false</value>
      </binding>
      <binding>
        <command>property-assign</command>
        <property>instrumentation/elt/on</property>
        <value type="bool">false</value>
      </binding>
      <binding>
        <command>property-toggle</command>
        <property>sim/model/click</property>
      </binding>
      <mod-up>
        <binding>
          <command>property-assign</command>
          <property>/instrumentation/elt/test</property>
          <value type="bool">false</value>
        </binding>
        <binding>
          <command>property-assign</command>
          <property>instrumentation/elt/armed</property>
          <value type="bool">true</value>
        </binding>
      </mod-up>
    </action>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>SwitchUp</object-name>
    <object-name>SwitchDown</object-name>
    <factor>-15</factor>
    <property>instrumentation/elt/test</property>
    <center>
      <x-m> 0.003 </x-m>
      <y-m> 0.000 </y-m>
      <z-m> 0.000 </z-m>
    </center>
    <axis>
      <x>  0 </x>
      <y> -1 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>SwitchUp</object-name>
    <object-name>SwitchDown</object-name>
    <property>instrumentation/elt/on</property>
    <factor> 15 </factor>
    <center>
      <x-m> 0.003 </x-m>
      <y-m> 0.000 </y-m>
      <z-m> 0.000 </z-m>
    </center>
    <axis>
      <x>  0 </x>
      <y> -1 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>select</type>
    <object-name>Light-ON</object-name>
    <condition>
      <or>
        <property>instrumentation/elt/on</property>
        <property>instrumentation/elt/test</property>
      </or>
    </condition>
  </animation>

  <animation>
    <type>select</type>
    <object-name>Light-OFF</object-name>
    <condition>
      <not>
        <or>
          <property>instrumentation/elt/on</property>
          <property>instrumentation/elt/test</property>
        </or>
      </not>
    </condition>
  </animation>

</PropertyList>
