Home Reference Source Repository
import Player from 'deckster/src/models/player.js'
public class | source

Player

Represents a player who plays in a round of a game.

Constructor Summary

Public Constructor
public

Creates a new player.

Member Summary

Public Members
public get

cards: Card[]

Gets the cards in the player's hand.

public get

Gets the ID of the player.

Public Constructors

public constructor(id: number | string) source

Creates a new player.

Params:

NameTypeAttributeDescription
id number | string
  • nullable: true

The ID of the player.

Public Members

public get cards: Card[] source

Gets the cards in the player's hand.

public get id: number | string source

Gets the ID of the player.