Tu-154B2 version 3.1:
[fg:toms-fgdata.git] / Aircraft / tu154b / Instruments-3d / buttons / startpanel.xml
1 <?xml version="1.0"?>
2 <!--
3     #############################################################################
4     #    (C) 2008 by Yurik V. Nikiforoff - port for FGFS,  FDM,         #
5     #   2d & 3d instruments, animations, systems and over.                      #
6     #           yurik@megasignal.com                                            #
7     #############################################################################         
8     -->
9
10 <!-- Engines start panel
11 3D instrument for Tu-154 -->
12 <PropertyList>
13  <path>startpanel.ac</path>
14 <!-- Internal instruments lighting -->
15 <animation>
16   <type>material</type>
17   <object-name>base</object-name>
18   <object-name>cover</object-name>
19   <emission>
20     <red-prop>tu154/light/panel/amb-red</red-prop>
21     <green-prop>tu154/light/panel/amb-green</green-prop>
22     <blue-prop>tu154/light/panel/amb-blue</blue-prop>
23   </emission>
24 </animation>-->
25 <animation>
26   <type>material</type>
27   <object-name>_c_1</object-name>
28   <object-name>_c_2</object-name>
29   <object-name>handle_1</object-name>
30   <object-name>handle_2</object-name>
31   <object-name>handle_3</object-name>
32   <object-name>handle_4</object-name>
33   <object-name>button_1</object-name>
34   <object-name>button_2</object-name>
35   <emission>
36     <red-prop>tu154/light/panel/ext-red</red-prop>
37     <green-prop>tu154/light/panel/ext-green</green-prop>
38     <blue-prop>tu154/light/panel/ext-blue</blue-prop>
39   </emission>
40 </animation>-->
41
42 <!-- "PDA working" green lamp -->
43 <!--Brightness-->
44 <animation>
45   <type>material</type>
46   <object-name>_d_2</object-name>
47   <emission>
48     <red>1.0</red>
49     <green>1.0</green>
50     <blue>1.0</blue>
51     <factor-prop>tu154/systems/electrical/checking-lamps/lamps-power</factor-prop>
52   </emission>
53 </animation>
54
55 <!--Set-->
56 <animation>
57   <type>select</type>
58   <object-name>_d_2</object-name>
59   <condition>
60     <or>
61       <property>controls/engines/engine[0]/starter</property>
62       <property>controls/engines/engine[1]/starter</property>
63       <property>controls/engines/engine[2]/starter</property>
64       <property>tu154/systems/electrical/checking-lamps/engine-panel</property>
65     </or>
66   </condition>
67 </animation>
68
69   
70 <!--Cover-->
71
72 <animation>
73     <type>rotate</type>
74     <object-name>cover</object-name>
75     <property>tu154/switches/startpanel-cover</property>
76     <factor>90.0</factor>
77     <center>
78       <x-m>0.0</x-m>
79       <y-m>0.052</y-m>
80       <z-m>0.0</z-m>
81     </center>
82     <axis>
83       <x>0.0</x>
84       <y>0.0</y>
85       <z>1.0</z>
86     </axis>
87 </animation>
88
89 <!--Start switch-->
90 <animation>
91   <type>rotate</type>
92   <object-name>handle_1</object-name>
93   <property>tu154/switches/startpanel-start</property>
94   <interpolation>
95     <entry><ind>        0.0</ind>       <dep>   -60.0</dep></entry>
96     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
97   </interpolation>
98   <center>
99     <x-m>0.00035</x-m>
100     <y-m>0.0</y-m>
101     <z-m>0.05775</z-m>
102   </center>
103   <axis>
104     <x>0.0</x>
105     <y>-1.0</y>
106     <z>0.0</z>
107   </axis>
108 </animation>
109 <!--Cold  switch-->
110 <animation>
111   <type>rotate</type>
112   <object-name>handle_2</object-name>
113   <property>tu154/switches/startpanel-cold</property>
114   <interpolation>
115     <entry><ind>        0.0</ind>       <dep>   -60.0</dep></entry>
116     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
117   </interpolation>
118   <center>
119     <x-m>0.00035</x-m>
120     <y-m>0.0</y-m>
121     <z-m>0.02685</z-m>
122   </center>
123   <axis>
124     <x>0.0</x>
125     <y>-1.0</y>
126     <z>0.0</z>
127   </axis>
128 </animation>
129
130 <!--Heating  switch-->
131 <animation>
132   <type>rotate</type>
133   <object-name>handle_3</object-name>
134   <property>tu154/switches/startpanel-heating</property>
135   <interpolation>
136     <entry><ind>        0.0</ind>       <dep>   -60.0</dep></entry>
137     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
138   </interpolation>
139   <center>
140     <x-m>0.00035</x-m>
141     <y-m>0.0</y-m>
142     <z-m>0.02685</z-m>
143   </center>
144   <axis>
145     <x>0.0</x>
146     <y>-1.0</y>
147     <z>0.0</z>
148   </axis>
149 </animation>
150
151 <!--Engine selector switch-->
152 <animation>
153   <type>rotate</type>
154   <object-name>handle_4</object-name>
155   <property>tu154/switches/startpanel-selector-2</property>
156   <interpolation>
157     <entry><ind>        0.0</ind>       <dep>   0.0</dep></entry>
158     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
159   </interpolation>
160   <center>
161     <x-m>0.00035</x-m>
162     <y-m>0.00113</y-m>
163     <z-m>-0.01164</z-m>
164   </center>
165   <axis>
166     <x>0.0</x>
167     <y>-1.0</y>
168     <z>0.0</z>
169   </axis>
170 </animation>
171 <animation>
172   <type>rotate</type>
173   <object-name>handle_4</object-name>
174   <property>tu154/switches/startpanel-selector-3</property>
175   <interpolation>
176     <entry><ind>        0.0</ind>       <dep>   0.0</dep></entry>
177     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
178   </interpolation>
179   <center>
180     <x-m>0.00035</x-m>
181     <y-m>0.00113</y-m>
182     <z-m>-0.01276</z-m>
183   </center>
184   <axis>
185     <x>0.0</x>
186     <y>0.5</y>
187     <z>0.866</z>
188   </axis>
189 </animation>
190 <animation>
191   <type>rotate</type>
192   <object-name>handle_4</object-name>
193   <property>tu154/switches/startpanel-selector-1</property>
194   <interpolation>
195     <entry><ind>        0.0</ind>       <dep>   0.0</dep></entry>
196     <entry><ind>        1.0</ind>       <dep>   60.0</dep></entry>
197   </interpolation>
198   <center>
199     <x-m>0.00035</x-m>
200     <y-m>0.00113</y-m>
201     <z-m>-0.01276</z-m>
202   </center>
203   <axis>
204     <x>0.0</x>
205     <y>0.5</y>
206     <z>-0.866</z>
207   </axis>
208 </animation>
209
210 <!--buttons-->
211 <animation>
212   <type>translate</type>
213   <object-name>b_3_1</object-name>
214   <property>tu154/switches/startpanel-button-1</property>  
215   <factor>0.002</factor>
216   <axis>
217     <x>-1.0</x>
218     <y>0.0</y>
219     <z>0.0</z>
220   </axis>
221 </animation>
222 <animation>
223   <type>translate</type>
224   <object-name>b_3_2</object-name>
225   <property>tu154/switches/startpanel-button-2</property>  
226   <factor>0.002</factor>
227   <axis>
228     <x>-1.0</x>
229     <y>0.0</y>
230     <z>0.0</z>
231   </axis>
232 </animation>
233
234
235 <!--Controls-->
236 <!--Buttons-->
237 <animation>
238   <type>pick</type>
239   <object-name>b_3_1</object-name>
240   <visible>true</visible>
241   <action>
242     <button>0</button>
243     <repeatable>false</repeatable>
244     <binding>
245       <command>nasal</command>
246       <script>
247         engines.start_engine();
248       </script>
249     </binding>
250     <binding>
251       <command>property-assign</command>
252       <property>tu154/switches/startpanel-button-1</property>  
253       <value>1.0</value>
254     </binding>
255     <mod-up>
256       <binding>
257         <command>property-assign</command>
258         <property>tu154/switches/startpanel-button-1</property>  
259         <value>0.0</value>
260       </binding>
261     </mod-up>
262   </action>
263 </animation>
264
265 <animation>
266   <type>pick</type>
267   <object-name>b_3_2</object-name>
268   <visible>true</visible>
269   <action>
270     <button>0</button>
271     <repeatable>false</repeatable>
272     <binding>
273       <command>nasal</command>
274       <script>
275         engines.break_start();
276       </script>
277     </binding>
278     <binding>
279       <command>property-assign</command>
280       <property>tu154/switches/startpanel-button-2</property>  
281       <value>1.0</value>
282     </binding>
283     <mod-up>
284       <binding>
285         <command>property-assign</command>
286         <property>tu154/switches/startpanel-button-2</property>  
287         <value>0.0</value>
288       </binding>
289     </mod-up>
290   </action>
291 </animation>
292
293 <!--Cover-->
294 <animation>
295   <type>pick</type>
296   <object-name>cover</object-name>
297   <visible>true</visible>
298   <action>
299     <button>0</button>
300     <repeatable>false</repeatable>
301     <binding>
302       <command>nasal</command>
303       <script>
304         if( getprop("tu154/switches/startpanel-cover" ) == 0.0 )
305                 interpolate("tu154/switches/startpanel-cover", 1.0, 0.1 );
306         else    interpolate("tu154/switches/startpanel-cover", 0.0, 0.1 );
307       </script>
308     </binding>
309   </action>
310 </animation>
311
312 <!--Start switch-->
313 <animation>
314   <type>pick</type>
315   <object-name>hotspot_1</object-name>
316   <visible>false</visible>
317   <action>
318     <button>0</button>
319     <repeatable>false</repeatable>
320     <binding>
321       <command>nasal</command>
322       <script>
323         interpolate("tu154/switches/startpanel-start", 1.0, 0.1 );
324       </script>
325     </binding>
326   </action>
327 </animation>
328 <animation>
329   <type>pick</type>
330   <object-name>hotspot_2</object-name>
331   <visible>false</visible>
332   <action>
333     <button>0</button>
334     <repeatable>false</repeatable>
335     <binding>
336       <command>nasal</command>
337       <script>
338         interpolate("tu154/switches/startpanel-start", 0.0, 0.1 );
339       </script>
340     </binding>
341   </action>
342 </animation>
343
344 <!--Cold switch-->
345 <animation>
346   <type>pick</type>
347   <object-name>hotspot_3</object-name>
348   <visible>false</visible>
349   <action>
350     <button>0</button>
351     <repeatable>false</repeatable>
352     <binding>
353       <command>nasal</command>
354       <script>
355         interpolate("tu154/switches/startpanel-cold", 1.0, 0.1 );
356       </script>
357     </binding>
358   </action>
359 </animation>
360 <animation>
361   <type>pick</type>
362   <object-name>hotspot_4</object-name>
363   <visible>false</visible>
364   <action>
365     <button>0</button>
366     <repeatable>false</repeatable>
367     <binding>
368       <command>nasal</command>
369       <script>
370         interpolate("tu154/switches/startpanel-cold", 0.0, 0.1 );
371       </script>
372     </binding>
373   </action>
374 </animation>
375
376 <!--Heating switch-->
377 <animation>
378   <type>pick</type>
379   <object-name>hotspot_5</object-name>
380   <visible>false</visible>
381   <action>
382     <button>0</button>
383     <repeatable>false</repeatable>
384     <binding>
385       <command>nasal</command>
386       <script>
387         interpolate("tu154/switches/startpanel-heating", 1.0, 0.1 );
388       </script>
389     </binding>
390   </action>
391 </animation>
392 <animation>
393   <type>pick</type>
394   <object-name>hotspot_6</object-name>
395   <visible>false</visible>
396   <action>
397     <button>0</button>
398     <repeatable>false</repeatable>
399     <binding>
400       <command>nasal</command>
401       <script>
402         interpolate("tu154/switches/startpanel-heating", 0.0, 0.1 );
403       </script>
404     </binding>
405   </action>
406 </animation>
407
408 <!--Engine selector-->
409 <animation>
410   <type>pick</type>
411   <object-name>hotspot_7</object-name>
412   <visible>false</visible>
413   <action>
414     <button>0</button>
415     <repeatable>false</repeatable>
416     <binding>
417       <command>nasal</command>
418       <script>
419         interpolate("tu154/switches/startpanel-selector-2", 1.0, 0.1 );
420         setprop("tu154/switches/startpanel-selector-3", 0.0 );
421         setprop("tu154/switches/startpanel-selector-1", 0.0 );
422       </script>
423     </binding>
424   </action>
425 </animation>
426 <animation>
427   <type>pick</type>
428   <object-name>hotspot_8</object-name>
429   <visible>false</visible>
430   <action>
431     <button>0</button>
432     <repeatable>false</repeatable>
433     <binding>
434       <command>nasal</command>
435       <script>
436         setprop("tu154/switches/startpanel-selector-2", 0.0 );
437         interpolate("tu154/switches/startpanel-selector-3", 1.0, 0.1 );
438         setprop("tu154/switches/startpanel-selector-1", 0.0 );
439       </script>
440     </binding>
441   </action>
442 </animation>
443 <animation>
444   <type>pick</type>
445   <object-name>hotspot_9</object-name>
446   <visible>false</visible>
447   <action>
448     <button>0</button>
449     <repeatable>false</repeatable>
450     <binding>
451       <command>nasal</command>
452       <script>
453         setprop("tu154/switches/startpanel-selector-2", 0.0 );
454         setprop("tu154/switches/startpanel-selector-3", 0.0 );
455         interpolate("tu154/switches/startpanel-selector-1", 1.0, 0.1 );
456       </script>
457     </binding>
458   </action>
459 </animation>
460 <animation>
461   <type>pick</type>
462   <object-name>base_hs_10</object-name>
463   <visible>true</visible>
464   <action>
465     <button>0</button>
466     <repeatable>false</repeatable>
467     <binding>
468       <command>nasal</command>
469       <script>
470         interpolate("tu154/switches/startpanel-selector-1", 0.0, 0.1 );
471         interpolate("tu154/switches/startpanel-selector-2", 0.0, 0.1 );
472         interpolate("tu154/switches/startpanel-selector-3", 0.0, 0.1 );
473       </script>
474     </binding>
475   </action>
476 </animation>
477
478
479
480
481 </PropertyList>