@overwolf/ow-electron-packages-types 0.0.11 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/game-list.ts +80 -52
- package/gep-supported-games.ts +8 -8
- package/overlay.d.ts +325 -332
- package/package.json +23 -23
package/game-list.ts
CHANGED
|
@@ -1,52 +1,80 @@
|
|
|
1
|
-
// game list version:
|
|
2
|
-
|
|
3
|
-
export const enum kLaunchersIds {
|
|
4
|
-
LOLLauncher = 10902,
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
export const enum kGameIds {
|
|
8
|
-
AmericanTruckSimulator = 10874,
|
|
9
|
-
ApexLegends = 21566,
|
|
10
|
-
ARKSurvivalAscended = 23476,
|
|
11
|
-
ARKSurvivalEvolved = 10778,
|
|
12
|
-
BaldursGateIII = 22088,
|
|
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
|
-
|
|
1
|
+
// game list version: 10
|
|
2
|
+
|
|
3
|
+
export const enum kLaunchersIds {
|
|
4
|
+
LOLLauncher = 10902,
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export const enum kGameIds {
|
|
8
|
+
AmericanTruckSimulator = 10874,
|
|
9
|
+
ApexLegends = 21566,
|
|
10
|
+
ARKSurvivalAscended = 23476,
|
|
11
|
+
ARKSurvivalEvolved = 10778,
|
|
12
|
+
BaldursGateIII = 22088,
|
|
13
|
+
BlackMythWukong = 24504,
|
|
14
|
+
CallofDutyModernWarfareII = 22328,
|
|
15
|
+
CallOfDutyModernWarfareIII = 23424,
|
|
16
|
+
CallofDutyVanguard = 21876,
|
|
17
|
+
ContentWarning = 24110,
|
|
18
|
+
CS2 = 22730,
|
|
19
|
+
DarkandDarker = 22584,
|
|
20
|
+
Deadlock = 24482,
|
|
21
|
+
Diablo2Resurrected = 21848,
|
|
22
|
+
DiabloIV = 22700,
|
|
23
|
+
Dota2 = 7314,
|
|
24
|
+
ELDENRING = 21866,
|
|
25
|
+
Enshrouded = 23946,
|
|
26
|
+
EscapeFromTarkov = 21634,
|
|
27
|
+
EternalReturnBlackSurvival = 21672,
|
|
28
|
+
EuroTruckSim2 = 8584,
|
|
29
|
+
FinalFantasyXIVOnline = 6350,
|
|
30
|
+
Fortnite = 21216,
|
|
31
|
+
GenshinImpact = 21656,
|
|
32
|
+
GTAV = 1076,
|
|
33
|
+
HadesII = 24218,
|
|
34
|
+
HaloInfinite = 21854,
|
|
35
|
+
HearthstoneHeroesofWarcraft = 9898,
|
|
36
|
+
HELLDIVERS2 = 24000,
|
|
37
|
+
HeroesoftheStorm = 10624,
|
|
38
|
+
HonkaiStarRail = 22804,
|
|
39
|
+
LeagueofLegends = 5426,
|
|
40
|
+
LeagueofLegendsPBE = 22848,
|
|
41
|
+
LegendsofRuneterra = 21620,
|
|
42
|
+
LethalCompany = 23522,
|
|
43
|
+
LostArk = 21864,
|
|
44
|
+
MagictheGatheringArena = 21308,
|
|
45
|
+
ManorLords = 24176,
|
|
46
|
+
Minecraft = 8032,
|
|
47
|
+
MinecraftBedrock = 22176,
|
|
48
|
+
NewWorld = 21816,
|
|
49
|
+
OnceHuman = 23930,
|
|
50
|
+
Osu = 3683,
|
|
51
|
+
Overwatch = 10844,
|
|
52
|
+
Palworld = 23944,
|
|
53
|
+
PathofExile = 7212,
|
|
54
|
+
PUBG = 10906,
|
|
55
|
+
Rainbow6Siege = 10826,
|
|
56
|
+
Roblox = 4688,
|
|
57
|
+
RocketLeague = 10798,
|
|
58
|
+
Rust = 10156,
|
|
59
|
+
SonsoftheForest = 22638,
|
|
60
|
+
SpectreDivide = 24484,
|
|
61
|
+
SplitgateArenaWarfare = 21404,
|
|
62
|
+
StarCraftII = 5855,
|
|
63
|
+
Starfield = 23222,
|
|
64
|
+
Stormgate = 23818,
|
|
65
|
+
TeamfightTactics = 21570,
|
|
66
|
+
TheFinals = 23478,
|
|
67
|
+
TheFirstDescendant = 24360,
|
|
68
|
+
TheSims4 = 10540,
|
|
69
|
+
Valheim = 21668,
|
|
70
|
+
VALORANT = 21640,
|
|
71
|
+
Warframe = 8954,
|
|
72
|
+
Warhammer40000SpaceMarine2 = 24548,
|
|
73
|
+
WorldOfTanks = 6365,
|
|
74
|
+
WorldofWarships = 10746,
|
|
75
|
+
WoW = 765,
|
|
76
|
+
WoWClassic = 21630,
|
|
77
|
+
WutheringWaves = 24300,
|
|
78
|
+
XDefiant = 22994,
|
|
79
|
+
}
|
|
80
|
+
|
package/gep-supported-games.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export const enum kGepSupportedGameIds {
|
|
2
|
-
TeamfightTactics = 21570,
|
|
3
|
-
RocketLeague = 10798,
|
|
4
|
-
LeagueofLegends = 5426,
|
|
5
|
-
LeagueofLegendsPBE = 22848,
|
|
6
|
-
WoW = 765,
|
|
7
|
-
FinalFantasyXIVOnline = 6350,
|
|
8
|
-
}
|
|
1
|
+
export const enum kGepSupportedGameIds {
|
|
2
|
+
TeamfightTactics = 21570,
|
|
3
|
+
RocketLeague = 10798,
|
|
4
|
+
LeagueofLegends = 5426,
|
|
5
|
+
LeagueofLegendsPBE = 22848,
|
|
6
|
+
WoW = 765,
|
|
7
|
+
FinalFantasyXIVOnline = 6350,
|
|
8
|
+
}
|
package/overlay.d.ts
CHANGED
|
@@ -1,332 +1,325 @@
|
|
|
1
|
-
import {
|
|
2
|
-
BrowserWindow,
|
|
3
|
-
BrowserWindowConstructorOptions,
|
|
4
|
-
Size,
|
|
5
|
-
WebContents,
|
|
6
|
-
} from 'electron';
|
|
7
|
-
import { EventEmitter } from 'events';
|
|
8
|
-
|
|
9
|
-
export declare type GameProcessInfo = {
|
|
10
|
-
pid?: number;
|
|
11
|
-
|
|
12
|
-
fullPath: string;
|
|
13
|
-
|
|
14
|
-
commandLine?: string;
|
|
15
|
-
|
|
16
|
-
is32Bit?: boolean;
|
|
17
|
-
|
|
18
|
-
isElevated?: boolean;
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
export declare type GameInfo = {
|
|
22
|
-
id: number;
|
|
23
|
-
|
|
24
|
-
classId: number;
|
|
25
|
-
|
|
26
|
-
name: string;
|
|
27
|
-
|
|
28
|
-
supported: boolean;
|
|
29
|
-
|
|
30
|
-
processInfo?: GameProcessInfo;
|
|
31
|
-
|
|
32
|
-
flags?: any;
|
|
33
|
-
|
|
34
|
-
type: 'Game' | 'Launcher';
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export interface GamesFilter {
|
|
38
|
-
all?: boolean;
|
|
39
|
-
|
|
40
|
-
includeUnsupported?: boolean;
|
|
41
|
-
|
|
42
|
-
gamesIds: number[];
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* Input pass through
|
|
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
|
-
name: string;
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
export interface
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
export interface
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
export
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
export
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
*
|
|
158
|
-
* Use `0` to disable
|
|
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
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
/**
|
|
198
|
-
*
|
|
199
|
-
*/
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
*
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
*
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
*
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
*
|
|
248
|
-
*
|
|
249
|
-
*
|
|
250
|
-
*/
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
/**
|
|
254
|
-
*
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
* Only relevant to `mixed mode when available` and/or `exclusive only` games
|
|
327
|
-
*/
|
|
328
|
-
on(
|
|
329
|
-
eventName: 'game-input-exclusive-mode-changed',
|
|
330
|
-
listener: (info: GameInputInterception) => void
|
|
331
|
-
): this;
|
|
332
|
-
}
|
|
1
|
+
import {
|
|
2
|
+
BrowserWindow,
|
|
3
|
+
BrowserWindowConstructorOptions,
|
|
4
|
+
Size,
|
|
5
|
+
WebContents,
|
|
6
|
+
} from 'electron';
|
|
7
|
+
import { EventEmitter } from 'events';
|
|
8
|
+
|
|
9
|
+
export declare type GameProcessInfo = {
|
|
10
|
+
pid?: number;
|
|
11
|
+
|
|
12
|
+
fullPath: string;
|
|
13
|
+
|
|
14
|
+
commandLine?: string;
|
|
15
|
+
|
|
16
|
+
is32Bit?: boolean;
|
|
17
|
+
|
|
18
|
+
isElevated?: boolean;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export declare type GameInfo = {
|
|
22
|
+
id: number;
|
|
23
|
+
|
|
24
|
+
classId: number;
|
|
25
|
+
|
|
26
|
+
name: string;
|
|
27
|
+
|
|
28
|
+
supported: boolean;
|
|
29
|
+
|
|
30
|
+
processInfo?: GameProcessInfo;
|
|
31
|
+
|
|
32
|
+
flags?: any;
|
|
33
|
+
|
|
34
|
+
type: 'Game' | 'Launcher';
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export interface GamesFilter {
|
|
38
|
+
all?: boolean;
|
|
39
|
+
|
|
40
|
+
includeUnsupported?: boolean;
|
|
41
|
+
|
|
42
|
+
gamesIds: number[];
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Input pass through
|
|
47
|
+
* 'noPassThrough': Window will handle input and block from game (Default)
|
|
48
|
+
* 'passThrough': window will not handle any input
|
|
49
|
+
* 'passThroughAndNotify': Window will handle input and also pass it to the game.
|
|
50
|
+
*/
|
|
51
|
+
export type PassthroughType = "noPassThrough" | "passThrough" | "passThroughAndNotify";
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Overlay rendering Z-Order
|
|
55
|
+
*/
|
|
56
|
+
export type ZOrderType = "default" | "topMost" | "bottomMost";
|
|
57
|
+
|
|
58
|
+
/** Overlay ow-electron options */
|
|
59
|
+
export interface OverlayOptions {
|
|
60
|
+
passthrough?: PassthroughType | number;
|
|
61
|
+
|
|
62
|
+
zOrder?: ZOrderType | number; // backwards compatible
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface OverlayWindowOptions
|
|
66
|
+
extends BrowserWindowConstructorOptions,
|
|
67
|
+
OverlayOptions {
|
|
68
|
+
/**
|
|
69
|
+
* unique name (id)
|
|
70
|
+
*/
|
|
71
|
+
name: string;
|
|
72
|
+
|
|
73
|
+
/** not supported yet */
|
|
74
|
+
enableHWAcceleration?: boolean;
|
|
75
|
+
|
|
76
|
+
/** */
|
|
77
|
+
enableIsolation?:boolean;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export interface IOverlayHotkey {
|
|
81
|
+
name: string;
|
|
82
|
+
keyCode: number;
|
|
83
|
+
modifiers?: {
|
|
84
|
+
alt?: boolean;
|
|
85
|
+
ctrl?: boolean;
|
|
86
|
+
shift?: boolean;
|
|
87
|
+
custom?: number; // custom modifier (i.e key code)
|
|
88
|
+
meta?: boolean;
|
|
89
|
+
};
|
|
90
|
+
passthrough?: boolean;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export interface GameLaunchEvent {
|
|
94
|
+
inject: () => void;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* TBD
|
|
99
|
+
*/
|
|
100
|
+
export interface OverlayBrowserWindow {
|
|
101
|
+
window: BrowserWindow;
|
|
102
|
+
|
|
103
|
+
readonly overlayOptions: OverlayOptions;
|
|
104
|
+
|
|
105
|
+
readonly name: string;
|
|
106
|
+
|
|
107
|
+
readonly id: number;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export interface InjectionError {
|
|
111
|
+
error: string;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export interface GameWindowInfo {
|
|
115
|
+
size: Size;
|
|
116
|
+
nativeHandle: number;
|
|
117
|
+
focused: boolean;
|
|
118
|
+
graphics: 'd3d9' | 'd3d12' | 'd3d11' | string | undefined;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export interface GameInputInterception {
|
|
122
|
+
/**
|
|
123
|
+
* Can the Overlay window process input
|
|
124
|
+
* Related to `mixed mode when available` and/or `exclusive only` games
|
|
125
|
+
*/
|
|
126
|
+
readonly canInterceptInput?: boolean;
|
|
127
|
+
/**
|
|
128
|
+
* Overlay has full input control, blocking input from the game
|
|
129
|
+
*/
|
|
130
|
+
readonly exclusiveMode?: boolean;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export interface ActiveGameInfo {
|
|
134
|
+
readonly gameInfo: GameInfo;
|
|
135
|
+
readonly gameWindowInfo: GameWindowInfo;
|
|
136
|
+
readonly gameInputInfo: GameInputInterception;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export declare type GameWindowUpdateReason = undefined | 'resized' | 'focus';
|
|
140
|
+
export declare type HotkeyState = 'pressed' | 'released';
|
|
141
|
+
|
|
142
|
+
export declare type HotkeyCallback = (
|
|
143
|
+
hotKey: IOverlayHotkey,
|
|
144
|
+
state: HotkeyState
|
|
145
|
+
) => void;
|
|
146
|
+
|
|
147
|
+
export interface ExclusiveInputOptions {
|
|
148
|
+
/**
|
|
149
|
+
* Exclusive mode FadeIn / FadeOut duration in miliseconds.
|
|
150
|
+
*
|
|
151
|
+
* Use `0` to disable.
|
|
152
|
+
* @default 100
|
|
153
|
+
*/
|
|
154
|
+
fadeAnimateInterval?: number;
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* Exclusive mode overlay background color.
|
|
158
|
+
* Use `rgba(0,0,0,0)` to disable background color
|
|
159
|
+
*
|
|
160
|
+
* Note: Using an invalid color format (e.g: not `rgba(...)`) will throw an Error.
|
|
161
|
+
* @default 'rgba(12, 12, 12, , 0.5)'
|
|
162
|
+
*/
|
|
163
|
+
backgroundColor?: string;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export interface IOverlayHotkeys {
|
|
167
|
+
/**
|
|
168
|
+
* Register new hotkey.
|
|
169
|
+
* Throw error when hotkey already exits, or callback is missing
|
|
170
|
+
*/
|
|
171
|
+
register(hotKey: IOverlayHotkey, callback: HotkeyCallback): void;
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* Update existing hotkey.
|
|
175
|
+
* Return false if hotkey doesn't exits
|
|
176
|
+
*/
|
|
177
|
+
update(hotKey: IOverlayHotkey): boolean;
|
|
178
|
+
|
|
179
|
+
/**
|
|
180
|
+
* Clear all hotkeys
|
|
181
|
+
*/
|
|
182
|
+
unregisterAll(): void;
|
|
183
|
+
|
|
184
|
+
/**
|
|
185
|
+
* Remove hotkey by name.
|
|
186
|
+
* Return false if doesn't exits.
|
|
187
|
+
*/
|
|
188
|
+
unregister(name: string): boolean;
|
|
189
|
+
|
|
190
|
+
/**
|
|
191
|
+
* Get all active hotkeys.
|
|
192
|
+
*/
|
|
193
|
+
all(): IOverlayHotkey[];
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export interface IOverwolfOverlayApi extends EventEmitter {
|
|
197
|
+
/**
|
|
198
|
+
* Create new Overlay window
|
|
199
|
+
*/
|
|
200
|
+
createWindow(options: OverlayWindowOptions): Promise<OverlayBrowserWindow>;
|
|
201
|
+
|
|
202
|
+
/**
|
|
203
|
+
* Game launch registration
|
|
204
|
+
*/
|
|
205
|
+
registerGames(filter: GamesFilter);
|
|
206
|
+
|
|
207
|
+
/**
|
|
208
|
+
* injected Game inforamation
|
|
209
|
+
*/
|
|
210
|
+
getActiveGameInfo(): ActiveGameInfo | undefined;
|
|
211
|
+
|
|
212
|
+
/**
|
|
213
|
+
* Get all open overlay windows
|
|
214
|
+
*/
|
|
215
|
+
getAllWindows(): OverlayBrowserWindow[];
|
|
216
|
+
|
|
217
|
+
/**
|
|
218
|
+
* The overlay window that owns the given `webContents` or `null` if the contents are not
|
|
219
|
+
* owned by a window.
|
|
220
|
+
*/
|
|
221
|
+
fromWebContents(webContents: WebContents): OverlayBrowserWindow | null;
|
|
222
|
+
|
|
223
|
+
/**
|
|
224
|
+
* The overlay window that owns the given `BrowserWindow` or `null` if the browerWindow are not
|
|
225
|
+
* owned by a window.
|
|
226
|
+
*/
|
|
227
|
+
fromBrowserWindow(browserWindow: BrowserWindow): OverlayBrowserWindow | null;
|
|
228
|
+
|
|
229
|
+
/**
|
|
230
|
+
* Overlay hotkeys api
|
|
231
|
+
*/
|
|
232
|
+
hotkeys: IOverlayHotkeys;
|
|
233
|
+
|
|
234
|
+
/**
|
|
235
|
+
* Enters Overlay "Exclusive Mode" - meaning, the game no longer receives user
|
|
236
|
+
* input (all input will go to the overlay windows).
|
|
237
|
+
*
|
|
238
|
+
* The `game-input-exclusive-mode-changed` event fires if exclusive mode was entered.
|
|
239
|
+
*
|
|
240
|
+
* NOTE: This is only supported when getActiveGameInfo returns
|
|
241
|
+
* `"canInterceptInput" == false`. Calling this function when unsupported will
|
|
242
|
+
* be ignored and will not throw an exception.
|
|
243
|
+
*/
|
|
244
|
+
enterExclusiveMode(options?: ExclusiveInputOptions): void;
|
|
245
|
+
|
|
246
|
+
/**
|
|
247
|
+
* Exits Overlay Exclusive Mode, returning input control to the game.
|
|
248
|
+
*
|
|
249
|
+
* The `game-input-exclusive-mode-changed` event fires when exiting exclusive mode.
|
|
250
|
+
*/
|
|
251
|
+
exitExclusiveMode(): void;
|
|
252
|
+
|
|
253
|
+
/**
|
|
254
|
+
*TODO(bFox) :replace ...args
|
|
255
|
+
*/
|
|
256
|
+
on(eventName: 'error', listener: (...args: any[]) => void): this;
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
* Fired when registered game is detected
|
|
260
|
+
* call `event.inject()` to enable overlay for the game.
|
|
261
|
+
*/
|
|
262
|
+
on(
|
|
263
|
+
eventName: 'game-launched',
|
|
264
|
+
listener: (event: GameLaunchEvent, gameInfo: GameInfo) => void
|
|
265
|
+
): this;
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* Fired on registered game process terminated.
|
|
269
|
+
*/
|
|
270
|
+
on(
|
|
271
|
+
eventName: 'game-exit',
|
|
272
|
+
listener: (gameInfo: GameInfo, wasInjected: boolean) => void
|
|
273
|
+
): this;
|
|
274
|
+
|
|
275
|
+
/**
|
|
276
|
+
* Fired when overlay is ready for game.
|
|
277
|
+
*
|
|
278
|
+
*/
|
|
279
|
+
on(eventName: 'game-injected', listener: (gameInfo: GameInfo) => void): this;
|
|
280
|
+
|
|
281
|
+
/**
|
|
282
|
+
* TODO(bFox) :replace ...args
|
|
283
|
+
*/
|
|
284
|
+
on(
|
|
285
|
+
eventName: 'game-injection-error',
|
|
286
|
+
listener: (gameInfo: GameInfo, error: string, ...args: any[]) => void
|
|
287
|
+
): this;
|
|
288
|
+
|
|
289
|
+
/** */
|
|
290
|
+
on(
|
|
291
|
+
eventName: 'game-focus-changed',
|
|
292
|
+
listener: (
|
|
293
|
+
window: GameWindowInfo,
|
|
294
|
+
gameInfo: GameInfo,
|
|
295
|
+
focus: boolean
|
|
296
|
+
) => void
|
|
297
|
+
): this;
|
|
298
|
+
|
|
299
|
+
/** */
|
|
300
|
+
on(
|
|
301
|
+
eventName: 'game-window-changed',
|
|
302
|
+
listener: (
|
|
303
|
+
window: GameWindowInfo,
|
|
304
|
+
gameInfo: GameInfo,
|
|
305
|
+
reason?: GameWindowUpdateReason
|
|
306
|
+
) => void
|
|
307
|
+
): this;
|
|
308
|
+
|
|
309
|
+
/**
|
|
310
|
+
* Fires when the game input interception state changes
|
|
311
|
+
*/
|
|
312
|
+
on(
|
|
313
|
+
eventName: 'game-input-interception-changed',
|
|
314
|
+
listener: (info: GameInputInterception) => void
|
|
315
|
+
): this;
|
|
316
|
+
|
|
317
|
+
/**
|
|
318
|
+
* Fires when Overlay input Exclusive Mode changes.
|
|
319
|
+
* Only relevant to `mixed mode when available` and/or `exclusive only` games
|
|
320
|
+
*/
|
|
321
|
+
on(
|
|
322
|
+
eventName: 'game-input-exclusive-mode-changed',
|
|
323
|
+
listener: (info: GameInputInterception) => void
|
|
324
|
+
): this;
|
|
325
|
+
}
|
package/package.json
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@overwolf/ow-electron-packages-types",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"description": "Type definition file for autocompletion and documentation purposes for ow-electron packages",
|
|
5
|
-
"license": "MIT",
|
|
6
|
-
"types": "overlay.d.ts",
|
|
7
|
-
"keywords": [
|
|
8
|
-
"types",
|
|
9
|
-
"npm",
|
|
10
|
-
"package",
|
|
11
|
-
"overwolf",
|
|
12
|
-
"ow-electron",
|
|
13
|
-
"overlay",
|
|
14
|
-
"game-list"
|
|
15
|
-
],
|
|
16
|
-
"devDependencies": {
|
|
17
|
-
"@overwolf/ow-electron": "
|
|
18
|
-
},
|
|
19
|
-
"repository": {
|
|
20
|
-
"type": "git",
|
|
21
|
-
"url": "https://github.com/overwolf/ow-electron-packages-types"
|
|
22
|
-
}
|
|
23
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@overwolf/ow-electron-packages-types",
|
|
3
|
+
"version": "0.0.13",
|
|
4
|
+
"description": "Type definition file for autocompletion and documentation purposes for ow-electron packages",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"types": "overlay.d.ts",
|
|
7
|
+
"keywords": [
|
|
8
|
+
"types",
|
|
9
|
+
"npm",
|
|
10
|
+
"package",
|
|
11
|
+
"overwolf",
|
|
12
|
+
"ow-electron",
|
|
13
|
+
"overlay",
|
|
14
|
+
"game-list"
|
|
15
|
+
],
|
|
16
|
+
"devDependencies": {
|
|
17
|
+
"@overwolf/ow-electron": "latest"
|
|
18
|
+
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "https://github.com/overwolf/ow-electron-packages-types"
|
|
22
|
+
}
|
|
23
|
+
}
|