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

"Pausing" an A variable

Messages
44
Country
italy
Are there any workaround to do so?
For example I need to pause an animation to what A:HEADING INDICATOR var is linked, and then resume it after a while from exact same position when animation was paused, while A:var may change
Thanks
 
For heading there doesn't seem to be a failure command, so that, with (A: PARTIAL PANEL HEADING, bool) and the use of "freeze" in the failure table isn't going to happen.

Something like this may work using a single register -

XML:
<!--
(L:my_hdg_register, number)
-10000 = all is OK
-9999 = get heading at pause
-->

<!-- Trigger the pause -->
(L:my_hdg_register, number) -9999 == if{ (A:PLANE HEADING DEGREES GYRO, degrees)  (>L:my_hdg_register, number) }

<!-- Resume normal operation -->
-10000 (>L:my_hdg_register, number)

<!-- Heading value at instrument -->
<Value>(L:my_hdg_register, number) -10000 == if{ (A:PLANE HEADING DEGREES GYRO, degrees)  } els{ (L:my_hdg_register, number) } dgrd</Value>
 
Last edited:
Yes, the usual way to handle that is to create a custom L: variable and use that instead.
 
wellp guys, the problem which I can spot it's that:
Code:
1. L:Var linked to an A:Var, they are both at the same value (L:Var linked to an animation) => 
2. I pausing L:Var => 
3. A:Var continuing to change, L:Var not equal to A:Var anymore =>
4. I resuming L:Var and it's instantly jump to A:Var value
^^ instead of starting from the point where it was paused and continue to evolve from that point
That's the problem I'd like to work out, unfortunately without success so far..
 
Do *not* have the L: variable *always* set to the A: variable value - that just makes a copy of the A: variable, pretty useless. You set the L: variable equal to the A: variable only when YOU want it to, otherwise it contains the same value it had when first set.
 
Code:
(L:CompassUpdatePaused, bool) !

if{

(A:PLANE HEADING DEGREES GYRO, degrees) (>L:CompassAnimationDriver, number)

}
 
wellp guys, the problem which I can spot it's that:
Code:
1. L:Var linked to an A:Var, they are both at the same value (L:Var linked to an animation) =>
2. I pausing L:Var =>
3. A:Var continuing to change, L:Var not equal to A:Var anymore =>
4. I resuming L:Var and it's instantly jump to A:Var value
^^ instead of starting from the point where it was paused and continue to evolve from that point
That's the problem I'd like to work out, unfortunately without success so far..
need of timer, I feel never can't escape from this (time)
 
Check the difference between a A:Var and L:Var
If there is a small differ then A:Var -> L:Var

if there is big differ then count up or count down the L:Var to A:Var until you get a small differ.
 
In my case L:Var should preserve the priority, and A:Var should work like a slave which give to L:Var not exact the same value of itself, but scale it taking in account pause difference between two of them.
In ideal:
Code:
(L:CompassUpdatePaused, bool) !
    if{
        (A:PLANE HEADING DEGREES GYRO, degrees) (>L:CompassAnimationDriver, number)
    }

(L:CompassUpdatePaused, bool)
        if{
            (L:CompassAnimationDriver, number) (A:PLANE HEADING DEGREES GYRO, degrees) !=
                if{
                    (L:CompassAnimationDriver, number) (>A:PLANE HEADING DEGREES GYRO, degrees) <=== what is imposibale
                                                        {or any other Var, the existence of which I do not suspect,
                                                        what may give direction of the plane and be settable[paused]}
                }             
        }
HEADING INDICATOR what may be set through GYRO_DRIFT_SET works weird
 
You cannot make an A: variable work like a slave - you must create your own variables for that. An A: variable will follow the FS value, period.
 
Back
Top