- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
How to: shift + G1 script?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 05:06 PM
Hello.
G15, older version.
I'm wondering if, and how, I would write a script that would allow me to use the shift key to make a G key execute another key press.
G1 executes the key press shift 1.
Can I make a script that would allow me to press shift G1 and have it execut the keypress ctrl 1.
Basically, I have the G keys assigned for shift 1-6, M2 is ctrl 1-6, and M3 is alt 1-6, but I don't want to have to actually hit the M1-3 tabs to chane the G key function.
I don't know how to write a script, and I'm hoping a kind soul here would be able to show me what the script would be so that I can leave the keyboard on M1, but get my Shift, ctrl, and alt presses from the G1-6 keys without switching the use of the M1-3 tabs.
Is a script to do this posible?
Would anyone be willing to show me how this script should be written?
Did I epxlain this clearly enough?
Re: How to: shift + G1 script?
[ Edited ]- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 05:56 PM - edited 03-04-2012 06:18 PM
It's as simple as using the function IsModifierPressed("ctrl")
example:
function OnEvent(event, arg, family)
if event == "G_PRESSED" and arg == 1 and family == "lhc" and IsModifierPressed("shift") then
-- do your code here
end
end
