Tu-154B2 version 3.1:
[fg:toms-fgdata.git] / Aircraft / tu154b / Instruments-3d / com / com.xml
1 <?xml version="1.0"?>
2 <!--
3     #############################################################################
4     #    (C) 2007 by Yurik V. Nikiforoff - port for FGFS,  FDM,                 #
5     #   2d & 3d instruments, animations, systems and over.                      #
6     #           yurik@megasignal.com                                            #
7     #############################################################################
8     -->
9
10 <!-- Comm radio control
11 3D instrument for Tu-154 -->
12 <PropertyList>
13   <params>
14     <freq>instrumentation/comm[0]/frequencies/selected-mhz</freq>
15     <volume>instrumentation/comm[0]/volume</volume>
16   </params>
17
18  <path>com.ac</path>
19
20  <effect>
21     <inherits-from>Effects/model-transparent</inherits-from>
22     <object-name>base</object-name>
23  </effect>
24
25 <animation>
26   <type>select</type>
27   <object-name>d1_night</object-name>
28   <object-name>d2_night</object-name>
29   <object-name>digits_night</object-name>
30   <condition>
31     <greater-than>
32       <property>tu154/light/instruments/int-red</property>
33       <value>0.1</value>
34     </greater-than>
35   </condition>
36 </animation>
37
38 <animation>
39   <type>select</type>
40   <object-name>d1</object-name>
41   <object-name>d2</object-name>
42   <object-name>digits</object-name>
43   <condition>
44     <less-than>
45       <property>tu154/light/instruments/int-red</property>
46       <value>0.1</value>
47     </less-than>
48   </condition>
49 </animation>
50
51 <!-- Internal instruments lighting -->
52 <animation>
53   <type>material</type>
54   <object-name>d1_night</object-name>
55   <object-name>d2_night</object-name>
56   <object-name>digits_night</object-name>
57   <emission>
58     <red>0.6</red>
59   </emission>
60 </animation>
61
62 <animation>
63   <type>rotate</type>
64   <object-name>dig_f_hi</object-name>
65   <object-name>dig_f_hi_night</object-name>
66   <expression>
67     <table>
68       <difference>
69         <property alias="../../../../../params/freq"/>
70         <mod>
71           <property alias="../../../../../../params/freq"/>
72           <value>1</value>
73         </mod>
74       </difference>
75       <entry><ind>      108</ind>       <dep>   0</dep></entry>
76       <entry><ind>      137</ind>       <dep>   360</dep></entry>
77     </table>
78   </expression>
79   <center>
80     <x-m>-0.0480</x-m>
81     <y-m>0.0</y-m>
82     <z-m>0.0059</z-m>
83   </center>
84   <axis>
85     <x>0.0</x>
86     <y>-1.0</y>
87     <z>0.0</z>
88   </axis>
89 </animation>
90 <animation>
91   <type>rotate</type>
92   <object-name>dig_f_low</object-name>
93   <object-name>dig_f_low_night</object-name>
94   <property alias="../../params/freq"/>
95   <factor>360</factor>
96   <center>
97     <x-m>-0.0636</x-m>
98     <y-m>0.0</y-m>
99     <z-m>0.0023</z-m>
100   </center>
101   <axis>
102     <x>0.0</x>
103     <y>-1.0</y>
104     <z>0.0</z>
105   </axis>
106 </animation>
107
108 <!--Frequency-->
109 <animation>
110   <type>knob</type>
111   <object-name>c1</object-name>
112   <visible>true</visible>
113   <action>
114     <binding>
115       <command>property-adjust</command>
116       <property alias="../../../../params/freq"/>
117       <mask>integer</mask>
118       <min>108</min>
119       <max>137</max>
120       <wrap>true</wrap>
121     </binding>
122   </action>
123 </animation>
124 <animation>
125   <type>knob</type>
126   <object-name>c2</object-name>
127   <visible>true</visible>
128   <action>
129     <binding>
130       <command>property-adjust</command>
131       <property alias="../../../../params/freq"/>
132       <mask>decimal</mask>
133       <factor>0.025</factor>
134       <min>0</min>
135       <max>1</max>
136       <wrap>true</wrap>
137     </binding>
138   </action>
139 </animation>
140
141 <!--Volume-->
142 <animation>
143   <type>knob</type>
144   <object-name>c3</object-name>
145   <visible>true</visible>
146   <action>
147     <binding>
148       <command>property-adjust</command>
149       <property alias="../../../../params/volume"/>
150       <factor>0.1</factor>
151       <min>0</min>
152       <max>1</max>
153     </binding>
154   </action>
155   <hovered>
156     <binding>
157       <command>set-tooltip</command>
158       <tooltip-id>comm-volume</tooltip-id>
159       <label>Volume: %d%%</label>
160       <property alias="../../../../params/volume"/>
161       <mapping>nasal</mapping>
162       <script>return int(arg[0] * 100)</script>
163     </binding>
164   </hovered>
165 </animation>
166
167
168 </PropertyList>