• 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 Creating blinking lights?

Messages
176
Country
denmark
What is the best procedure for creating timed blinking lights?

I want a set of two timed blinking lights, when one is off the other is on.

I can see two methods:

1. Create each one as an individual effect and hope the timing between them is
constant.

2. Create the set as a single effect with timing included (is this a garanteed to
make the timing constant?)


Thanks
Michael
 
If you are working on an aircraft model, you can use attachpoints for the .fx file(s) and drive them with embedded XML scripts.

Here is an example for driving a beacon light:
Code:
    <!-- BEACON LIGHT FLASHER -->
    (A:LIGHT BEACON,bool)
    (A:ELECTRICAL MASTER BATTERY,bool)
    and
    if{
    (P:Absolute time,seconds) 2.0 % 1.0 > !
    if{ 1 (>L:B737_Beacon,bool) }
    els{ 0 (>L:B737_Beacon,bool) }
    }
Here is an example for a "Double-Flash" Strobe light:
Code:
    <!-- STROBE LIGHT FLASHER -->
    (A:LIGHT STROBE,bool)
    (A:ELECTRICAL MASTER BATTERY,bool)
    and
    if{
    (P:Absolute time,seconds) 2 % 0.4 > !
    if{
    (P:Absolute time,seconds) 0.2 % 0.1 > !
    if{ 1 (>L:B737_Strobe,bool) }
    els{ 0 (>L:B737_Strobe,bool) }
    }
    }
The possibilities are staggering, and limited only by your imagination... :D
 
Last edited:
If you are working on an aircraft model, you can use attachpoints for the .fx file(s) and drive them with embedded XML scripts.

Here is an example for driving a beacon light:
Code:
    <!-- BEACON LIGHT FLASHER -->
    (A:LIGHT BEACON,bool)
    (A:ELECTRICAL MASTER BATTERY,bool)
    and
    if{
    (P:Absolute time,seconds) 2.0 % 1.0 > !
    if{ 1 (>L:B737_Beacon,bool) }
    els{ 0 (>L:B737_Beacon,bool) }
    }
Here is an example for a "Double-Flash" Strobe light:
Code:
    <!-- STROBE LIGHT FLASHER -->
    (A:LIGHT STROBE,bool)
    (A:ELECTRICAL MASTER BATTERY,bool)
    and
    if{
    (P:Absolute time,seconds) 2 % 0.4 > !
    if{
    (P:Absolute time,seconds) 0.2 % 0.1 > !
    if{ 1 (>L:B737_Strobe,bool) }
    els{ 0 (>L:B737_Strobe,bool) }
    }
    }
The possibilities are staggering, and limited only by your imagination... :D

Thanks n4gix, but I have no control over the aircraft model :(


Michael
 
Oh dear. I am afraid that creating and editing .fx files are the second worst explained (or rather not explained at all) bit of development in the "SDK." The worst being of course the black-box known as the .air file.

I've only had modest success with .fx files myself, and that quite honestly mostly by accident. I typically begin with finding an effect (.fx) file that's similar to what I want, then proceed to reverse-engineer it to try to figure out how it's doing what it's doing... :D

Part of the problem is that no edits to an .fx file can be seen without shutting down FS and relaunching it. It's tedious and a very HUGE "time sink..." :banghead:
 
Oh dear. I am afraid that creating and editing .fx files are the second worst explained (or rather not explained at all) bit of development in the "SDK." The worst being of course the black-box known as the .air file.

I've only had modest success with .fx files myself, and that quite honestly mostly by accident. I typically begin with finding an effect (.fx) file that's similar to what I want, then proceed to reverse-engineer it to try to figure out how it's doing what it's doing... :D

Part of the problem is that no edits to an .fx file can be seen without shutting down FS and relaunching it. It's tedious and a very HUGE "time sink..." :banghead:

I completely agree.

Even though I use FX Editor, it takes forever to create a useable effect.

My problem is now that if I launch two separate light effects side by side, they are often out of sync and I dont know what to do about it.

I have seen an 'effect control' being used for e.g. lighthouse lights, but can they be called from the aircraft cfg somehow?


Michael
 
Yes, you can use a 'controller .fx' file in an aircraft.
 
Yes, you can use a 'controller .fx' file in an aircraft.

I am not sure if this can be done 'outside' the model.

If I place a control fx in the aircraft cfg lights section, nothing happens?

light.17 = 7, 23.3, 0.3, -2.2, Cntrl_S64_mirror_lights,


Michael
 
A question if I may.

My working with effects files is at an early stage. In my experiments I have created a single-sided poly as an attach point, and placed accordingly. I have attached the effect as the left nav light. This does the trick, but my brain is thinking outside the box. Is it best to use a single sided poly, or is it best to create a small sphere and attach the effect to several polys in all directions of the radius, as far as efficiency in effect is concerned?
 
Last edited:
Back
Top