@thenick775/mgba-wasm 2.5.1 → 2.6.0-beta.2
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/dist/mgba.d.ts +32 -0
- package/dist/mgba.js +1 -1
- package/dist/mgba.wasm +0 -0
- package/dist/mgba.wasm.map +1 -1
- package/package.json +1 -1
package/dist/mgba.d.ts
CHANGED
|
@@ -75,6 +75,13 @@ declare namespace mGBA {
|
|
|
75
75
|
message: string;
|
|
76
76
|
};
|
|
77
77
|
|
|
78
|
+
export type LinkPlayer = 1 | 2; // TODO: more than 2 player support
|
|
79
|
+
|
|
80
|
+
export type LinkLocalStatus = {
|
|
81
|
+
running: boolean;
|
|
82
|
+
activePlayer: LinkPlayer | 0;
|
|
83
|
+
};
|
|
84
|
+
|
|
78
85
|
export type coreSettings = {
|
|
79
86
|
/**
|
|
80
87
|
* Number of frames to skip rendering between screen paints.
|
|
@@ -320,6 +327,31 @@ declare namespace mGBA {
|
|
|
320
327
|
*/
|
|
321
328
|
loadGame(romPath: string, savePathOverride?: string): boolean;
|
|
322
329
|
|
|
330
|
+
/**
|
|
331
|
+
* Starts a local linked GBA session. Version 1 supports two players.
|
|
332
|
+
*/
|
|
333
|
+
linkLocalStartSession(
|
|
334
|
+
player1RomPath: string,
|
|
335
|
+
player1SavePath: string | undefined,
|
|
336
|
+
player2RomPath: string,
|
|
337
|
+
player2SavePath?: string,
|
|
338
|
+
): boolean;
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* Stops the active local linked session.
|
|
342
|
+
*/
|
|
343
|
+
linkLocalStopSession(): void;
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* Selects which linked player is rendered and controlled by normal input APIs.
|
|
347
|
+
*/
|
|
348
|
+
linkLocalSetActivePlayer(player: LinkPlayer): void;
|
|
349
|
+
|
|
350
|
+
/**
|
|
351
|
+
* Gets the current local linked session status.
|
|
352
|
+
*/
|
|
353
|
+
linkLocalGetStatus(): LinkLocalStatus;
|
|
354
|
+
|
|
323
355
|
/**
|
|
324
356
|
* Loads a save state from a given slot.
|
|
325
357
|
*
|