Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

To activate a function by simultaneously pressing the right and left buttons using LUA with Logitech Gaming Software, you can follow these steps:

  1. Open Logitech Gaming Software and click on the gear icon on the top right corner to open the settings.

  2. Click on the 'Scripting' tab and select the profile you want to edit.

  3. In the Lua script editor, create a function that will be called when both right and left buttons are pressed simultaneously. For example:

function OnComboPress() -- code here end

  1. Use the 'OnEvent' function to detect when both buttons are pressed. For example:

function OnEvent(event, arg) if event == "MOUSEBUTTONPRESSED" and arg == 1 then pressedleft = true elseif event == "MOUSEBUTTONPRESSED" and arg == 2 then pressedright = true elseif event == "MOUSEBUTTONRELEASED" and arg == 1 then pressedleft = false elseif event == "MOUSEBUTTONRELEASED" and arg == 2 then pressedright = false end

if pressedleft and pressedright then OnComboPress() end end

  1. Save your Lua script and assign it to your desired button in your Logitech Gaming Software profile.

  2. Test the function by simultaneously pressing the right and left buttons on your mouse. The 'OnComboPress' function should be executed.