Настенный считыватель смарт-карт  МГц; идентификаторы ISO 14443A, смартфоны на базе ОС Android с функцией NFC, устройства с Apple Pay

Logitech lua script press key

Logitech lua script press key. It does this by providing an API (application programming interface) which is essentially just a set of functions that you can use to tell your hardware to do things. I wrote 2 similar codes to try and approach my problem from two different ways. Windows allows maximum 6 keys to be down at the same time. function OnEvent(event, arg) --OutputLogMessage("event = %s, arg = %s", event, arg); if IsMouseButtonPressed(5) then. You would need to have a timer calling your function every so often, and that function would check a flag, which you set when the get the Key Pressed event and clear when you get the Key Released event. toggle = "off". Maybe I'm just a little old but I can't seem to find a way to set up a macro for that either :D. Apr 20, 2023 · scripting. Just use the Keyname in quotes as shown throughout this guide. But I have difficulties to run their example code. Now you should keep LAlt pressed while pressing LMB to start the script. Press G3 - hold down ALT. Example, Tapping Mouse Button 4 activated the 1 command. 2. Hello, Recently I added the logitech Pro X gaming Keyboard to my G Hub software (already using the G502 wireless mouse). How to use logitech lua scripting. Now you should have the following: Primary Click = G8. Egor Skriptunoff. btn4 = btn4_current_state. And your script would be the following: EnablePrimaryMouseButtonEvents(true) function OnEvent(event, arg) if event == "MOUSE_BUTTON_PRESSED" and Feb 25, 2022 · Sleep expects a single argument - an integer amount of milliseconds. Jul 9, 2022 · For a toggle-key LGS/GHUB can use only lock keys (ScrollLock, NumLock, CapsLock) and (only if you have Logitech gaming keyboard) keys G1,G2, It cannot use usual keys: letters. How to make this Logitech Mouse LUA script work better? 0 Can Someone Combine these 2 scripts. Yeah with LUA or python scripts or AHK. event. USE DEFAULT. Yes exactly, I would like the script to use the G5 key's mapped "3" from the macro editor. Toggle ALT G3. So if i hold down W i could have it being spammed with random delays until i release the key. until not IsModifierPressed("lctrl") -- left ctrl. Jan 16, 2024 · I need Lua script start when I press M4 button on mouse press keys but I need this in loop until I press M4 again. I'm new to Lua language, just wanna program a macro for Logitech Mouse button, the desired action is: press the button to start and loop the macro continuously until I toggle it off by pressing the button again. io/logi Dec 2, 2022 · I have a logitech G910 keyboard which has 9 G-keys and 3 "M-key" sets for a total of 27. May 15, 2022 · But you can write external program (exe file) working with Logitech LED illumination SDK functions, create a GHUB macro to run this exe-file, and invoke PlayMacro from Lua script to run this macro. more. Dec 23, 2022 · Logitech Script, Press and hold key until releas. So it will loop for 300 times and then press 1 when it's done, then repeat the loop again for 300 times, so on & so on. Oct 31, 2021 · Welcome,I'll teach you how to create or import a script in the new Logitech Gaming Hub update on LUA. function OnEvent(event, arg) if event == "MOUSE_BUTTON_PRESSED" and arg == 4 then. Jan 10, 2021 · Rapidfirebutton=4 -- tis my forward key for thumb use But "forward" key is MB#5, not 4. Jul 2, 2018 · Get access to all of the LED backlighting and RGB capabilities of Logitech G products, including implementation in Logitech G HUB Early Access. The GHub team has the fix ready for the next update of GHub. Spamming Key with lua. Create a new Lua script. G HUB can also see LED status for NumLock, ScrollLock and CapsLock (for example, IsKeyLockOn("CapsLock"). github. Spamming Key with G Hub scripting question with Lua. Under Profiles, you will see the second option to the right of Details is Scripting. Integrate profiles for custom key configurations, develop in-game effects, or mark keys to keep track of cooldowns on various commands. CSMacro. For example, the following LUA script should switch the MKey state between M1/M2/M3 using the G1 key, but actually does not do anything (although the code is executed, as the debug log lines appear): Nov 23, 2015 · Can someone help me write a script to toggle Shift+W on a G-key for my Logitech keyboard? I found one for "W" but not "Shift+W", and don't understand the language necessary to add it. com Store: https: May 25, 2021 · Was wondering how to add the sleep timer to my LUA script so it doesn't continually loop as fast as possible and press 0x29, I'd like to make it so when buttons 1 and 3 are pressed on my mouse it hits key 0x29 once every 3-4 seconds instead of as fast as possible. Start() task_autoPress. Lua is needed if you want sometimes turn this functionality on, and sometimes turn it off. Goto GHUB (keyboard device, assignments section, SYSTEM tab) Bind "Back" to key G5. ") until not rbPressed. There is no event LSHIFT_BUTTON_PRESSED, you receives events only from G-buttons (all buttons Oct 22, 2022 · Replace IsKeyLockOn("capslock") with IsModifierPressed("LAlt"). Oct 8, 2023 · Today I bought a logitek g502x mouse started writing scripts (I had never written them before) I looked in different places and saw an interesting option The script that i make, does not return errors, but for some reason it does not do anything. The code example #1 at the end of LGS_script_template. here is my code; local M4_pressed = false. A quick and informative guide awa Jun 19, 2021 · I would like to make a Logitech Lua script where it continuously holds down the mouse buttons for example mouse button 5 without holding it, just have the mouse button turned on until i release it by clicking it once. Back = G1 G4. G HUB will reinstall, and this will resolve the issue while retaining the settings. Step 4. toggle = "on". Copy the Lua script provided in the script file (src/script. e. If it does not work, try inserting Sleep(10) just after if recoil then. Yours are not. Of course, it would be ideal if the devs would just add one to the game, but we make do. answered Jul 5, 2020 at 4:36. So if sub profile 1 "M1" is active and I press the G4 key the LCD says "Forward" and if the sub profile 2 "M2" is active and I press the same G4 key then Dec 28, 2023 · Assign the "Back" action to physical G1 key (in the LGS/GHub GUI). Is there anyway to add something to specify that. my code: local msMakro = false. Add a Comment. I just ordered a G502 Lightspeed and learned about the scripting capabilities with Lua. Hello All! We are aware that the current version of GHub is not allowing us to save LUA scripts. Make the Most of your warranty. 45" documentation and it looks like I am using them correctly. Set to 5 if you want to use "forward" mouse button. A subset of LUA built-in functions. 1. Mouse 4 On/off. Jan 23, 2023 · I am trying to create a script that works as a toggle using LUA the functionality I want is a single key "G1" which initiates a loop when pressed and breaks the loop when pressed again. . But if an event is generated (by a mouse button), Lua script can determine whether NumLockLED was ON or OFF at this time moment. You can find this by going to 'Help > Scripting API' in the scripting window. button_to_toggle = 1 -- What button to toggle. Learn how to upload Logitech macros, edit scripts, and I have a Logitech G502 mouse and a G213 keyboard, and I'm looking for a way to activate an action in Lua by pressing a key. Lua is used by Logitech G-series hardware to provide advanced scripting functionality. Only a subset of functions that came with the Lua engine (i. Jan 6, 2021 · PressMouseButton(1) Sleep(50) ReleaseMouseButton(1) end. (Left Shift can be simulated by another software). 5. Keyboard keys can be found at the very bottom of the "Scripting API" document. is remapping even possible in this case? I would not want to use ahk for this as i only want it for one game and ahk is bannable in this one Jul 31, 2020 · 1. – Egor Skriptunoff 2. If some action is assigned to MB#4 in the game, do the following: choose keyboard button you don't currently use in the game (for example, F12) goto GHUB (KEYS tab); bind F12 to your physical MB#4. The script works while CapsLock is ON. . How to program a toggle macro in LUA for Logitech Mouse button. function… Jun 14, 2023 · The only thing you need a Logitech mouse/keyboard for is to generate an event processed by OnEvent - this function is invoked by Logitech driver when a Logitech device (recognized by the driver) has changed its state. Stop() PressKey(pushKey) Here are the bindings that I have been working on. Paste this into the default profile script box, save, enjoy! toggle_button = 7 -- What mouse button should control the toggle. Bind this macro to mouse button. A user should open a text editor and press-and-hold middle mouse button until the string is long enough. 1 1. Jun 28, 2023 · I'm new to the community and I'm a little lost as to how to resolve this issue. Mar 13, 2023 · I like to combine these two lua scripts that let you switch between each function with mouse key. arg. ChangeVars(arg) task_autoPress. And i would like to toggle the status of the F buttons and change the RGB colour when that happened. Researching and looking for information on the matter, I found that the solution was to use "event == "KEY_PRESSED ", But it didn't work, I tested to see if there was any response with this code: function OnEvent (event Dec 19, 2022 · The only keys G HUB can "see" are: Shift, Alt, Ctrl (selectable: left/right/any). I'm trying to make a macro key with random delay times. 4,907 2 14 33. Click on the profile for the function keys you want to customize. The thing is i tried some modifications like this one, which is to replace (MOUSE_BUTTON_PRESSED) with (G_PRESSED) because my keyboard has f1-f12 g keys but nothing works. EDIT!!! SOLVED! TWICE! Thanks to StormWeaker for his script I found this solution on the Logitech website https://forums May 4, 2022 · The event is not generated for G-keys with disabled binding and for G-keys with standard binding. Create a macro which presses and releases mouse button. Make sure you're not using MB#4 ("backward") in the game. These are documented in the Scripting API that can be accessed via the script editor Help menu. This is possible with lua scripts right? I'm not familiar with how to use lua scripts at all. Jan 7, 2023 · 1. 4. Specifically, in my case, I do setup of the keyboard under Windows, and then go to my Linux PC to work, so I need to have the keyboard in on-board mode. Oct 8, 2020 · 1. ") Sleep(300) rbPressed = IsMouseButtonPressed(3) PrintBool(rbPressed) --PressMouseButton(3) OutputLogMessage("PRESSED. Or it can use any mouse button as a toggle key. The idea is the following, there are 2 commands. Mouse button#8 is now "spare LMB" just in case LMB works incorrectly. Mar 26, 2017 · These are all the buttons associated with the G920 Steering Wheel. attempt to call a nil value Line Number:1. DISABLE. Jul 4, 2021 · I have read the docs related to these two functions in the "G-series Lua API V8. if anyone could help, it'd be much appreciated. For example, use Sleep(10) MOUSE_BUTTON_PRESSED("11") is unknown function. – Egor Skriptunoff. -- NOT HOLD - PRESS AGAIN --. goto game options; bind the action to F12 instead of MB#4. I have written this script myself using logitechs lua api documentation to learn the language. EDIT!!! SOLVED! TWICE! Thanks to StormWeaker for his script I found this solution on the Logitech website https://forums May 25, 2016 · The script should perform the following: mouse key 4 switch on/off the script. if / elseif / else / end must be balanced. Nov 21, 2020 · A friend is using a LUA script for this Logitech mouse in a game, which performs a "press left-alt" action if he clicks and holds the right mouse button and then also clicks the left mouse button: May 25, 2021 · When the A key is being pressed the left MoveMouseRelative should switch to right MoveMouseRelative at the exact same time like A and Left mouse movement should stop exactly at same time and R and right mouse Move should start at exact same time then stop then go in perfect sync and it also needs to go vertically up at a third of the horizontal move speed when moving right and vertically down Nov 26, 2019 · I would like the script to know what is the current MKeystate M1,M2,M3 of the G13 and execute the these commands on only one MKeyState at a time M1, M2 or M3 rather then work across every one. However, I do not want it hardcoded as I want to be able to use to repeat any of the mapped keys. I wanted to know how I can activate each of them separately using mouse button 4 and mouse button 5. Update: As of today's GHub update users should be Jun 23, 2020 · Bind "Primary Click" to G8 (from now on, use button#8 instead of LMB) Bind "Back" to G1. In other words, you should modify the standard command assigned to G1 key. First I tried to use onevent (I know it isn't very advanced) and created this attack combo script. When I comment out the PressMouseButton(3) as above, press down the right mouse button with enough time (>300ms) and release the button, I get the following log: RELEASED. Click DISABLEto deactivate the button and clear any programming. local function is_btn4_pressed_again() Sleep(10) local btn4_current_state = IsMouseButtonPressed(4) local answer = not btn4 and btn4_current_state. And so that the script starts and finishes working ONLY when both mouse buttons are pressed (aiming and shooting). I want to link some regular keys to macro's for an example the shift key. For example, in the game config you assign both left mouse button and keyboard key combination Ctrl P to "Fire". Click on Scripting under the profile you use while gaming. Is it possible to have the Lua script execute keyboard button presses My Empyrion scripts, to get you started:https://pastebin. LGS/GHUB is unable to monitor press/release of usual keys (letters, digits, spacebar) on your keyboard. This one type "a" every 2000ms. random (50, 90)) ReleaseKey ("g") Sleep (math. DOWNLOAD ILLUMINATION. LUA scripts in GHub. mouse key 5 switch from one feature to other ( force move and autoattack ) The code is the follow: forceMove = false. If you want to determine whether button #11 is down: Assign a command "Back" to the mouse button #11 in the user interface of G Hub; Use IsMouseButtonPressed(4) in the script: function OnEvent(event, arg) Sep 27, 2022 · I have picked up learning lua. any idea how to fix this? here's the script: PressKey ("g") Sleep (math. Press G3 again - release ALT. Sleep(500) So, you want the following: 1) You press Btn#8, 2) LGS simulates mouse clicks and moves right and left continuously, 3) You press Btn#8 again, 4) LGS stops simulating mouse clicks and moves. Your code should work correctly. ("Back" is the default action for mouse button 4). Set repeat mode for this macro "while pressed". This is my first programming language. function OnEvent(event, arg) if event == "MOUSE_BUTTON_PRESSED" and arg == 1 then --set flag for mb1. Make sure the game ignores mouse button 4 click (in the game control settings). This is the easiest way to generate a strong password. Step 2. Feb 17, 2021 · idx = idx % #keys + 1. Nov 30, 2021 · 1. if IsMouseButtonPressed(1) then. Code#1 I am trying to make a Logitech GHub script which would press a single key at randomly varying intervals but it says: LOADED. function OnEvent (event, arg) if event == "MOUSE_BUTTON_PRESSED" and arg == toggle Mar 20, 2024 · Learn how to upload Logitech macros, edit scripts, and customize buttons on your Logitech mice and keyboards in this video. 0. Nov 23, 2021 · Logitech Script, Press and hold key until releas. AutoHotKey is unable to change internal variable of Logitech mouse driver. Then used this script. To assign a command to a function key, do one of the following: . I am starting to learn how to use Lua scripting for different game profile with logitech software. For example, if LMB means "Fire" then add key "P" as alternative way to fire in the game. PressKey(keys[idx]) elseif event == "MOUSE_BUTTON_RELEASED" and arg == 4 then. Aug 26, 2021 · Logitech Script, Press and hold key until releas. I'm using the G9 key here so arg can be changed to whatever button you want it to be set to. Scipt works great but i also want to add time too. Logitech Gaming Software F-key binding script. Drag and drop an existing command from the Sep 18, 2021 · choose keyboard key you don't currently use in the game (let's assume the F12 key is not currently used) go to the big mouse picture in LGS and assign command F12 to your physical MB#4; go to your game settings and set the game action to F12 instead of MB#4; As a result, when you press physical MB#4, the game receives F12 and activates the game May 29, 2020 · Is it possible to program logitech mouse with lua script to press 2 keys (J and K) when I press a mouse button? Mar 23, 2024 · Learn how to assign Logitech macros, edit scripts, and customize buttons on your Logitech mice and keyboards in this video. repeat. The subreddit dedicated to Logitech G-series hardware is r/LogitechG. Thanks 😀. Copy and Paste the code I provided. Click on Logitech G HUB and click Modify. answered Jun 30, 2021 at 6:55. In Windows Settings, open Apps & features. Issue is even if i release the key early the script will run for 5000 ms, looking for way to exit the script immediately if i release the mouse 1. random(314, 664)) until not IsMouseButtonPressed(5) end. When i press mouse button 4 multiple times fast with the above script in a game, i am not able to know which key will be pressed next after a Jun 21, 2022 · until not IsMouseButtonPressed(1) end. Mar 20, 2024 · How to Setup Logitech G-Hub Macros & LUA Scripts Tutorials - YouTube. Here's my attempt: Jul 9, 2020 · You can determine if a key is pressed only for the following keys: 1) modifier keys by calling IsModifierPressed (see Piglet's answer) and 2) G1,G2,G3,G4, keys by handling the G_PRESSED / G_RELEASED events. Step 1. if event == "MOUSE_BUTTON_PRESSED" and arg == 2 and IsModifierPressed("lshift") then. This is one of the scripts I have Sep 17, 2021 · 0. Please note that G5 mouse button must be bound to "Forward" action in GHUB interface. If you want to preserve the original action (pressing of F1 key) for G1 key, you need to create new macro (something like: press F1, wait, release F1) and assign it to G1 key. I would like to write a script that listens for when I press the F1 key and does some action. After trying the above mentioned, try recording the macro on G-HUB and see how it is. Such feature would make possible to write a keylogger script in Lua, and Logitech wants to prevent this to make script sharing safe. Nifim. Lua script loop keys press. NumLock does not generate GHub events (that means Lua script will not start doing smth because you pressed NumLock). built-in functions defined by the LUA language specs) can be used. Before exiting the game turn CapsLock OFF. PressAndReleaseKey("lshift") PressAndReleaseKey("9") end. Jun 3, 2020 · It's impossible to both simulate LMB press/release and determine if it's pressed or released. Configure your Logitech mouse software (Logitech GHUB) to run the Lua script. Please note that P without a modifier must be NOT assigned to any action in the game. M4_pressed = not M4_pressed. Change the name of the macro to whatever your macro is named in GHUB. Apr 9, 2021 · MoveMouseRelative(-4,0) Sleep(1) end. Both have failed. asked Apr 19, 2023 at 16:16. end. I now have easy access to every command I want, with the added benefit that the G13 also supports LUA scripting! What this means is that now I can do things like bind COMSTAB and G-SAFE each to individual keys. Unfortunately it doesn't look like that API provides any kind of timer function. This is the default setting, You probably have changed it manually. mb1_pressed = true. local safety = 0. The only way to use G-Shift on your mouse is to bind G-Shift to a mouse button. "") Lua is used by Logitech G-series hardware to provide advanced scripting functionality. Only the following keys could be a toggle-key: mouse buttons, Logitech keyboard G-keys, lock keys with LED (scrolllock, numlock, capslock). function OnEvent (event, arg) if event == "MOUSE_BUTTON_PRESSED" and arg == 9 then. In the new window, select Reinstall G HUB, then click REINSTALL. task_autoPress. I plan on writing a script that will trigger a series of mouse clicks, mouse movements and keyboard clicks. PlayMacro("DPI Down") if not IsModifierPressed("ctrl") then. I know a similar question had been post as: Lua handling mouse event . May 24, 2021 · Sleep(math. on = false. When i press mouse 1 script will press and hold "x" key for 5000 ms, wait 200 ms and repeat the cycle until i release the mouse 1 . Mar 30, 2024 · 1. Sep 25, 2022 · The fact is that this should work when the "Caps Lock" key is turned on and the "Right mouse button" + "Left button" is pressed at the same time. -- 3. Check our Logitech Warranty here. random (50, 90)) 1. Jan 15, 2021 · I'm trying to give me logitech mouse an order using lua script that when the primary key is pressed a key in the keyboard is also clicked until I stop holding the mouse button I tried this one but it works perfectly with all the mouse buttons but no actions happens when I set it up for the primary key. Functions in the script are not shown in the Jun 12, 2021 · I have a G513 which means i cannot simply remap most of the buttons. Set the script. Nov 23, 2015 · Can someone help me write a script to toggle Shift+W on a G-key for my Logitech keyboard? I found one for "W" but not "Shift+W", and don't understand the language necessary to add it. lua shows how you could simulate typing random alphanumeric string in Lua script. We apologize for any inconvenience that this may have caused and we thank you for your patience and understanding. How to make this Logitech Mouse LUA script work better? 0. function OnEvent(event, arg) if IsKeyLockOn("numlock" )then if IsMouseButtonPressed(3)then repeat if IsMouseButtonPressed(1) then repeat PressKey("a") Sleep(100) ReleaseKey("a") Sleep(2000) until not IsMouseButtonPressed(1) end until not IsMouseButtonPressed(3) end Dec 19, 2022 · Top Left Menu - Click Games & Applications. ReleaseKey(keys[idx]) tm = GetRunningTime() end. So, while you are inside OnEvent function, you can stop using Logitech mouse and work with non-Logitech mouse. Use indentation in the code to make it obvious. You may have problems trying to keep pressed 8 keys simultaneously. A quick and informative guide awa Sep 10, 2020 · Selection_Key removed, weapon now is selected by capslock-- capslock on = ak47 -- capslock off = m4a1 local Macro_Activation_Key = 4 -- mouse button for turning macro Aug 30, 2020 · Logitech Script, Press and hold key until releas. Oct 28, 2023 · Right click on a profile's icon and choose scripting. Turn CapsLock ON and generate an event (press Right Mouse Button on Logitech mouse or press any remapped G key on Logitech keyboard) to start the script. I have a script that i have linked to G1 key but i have other macros on M1 set and M2 set, I only want the scripts to activate if on M3 set. You can write scripts that listen for special keys on Logitech G hardware (such as the G Keys or the M Keys) using the scripting feature in Logitech G Hub. i was thinking of detecting a button press and then press another button with logitech lua but i cannot find an event for it. Lets say from like 50-100. Logitech Lua script. Apr 11, 2019 · 1. Or you can implement similar logic in a Lua script (mouse button action would depend on Shift, Alt, Ctrl keyboard keys or ScrollLock, NumLock, CapsLock keyboard LEDs). I have a lua script that lets me toggle between 'right mouse down' and 'right mouse release' with G4, and left mouse down/release with G5. But there is a workaround: you can add alternative button for the same action as LMB. Click on Customize Function Keys. EDIT: It actually doesn't need to replace CTRL, just look for when CRTL is held, then also hold DPI Shift. Oct 21, 2020 · 0. com/3GrbhXLDLua reference that tells you what commands/functions exist:https://douile. Search for Logitech G HUB. 2K views 1 month ago. Mar 2, 2021 · Hi I've been using the lua script (on Logitech G Hub) above in order to stop the macro as soon as I release the mouse button, but I don't wanna hold mouse button, instead I want to use the mouse button to toggle the macro. G keys are different on different keyboards, for example on my G413 they are F1-F12. Thanks to everyone who might help :) 2. Only mouse buttons (on Logitech mouse) and special G-keys (on Logitech keyboard) generate events. GitHub Gist: instantly share code, notes, and snippets. Click USE DEFAULTto reset the button to factory settings. How can I write simple Lua code for Logitech mouse? 0. Rapid fire with logitech lua script? 0. PressKey("x") Jun 30, 2021 · 0. Jul 5, 2014 · 1. The script should be active only after press-and-hold RMB, then press LMB. button_toggled = false. I tapped Mouse button 5 disabled 4 and enabled 5. digits. SDK FOR WINDOWS. edited Sep 11, 2020 at 6:21. To enable the button, click on it again and either drag an assignment back onto it or click USE DEFAULT. Goto GHUB (mouse device, assignments section) Unbind "Back" from MB#4 (if you have not done it already in Step 1) Step 3. You can not make LAlt a toggle key as it was with CapsLock. The script. and i want to set when capslock is off script use this: MoveMouseRelative(-2, 3) Sleep(10) MoveMouseRelative(2, -2) Sleep(10) and when capslock is on script use this: MoveMouseRelative(-10, 9) Dec 13, 2020 · Now when you press physical MB#4, the game sees F12 and activates your old action. " Arg: ". Qualily. PressAndReleaseKey("1") repeat. I don’t have a Logitech keyboard though. The subreddit dedicated to Logitech G-series hardware is r/LogitechG . local btn4. kriptaep. G HUB can also handle press/release events of special G-keys and M-keys on a Logitech keyboard (G-keys are Oct 31, 2020 · I have a Logtech G915 TKL keyboard, and it has programmable function keys. Please guide me through the script how to change to toggle on/off macro with mouse button. i want to implement this lua script which was posted by "Egor Skriptunoff" in a previous thread of mine into my logitech g512 keyboard. random(27, 78)) ReleaseMouseButton(1) Sleep(math. You’d want to look at what API Windows exposes for accessibility, and then find a Lua library that can talk to that API. 450 subscribers. 3. Double-click on the listed function key command assignment to begin assigning a new command. i want to set numlock to turn on and off script. function OnEvent(event, arg) OutputLogMessage("Event: ". Dec 29, 2021 · OutputLogMessage("RELEASED. until IsMouseButtonPressed(3) end. lua). (I use the ones by the thumb stick. ★LinksMy website: https://www. And I am struggling with Macro's and Lua Scripting. Looking at what other people have tried using macros to trigger DPI, I tried: function OnEvent(event, arg) if IsModifierPressed("ctrl") then. Feb 17, 2018 · G-keyboard LUA API: functions added to the Lua engine by Logitech. Create a script on the profile. @nektarios - You don't need Lua here. Accessibility APIs are the way to do GUI scripting or remote control of other apps. Thank you! Click on the icon for your gaming keyboard. edited Apr 20, 2023 at 2:14. The only possible way that I found is to do a LUA script that detects a key press on a G key, but now I want to send the scancode of the Calculator button, and it is, as stated in many manuals Nov 12, 2021 · This script increases DPI while Left Shift is down. of ow rk bo wn hk ab wg yi ni