<?xml version="1.0"?>

<!--Vertical Display Indicator F-14B -->

<PropertyList>
	<path>vdi.ac</path>

	<animation>
		<type>select</type>
		<object-name>vdi</object-name>
		<condition>
			<equals>
				<property>sim/current-view/name</property>
				<value>Cockpit View</value>
			</equals>
		</condition>
	</animation>

	<effect>
		<inherits-from>Aircraft/f-14b/Effects/model-transparent</inherits-from>
		<object-name>ap-heading-lock</object-name>
		<object-name>ap-altitude-lock</object-name>
		<object-name>ap-attitude-lock</object-name>
		<object-name>ap-altitude</object-name>
		<object-name>ap-attitude</object-name>
		<object-name>ap-heading</object-name>
		<object-name>apc</object-name>
		<object-name>dlc</object-name>
		<object-name>ground</object-name>
		<object-name>sky</object-name>
		<object-name>compas</object-name>
		<object-name>pitch-ladder</object-name>
		<object-name>static-indexes</object-name>
		<object-name>reticle</object-name>
		<object-name>ref-bars</object-name>
		<object-name>horizon-line</object-name>
		<object-name>bank-index</object-name>
		<object-name>compas-index</object-name>
		<object-name>rudder-index</object-name>
	</effect>

	<!-- vdi on-off -->
	<animation>
		<type>select</type>
		<object-name>display</object-name>
		<condition>
			<greater-than>
				<property>/fdm/jsbsim/systems/electrics/ac-left-main-bus</property>
				<value>0</value>
			</greater-than>
			<property>sim/model/f-14b/controls/VDI/on-off</property>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>screen-bkg-off</object-name>
		<condition>
            <or>
                <less-than>
                    <property>/fdm/jsbsim/systems/electrics/ac-left-main-bus</property>
                    <value>1</value>
                </less-than>
                <not>
                    <property>sim/model/f-14b/controls/VDI/on-off</property>
                </not>
            </or>
        </condition>
	</animation>

	<!-- sky -->
	<animation>
		<name>sky-roll-rotation</name>
		<type>rotate</type>
		<object-name>sky</object-name>
		<property>orientation/roll-deg</property>
		<factor>1</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0.0054</z-m>
		</center>
		<axis>
			<x>1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>
	<animation>
		<name>sky-pitch-translation</name>
		<type>translate</type>
		<object-name>sky</object-name>
		<property>orientation/pitch-deg</property>
		<interpolation>
			<entry><ind>-90</ind><dep>-0.1090</dep></entry>
			<entry><ind>-50</ind><dep>-0.1090</dep></entry>
			<entry><ind>0</ind><dep>0</dep></entry>
			<entry><ind>50</ind><dep>0.1090</dep></entry>
			<entry><ind>90</ind><dep>0.1090</dep></entry>
		</interpolation>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0</z-m>
		</center>
		<axis>
			<x>0</x>
			<y>0</y>
			<z>-1</z>
		</axis>
	</animation>
	<animation>
		<name>sky-pitch-scale</name>
		<type>scale</type>
		<object-name>sky</object-name>
		<property>orientation/pitch-deg</property>
		<z-min>1</z-min>
		<z-max>2</z-max>
		<x-factor>0</x-factor>
		<y-factor>0</y-factor>
		<z-factor>0.015</z-factor>
		<x-offset>1</x-offset>
		<y-offset>1</y-offset>
		<z-offset>1</z-offset>
	</animation>
	<animation>
		<name>horizon-line-roll-rotation</name>
		<type>rotate</type>
		<object-name>horizon-line</object-name>
		<property>orientation/roll-deg</property>
		<factor>1</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0.0054</z-m>
		</center>
		<axis>
			<x>1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>
	<animation>
		<name>horizon-line-pitch-translation</name>
		<type>translate</type>
		<object-name>horizon-line</object-name>
		<property>orientation/pitch-deg</property>
		<factor>0.00218</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0</z-m>
		</center>
		<axis>
			<x>0</x>
			<y>0</y>
			<z>-1</z>
		</axis>
	</animation>

	<!-- ground -->
	<animation>
		<name>ground-roll-rotation</name>
		<type>rotate</type>
		<object-name>ground</object-name>
		<property>orientation/roll-deg</property>
		<factor>1</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0.0054</z-m>
		</center>
		<axis>
			<x>1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>
	<animation>
		<type>textranslate</type>
		<object-name>ground</object-name>
		<property>sim/model/f-14b/instrumentation/ticker</property>
		<factor>0.0025</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
		</center>
		<axis>
			<x>0</x>
			<y>1</y>
		</axis>
	</animation>

	
	<!-- heading tape -->	
	<animation>
		<type>textranslate</type>
		<object-name>compas</object-name>
		<property>orientation/heading-magnetic-deg</property>
		<factor>0.002777778</factor>
		<step>1</step>
		<scroll>1</scroll>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
		</center>
		<axis>
			<x>1</x>
			<y>0</y>
		</axis>
	</animation>
 
	<!-- pitch ladder -->	
	<animation>
		<type>rotate</type>
		<object-name>pitch-ladder</object-name>
		<property>orientation/roll-deg</property>
		<factor>1</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0</z-m>
		</center>
		<axis>
			<x>1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>
	<animation>
		<type>textranslate</type>
		<object-name>pitch-ladder</object-name>
		<property>orientation/pitch-deg</property>
		<interpolation>
			<entry><ind>90</ind><dep>0.25</dep></entry>
			<entry><ind>0</ind><dep>0</dep></entry>
			<entry><ind>-90</ind><dep>-0.25</dep></entry>
		</interpolation>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
		</center>
		<axis>
			<x>0</x>
			<y>1</y>
		</axis>
	</animation>
 
	<!-- bank-index -->
	<animation>
		<type>rotate</type>
		<object-name>bank-index</object-name>
		<property>orientation/roll-deg</property>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0</z-m>
		</center>
		<axis>
			<x>-1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>

	<animation>
		<type>translate</type>
		<object-name>rudder-index</object-name>
		<property>controls/flight/rudder</property>
		<factor>0.07B5</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0</y-m>
			<z-m>0</z-m>
		</center>
		<axis>
			<x>0</x>
			<y>1</y>
			<z>0</z>
		</axis>
		<y-max>0.0756</y-max>
	</animation>

	<!-- hud red filter knob -->
	<animation>
		<name>hud-filer-knob-rotation</name>
		<type>rotate</type>
		<object-name>filter-knob</object-name>
		<property>sim/hud/current-color</property>
		<factor>85</factor>
		<center>
			<x-m>0</x-m>
			<y-m>0.1086</y-m>
			<z-m>0.0008</z-m>
		</center>
		<axis>
			<x>-1</x>
			<y>0</y>
			<z>0</z>
		</axis>
	</animation>


	<!-- warnings -->
	<animation>
		<type>select</type>
		<object-name>reduce-speed</object-name>
		<condition>
			<greater-than>
				<property>/fdm/jsbsim/systems/electrics/ac-essential-bus1</property>
				<value>0</value>
			</greater-than>
			<or>
				<greater-than>
					<property>instrumentation/airspeed-indicator/indicated-speed-kt</property>
					<property>sim/model/f-14b/instrumentation/airspeed-indicator/safe-speed-limit-bug</property>
				</greater-than>
				<and>
					<greater-than>
						<property>instrumentation/airspeed-indicator/indicated-speed-kt</property>
						<value>225</value>
					</greater-than>
					<greater-than>
						<property>surface-positions/flap-pos-norm</property>
						<value>0.5</value>
					</greater-than>
				</and>
			</or>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>alt-low</object-name>
		<condition>
			<greater-than>
				<property>/fdm/jsbsim/systems/electrics/ac-essential-bus1</property>
				<value>0</value>
			</greater-than>
			<less-than>
				<property>orientation/roll-deg</property>
				<value>45</value>
			</less-than>
			<greater-than>
				<property>orientation/roll-deg</property>
				<value>-45</value>
			</greater-than>
			<less-than>
				<property>orientation/pitch-deg</property>
				<value>45</value>
			</less-than>
			<greater-than>
				<property>orientation/pitch-deg</property>
				<value>-45</value>
			</greater-than>
			<less-than>
				<property>position/altitude-agl-ft</property>
				<property>sim/model/f-14b/instrumentation/radar-altimeter/limit-bug</property>
			</less-than>
		</condition>
	</animation>

	<!-- Autopilot -->
	<animation>
		<type>select</type>
		<object-name>ap-attitude</object-name>
		<condition>
			<property>sim/model/f-14b/controls/AFCS/engage</property>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>ap-altitude</object-name>
		<condition>
			<property>sim/model/f-14b/controls/AFCS/altitude</property>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>ap-heading</object-name>
		<condition>
			<equals>
				<property>sim/model/f-14b/controls/AFCS/heading-gt</property>
				<value>1</value>
			</equals>
		</condition>
	</animation>

	<animation>
		<type>select</type>
		<object-name>ap-attitude-lock</object-name>
		<condition>
			<equals>
				<property>autopilot/locks/heading</property>
				<value>wing-leveler</value>
			</equals>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>ap-altitude-lock</object-name>
		<condition>
			<equals>
				<property>/autopilot/locks/altitude</property>
				<value>altitude-hold</value>
			</equals>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>ap-heading-lock</object-name>
		<condition>
			<equals>
				<property>autopilot/locks/heading</property>
				<value>dg-heading-hold</value>
			</equals>
		</condition>
	</animation>

	<animation>
		<type>select</type>
		<object-name>apc</object-name>
		<condition>
			<equals>
				<property>autopilot/locks/aoa</property>
				<value>APC</value>
			</equals>
		</condition>
	</animation>
	<animation>
		<type>select</type>
		<object-name>dlc</object-name>
		<condition>
			<property>controls/flight/DLC-engaged</property>
		</condition>
	</animation>

	<animation>
		<type>select</type>
		<object-name>ap-ref</object-name>
		<condition>
			<greater-than>
				<property>/fdm/jsbsim/systems/electrics/ac-left-main-bus</property>
				<value>0</value>
			</greater-than>
			<property>sim/model/f-14b/controls/AFCS/altitude-enable</property>
		</condition>
	</animation>


	<!-- lighting -->

	<animation>
		<object-name>sky</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/contrast</factor-prop>
			<red>0.0</red>
			<green>0.7</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ground</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/contrast</factor-prop>
			<red>0.0</red>
			<green>0.7</green>
			<blue>0.0</blue>
		</emission>
	</animation>

	<animation>
		<object-name>display</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.7</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<!--<animation>
		<object-name>dlc</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-attitude</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-altitude</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-heading</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-attitude-lock</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-altitude-lock</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ap-heading-lock</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>


	<animation>
		<object-name>pitch-ladder</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.7</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>compas</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>1.0</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>compas-index</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.75</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>horizon-line</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.70</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>reticle</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.60</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>ref-bars</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.60</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>bank-index</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.75</green>
			<blue>0.0</blue>
		</emission>
	</animation>
	<animation>
		<object-name>rudder-index</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/VDI/brightness</factor-prop>
			<red>0.0</red>
			<green>0.4</green>
			<blue>0.0</blue>
		</emission>
	</animation>-->

	<animation>
		<object-name>casing</object-name>
		<type>material</type>
        <condition>
            <greater-than>
                <property>/fdm/jsbsim/systems/electrics/ac-essential-bus1</property>
                <value>0</value>
            </greater-than>
            <not>
                <property>sim/rendering/rembrandt/enabled</property>
            </not>
        </condition>
        <emission>
			<factor-prop>controls/lighting/panel-norm</factor-prop>
			<red>0.55</red>
			<green>0.24</green>
			<blue>0.10</blue>
		</emission>
	</animation>

	<animation>
		<object-name>warnings</object-name>
		<type>material</type>
		<emission>
			<factor-prop>sim/model/f-14b/controls/lighting/index-norm</factor-prop>
			<red>1</red>
			<green>1</green>
			<blue>1</blue>
		</emission>
	</animation>



	<animation>
		<type>range</type>
		<min-m>0</min-m>
		<max-m>50</max-m>
	</animation>

</PropertyList>
