Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing issues from my last PRs #22

Merged
merged 6 commits into from
Aug 2, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Models/c150.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2300,7 +2300,7 @@
<model>
<path>Aircraft/c150/Models/Panel/Instruments/ai/ai.xml</path>
<offsets>
<x-m>1.6485</x-m>
<x-m>1.645</x-m>
<y-m>-0.318</y-m>
<z-m>0.214</z-m>
</offsets>
Expand All @@ -2309,7 +2309,7 @@
<model>
<path>Aircraft/c150/Models/Panel/Instruments/hi/hi.xml</path>
<offsets>
<x-m>1.660</x-m>
<x-m>1.657</x-m>
<y-m>-0.323</y-m>
<z-m>0.096</z-m>
</offsets>
Expand All @@ -2327,7 +2327,7 @@
<model>
<path>Aircraft/c150/Models/Panel/Instruments/vac/vac.xml</path>
<offsets>
<x-m>1.6615</x-m>
<x-m>1.657</x-m>
<y-m>0.445</y-m>
<z-m>0.210</z-m>
</offsets>
Expand All @@ -2336,7 +2336,7 @@
<model>
<path>Aircraft/c150/Models/Panel/Instruments/ammeter/ammeter.xml</path>
<offsets>
<x-m>1.657</x-m>
<x-m>1.654</x-m>
<y-m>0.453</y-m>
<z-m>0.112</z-m>
</offsets>
Expand All @@ -2355,7 +2355,7 @@
<model>
<path>Aircraft/c150/Models/Panel/Instruments/tc/tc.xml</path>
<offsets>
<x-m>1.662</x-m>
<x-m>1.657</x-m>
<y-m>-0.421</y-m>
<z-m>0.096</z-m>
</offsets>
Expand Down
30 changes: 30 additions & 0 deletions Systems/filters.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>


<PropertyList>

<filter>
<type>gain</type>
<gain>0.3048</gain>
<input>
<property>/position/altitude-agl-ft</property>
</input>
<reference>1.0</reference>
<output>
<property>/position/altitude-agl-m</property>
</output>
</filter>

<filter>
<type>gain</type>
<gain>100.0</gain>
<input>
<property>/systems/electrical/battery-charge-percent</property> <!-- this property ranges from 0.0 to 1.0 despite its name -->
</input>
<reference>0.0</reference>
<output>
<property>/systems/electrical/battery-charge-percent-100</property>
</output>
</filter>

</PropertyList>
18 changes: 0 additions & 18 deletions Systems/ground-effects.xml

This file was deleted.

34 changes: 23 additions & 11 deletions c150-set.xml
Original file line number Diff line number Diff line change
Expand Up @@ -197,31 +197,43 @@ The Cessna 150 is the fifth most produced civilian plane ever, with 23,839 aircr
<internal archive="y">true</internal>
<config>
<x-offset-m archive="y">-0.25</x-offset-m>
<y-offset-m archive="y">0.37</y-offset-m>
<z-offset-m archive="y">2.30</z-offset-m>
<pitch-offset-deg>-10</pitch-offset-deg>
<y-offset-m archive="y">0.39</y-offset-m>
<z-offset-m archive="y">2.35</z-offset-m>
<pitch-offset-deg>-7</pitch-offset-deg>
<default-field-of-view-deg type="double">76.5</default-field-of-view-deg>
</config>
</view>

<!-- Position the co-pilot viewpoint and angle -->
<view n="100">
<view n="101">
<name>Cockpit Right Seat View</name>
<type>lookfrom</type>
<internal type="bool">true</internal>
<config>
<from-model type="bool">true</from-model>
<from-model-idx type="int">0</from-model-idx>
<x-offset-m type="double">0.25</x-offset-m>
<y-offset-m type="double">0.37</y-offset-m>
<z-offset-m type="double">2.30</z-offset-m>
<pitch-offset-deg type="double">-10</pitch-offset-deg>
<y-offset-m type="double">0.39</y-offset-m>
<z-offset-m type="double">2.35</z-offset-m>
<pitch-offset-deg type="double">-7</pitch-offset-deg>
<default-field-of-view-deg type="double">76.5</default-field-of-view-deg>
<limits>
<enabled type="bool">true</enabled>
<left>
<heading-max-deg type="double">140</heading-max-deg>
<x-offset-max-m type="double">0.15</x-offset-max-m>
<x-offset-threshold-deg type="double">65</x-offset-threshold-deg>
</left>
<right>
<heading-max-deg type="double">140</heading-max-deg>
<x-offset-max-m type="double">0.15</x-offset-max-m>
<x-offset-threshold-deg type="double">65</x-offset-threshold-deg>
</right>
</limits>
</config>
</view>


<view n="101">
<view n="100">
<name>Right Wing View</name>
<type>lookfrom</type>
<internal>false</internal>
Expand All @@ -234,7 +246,7 @@ The Cessna 150 is the fifth most produced civilian plane ever, with 23,839 aircr
<y-offset-m type="double">0.50</y-offset-m>
<z-offset-m type="double">2.50</z-offset-m>
</config>
</view>
</view>

<view n="1">
<config>
Expand Down Expand Up @@ -281,7 +293,7 @@ The Cessna 150 is the fifth most produced civilian plane ever, with 23,839 aircr
http://forum.flightgear.org/viewtopic.php?f=4&t=25157&start=75#p232120
-->
<property-rule n="101">
<path>Aircraft/c150/Systems/ground-effects.xml</path>
<path>Aircraft/c150/Systems/filters.xml</path>
</property-rule>

<property-rule n="102">
Expand Down
9 changes: 4 additions & 5 deletions gui/dialogs/c150-aircraft-dialog.xml
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,12 @@
<script>c150.dialog_battery_reload();</script>
</binding>
</button>

<text>
<label>Current charge is 00.00 V</label>
<halign>center</halign>
<format>Current charge is %2.2f V</format>
<label>Current charge is xxxx %%</label>
<format>Current charge is %3.1f %%</format>
<live>true</live>
<property>/systems/electrical/battery-volts</property>
<property>/systems/electrical/battery-charge-percent-100</property>
</text>

</group>
Expand Down