-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path8BitDo_M30.css
More file actions
183 lines (168 loc) · 3.62 KB
/
8BitDo_M30.css
File metadata and controls
183 lines (168 loc) · 3.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
/*
8BitDo M30 Gamepad Viewer skin by Animach1ne twitch.tv/animach1ne
With the help of BenInSweden https://www.twitch.tv/beninsweden
*/
/* Base 8BitDo M30 */
.controller.custom{
background: url(https://i.imgur.com/2AybQDC.png);
width: 1500px;
height: 759px;
}
.custom.disconnected { /* This class shows an image when the controller is disconnected */
background: url(https://i.imgur.com/7BJl8PS.png);
}
/* Bumpers */
.custom .bumper{
background: url(https://i.imgur.com/MG38Oac.png);
width: 345px;
height: 63px;
opacity: 0;
}
.custom .bumpers{
position: absolute;
width: 1111px;
height: 63px;
left: 194px;
top: 4px;
}
.custom .bumper.pressed{ /* The '.pressed' class is used for most buttons to signify they've been pressed */
opacity: 1;
}
.custom .bumper.left{
float: left;
}
.custom .bumper.right{
-webkit-transform: rotateY(180deg);
float: right;
}
/* Dpad */
.custom .dpad{
position: absolute;
width: 278px;
height: 280px;
top: 201px;
left: 228px;
}
.custom .face{
position: absolute;
background: url(https://i.imgur.com/vo7Eo6l.png);
width: 71px;
height: 138px;
opacity: 0;
}
.custom .face.up{
top: 0px;
left: 104px;
}
.custom .face.down{
-webkit-transform: rotateX(180deg);
top: 142px;
left: 104px;
}
.custom .face.left{
transform-origin: bottom center;
-webkit-transform: rotate(270deg);
top: 2px;
left: 101px; /* Roughly equal to width + width/2 + empty space between left an right */
}
.custom .face.right{
transform-origin: bottom center;
-webkit-transform: rotate(90deg);
top: 3px;
left: 106px; /* Roughly equal to width + width/2 + empty space between left an right */
}
.custom .face.pressed{
opacity: 1;
}
/* Back & Start */
.custom .back{
position: absolute;
background: url(https://i.imgur.com/nLKbles.png);
width: 63px;
height: 63px;
top: 462px;
left: 708px;
opacity: 0;
}
.custom .back.pressed{
opacity: 1;
}
.custom .start{
position: absolute;
background: url(https://i.imgur.com/LLnB0nF.png);
width: 119px;
height: 38px;
top: 323px;
left: 680px;
opacity: 0;
}
.custom .start.pressed{
opacity: 1;
}
/* AB */
.custom .button{
position: absolute;
opacity: 0;
}
.custom .button.a.pressed{
background: url(https://i.imgur.com/JlhU5T1.png);
width: 118px;
height: 118px;
top: 411px;
left: 945px;
opacity: 1;
}
.custom .button.b.pressed{
background: url(https://i.imgur.com/yHpjHQu.png);
width: 118px;
height: 118px;
top: 333px;
left: 1084px;
opacity: 1;
}
/* XY */
.custom .button.x.pressed{
background: url(https://i.imgur.com/In52dsg.png);
width: 93px;
height: 93px;
top: 264px;
left: 909px;
opacity: 1;
}
.custom .button.y.pressed{
background: url(https://i.imgur.com/m9hyZuI.png);
width: 93px;
height: 93px;
top: 201px;
left: 1039px;
opacity: 1;
}
/* CZ - Tricking Gamepadviewer to think they're triggers */
.custom .triggers{
width: 184px;
height: 255px;
top: 162px;
left: 1172px;
position: absolute;
}
.custom .trigger{
position: absolute;
opacity: 0;
}
.custom .trigger-button.left.pressed{ /* Actually Z */
background: url(https://i.imgur.com/99m0J1O.png);
width: 93px;
height: 93px;
opacity: 1;
position: absolute;
}
.custom .trigger-button.right.pressed{ /* Actually C */
background: url(https://i.imgur.com/cL4NwyI.png);
width: 118px;
height: 118px;
bottom: 9px;
right: 0;
opacity: 1;
position: absolute;
}
/*END 8bitDo M30 Controller Styling*/