This constructor is an implementation detail. Do not use this.
Returns the current comparison that is being compared against. This may be a custom comparison or one of the Comparison Generators.
Returns the current Timer Phase.
Accesses the index of the split the attempt is currently on. If there's
no attempt in progress, -1
is returned instead. This returns an
index that is equal to the amount of segments when the attempt is
finished, but has not been reset. So you need to be careful when using
this value for indexing.
Returns the current time of the Timer. The Game Time is null if the Game Time has not been initialized.
Returns the currently selected Timing Method.
Deinitializes Game Time for the current attempt.
Accesses the Run in use by the Timer.
Initializes Game Time for the current attempt. Game Time automatically gets uninitialized for each new attempt.
Returns whether Game Time is currently initialized. Game Time automatically gets uninitialized for each new attempt.
Returns whether the Game Timer is currently paused. If the Game Timer is not paused, it automatically increments similar to Real Time.
Accesses the loading times. Loading times are defined as Game Time - Real Time.
Marks the Run as unmodified, so that it is known that all the changes have been saved.
Pauses an active attempt that is not paused.
Pauses the Game Timer such that it doesn't automatically increment similar to Real Time.
Prints out debug information representing the whole state of the Timer. This is being written to stdout.
Replaces the Run object used by the Timer with the Run object provided. If
the Run provided contains no segments, it can't be used for timing and is
not being modified. Otherwise the Run that was in use by the Timer gets
stored in the Run object provided. Before the Run is returned, the current
attempt is reset and the splits are being updated depending on the
update_splits
parameter. The return value indicates whether the Run got
replaced successfully.
Resets the current attempt if there is one in progress. If the splits are to be updated, all the information of the current attempt is stored in the Run's history. Otherwise the current attempt's information is discarded.
Resets the current attempt if there is one in progress. The splits are updated such that the current attempt's split times are being stored as the new Personal Best.
Resumes an attempt that is paused.
Resumes the Game Timer such that it automatically increments similar to Real Time, starting from the Game Time it was paused at.
Saves the Run in use by the Timer as a LiveSplit splits file (*.lss).
Sets the current Timing Method to the Timing Method provided.
Sets the Game Time to the time specified. This also works if the Game Time is paused, which can be used as a way of updating the Game Timer periodically without it automatically moving forward. This ensures that the Game Timer never shows any time that is not coming from the game.
Instead of setting the Game Time directly, this method can be used to just specify the amount of time the game has been loading. The Game Time is then automatically determined by Real Time - Loading Times.
Sets the Run object used by the Timer with the Run object provided. If the Run provided contains no segments, it can't be used for timing and gets returned again. If the Run object can be set, the original Run object in use by the Timer is disposed by this method and null is returned.
Skips the current split if an attempt is in progress and the current split is not the last split.
If an attempt is in progress, stores the current time as the time of the current split. The attempt ends if the last split time is stored.
Starts a new attempt or stores the current time as the time of the current split. The attempt ends if the last split time is stored.
Starts the Timer if there is no attempt in progress. If that's not the case, nothing happens.
Switches the current comparison to the next comparison in the list.
Switches the current comparison to the previous comparison in the list.
Toggles an active attempt between Paused
and Running
.
Toggles an active attempt between Paused
and Running
or starts an
attempt if there's none in progress.
Removes all the pause times from the current time. If the current attempt is paused, it also resumes that attempt. Additionally, if the attempt is finished, the final split time is adjusted to not include the pause times as well.
This behavior is not entirely optimal, as generally only the final split time is modified, while all other split times are left unmodified, which may not be what actually happened during the run.
Removes the split time from the last split if an attempt is in progress
and there is a previous split. The Timer Phase also switches to
Running
if it previously was Ended
.
Generated using TypeDoc
A Timer provides all the capabilities necessary for doing speedrun attempts.