1
0
Fork 0

Enable AIRPORT key (doesn't work quite to spec but at least works); improve code for button handling

This commit is contained in:
legoboyvdlp R 2020-05-15 23:30:53 +01:00
parent 9075636188
commit 729ec0db7d
5 changed files with 408 additions and 433 deletions

View file

@ -854,6 +854,31 @@
</action>
</animation>
<animation>
<type>pick</type>
<object-name>airport</object-name>
<action>
<button>0</button>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>mcdu.pagebutton("airport", 0);</script>
<condition>
<and>
<greater-than-equals>
<property>systems/electrical/bus/ac-1</property>
<value>110</value>
</greater-than-equals>
<greater-than>
<property>controls/lighting/DU/mcdu1</property>
<value>0.01</value>
</greater-than>
</and>
</condition>
</binding>
</action>
</animation>
<animation>
<type>pick</type>
<object-name>left</object-name>

View file

@ -854,6 +854,31 @@
</action>
</animation>
<animation>
<type>pick</type>
<object-name>airport</object-name>
<action>
<button>0</button>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>mcdu.pagebutton("airport", 1);</script>
<condition>
<and>
<greater-than-equals>
<property>systems/electrical/bus/ac-2</property>
<value>110</value>
</greater-than-equals>
<greater-than>
<property>controls/lighting/DU/mcdu2</property>
<value>0.01</value>
</greater-than>
</and>
</condition>
</binding>
</action>
</animation>
<animation>
<type>pick</type>
<object-name>left</object-name>

File diff suppressed because it is too large Load diff

View file

@ -508,6 +508,16 @@
<legend>AIR</legend>
<pref-height>25</pref-height>
<pref-width>40</pref-width>
<binding>
<command>nasal</command>
<script>mcdu.pagebutton("airport", 0);</script>
<condition>
<greater-than-equals>
<property>systems/electrical/bus/ac-1</property>
<value>110</value>
</greater-than-equals>
</condition>
</binding>
</button>
<button>

View file

@ -508,6 +508,23 @@
<legend>AIR</legend>
<pref-height>25</pref-height>
<pref-width>40</pref-width>
<button>
<row>0</row>
<col>0</col>
<legend>AIR</legend>
<pref-height>25</pref-height>
<pref-width>40</pref-width>
<binding>
<command>nasal</command>
<script>mcdu.pagebutton("airport", 1);</script>
<condition>
<greater-than-equals>
<property>systems/electrical/bus/ac-2</property>
<value>110</value>
</greater-than-equals>
</condition>
</binding>
</button>
</button>
<button>