Jump to content
The simFlight Network Forums

Leaderboard

Popular Content

Showing content with the highest reputation since 08/17/2025 in Posts

  1. Do you mean Hvars? And if so why is the title of this topic 'Lvars'? K-type variables are events, B-type Input Events, etc. You can use both H (HTML) and L (local) type vars in FSUIPC7, either directly or using presets / calculator code. The easiest way to use hvars is via calculator code really. There is no actual way to discover the available hvars for the loaded aircraft, as there is with lvars, so the way this works in FSUIPC7 is that you have to let FSUIPC7 know which hvars you want to use by providing a *.hvar file (some are included as an example). This is documented in the Advanced User guide, under the WASM section. Once a hvar is known to FSUIPC7, you can use it either in a macro or a lua script. But these days almost everybody uses hvars via presets (calculator code). You can define your own preset to trigger a hvar: in the myevents.txt file, e.g. Trigger_My_Hvar#(>H:hvarName) Then assigning to the preset 'Trigger My Hvar' would trigger/set the hvar ' H:hvarName'. See the documentation for further information. Also take a look at the available presets in the events.txt file as many of these will use hvars. You can find available presets by pressing the Find Preset button in the assignments windows once Select for Preset is selected/checked. John
    1 point
  2. Yes, I should have mentioned that. Basically, if one program needs admin privileges, then for auto-start (either via FSUIPC or MSFS) then everything needs to be ran with elevated privileges. Previously this was possible, but windows OS is getting stricter and stricter on each release, for obvious reasons I think... I don't think there is anything I can do about this, but will look into it further when time permits. I think that for now you will just have to manually start anything that requires admin privileges. You could also ask/enquire on the support forums for any program that does this as to why this is necessary in the first place... If you find any solution, please update this thread! Regards, John
    1 point
  3. Thank your all you help in this. I successfully created the profiles for the aircraft--I appreciate your insights-- Robert
    1 point
  4. Glad you have now resolved this. I have updated the title. Regards, John
    1 point
  5. What aircraft are you using? Look for available presets - either using the Find Preset button in FSUIPC, or search on the MobiFlight HubHop site (https://hubhop.mobiflight.com/presets/). You can also try listing available lvars (Add-ons->WASM->List Lvars) to see if any look applicable and if so try them. You can also use logging: set logging for Events, open the logging console (Log->Open Console) and then open the doors using the virtual cockpit and see if anything is logged, and if so, you can use that. John
    1 point
  6. Yes - I saw that when I made the second script and corrected it! As reading the value of an lvar by name is quite time consuming (as it has to go through the list of available lvars) , the script cant also be more efficient: id = ipc.getLvarId("L:Lear_LDG_Weight") if id == nil then ipc.createLvar("L:Lear_LDG_Weight",10361) while (id == nil) do ipc.sleep(50) id = ipc.getLvarId("L:Lear_LDG_Weight") end end ipc.execCalcCode(" (A:TOTAL WEIGHT, pounds) (>L:Lear_LDG_Weight) ") -- get current total weight ipc.sleep(200) ldg_wt = ipc.readLvarById(id) ldg_wt = math.floor(ldg_wt + 0.5) Basically if you are accessing an lvar by name more than once, it is better to get the id of the lvar and use the id functions. John
    1 point
×
×
  • 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.