SongGuess
    Preparing search index...

    Interface PersistedPlayer

    Represents a player in the game with their state and score.

    interface PersistedPlayer {
        answerData?: {
            answer?: string;
            answerIndex?: number;
            answerSpeed?: number;
            answerTimestamp?: number;
            questionPoints: number;
        };
        color: string;
        connId: string;
        hasPicked?: boolean;
        isHost: boolean;
        isSpectator: boolean;
        points: number;
        username: string;
        uuid: string;
    }

    Hierarchy (View Summary)

    Index
    answerData?: {
        answer?: string;
        answerIndex?: number;
        answerSpeed?: number;
        answerTimestamp?: number;
        questionPoints: number;
    } = ...

    The current answer of this player.

    Type Declaration

    • Optionalanswer?: string

      Provided only for PlayerPicksGame. The answer the player selected.

    • OptionalanswerIndex?: number

      Provided only for MultipleChoiceGame. The index of the question the player selected.

    • OptionalanswerSpeed?: number

      The relative time in ms a player took to answer a round question.

    • OptionalanswerTimestamp?: number

      The absolute time in ms where the player answered a round question.

    • questionPoints: number

      The points the player got for the current question.

    color: string = ...

    The player's color

    connId: string
    hasPicked?: boolean = ...

    True, if this player has picked a song in player picks. Ommitted otherwise.

    isHost: boolean = ...

    True, if the receiver is the host

    isSpectator: boolean = ...

    True, if this player is just spectating

    points: number = ...

    How many points the player had in the last round.

    username: string = UsernameSchema

    The player's username

    uuid: string = ...

    The server generated uuid, NOT the connection id.