Options
All
  • Public
  • Public/Protected
  • All
Menu

Player class that persists data for the same ephemereal agent across multiple matches. Used for {@link Tournament | Tournaments}

Hierarchy

  • Player

Index

Constructors

constructor

  • new Player(tournamentID: ID, file: string, zipFile: string, botkey?: string): Player

Properties

anonymous

anonymous: boolean = true

Whether this player is anonymous and not tied to a user on the back end

If this is ever false, then that means 1. we have a backend setup 2. there is an actual user entry

botDirPath

botDirPath: string = undefined

Path to player's directory, not the file to be executed/used. Value is necessary if storage system is not used or there is no bot key because the player is anonymous (locally stored). Used so tournament can clean up old bot directory when a new bot is uploaded

botkey

botkey: string = undefined

Key that references the player's bot file object if it exists

disabled

disabled: boolean = false

Whether or not this player is disabled and won't be used in in the default match scheduling for {@link Tournament.Ladder | Ladder Tournaments}. Is set to true if this player's bot throws an error during the initialization stage of a Match.

file

file: string

tournamentID

tournamentID: ID

username

username: string = undefined

Associated username if there is one

version

version: number = 0

The version of the bot associated with this player. Incremented whenever addPlayer is called

zipFile

zipFile: string = undefined

Path to the zip file for the bot. Used when no storage service is used. Used to allow api to send zipped bot file

Methods

Static generatePlayerID

  • generatePlayerID(): string

Generated using TypeDoc