Jump to content
The simFlight Network Forums

ark1320

Members
  • Content Count

    191
  • Joined

  • Last visited

  • Days Won

    4

ark1320 last won the day on July 27 2017

ark1320 had the most liked content!

Community Reputation

5 Neutral

About ark1320

  • Rank
    Advanced Member

Profile Information

  • Gender
    Male
  • Location
    Colorado, USA

Recent Profile Visitors

1,460 profile views
  1. ark1320

    ipc.writeSTR() Window

    Ah, it was the single line vs multi-line difference that I didn't understand. Thanks very much for clearing that up. Al
  2. Hi Pete, It seems in P3Dv4.3 that sometimes the code ipc.writeSTR(0x3380, " text ") ipc.writeSW(0x32FA, n) writes to the sim's 'Green Bar', and other times to the common Simconnect window. Is there a way to force the output text to the "Green Bar", and to know to which type of display window the output will go? Thx, Al FSUIPC5.141e Win10
  3. ark1320

    P3Dv4 Display Help Needed

    OK, yes, I use the Window mode with P3D4, so that explains why it didn't work. Not really important in the scheme of things right now. I will send you an email now so you can respond on Monday at your convenience. Thanks, Al
  4. ark1320

    P3Dv4 Display Help Needed

    Sure, glad to help. I can just uncomment the ipc.setdisplay() commands in my scripts to test things. Maybe ipc.setdisplay(SET_PERCENTS: x, y, cx, cy) The : after PERCENTS implies the x,y,cx,cy parameters are percentages, at least to me. 😊 BTW, the RestoreSimcWindows=Yes option does not seem to work for me -- another P3Dv4 casualty I guess. Al
  5. ark1320

    P3Dv4 Display Help Needed

    Ah, a great tip -- thanks! Al
  6. ark1320

    P3Dv4 Display Help Needed

    Pete, In regard to my second post above about NO display after reinstalling P3Dv4, the solution to the problem was I needed to check the Message Text box found on the P3Dv4 Information Tab under MISCELLANEOUS TEXT. That little detail has cost me many many hours of grief, so I hope this helps someone! Regarding my first post above, I have found the best temporary solution is to grab and reposition/resize the SimConnect Msg window as I want it and leave it there for all Lua scripts to use. I have temporarily commented out all the ipc.setdisplay() commands from the scripts. This is not an ideal solution, but better than what I had. And if you ever find a way to have more than one window active at a time, that would be great! I really miss having that capability. Thanks very much for your efforts with this difficult display issue. Al
  7. ark1320

    P3Dv4 Display Help Needed

    Pete, Another problem related to the issue of display in P3Dv4 as described above: After reinstalling P3Dv4 and FSUIPC5 (after a Win10 update caused problems), I not getting any Lua script displays at all on the screen (not the green bar or the simconnect message window) even though the Lua scripts are running . For example, I have a script that moves an aircraft after asking the user to input information like new heading, distance to move, etc, using the ipc.ask() function. Even though there is no display as expected as a result of the ipc.ask() functions, the aircraft does move as expected based on the inputs I provide "in the blind". And these scripts have all been used in FSX for a long time. I had the exact same problem the first time I installed P3Dv4 and FSUIPC5 and after a day of struggles the problem went away but I don't know why ( have not been so lucky this time). The issue seems to have to do with somehow initializing the simconnect message window location and size in order to get a display on the screen. Al
  8. Hi Pete, Many of my Lua scripts make extensive use of the setowndisplay() command and now that this command does not work in P3Dv4 as it previously did, I am trying to find alternatives to the extent possible. As a first step I'm trying to understand how the ipc.setdisplay() command works with the 'common use' P3D4 simconnect message display window. When I run the small test script below with a keystroke, the display window is not in the location or the size that I expect. I understand ipc.setdisplay parameters are percentages relative to a display window, but what window? Do the percentages apply to the previous window even after it has been closed? Do I perhaps need to somehow reset the P3D4 simconnect display window location and size (e.g., to 'full screen size') before setting it to the size I need? Clearly there is something basic I don't understand about initializing and controlling the common simconnect message window location and size. In addition, when I ran the script below I got the 'dual' display (green bar and the little simconnect msg window) shown below as expected. But if I comment out the ipc.writeSTR() and ipc.writeSW() lines, I get no display at all. It is as if the green bar string display is also triggering the simconnect msg window display somehow. Without that trigger there is no simconnect window display. Also note the ipc.getdisplay() returns a sy window size of 50 vs 60 for some reason. If I change the simconnect location parameters from 100, 100 to 50, 50, the little display window moves about an inch to the left and an inch up on the screen. Test script: ipc.setdisplay (100, 100, 40, 60) ipc.display ("TEST") state, x,y, sx, sy = ipc.getdisplay() ipc.writeSTR(0x3380, state..x..y..sx..sy) ipc.writeSW(0x32FA, 10) ipc.sleep (10000) ipc.display ("") return Thanks for your help, Al FSUIPC 5.14 Win10, P3Dv4.3 Edited with new information
  9. Landing_Params is a Lua script for FSX/P3D that displays landing parameters in a small text window that pops up after the aircraft has landed and has slowed to taxi speed. The script should be activated with a key or button (like the gear down key/button) during the approach to landing. Parameters displayed in the window at touchdown are Indicated Airspeed (IAS, Kts), Ground Speed (GS, Kts), Landing Distance (LD, ft), Landing Roll (LR, ft), Vertical Speed (VS, ft/min), Attitude Indicator pitch at touchdown (AI), and Bounce Count (BC). Data collection begins when the a/c passes through a radar altimeter determined threshold altitude window between 45 and 55 ft (i.e., the nominal 50ft threshold height). In addition, more detailed landing parameter information may also be logged. May not display correctly with P3Dv4 due to Lua display limitations. Documentation included. Landing ParamsFiles.zip
  10. Approach CallOuts consists of two Lua scripts and a sound folder with wav files that work together to provide altitude, gear and flap settings, and approach minimums (Decision Height) audio callouts on an approach to landing. The altitude callouts are at Radio Altimeter (RA) heights of 2000, 1000, 500, 400, 300, 200, 100, 50, 40, 30, 20, and 10 ft. At 800ft RA (a user settable value) you get a callout of current flap and gear positions. There is no gear callout if the aircraft has a fixed gear. The minimums callout may be based on a RA or BARO (MSL) altitude. May not display correctly with P3Dv4 due to Lua display limitations. Documentation included. ApproachCallOut2Files.zip
  11. ark1320

    LuaToggle Clarification

    Pete -- thanks very much for the detailed answer. Al
  12. Hi Pete, Is my understanding below correct? If a key assignment is made using Lua ScriptName under the FSUIPC Key assignments tab, then when that key is pressed the Lua file ScriptName is loaded and run. In contrast to this, if a key assignment is made using LuaToggle ScriptName along with a Parameter field entry (flag number), then when the key is pressed the associated flag value is toggled, but that is all, the script ScriptName is not loaded and run at that point due to the key stroke. So if ScriptName is to detect and process the changed flag value, [e.g., by using event.flag( ) ], ScriptName must of previously been loaded and run such as by listing it under an [Auto] section in the FSUIPC.ini file. Thanks, Al
  13. Hi Pete, Is it correct to say that each Lua plug-in has its own set of 256 flags to be independently manipulated and tested? BTW, there seems to be a minor typo in the event.flag() documentation: "If no flag number (0 – 256 255) is provided, any of the 256 changing will trigger the event. Otherwise only the selected flag will do so." Thx, Al
  14. ark1320

    event.offset() questions

    OK, I see. And if the only condition you were trying to detect was a change in the offset value, rather then a particular offset value, you would need to identify the first call to the function associated with event.offset() and handle that as a special case. Thx, Al
  15. Hi Pete, In the documentation for event.offset() it says: The function is also executed initially, when the plugin is first run, in order to initialise things. This saves using an explicit call to do the same. Q1. Does this mean, for example, if the purpose of the called function is to terminate the script with an ipc.exit() command when the value in the offset changes, the script will be immediately terminated because the function is executed automatically when the script is first run even though the offset value has not changed? Q2. If execution of the script has been suspended with an ipc.sleep() command, will a change in the offset being monitored by event.offset() be missed or ignored? In other words, does ipc.sleep() also suspend the action of the event.offset() command? Thanks, Al
×

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.