Options
All
  • Public
  • Public/Protected
  • All
Menu

Class UserCreator

A creator for Geometry Dash players

Hierarchy

Index

Methods

authorize

  • Log in to a Geometry Dash account using preprocessed credentials

    throws

    {TypeError} if credentials are invalid

    async

    Parameters

    Returns Promise<LoggedInUser>

    The logged in user associated with the provided credentials

get

  • Find a player by accountID or username

    async

    Parameters

    Returns Promise<User>

    The player with the provided account ID or username

getByAccountID

  • getByAccountID(id: number): Promise<User>
  • Gets the information about a player using its account ID

    async

    Parameters

    • id: number

      The account ID of the player to get

    Returns Promise<User>

    The player with the provided account ID

getByUsername

  • getByUsername(str: string, resolve?: true): Promise<User>
  • getByUsername(str: string, resolve: false): Promise<SearchedUser>
  • Get information about a user by its username

    async

    Parameters

    • str: string

      The name of the user to search for

    • Optional resolve: true

      Whether to resolve the searched user into its full user, making another network request.

    Returns Promise<User>

    The user with the given username

  • Get information about a user by its username

    async

    Parameters

    • str: string

      The name of the user to search for

    • resolve: false

      Whether to resolve the searched user into its full user, making another network request.

    Returns Promise<SearchedUser>

    The user with the given username

getLeaderboard

  • getLeaderboard(creators?: boolean): Promise<SearchedUser>
  • getLeaderboard(creators: boolean, num: number): Promise<SearchedUser[]>
  • Gets the top player of a user leaderboard

    async

    Parameters

    • Optional creators: boolean

    Returns Promise<SearchedUser>

    The top player in the given leaderboard category

  • Gets a user leaderboard

    async

    Parameters

    • creators: boolean
    • num: number

      The number of entries to get.

    Returns Promise<SearchedUser[]>

    The leaderboard, with position being index + 1

login

  • Log in to a Geometry Dash account

    throws

    {TypeError} if credentials are invalid

    async

    Parameters

    Returns Promise<LoggedInUser>

    The logged in user associated with the provided credentials

search

  • Searches for a player with a given string in their names. Note that the official Geometry Dash servers will always only return the player (if any) whose name is exactly the provided string.

    async
    deprecated

    Parameters

    • str: string

      The string to search for

    Returns Promise<SearchedUser>

    The first user whose name matches the given string

  • Searches for players with a given string in their names. Note that the official Geometry Dash servers will always only return the player (if any) whose name is exactly the provided string.

    async
    deprecated

    Parameters

    • str: string

      The string to search for

    • num: number

      The maximum number of users to get

    Returns Promise<SearchedUser[]>

    The array of users whose names match the given string

Generated using TypeDoc