Hello,
I already tried to post my thread but then I got the logout message and my thread was gone. I actually explained all things briefly and very understandable even for users, who simply don't want to read endless documentations!
Anyway, I'm too lazy to re-do that again. Therefore, here's the code (Add. note: I calculated the hex code of the Appendix into digits via calc.exe from Windows):
Code:
function OnEvent(event, arg) --Any input device
if(event == "PROFILE_ACTIVATED") then
--profile has been activated
end
if(event == "PROFILE_DEACTIVATED") then
--profile has been deactivated
end
if(event == "G_PRESSED" and arg == 18) then --check if G18 is pressed
--You have to make the beginning by yourself ingame i.e. make a simple stair and a the first roof.
--The rest is automatically done by the script.
PressAndReleaseKey(47) --Stair
Sleep(60)
PressAndReleaseMouseButton(1)
Sleep(10)
PressAndReleaseKey(48) --Roof
Sleep(60)
PressAndReleaseMouseButton(1)
Sleep(10)
PressAndReleaseKey(45) --Wall
Sleep(50)
PressAndReleaseMouseButton(1)
Sleep(10)
PressAndReleaseKey(46) --Floor
Sleep(50)
PressAndReleaseMouseButton(1)
Sleep(10)
PressAndReleaseKey (47) --Stair
Sleep(20)
PressAndReleaseMouseButton(1)
end
end
--Use the G-Series LUA-API Docs to understand what's going on.
--Link: https://douile.******.io/logitech-toggle-keys/APIDocs.pdf
Sincerely Macrophage.