• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

XML Fuel Gauge

Messages
400
Country
us-texas
Can someone design a digital XML fuel gauge that would show the percent of fuel remaining using a digital number readout that could be used in jet fighters or any other aircraft FS9 and FSX?

Always have to press "shift + z" twice to view remaining fuel amount. Like the gauge to match the number seen there. Prefer black background with red numbers, if possible. At 65, knowledge of XML is "0".
Thanks
 
Hasn't someone come along and made you a gauge yet? It's easy to do, make yourself a new folder inside your gauges folder, name it "fuel_quantity" for example.

Paste the following code to Notepad and save it in the new folder as "fuel_percent.xml" :

Code:
<Gauge Name="fuel_percent" Version="1.0">

<Element>
<Rectangle Width="210" Height="35" FillColor="BLACK" Transparency="0"/>
</Element>

<Element>
<Position X="5" Y="5"/>
<Text X="190" Y="26" Length="19" Fixed="no" Font="Arial" Attributes="Bold" Adjust="right" VerticalAdjust="center" Color="#FF0000" Bright="Yes">

<String>TOTAL FUEL: %(100 (A:fuel total quantity, gallons) (A:fuel total capacity,gallons) / *)%!3.1f! %%</String>
</Text>
</Element>

</Gauge>


Then add the new gauge to the panel.cfg of your choice like this:

(for the default FS9 Lear 45)
gauge34=fuel_quantity!fuel_percent, 8, 65, 131, 22

(for the default FSX Lear 45)
gauge25=fuel_quantity!fuel_percent, 746, 251, 210, 35

There, now your knowledge of XML is +1. :)

Jim
 
Back
Top