• 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.

FSXA Missing text and mouse areas

Messages
75
Country
unitedstates
Hey everyone,

I have been scratching my head on this one. I feel like I'm missing something simple but I can't see it.

Below is the image I made for a refuel panel. the black area has a display for (L:14TANKSET,number). over this area there are 2 mouse zones identified with the hand + (Green box) and hand - (Cyan Box) symbols to increment or decrement the value by 100. it can be loaded up in ace and it looks ok there. Not that it means much.

Problems:
1) the text does not display
2) only one mouse area is active (the increment)

Trouble shooting steps taken:
1) remove visibility conditional
2) change order of elements

Thanks in advance for all the help!

fuel%20control.png


Code:
<?xml version="1.0" encoding="UTF-8"?>

<SimBase.Document Type="AceXML" version="1,0">
    <Descr>AceXML Document</Descr>
    <Filename>FUELCONT.xml</Filename>
    <SimGauge.Gauge id="Gauge">
        <FloatPosition>0.000,0.000</FloatPosition>
        <Size>325,323</Size>
        <Element id="TEXT">
            <FloatPosition>14.000,130.000</FloatPosition>
            <Visibility>(A:ELECTRICAL MASTER BATTERY,bool) 1 ==</Visibility>
            <GaugeText id="GaugeText">
                <Bold>True</Bold>
                <FontColor>white</FontColor>
                <FontFace>arial</FontFace>
                <FontHeightScript>12</FontHeightScript>
                <GaugeString>%((L:14TANKSET,number))%!5f!</GaugeString>
                <Size>58,16</Size>
                <Transparent>True</Transparent>
            </GaugeText>
        </Element>
        <Element id="Element">
            <FloatPosition>14.000,130.000</FloatPosition>
            <Rectangle id="Rectangle">
                <LineWidth>2</LineWidth>
                <Width>58</Width>
                <Height>16</Height>
                <LineColor>lightslategray</LineColor>
                <FillColor>black</FillColor>
            </Rectangle>
        </Element>
        <MouseArea id="MouseArea">
            <FloatPosition>14.000,130.000</FloatPosition>
            <Size>29,16</Size>
            <CursorType>UpArrow</CursorType>
            <MouseClick id="MouseClick">
                <Script>(L:14TANKSET,number) 100 + (&gt;L:14TANKSET,number)</Script>
                <ClickType>LeftSingle</ClickType>
            </MouseClick>
        </MouseArea>
        <MouseArea id="MouseArea">
            <FloatPosition>43.000,130.000</FloatPosition>
            <Size>29,16</Size>
            <CursorType>DownArrow</CursorType>
            <MouseClick id="MouseClick">
                <Script>(L:14TANKSET,number) 100 - (&gt;L:14TANKSET,number)</Script>
                <ClickType>LeftSingle</ClickType>
            </MouseClick>
        </MouseArea>
        <Image id="refuel.bmp" Name="refuel.bmp">
            <Transparent>True</Transparent>
        </Image>
    </SimGauge.Gauge>
</SimBase.Document>
 
Try removing this as it draws a rectangle with a black filling onto the gauge:
Code:
<Element id="Element">
<FloatPosition>14.000,130.000</FloatPosition>
<Rectangle id="Rectangle">
<LineWidth>2</LineWidth>
<Width>58</Width>
<Height>16</Height>
<LineColor>lightslategray</LineColor>
<FillColor>black</FillColor>
</Rectangle>
</Element>

Next, try renaming the "id=" values of the second mouse area to make them unique.
 
Try removing this as it draws a rectangle with a black filling onto the gauge:

Next, try renaming the "id=" values of the second mouse area to make them unique.

Thanks, That did it for the missing Text! The second mouse area still isnt showing up.
 
