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

<!-- KI 227
     ADF Heading Indicator -HSI driven compass card
     Syd Adams

     Updated : BARANGER Emmanuel 11/2022
-->
<PropertyList>

  <path>ki227.ac</path>

  <animation>
    <object-name>bezel</object-name>
    <object-name>ring</object-name>
    <object-name>needle</object-name>
    <object-name>knob</object-name>
    <object-name>face</object-name>

    <object-name>vitre</object-name>
  </animation>

  <animation>
    <type>noshadow</type>
    <object-name>bezel</object-name>
    <object-name>ring</object-name>
    <object-name>needle</object-name>
    <object-name>knob</object-name>
    <object-name>face</object-name>
    <object-name>vitre</object-name>
  </animation>

  <!-- working for Compositor -->
  <effect>
    <inherits-from>../../../../Effects/Glass/glass</inherits-from>
    <object-name>vitre</object-name>
  </effect>

  <animation>
    <type>material</type>
    <object-name>ring</object-name>
    <object-name>needle</object-name>
    <object-name>knob</object-name>
    <object-name>face</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>rotate</type>
    <object-name>ring</object-name>
    <property>instrumentation/adf[0]/rotation-deg</property>
    <property>instrumentation/heading-indicator/indicated-heading-deg</property>
    <condition>
      <not>
        <equals>
          <property>instrumentation/adf[0]/model</property>
          <value>ki228</value>
        </equals>
      </not>
    </condition>
    <factor> -1 </factor>
    <axis>
      <x> -1 </x>
      <y>  0 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>ring</object-name>
    <property>instrumentation/heading-indicator/indicated-heading-deg</property>
    <condition>
      <equals>
        <property>instrumentation/adf[0]/model</property>
        <value>ki228</value>
      </equals>
    </condition>
    <factor> -1 </factor>
    <axis>
      <x> -1 </x>
      <y>  0 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>needle</object-name>
    <property>instrumentation/adf[0]/indicated-bearing-deg</property>
    <axis>
      <x> -1 </x>
      <y>  0 </y>
      <z>  0 </z>
    </axis>
  </animation>

  <animation>
    <type>rotate</type>
    <object-name>knob</object-name>
    <property>instrumentation/adf[0]/rotation-deg</property>
    <factor>8.0</factor>
    <center>
      <x-m>  0.00000 </x-m>
      <y-m> -0.03435 </y-m>
      <z-m> -0.03417 </z-m>
    </center>
    <axis>
      <x> 1 </x>
      <y> 0 </y>
      <z> 0 </z>
    </axis>
  </animation>

  <animation>
    <type>pick</type>
    <object-name>knob</object-name>
    <visible>true</visible>
    <action>
      <name>Small up</name>
      <button>0</button>
      <repeatable>true</repeatable>
      <binding>
        <command>property-adjust</command>
        <property>instrumentation/adf[0]/rotation-deg</property>
        <step> 1</step>
        <min>  0</min>
        <max>360</max>
        <wrap>1</wrap>
      </binding>
    </action>
    <action>
      <name>Small down</name>
      <button>1</button>
      <repeatable>true</repeatable>
      <binding>
        <command>property-adjust</command>
        <property>instrumentation/adf[0]/rotation-deg</property>
        <step>-1</step>
        <min>  0</min>
        <max>360</max>
        <wrap>1</wrap>
      </binding>
    </action>
    <action>
      <name>Big up</name>
      <button>3</button>
      <repeatable>true</repeatable>
      <binding>
        <command>property-adjust</command>
        <property>instrumentation/adf[0]/rotation-deg</property>
        <step> 5</step>
        <min>  0</min>
        <max>360</max>
        <wrap>1</wrap>
      </binding>
    </action>
    <action>
      <name>Big down</name>
      <button>4</button>
      <repeatable>true</repeatable>
      <binding>
        <command>property-adjust</command>
        <property>instrumentation/adf[0]/rotation-deg</property>
        <step>-5</step>
        <min>  0</min>
        <max>360</max>
        <wrap>1</wrap>
      </binding>
    </action>
  </animation>

  <!-- Label Text -->
  <text>
    <name>LabelText</name>
    <type type="string">literal</type>
    <text type="string">ADF Indicator</text>
    <draw-text type="bool">true</draw-text>
    <font>Helvetica.txf</font>
    <character-size type="double">0.012</character-size>
    <character-aspect-ratio type="double">1.0</character-aspect-ratio>
    <axis-alignment>yz-plane</axis-alignment>
    <max-height>0.2</max-height>
    <max-width>0.07</max-width>
    <font-resolution>
      <width type="int">32</width>
      <height type="int">32</height>
    </font-resolution>
    <alignment>center-center</alignment>
    <offsets>
      <x-m> 0.01 </x-m>
      <y-m> 0.00 </y-m>
      <z-m> 0.00 </z-m>
    </offsets>
  </text>

  <animation>
    <type>material</type>
    <object-name>LabelText</object-name>
    <emission>
      <red>   1.0 </red>
      <green> 0.8 </green>
      <blue>  0.0 </blue>
    </emission>
  </animation>

  <animation>
    <type>select</type>
    <object-name>LabelText</object-name>
    <condition>
      <property>sim/panel-hotspots</property>
    </condition>
  </animation>

</PropertyList>
