-
Posts
1802 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Everything posted by Bailey
-
I would look for it via a list_indication that displays the info on the digital fuel panel.
-
Short answer for trim setting is "not really". The trim amount in the fly-by-wire aircraft can change on its own and is hidden in one of the screen menus. You'll have to fly by feel and continue to practice for the F18. Short answer for fuel weight is yes.
-
STREAM DECK PROFILES LIBRARY
Bailey replied to ZQuickSilverZ's topic in PC Hardware and Related Software
You should be able to get the cockpit readout using list_indications, right? Its going to be the final three digits of list_indication(9) which by default returns something like: PCN_UR_DIGITS\ 041072\ in its normal mode. Ah, I see the problem here. CAL = Calibration (Maintenance) which is used for maintenance and not functional in DCS. I see! Nevermind then! -
TLDR: Scroll down for the code. I think about the logic as it makes sense to me. Firstly, if I look at the speedbrake indicator and see the word "IN", I would expect the speedbrakes to be "in". Now that I have established that mentally, what determines the speedbrake showing "IN"? These values are what I observed playing with the two args in the modelViewer. We know that when arg[8307] AND arg[8308] are both 0, we see "IN". We know that when arg[8307] is 1 AND arg[8308] is 0, we see the holes, which means Partially Extended. We know that when arg[8308] is 1, we see the black flag, which means Fully Extended. Here is how it looks in lua: You can see that I used "more and less than" instead of 1 or 0. That's because 1 and 0 are very precise and sometimes the animations give a fit. Sometimes they don't. In this case it is ok for us to use "more and less than 0.5" because the animations should not stop on anything other than 1 or 0. I hope that makes sense. Also notice that I named things plainly and in a way that is readable, especially the exported values. This helps in the event that you have to go pack and adjust something. Remember, a value in "quotes" is a string. Jumping in-game we see that it works. Now we can rewrite it into data that other apps or functions can use. function ExportScript.SpeedBrakeIndicator(mainPanelDevice) --exports two speedbrake indicators in one local speedbrake_indicator --exported value if mainPanelDevice:get_argument_value(8307) < 0.5 and mainPanelDevice:get_argument_value(8308) < 0.5 then speedbrake_indicator = 0 elseif mainPanelDevice:get_argument_value(8307) > 0.5 and mainPanelDevice:get_argument_value(8308) < 0.5 then speedbrake_indicator = 1 elseif mainPanelDevice:get_argument_value(8308) > 0.5 then speedbrake_indicator = 2 end ExportScript.Tools.SendData(53025, speedbrake_indicator) end And there you go. Put `ExportScript.SpeedBrakeIndicator(mainPanelDevice)` in your preferred refresh rate and you now have the base for a speedbrake indicator for the F14. With more time you can write an even more accurate indicator, but I think this gets the intention across and is quite usable. Thank you for this. I'll put it in the Library when I have the chance.
-
here is a snippet of list_indication(5) -----------------------------------------\ txt_BINGO\ 0\ -----------------------------------------\ txt_FUEL_UP\ 10660T\ -----------------------------------------\ txt_FUEL_DOWN\ 10660I\ -----------------------------------------\ I do not know a way of getting that data in the image without having it on the screen, which kind of defeats the purpose of having it on the Streamdeck. But, for the left screen, you will get stuff like this. I have edited out some lines from list_indication(2). I hope that help. TLDR; What you are asking for may not be possible, but there are some other options.
-
Streamdeck and voice attack conflict
Bailey replied to F18mech's topic in Controller Questions and Bugs
Your question is a bit too general. There are many voice attack profiles and plugins and there are many streamdeck profiles. If you can be extremely specific with everything I think it would help when people try to either diagnose or replicate your problem. To answer your initial question, no, I don't get conflicts. -
Please attach the lua you are using.
-
I am glad my walkthrough helped. Take a look at arround line 1398 of the F16 lua file in the Library. You should see this: ExportScript.Tools.SendData(3000, "OTHER1\n" .. CMDS_O1_Amount) ExportScript.Tools.SendData(3001, "OTHER2\n" .. CMDS_O2_Amount) ExportScript.Tools.SendData(3002, "CHAFF\n" .. CMDS_CH_Amount) ExportScript.Tools.SendData(3003, "FLARE\n" .. CMDS_FL_Amount) ExportScript.Tools.SendData(3004, "CH " .. CMDS_CH_Amount .. "\nFL " .. CMDS_FL_Amount) ExportScript.Tools.SendData(3005, "O1 " .. CMDS_O1_Amount .. "\nO2 " .. CMDS_O2_Amount .. "\nCH " .. CMDS_CH_Amount .. "\nFL " .. CMDS_FL_Amount) I'll show you what the output will look like on some of these: (3000) OTHER1 -- (3002) CHAFF 60 (3004) CH 60 FL 60 See the pattern yet? A pair of quote defines a string. The lack of a pair of quotes says that it's a variable that was previously defined. The \n is how you do a NEWLINE, similar to pressing ENTER on the keyboard. A pair of dots ties string groups and variables together. (Or even variables to other variables for special cases.) This is how you make the export say different things. Give it a try.
-
I havent tried your code, but you are missing and "end" after the end of the "if". Random example: if string.len(minutes) < 2 then minutes = "0" .. minutes end Let me know how that works out for ya.
-
Here is what I would do. Head over to the moduleViewer and load in the F-5 Cockpit via Mods/aircraft/F-5E/Cockpit/Shapes/Cockpit_F-5E.EDM. Open the Args dropdown and find [22]. Adjust the screen so that you are looking at the fuel guage and start adjusting the 22 value to see what it looks like. Lucky for us, you should notice that it adjusts from 0 to 2,500 lbs of fuel in a linear fashion. Now we know that in the lua we can simply multiply the output by some number to get the indicated fuel. That number is....2,500 ! Quick mental math check, if the fuel guage is half way, the arg should indicate 0.50 and the value on the guage should be half of 2,500, which would be 1,250. Ok, we already said that our magic multiple is 2,500 so our equation is [22] * 2,500 = resultFuel 0.50 * 2,500 = resultFuel 0.50 * 2,500 = 1,250 Correct! The first equation will be the math you will use in the lua. (We will adjust it to read as lua code later). Now we open the F5 lua, Ctrl+F "fuel" and...oh my... someone already did it for us! Check around line 646 if you have the lua from the Library (). -- Fuel Quantity Indicator (Dual) local lLeftFuel = ExportScript.Tools.round(mainPanelDevice:get_argument_value(22) * 2500, 0) local lRightFuel = ExportScript.Tools.round(mainPanelDevice:get_argument_value(23) * 2500, 0) ExportScript.Tools.SendDataDAC(2003, lLeftFuel) ExportScript.Tools.SendDataDAC(2004, lRightFuel) ExportScript.Tools.SendDataDAC(2005, lLeftFuel + lRightFuel) *It's just in the wrong place for DCS-Interface to see it and changes need to be made.* Copy and paste it to the end of the `function ExportScript.ProcessIkarusDCSConfigLowImportance(mainPanelDevice)` function, but before where it says "end". For me that's about line 615. Change the "SendDataDAC" to "SendData". Change the export numbers to 2006, 2007, and 2008 (or whatever is available). Save, launch DCS, and do as you did before but instead of putting 22 put 2006, 2007, or 2008. I am loading into DCS F-5 Instant Action Takeoff now and.....voila! whoops, I forgot to replace the two other "SendDataDAC" with "SendData"... Just gonna edit that real quick, save the lua, and in DCS press RShift+R to restart the mission, and...viola! There they are! I hope this helps answer the question as well as explain the process I use to get some of those values exported into useful information. (Yes, this was a live performance )
-
Good point. It should still be able to do that. I know some people that would protest if it had changed On the other hand, the Mi-8 is not a multi-crew aircraft (yet) so it wouldn’t be subjected to the “is it bugged or not” limitation discussed above.
-
The second post was with respect to online multiplayer. You can in the Gaz and Mossie.
-
Here are some posts that led me to believe the current implementation is not normal. Note "like any multi seat aircraft" and "..Huey, you can switch to pilot". These are searchable on the official DCS discord.
-
The only issue I have with that solution is that a button may have to be pressed one extra time to "sync" depending on the start state of the aircraft and if the Increment value is 1 or -1. Edit. Nevermind. Both cold and hot starts have the same buttons depressed. The above issue is fixed if you have ECM 1 Increment Value as 1 and all others as -1. Thank you. Wiki has been updated.
-
Cat's outta the bag. F16 has been updated with the ECM Panel to include the buttons and their colors. Check out this post and the ones surrounding it for the research, collaboration, and awesome teamwork: Please remember to read the wiki for more information. Enjoy! https://github.com/asherao/DCS-ExportScripts/wiki/F-16C
-
I have attached the working profile and lua. Specifically for the F16 ECM panel, pay attention to line 694 and lines 1047-1321 in the lua. I'll update the Wiki later. The BIT button is there for testing. Tap the ECM button once to turn it on. Double tap it to turn the button off... Oh, and before I forget, I can't get the ECM buttons to work nicely via a DCS Interface Switch Input button. Here is my setup for ECM 1. A press will enable it and a double press is required to disable it, which seems odd. Any ideas why and/or a solution? The ExportScripts Library has been updated with the files mentioned above: https://github.com/asherao/DCS-ExportScripts https://github.com/asherao/DCS-ExportScripts/wiki/F-16C
-
Yes, I do get the ghost outlines. I tried to lessen the effect by making the color more blue/grey-ish and by making enough boxes to go across the entire width. Hopefully its a workable solution. It does not look as bad IRL at distance.
-
I am putting the function near the bottom, yes. Remember to call the function using `ExportScript.EcmPanel(mainPanelDevice)` within either `ExportScript.ProcessIkarusDCSConfigHighImportance(mainPanelDevice)` or `ExportScript.ProcessIkarusDCSConfigLowImportance(mainPanelDevice)`. Thanks for the copy/paste!
-
Minor error: [192]= "%.1f", -- Btn_FRM_A should be [492]= "%.1f", -- Btn_FRM_A Thank you so much for the arguments! Really quick: I had my "eureka moment" right before having to go do something, so you'll have to wait for the full implementation and the partial-profile with the image-behind. Attached is the code in full for the function. The behind-image is below for your exploration. For the blocks to format correctly you must have the Text in the stream deck set to Times New Roman, 16 pt, align bottom, HTML color 0f1620. For the rest of the buttons it's just a copy/paste drill, exporting the new images, then documentation, etc. Just will take some time. More to come later!
-
the @scoobie certified "money approach" is how I attained the majority of my lua knowledge. The other parts are filled in by knowledge and helpful people on these forums, the DCS discord, and the Hoggit discord.
-
Hey there. So the question is how to represent the status of a number of lights on one single (jammer) button as seen in DCS on the stream deck? If so, that's an interesting problem. Off the top of my head, a solution I would try to do first would use a special character next to the letter to represent its status. Something like a dot (°), or colon (:), or even a pair of vertical bars(| |). Lua can take a lot of odd characters and even emojis, believe it or not! I don't think text color changes are possible. Be creative. I'll put this on my exploration list.
-
DiCE: DCS Integrated Countermeasure Editor by Bailey (v6 MAY2023)
Bailey replied to Bailey's topic in DCS Modding
DiCE has been updated to reflect the changes in the DCS F-16C Viper for DCS v2.7.9.17830. If you are not on that version, do not update. As of this post's timestamp DCS v2.7.9.17830 is the current DCS Open Beta version. If you find some oddities with the F-16 or its countermeasure system, please backup and then delete your '\DCS World OpenBeta \Mods\aircraft\F-16C\Cockpit\Scripts\EWS\CMDS\device\CMDS_ALE47.lua' file and your '\Saved Games\DCS.openbeta\Config\options.lua' file. Run a DCS repair. Then reinstall the mod. Enjoy and happy holidays! https://www.digitalcombatsimulator.com/en/files/3312680/