It's been a while since I've worked with the FSX syntax scheme. The FS9 scheme requires less tags and is parsed by FSX just fine, so it tends to be the preferred one among FSX devs (and it allows cross-development for FSX and FS9). And almost no one uses the ACE tool, so once you get a bit more comfortable with XML, try to ditch it as it's just too limited compared to working with Notepad.

Try to wrap your <MouseArea>s in another, "parent" <MouseArea> that has the size of your gauge. Something like this:
Code:
<MouseArea id="MouseArea">
<FloatPosition>0.000,0.000</FloatPosition>
<Size>325,323</Size>
<MouseArea id="MouseArea">
<FloatPosition>14.000,130.000</FloatPosition>
<Size>29,16</Size>
<CursorType>UpArrow</CursorType>
<MouseClick id="MouseClick">
<Script>(L:14TANKSET,number) 100 + (&gt;L:14TANKSET,number)</Script>
<ClickType>LeftSingle</ClickType>
</MouseClick>
</MouseArea>
<MouseArea id="MouseArea">
<FloatPosition>43.000,130.000</FloatPosition>
<Size>29,16</Size>
<CursorType>DownArrow</CursorType>
<MouseClick id="MouseClick">
<Script>(L:14TANKSET,number) 100 - (&gt;L:14TANKSET,number)</Script>
<ClickType>LeftSingle</ClickType>
</MouseClick>
</MouseArea>
</MouseArea>
 
Thanks! I'll give that a try Fair enough, I used to be able to straight code in XML straight to gauge but I haven't done this in years.
 
I don't use the ACEs style but try this:

Use unique names for each mousearea id.

Wrap the two mouseareas in another mousearea. Here is an example from the G1000. Notice there is one master MouseArea and all the individual mouse areas are contained within it.

Code:
       <MouseArea id="MouseArea">
            <FloatPosition>0.000,0.000</FloatPosition>
            <Size>91,479</Size>
            <Tooltip id="Tooltip">
                <DefaultId>TOOLTIPTEXT_GAUGE_RADIO_CONTROL_HEAD</DefaultId>
            </Tooltip>
            <MouseArea id="COM 1 Mic">
                <FloatPosition>20.000,17.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:COM1 Mic pressed)
(&gt;K:COM1_TRANSMIT_SELECT)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_COM1_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="COM 2 Mic">
                <FloatPosition>19.000,51.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:COM2 Mic pressed)
(&gt;K:COM2_TRANSMIT_SELECT)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_COM2_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="NAV 1 Audio">
                <FloatPosition>55.000,214.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:NAV1 pressed)
(&gt;K:RADIO_VOR1_IDENT_TOGGLE)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_NAV1_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="NAV 2 Audio">
                <FloatPosition>55.000,245.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:NAV2 pressed)
(&gt;K:RADIO_VOR2_IDENT_TOGGLE)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_NAV2_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="Marker Audio">
                <FloatPosition>20.000,180.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:MKR pressed)
(&gt;K:MARKER_SOUND_TOGGLE)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_MARKER_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="DME Audio">
                <FloatPosition>19.000,214.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:DME pressed)
(&gt;K:RADIO_DME1_IDENT_TOGGLE)
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_DME_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="COM 1 Audio">
                <FloatPosition>55.000,17.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:COM1 pressed, bool)
(A:COM1 TRANSMIT, bool) !
if{  (&gt;K:COM_RECEIVE_ALL_TOGGLE) }
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_COM1_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="COM 2 Audio">
                <FloatPosition>53.000,50.000</FloatPosition>
                <Size>24,18</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>1 (&gt;L:COM2 pressed, bool)
(A:COM2 TRANSMIT, bool) !
if{  (&gt;K:COM_RECEIVE_ALL_TOGGLE) }
</Script>
                    <ClickType>LeftSingle</ClickType>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_COM2_AUDIO_SELECTOR</DefaultId>
                </Tooltip>
            </MouseArea>
        </MouseArea>

EDIT: which is pretty much what Bjoern has said above.
 
Back
Top