Skip to content

Commit

Permalink
Added rank (plus minor fixes)
Browse files Browse the repository at this point in the history
  • Loading branch information
hiimjasmine00 authored Jan 10, 2021
1 parent 2aea078 commit 9e81162
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/entities/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,8 @@ class User {
username: string;
/** The player's user ID */
id: number;
/** The global rank of the player */
rank: number;
/** The player's account ID */
accountID: number;
/** The player's stats */
Expand Down Expand Up @@ -608,6 +610,7 @@ class User {
stars: +d[3],
diamonds: +d[46],
demons: +d[4],
rank: +d[30],
coins: {
normal: +d[13],
user: +d[17]
Expand Down Expand Up @@ -1708,6 +1711,8 @@ class StatlessSearchedUser {
username: string;
/** The player's user ID. Will only be present if it is known */
id?: number;
/** The global rank of the player */
rank: number;
/** The player's account ID */
accountID: number;
/** The player's cosmetics */
Expand Down Expand Up @@ -1856,12 +1861,16 @@ class StatlessSearchedUser {
class SearchedUser extends StatlessSearchedUser {
/** The player's user ID */
id: number;
/** The global rank of the player */
rank: number;
/** The player's stats */
stats: {
/** The number of stars the player has collected */
stars: number;
/** The number of demons the player has beaten */
demons: number;
/** The number of diamonds the player has collected */
diamonds: number;
/** The coins the player has collected */
coins: {
/** The number of coins in the single-player mode (gold coins) the player has collected */
Expand All @@ -1884,6 +1893,7 @@ class SearchedUser extends StatlessSearchedUser {
this.stats = {
stars: +d[3],
demons: +d[4],
rank: +d[30],
coins: {
normal: +d[13],
user: +d[17]
Expand Down

0 comments on commit 9e81162

Please sign in to comment.