• 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 List of Variables used for Conditional Display?

Messages
97
Country
unitedstates
Hi all,

I've made extensive use of the search function, and while I've found several very specific examples of code required for conditional display of objects, I have nor found any type of comprehensive list of what variables are available.

Can anyone point me to such a resource? I'm using 3ds Max 8, and depending on the need, I'm exporting with either the FS2002, FS2004, or FSX SDK's, tweaking .asm, then compiling with BGLC_9.

I searched the FSX SDK, but didn't find anything there. Do the FS2002/FS2004 SDK's have what I'm looking for?

Finally, does any available resource explain the "user variable" that I see mentioned fairly frequently..."Userv5" or something to that effect? How about the transformation matrices that I've seen mentioned?

Thanks!

Nick
 
Thanks Arno, that helps.

Are there any resources that explain how to use the user variables and/or the transformation matrix tweak?

Thanks again.

Nick
 
Hi Nick,

Not really I am afraid, that thread already combines information from different SDKs, etc.

What do you mean with transformation matrices? Maybe you can give a little more background about the tweaking you are trying to do.
 
Hey Arno,

I'm working on conditional display of runway lights at the moment.

It's been said many times that we can't test for visibility, so I'm looking for other combinations of variables in order to achieve a realistic result.

One way of getting more realistic behavior is to shut off the approach lights for runways that aren't in use. To do this, I want to test wind direction and velocity, so I can shutoff the approach lights for 24R if 6L is in use.

I'm also looking into ways of making realistic RAIL (strobes) for the various types of approach lights in my scenery (MALSR and ALSF-2). I've created very realistic strobes from FSX "effects", but I have literally no control over how and when they display. I can't make them invisible when viewed from behind, and that's a "non-starter" for me.

It seems the only way to make convincing directional and conditional lighting is through BGL lights, hence the need for a large amount of .asm tweaking.

I'm also very interested in learning more about a small utility that someone here made. If I understand correctly, it uses simconnect or something to test visibility, then write a value to the "user variable 5", which apparently scenery can read. Thus, it IS possible to have conditional lights based on visibility...

I know very little about how this is done, and since I'm working on a payware scenery, I can't just use his existing code. I need to learn how one writes a .dll that can use other FS variables, then write a bit to a variable that is available to scenery.

As far as the transformation matrices go, I have no idea if I need one or not. I would need to know what kinds of things can be accomplished with one before I'd know. Is it for animation? Would I need something like that to generate running strobes for my approach lights? Will I need one to animate a blowing flag?

I'm just trying to wrap my head around the many tweaks and methods available. As great as the wiki is, there seems to be a whole lot of stuff that isn't well documented. At least not to the point that a "n00b" can understand.

Thanks!

Nick
 
Hi Nick,

One way of getting more realistic behavior is to shut off the approach lights for runways that aren't in use. To do this, I want to test wind direction and velocity, so I can shutoff the approach lights for 24R if 6L is in use.

The variable for wind direction is in the list, so you should be able to use that. I have used that many times for windsock animations.

I'm also very interested in learning more about a small utility that someone here made. If I understand correctly, it uses simconnect or something to test visibility, then write a value to the "user variable 5", which apparently scenery can read. Thus, it IS possible to have conditional lights based on visibility...

I know very little about how this is done, and since I'm working on a payware scenery, I can't just use his existing code. I need to learn how one writes a .dll that can use other FS variables, then write a bit to a variable that is available to scenery.

I have done something similar with the ActiGate DLL I made. It uses FSUIPC to read data that you can't access in the scenery and then the values are written to the user variables. The biggest problem is that there are only 5 users variables, so if you have multiple tool using them the values are probably overwritten. And worst, FS2004 GMax animations use the first 3 variables already by default. So only two are left to us to play with.

As far as the transformation matrices go, I have no idea if I need one or not. I would need to know what kinds of things can be accomplished with one before I'd know. Is it for animation? Would I need something like that to generate running strobes for my approach lights? Will I need one to animate a blowing flag?

Not sure if I completely understand, but in animations there are interpollation tables which are used to get from the value of a variable to a frame number to drive the animation. With these interpolation tables you can do nice things if you know how to use them, somebody made a pilot controlled light with it that goes off after 15 minutes.

Or if you mean really transformation matrices, then they are used to position objects. But for animations they are not used in general.
 
Good stuff Arno. Thanks.

I see that wind velocity is present in the list as well, so it looks like I should be able to do what I had in mind there.

When you say that fs2004 Gmax animations take up the first 3 user variables, can you expound a bit more on that? I'm developing for FSX, not FS2004, and at present I do not have any animations in my scenery at all. Is this still a limitation given the above circumstances?

If I decide to add an animated ASR-9 radar, and perhaps an airport beacon, does this mean that I'll have only used the first two variables? What happens if I have more than three animations? If I use more than 5 animations, does that mean that there are no user variables left at all?

Assuming that I will have only two variables available to me, are there any known compatibility issues with other addons that you're aware of? It sounds like anyone who has your ActiGate utility installed will not be able to use variable 5...but does that apply "full-time"? Would ActiGate interfere with that variable all the time regardless of user location, or would it only be a problem if the user were within range of a scenery that uses your module?

Do you see what I'm driving at, or do I need to rephrase?

Thanks for your help Arno, it's much appreciated.

Nick
 
Hi Nick,

When you say that fs2004 Gmax animations take up the first 3 user variables, can you expound a bit more on that? I'm developing for FSX, not FS2004, and at present I do not have any animations in my scenery at all. Is this still a limitation given the above circumstances?

If there is any object in the area that has been made with the FS2004 gamepack and has animations, then it means the first three user variables will be written each frame by that object. So you can not be sure your information is still there. I guess now with FSX this should slowly become less of a problem, but one object in the area is enough to bother you.

If I decide to add an animated ASR-9 radar, and perhaps an airport beacon, does this mean that I'll have only used the first two variables? What happens if I have more than three animations? If I use more than 5 animations, does that mean that there are no user variables left at all?

With FSX animated objects it should not be a problem. All FS2004 animated objects use the first three users variables by default, it does not matter how many you have. Each will write in the same variables while determining the frame of the animation.

Assuming that I will have only two variables available to me, are there any known compatibility issues with other addons that you're aware of? It sounds like anyone who has your ActiGate utility installed will not be able to use variable 5...but does that apply "full-time"? Would ActiGate interfere with that variable all the time regardless of user location, or would it only be a problem if the user were within range of a scenery that uses your module?

The ActiGate module has a menu option to turn it off, but else it will write to the variable anywhere in the world. But I am not sure the module still works in FSX, I never tested that to be honest ;).
 
Back
Top