2

I'm trying the examples in private.xml. I want to do this: When I press control + W, I want it to automatically hold W (until I press control + W again).

And when I do control +left click, I want it to hold left click until I put in the command again. Anyone know how to do this?

yimmy
  • 436
  • 6
  • 13

1 Answers1

-1
{
     "type": "basic",
     "from": {
         "key_code": "w",
         "modifiers": {
             "optional": [
                 "control"
             ]
         }
     },

     "to": [
         {
             "key_code": "w",
             "modifiers": [
             "left_control"
             ]
         },
         {
             "set_variable": {
                 "name": "control_w pressed",
                 "value": 0
             }
         }
     ],
     "conditions": [
         {
             "type": "variable_if",
             "name": "control_w pressed",
             "value": 1
         }
     ]

 },
 {
       "type": "basic",
       "from": {
           "key_code": "w",
           "modifiers": {
               "optional": [
                   "control"
               ]
           }
       },
       "to": [
           {
               "key_code": "w",
               "modifiers": [
               "left_control"
               ]
           }
       ],
       "conditions": [
           {
               "type": "variable_if",
               "name": "control_w pressed",
               "value": 1
           }
       ]
   },


   {
       "type": "basic",
       "from": {
           "key_code": "w",
           "modifiers": {
               "optional": [
                   "control"
               ]
           }
       },

       "to": [
           {
               "key_code": "w",
               "modifiers": [
               "left_control"
               ]
           }
       ],
       "to_if_alone": [
           {
               "set_variable": {
                   "name": "control_w pressed",
                   "value": 1
               }
           }
       ]
   } 
Samuel Liew
  • 76,741
  • 107
  • 159
  • 260