Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SegmentRef

A Segment describes a point in a speedrun that is suitable for storing a split time. This stores the name of that segment, an icon, the split times of different comparisons, and a history of segment times.

Hierarchy

Index

Constructors

constructor

  • This constructor is an implementation detail. Do not use this.

    Parameters

    • ptr: number

    Returns SegmentRef

Properties

ptr

ptr: number

Methods

bestSegmentTime

  • Accesses the Best Segment Time.

    Returns TimeRef

comparison

  • comparison(comparison: string): TimeRef
  • Accesses the specified comparison's time. If there's none for this comparison, an empty time is being returned (but not stored in the segment).

    Parameters

    • comparison: string

    Returns TimeRef

iconLen

  • iconLen(): number
  • Accesses the amount of bytes the segment icon's data takes up.

    Returns number

iconPtr

  • iconPtr(): number
  • Accesses the segment icon's data. If there is no segment icon, this returns an empty buffer.

    Returns number

name

  • name(): string
  • Accesses the name of the segment.

    Returns string

personalBestSplitTime

  • Accesses the split time of the Personal Best for this segment. If it doesn't exist, an empty time is returned.

    Returns TimeRef

segmentHistory

  • Accesses the Segment History of this segment.

    Returns SegmentHistoryRef

Generated using TypeDoc