Jump to content
The simFlight Network Forums

Troubles with Lua in latest P3D Version.


Recommended Posts

Hello,

i have an Lua Script (Freeware for Dash8) loaded, but in latest FSUIPC id did not work korrekt.

The Window after Work of this lua  did not close...

Going back to 4939k.

 

see atachement (sorry im not permitted to upload an lua script?)

renamed it into txt.file

Q400VSpeeds.txt

Link to comment
Share on other sites

i have an Lua Script (Freeware for Dash8) loaded, but in latest FSUIPC id did not work korrekt.

The Window after Work of this lua  did not close..

 

Please state the VERSION of FSUIPC which "did not work correct". "Latest" is never good enough, it is not specific. If you do not mean 4.942, please update and try again.

 

Is the version of P3D the last hotfix (#4) for 2.5? Do you have the build number? And are you saying that whatever goes wrong doesn't with 4.939k?

 

4.939k is too old to work correctly the the latest P3D build, 12946.

 

Also please explain what you mean by "the Window after Work". 

 

Pete

Link to comment
Share on other sites

Hello,  its not easy to me tis to wirte (Bad englisch)

First: i use P3D 2.5.12945.0

an simconnect 2.5.0.0.

This script opens an window and i was ask, which flaps i use for start and landing.

in my installed version 4939k did this window close from itself, after i input the flaps.

whit the latest FSUIPC id did not so. i must close this self.

i mean this green window

it did not close:

post-8251-0-51068900-1439570204_thumb.jp

Link to comment
Share on other sites

First: i use P3D 2.5.12945.0

an simconnect 2.5.0.0.

This script opens an window and i was ask, which flaps i use for start and landing.

in my installed version 4939k did this window close from itself, after i input the flaps.

whit the latest FSUIPC id did not so. i must close this self.

i mean this green window

it did not close:

attachicon.gifUnbenannt.JPG

 

I'm afraid I cannot now go back to P3D build 12945 to test this. Can you update to 12946 please? However, I don't think it will necessarily make much difference.

 

I did try your Lua program here and though of course it won't work properly (I do not have the aircraft it deals with), I "fiddled" it to get some of the "display" calls to operate and they all closed fine -- when the program exits. However, this is a tidying up activity which FSUIPC attempts to do, and is quite precarious. I think the differences you found between versions are simply ones of timing.

 

It is definitely not good practice for a plug-in to create a display window then simply terminate, without caring what happens to it. You should either use the second parameter in the display calls  ("delay"), to specify how long the display should last, or explicitly clear it with a null string before exit. Please see the documentation.

 

Note also that the  documentation for the display function doesn't actually say what happens to the display when you exit, and you should also note that the one you are using is a generic one for all plug-ins and is not specific to your program, unlike "setowndisplay".

 

Pete

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.