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

P3D v2 XML Code help...

Messages
95
Country
ireland
Hi folks....
I simply cannot get this to work... can anybody spot an error or offer advice ? I copied the code from other working objects and simply changed the A vars to suit.. but it simply doesn't work. The lights come on when spoilers are deployed but the flap movement has no effect.
In my plane there's a steady spoiler annunciation light when they are deployed, however, when flaps are also deployed beyond 13 degress (which I already figured in my case to be approx 25 percent) the spoiler light should then flash. So, I assume this can be accomplished using a single lump of xml code.. but.. I ain't nearly that good, I've only just learned to reed and rite :( . So I decided on one lump of code for flaps less than 25pct and another for flaps more than 25pct (applied to a duplicate 'spoiler light' part). Anyway.. here's the confounded code.......

Skip

Code:
<PartInfo>
  <Name>J200_ANNUN_SPOILER_LITE</Name>
    <Visibility>
     <Parameter>
    <Code>
    (A:SPOILERS HANDLE POSITION, percent) 2 &gt;
    (A:FLAPS HANDLE INDEX, number) 25 &lt;
    (A:ELECTRICAL MASTER BATTERY, bool) 1 ==
    and
    and
    (L:J200_ANNUN_test_button, bool) 1 ==
    or
    if{ 100 } els{ 0 }
    </Code>
     </Parameter>
    </Visibility>
</PartInfo>

<PartInfo>
  <Name>J200_ANNUN_SPOILERFLASH_LITE</Name>
    <Visibility>
     <Parameter>
    <Code>
    (A:SPOILERS HANDLE POSITION, percent) 2 &gt;
    (A:FLAPS HANDLE INDEX, number) 25 &gt;
    (A:ELECTRICAL MASTER BATTERY, bool) 1 ==
    (P:Absolute time, seconds) 0.25 % 0.125 >
    and
    and
    and
    (L:J200_ANNUN_test_button, bool) 1 ==
    or
    if{ 100 } els{ 0 }
    </Code>
     </Parameter>
    </Visibility>
</PartInfo>
 
Hi,

I understood that (A:FLAPS HANDLE INDEX, number) was a number, related to the number of positions that the flaps could be moved to.

(A:FLAPS HANDLE PERCENT,percent) would seem to be what you require....

Maybe...

Walter
 
Hi Walter,

That worked perfectly, many thanks indeed.
(Seems that you're just up the road from me :) ).

Skip
 
Back
Top