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

<!-- Copyright (c) 2021 Josh Davidson (Octal450) -->

<PropertyList>

	<path>Catering_Loader_Truck_VolvoFM-stowed.ac</path>
	
	<animation>
		<type>translate</type>
		<property>aircraft/nose-compression</property>
		<factor>0.3125</factor> <!-- 3.2 ft = 1 m -->
		<axis>
			<z>1</z>
		</axis>
	</animation>

	<animation>
		<name>cargo_box_all</name>
		<object-name>cargo_box</object-name>
		<object-name>warning_light_glass</object-name>
		<object-name>warning</object-name>
		<object-name>platform</object-name>
		<object-name>arm_top</object-name>
		<object-name>Lights_side</object-name>
	</animation>
	
	<animation>
		<name>pistons_left</name>
		<object-name>piston_01_left</object-name>
		<object-name>piston_02_left</object-name>
	</animation>
	
	<animation>
		<name>pistons_right</name>
		<object-name>piston_01_right</object-name>
		<object-name>piston_02_right</object-name>
	</animation>
	
	<animation>
		<name>Lights_all</name>
		<object-name>Lights_front</object-name>
		<object-name>Lights_rear</object-name>
		<object-name>Lights_side</object-name>
		<object-name>warning_light_glass</object-name>
	</animation>
	
	<!-- Pistons animation -->
	<animation>
		<type>translate</type>
		<object-name>pistons_left</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.0 </ind><dep>  0.00 </dep></entry>
				<entry><ind> 0.10 </ind><dep>-0.60 </dep></entry>
				<entry><ind> 1.00 </ind><dep>-0.60 </dep></entry>
			</interpolation>
		<axis>
			<x1-m>  0.000 </x1-m>
			<y1-m> -1.000 </y1-m>
			<z1-m>  0.000 </z1-m>
			<x2-m>  0.000 </x2-m>
			<y2-m>  1.000 </y2-m>
			<z2-m>  0.000 </z2-m>
		</axis>
	</animation>
	
	<animation>
		<type>translate</type>
		<object-name>pistons_right</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.0 </ind><dep>  0.00 </dep></entry>
				<entry><ind> 0.10 </ind><dep> 0.60 </dep></entry>
				<entry><ind> 1.00 </ind><dep> 0.60 </dep></entry>
			</interpolation>
		<axis>
			<x1-m>  0.000 </x1-m>
			<y1-m> -1.000 </y1-m>
			<z1-m>  0.000 </z1-m>
			<x2-m>  0.000 </x2-m>
			<y2-m>  1.000 </y2-m>
			<z2-m>  0.000 </z2-m>
		</axis>
	</animation>
	
	<animation>
		<type>translate</type>
		<object-name>piston_02_left</object-name>
		<object-name>piston_02_right</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.0 </ind><dep>  0.00 </dep></entry>
				<entry><ind> 0.10 </ind><dep> 0.00 </dep></entry>
				<entry><ind> 0.15 </ind><dep>-0.40 </dep></entry>
				<entry><ind> 1.00 </ind><dep>-0.40 </dep></entry>
			</interpolation>
		<axis>
			<x1-m>  0.000 </x1-m>
			<y1-m>  0.000 </y1-m>
			<z1-m> -1.000 </z1-m>
			<x2-m>  0.000 </x2-m>
			<y2-m>  0.000 </y2-m>
			<z2-m>  1.000 </z2-m>
		</axis>
	</animation>

	<!-- Cargo Box move -->
	<animation>
		<type>translate</type>
		<object-name>cargo_box_all</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.0 </ind><dep>  0.00 </dep></entry>
				<entry><ind> 1.00 </ind><dep> 3.11 </dep></entry>
			</interpolation>
		<axis>
			<x1-m>  0.000 </x1-m>
			<y1-m>  0.000 </y1-m>
			<z1-m> -1.000 </z1-m>
			<x2-m>  0.000 </x2-m>
			<y2-m>  0.000 </y2-m>
			<z2-m>  1.000 </z2-m>
		</axis>
	</animation>
	
	<!-- Cargo Box platform move -->
	<animation>
		<type>translate</type>
		<object-name>platform</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.00 </ind><dep> 0.00 </dep></entry>
				<entry><ind> 0.57 </ind><dep>-1.75 </dep></entry>
				<entry><ind> 1.00 </ind><dep>-1.75 </dep></entry>
			</interpolation>
		<axis>
			<x1-m>  0.000 </x1-m>
			<y1-m>  0.000 </y1-m>
			<z1-m> -1.000 </z1-m>
			<x2-m>  0.000 </x2-m>
			<y2-m>  0.000 </y2-m>
			<z2-m>  1.000 </z2-m>
		</axis>
	</animation>

	<!-- Upper arm rotate-->
	<animation>
		<type>rotate</type>
		<object-name>arm_top</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.00 </ind><dep>  0.00 </dep></entry>
				<entry><ind> 1.00 </ind><dep> 25.34 </dep></entry>
			</interpolation>
		<axis>
			<x1-m> -2.271 </x1-m>
			<y1-m> -0.100 </y1-m>
			<z1-m>  1.310 </z1-m>
			<x2-m> -2.271 </x2-m>
			<y2-m>  0.100 </y2-m>
			<z2-m>  1.310 </z2-m>
		</axis>
	</animation>
	
	<!-- Lower arm rotate-->
	<animation>
		<type>rotate</type>
		<object-name>arm_bottom</object-name>
		<!--<property>sim/signals/fdm-initialized</property>-->
		<property>services/catering/position-norm</property>
			<factor>1</factor>
			<interpolation>
				<entry><ind> 0.00 </ind><dep>   0.00 </dep></entry>
				<entry><ind> 1.00 </ind><dep> -25.34 </dep></entry>
			</interpolation>
		<axis>
			<x1-m> -2.271 </x1-m>
			<y1-m> -0.100 </y1-m>
			<z1-m>  1.237 </z1-m>
			<x2-m> -2.271 </x2-m>
			<y2-m>  0.100 </y2-m>
			<z2-m>  1.237 </z2-m>
		</axis>
	</animation>
	
	<!-- Lights night illumination -->
	<animation>
		<type>material</type> 
		<object-name>Lights_all</object-name>
			<condition>
				<or>
					<greater-than>
						<property>sim/time/sun-angle-rad</property>
						<value>1.45</value>
					</greater-than>
					<less-than>
						<property>environment/visibility-m</property>
						<value>4500.00</value>
					</less-than>
				</or>
			</condition>
		<emission>	
			<red>0.7</red>	
			<green>0.7</green>	
			<blue>0.5</blue>
		</emission>
	</animation>
	
	<!-- dont show the light model during day-->
	<animation>
		<type>select</type> 
		<object-name>Lights_front</object-name>
		<!--<object-name>warning</object-name>-->
		<condition>
				<or>
					<greater-than>
						<property>sim/time/sun-angle-rad</property>
						<value>1.45</value>
					</greater-than>
					<less-than>
						<property>environment/visibility-m</property>
						<value>4500.00</value>
					</less-than>
				</or>
			</condition>
	</animation>
	
<!-- warning light -->
	<model>
	<name>warning</name>
	<path>warning-light.xml</path>
		<condition>
			<greater-than>
				<property>services/catering/position-norm</property>
				<value>0.01</value>
			</greater-than>
		</condition>
		<offsets>
			<x-m>-2.025</x-m>
			<y-m>0.000</y-m>
			<z-m>4.085</z-m>
			<heading-deg>90</heading-deg>
		</offsets>
	</model>
	
	<animation>
		<type>material</type> 
		<object-name>warning_light_glass</object-name>
			<condition>
			<greater-than>
				<property>services/catering/position-norm</property>
				<value>0.01</value>
			</greater-than>
		</condition>
		<emission>	
			<red>0.7</red>	
			<green>0.7</green>	
			<blue>0.5</blue>
		</emission>
	</animation>
	
<!-- LOD -->
	<animation>
		<type>range</type>
		<min-m>0</min-m>
		<max-m>2500</max-m>
	</animation>
	
</PropertyList>