-
-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: applu some requested changes
- Loading branch information
Showing
36 changed files
with
1,472 additions
and
1,392 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/** | ||
* Types extracted from https://discord.com/developers/docs/game-sdk/achievements | ||
*/ | ||
|
||
import type { Snowflake } from '../../globals.ts'; | ||
import type { LocalizationMap } from '../common.ts'; | ||
|
||
export interface APIAchievement { | ||
/** | ||
* Unique id of the application | ||
*/ | ||
application_id: Snowflake; | ||
/** | ||
* Name of this achievement | ||
*/ | ||
name: string; | ||
/** | ||
* Localization dictionary for the `name` field | ||
*/ | ||
name_localizations: LocalizationMap | null; | ||
/** | ||
* The description of this achievement | ||
*/ | ||
description: string; | ||
/** | ||
* Localization dictionary for the `description` field | ||
*/ | ||
description_localizations: LocalizationMap | null; | ||
/** | ||
* Whether this achievement is secret | ||
*/ | ||
secret: boolean; | ||
/** | ||
* Whether this achievement is secure | ||
*/ | ||
secure: boolean; | ||
/** | ||
* Unique id of this achievement | ||
*/ | ||
id: Snowflake; | ||
/** | ||
* The achievement icon hash | ||
*/ | ||
icon_hash: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
/** | ||
* Types extracted from https://discord.com/developers/docs/game-sdk/lobbies | ||
*/ | ||
|
||
import type { Snowflake } from '../../globals.ts'; | ||
|
||
export interface APILobby { | ||
/** | ||
* Unique id of this lobby | ||
*/ | ||
id: Snowflake; | ||
/** | ||
* The type of this lobby (whether it is private or public) | ||
* | ||
* @default Private | ||
*/ | ||
type: LobbyType; | ||
/** | ||
* The user id of the lobby owner | ||
*/ | ||
owner_id: Snowflake; | ||
/** | ||
* The password of this lobby | ||
*/ | ||
secret: string; | ||
/** | ||
* The maximum capacity of this lobby | ||
* | ||
* @default 16 | ||
*/ | ||
capacity: number; | ||
/** | ||
* Whether this lobby can be joined | ||
*/ | ||
locked: boolean; | ||
/** | ||
* Unique id of the application | ||
*/ | ||
application_id: Snowflake; | ||
/** | ||
* Metadata for this lobby. key/value pairs with type `string` | ||
* | ||
* @default {} | ||
*/ | ||
metadata: Record<string, string>; | ||
/** | ||
* The region of this lobby. Defaults the region of the requesting server's IP address | ||
*/ | ||
region: LobbyRegion; | ||
} | ||
|
||
export enum LobbyRegion { | ||
Atlanta = 'atlanta', | ||
Brazil = 'brazil', | ||
Bucharest = 'bucharest', | ||
BuenosAires = 'buenos-aires', | ||
Dubai = 'dubai', | ||
Finland = 'finland', | ||
Hongkong = 'hongkong', | ||
India = 'india', | ||
Japan = 'japan', | ||
Madrid = 'madrid', | ||
Milan = 'milan', | ||
Montreal = 'montreal', | ||
Newark = 'newark', | ||
Rotterdam = 'rotterdam', | ||
Russia = 'russia', | ||
SantaClara = 'santa-clara', | ||
Santiago = 'santiago', | ||
Seattle = 'seattle', | ||
Singapore = 'singapore', | ||
SouthKorea = 'south-korea', | ||
SouthAfrica = 'southafrica', | ||
StPete = 'st-pete', | ||
Stockholm = 'stockholm', | ||
Sydney = 'sydney', | ||
UsCentral = 'us-central', | ||
UsEast = 'us-east', | ||
UsSouth = 'us-south', | ||
UsWest = 'us-west', | ||
} | ||
|
||
export enum LobbyType { | ||
Private = 1, | ||
Public, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/** | ||
* Types extracted from https://discord.com/developers/docs/game-sdk/achievements | ||
*/ | ||
|
||
import type { Snowflake } from '../../globals.ts'; | ||
import type { LocalizationMap } from '../common.ts'; | ||
|
||
export interface APIAchievement { | ||
/** | ||
* Unique id of the application | ||
*/ | ||
application_id: Snowflake; | ||
/** | ||
* Name of this achievement | ||
*/ | ||
name: string; | ||
/** | ||
* Localization dictionary for the `name` field | ||
*/ | ||
name_localizations: LocalizationMap | null; | ||
/** | ||
* The description of this achievement | ||
*/ | ||
description: string; | ||
/** | ||
* Localization dictionary for the `description` field | ||
*/ | ||
description_localizations: LocalizationMap | null; | ||
/** | ||
* Whether this achievement is secret | ||
*/ | ||
secret: boolean; | ||
/** | ||
* Whether this achievement is secure | ||
*/ | ||
secure: boolean; | ||
/** | ||
* Unique id of this achievement | ||
*/ | ||
id: Snowflake; | ||
/** | ||
* The achievement icon hash | ||
*/ | ||
icon_hash: string; | ||
} |
Oops, something went wrong.