Skip to content

Commit a7c58bd

Browse files
committed
adding binds, fixing code
1 parent 9b529f6 commit a7c58bd

File tree

6 files changed

+77
-6
lines changed

6 files changed

+77
-6
lines changed

g13.cc

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -627,18 +627,20 @@ g13_keypad::g13_keypad(libusb_device_handle *handle, int id) {
627627
uinput_file = -1;
628628
for(int i = 0; i < sizeof(keys); i++)
629629
keys[i] = false;
630+
for(int i = 0; i < G13_NUM_KEYS; i++)
631+
map[i] = KEY_A;
630632
/* map = { KEY_A, KEY_B, KEY_C, KEY_D, KEY_E, KEY_F, KEY_G, KEY_H,
631633
KEY_I, KEY_J, KEY_K, KEY_L, KEY_M, KEY_N, KEY_O, KEY_P,
632634
KEY_Q, KEY_R, KEY_S, KEY_T, KEY_U, KEY_V, 0, 0,
633635
KEY_W, KEY_X, KEY_Y, KEY_Z, KEY_1, KEY_2, KEY_3, KEY_4,
634636
KEY_5, KEY_6, KEY_7, KEY_8, KEY_9, KEY_F1, KEY_F2 };*/
635637
// starcraft 2
636-
map = { KEY_5, KEY_3, KEY_1, KEY_0, KEY_2, KEY_4, KEY_6,
637-
KEY_V, KEY_F, KEY_E, KEY_C, KEY_B, KEY_G, KEY_I,
638-
KEY_LEFTSHIFT, KEY_M, KEY_T, KEY_L, KEY_H,
639-
KEY_A, KEY_S, KEY_LEFTCTRL, 0, 0,
640-
KEY_F1, KEY_N, KEY_R, KEY_P, KEY_K, KEY_D, KEY_X, KEY_Y,
641-
KEY_Z, KEY_TAB, KEY_W, KEY_BACKSPACE, 0, 0, 0, 0};
638+
// map = { KEY_5, KEY_3, KEY_1, KEY_0, KEY_2, KEY_4, KEY_6,
639+
// KEY_V, KEY_F, KEY_E, KEY_C, KEY_B, KEY_G, KEY_I,
640+
// KEY_LEFTSHIFT, KEY_M, KEY_T, KEY_L, KEY_H,
641+
// KEY_A, KEY_S, KEY_LEFTCTRL, 0, 0,
642+
// KEY_F1, KEY_N, KEY_R, KEY_P, KEY_K, KEY_D, KEY_X, KEY_Y,
643+
// KEY_Z, KEY_TAB, KEY_W, KEY_BACKSPACE, 0, 0, 0, 0};
642644
}
643645

644646
void g13_keypad::command(char const *str) {

hon.bind

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
bind G12 KEY_U
2+
bind G11 KEY_E
3+
bind G10 KEY_O
4+
5+
6+
bind G9 KEY_A
7+
bind G13 KEY_H

spring.bind

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
bind G15 KEY_LEFTSHIFT
2+
bind STICK_LEFT KEY_LEFT
3+
bind STICK_RIGHT KEY_RIGHT
4+
bind STICK_UP KEY_UP
5+
bind STICK_DOWN KEY_DOWN

starcraft.lpbm

960 Bytes
Binary file not shown.

starcraft2.bind

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
bind G1 KEY_7
2+
bind G2 KEY_5
3+
bind G3 KEY_3
4+
bind G4 KEY_1
5+
bind G5 KEY_2
6+
bind G6 KEY_4
7+
bind G7 KEY_6
8+
bind G8 KEY_V
9+
bind G9 KEY_F
10+
bind G10 KEY_E
11+
bind G11 KEY_C
12+
bind G12 KEY_B
13+
bind G13 KEY_G
14+
bind G14 KEY_I
15+
bind G15 KEY_LEFTSHIFT
16+
bind G16 KEY_M
17+
bind G17 KEY_T
18+
bind G18 KEY_L
19+
bind G19 KEY_H
20+
bind G20 KEY_A
21+
bind G21 KEY_S
22+
bind G22 KEY_LEFTCTRL
23+
bind BD KEY_F1
24+
bind L1 KEY_N
25+
bind L2 KEY_R
26+
bind L3 KEY_P
27+
bind L4 KEY_K
28+
bind M1 KEY_D
29+
bind M2 KEY_X
30+
bind M3 KEY_Y
31+
bind MR KEY_Z
32+
bind LEFT KEY_TAB
33+
bind DOWN KEY_W
34+
bind TOP KEY_BACKSPACE
35+
bind STICK_LEFT KEY_LEFT
36+
bind STICK_RIGHT KEY_RIGHT
37+
bind STICK_UP KEY_UP
38+
bind STICK_DOWN KEY_DOWN

war.bind

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
bind G1 KEY_1
2+
bind G2 KEY_2
3+
bind G3 KEY_3
4+
bind G4 KEY_W # walk forward
5+
bind G5 KEY_4
6+
bind G6 KEY_5
7+
bind G7 KEY_6
8+
bind G10 KEY_Q
9+
bind G11 KEY_S
10+
bind G12 KEY_E
11+
bind G15 KEY_SPACE
12+
bind G20 KEY_M # map
13+
bind G21 KEY_F1 # target self
14+
bind G22 KEY_LEFTALT
15+
bind G19 KEY_F3
16+
bind STICK_LEFT KEY_A
17+
bind STICK_RIGHT KEY_D
18+
bind STICK_UP KEY_W
19+
bind STICK_DOWN KEY_S

0 commit comments

Comments
 (0)