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

Settable Avars and XMLTools C:SIMVARS

Messages
159
Country
us-colorado
A 2D gauge that uses settable Avars (e.g., Fuel Tank Right Main Quantity, Payload Station Weight, etc) works with one aircraft, but not another. It seems the same Avars that are directly settable with the first a/c are not with the 2nd a/c for some reason.
If I use the XMLTOOLS C:SIMVARS functionality with the Avars all works as expected with the 2nd a/c. My understanding is C:SIMVARS will only write to Avars that are settable 'in the first place', so I don't understand why using C:SIMVARS works but using the Avars directly does not with the 2nd a/c (using P3dv4.4).
Thanks,
Al
 
Last edited:

Heretic

Resource contributor
Messages
6,830
Country
germany
Settable A: vars can only be manipulated via SimConnect when using a new class, which is exactly what XMLTOOLS' SIMVARS class provides. That the rest of the variables have human readable names is just a provision by Aces to make things easier. otherwise, you'd have to write to memory offsets, akin to FSUIPC.
 
Messages
159
Country
us-colorado
I've now taken the approach that when it comes to writing to settable A:vars, to be safe I should use the XMLTools C:SIMVARS:vars approach.
However, why code like:
(M:Event) 'LeftSingle' scmp 0 == (A: PAYLOAD STATION WEIGHT:4, Pounds) 25 + (>A: PAYLOAD STATION WEIGHT:4, Pounds)
worked fine for setting the weight for all the Payload stations in one a/c will just have to remain a mystery, I guess.
Al
 
Messages
913
Country
indonesia
you have more freedom by using SimConnect, but it in C++ code programming.
 

Heretic

Resource contributor
Messages
6,830
Country
germany
I've now taken the approach that when it comes to writing to settable A:vars, to be safe I should use the XMLTools C:SIMVARS:vars approach.
However, why code like:
(M:Event) 'LeftSingle' scmp 0 == (A: PAYLOAD STATION WEIGHT:4, Pounds) 25 + (>A: PAYLOAD STATION WEIGHT:4, Pounds)
worked fine for setting the weight for all the Payload stations in one a/c will just have to remain a mystery, I guess.

Could be P3Dv4 specific behavior or a custom module for the aircraft in question retaining the "A:" prefix for interaction with SimVars.
 
Top