Logitech Script Help

Posts 12 of 2 · Page 1 of 1
Logitech Script Help
Hi,
What Im trying to do :
1) When I press Mouse Button 5 I need it to do this : Insert Left Arrow Left Arrow Insert.
2) When I press Mouse button 5 + Shift I need it to do : Insert Right Arrow Right Arrow Insert.

What I have so far is :

Code:
function OnEvent(event, arg)
if (event == "MOUSE_BUTTON_PRESSED" and arg == 5) then
IsMouseButtonPressed(5)
PlayMacro("head")
end
end
 
if IsModifierPressed("shift" )then
IsMouseButtonPressed(5)
PlayMacro("body")
end
The "Head" Macro is Working but for some reason the "Body" macro is not !

Anybody can help me out ?
Quote Originally Posted by navysonar View Post
Hi,
What Im trying to do :
1) When I press Mouse Button 5 I need it to do this : Insert Left Arrow Left Arrow Insert.
2) When I press Mouse button 5 + Shift I need it to do : Insert Right Arrow Right Arrow Insert.

What I have so far is :

Code:
function OnEvent(event, arg)
if (event == "MOUSE_BUTTON_PRESSED" and arg == 5) then
IsMouseButtonPressed(5)
PlayMacro("head")
end
end
 
if IsModifierPressed("shift" )then
IsMouseButtonPressed(5)
PlayMacro("body")
end
The "Head" Macro is Working but for some reason the "Body" macro is not !

Anybody can help me out ?
You could try something like this:

function OnEvent(event, arg)
if (event == "MOUSE_BUTTON_PRESSED" and arg == 5) then
IsMouseButtonPressed(5)
PlayMacro("head")
end
end

if(or "elseif" try both) (event == "MOUSE_BUTTON_PRESSED" and arg == 5) and IsModifierPressed("lshift" )then
IsMouseButtonPressed(5)
PlayMacro("body")
end

Can i ask what are you using it for?
Posts 12 of 2 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?