How to run some FS2020 commands by luamacros?
Posted: 14 Oct 2022, 21:05
In FS2020 one can see different instrument views by the commands [CTRL]+1 ... [CTRL]+9. I would like to map a single key in a second keyboard to do this commands. But it seems impossible for FS2020 to reciev commands from LUAMacros. I have tried this command:
but nothing happends.
This commads works fine:
I use the commands in a modified quickstart.lua file.
Why won't the first command not work in FS2020?
Thanks!
Code: Select all
elseif (button == 97) then -- PANEL_1
lmc_send_input(162, 0, 0) -- press Left CTRL
lmc_send_input(49, 0, 0) -- press '1'
lmc_send_input(49, 0, 2) -- releare '1'
lmc_send_input(162, 0, 2) -- release Left CTRL
This commads works fine:
Code: Select all
elseif (button == 101) then --
lmc_send_input(162, 0, 0) -- press Left CTRL
lmc_send_input(67, 0, 0) -- press 'C'
lmc_send_input(67, 0, 2) -- releare 'C'
lmc_send_input(162, 0, 2) -- release Left CTRL
elseif (button == 102) then --
lmc_send_input(162, 0, 0) -- press Left CTRL
lmc_send_input(86, 0, 0) -- press 'V'
lmc_send_input(86, 0, 2) -- releare 'V'
lmc_send_input(162, 0, 2) -- release Left CTRL
Why won't the first command not work in FS2020?
Thanks!