[][src]Module livesplit_core::analysis

The analysis module provides a variety of functions for calculating information about runs.

Re-exports

pub use self::state_helper::*;

Modules

current_pace

Calculates the current pace of the active attempt based on the comparison provided. If there's no active attempt, the final time of the comparison is returned instead.

delta

Calculates the delta of the current attempt to the comparison provided. Additionally a value is returned that indicates whether the delta value is a live delta. A live delta indicates that the value is actively changing at the moment. This may be the case when the current attempt is slower than the comparison at the current split.

possible_time_save

Provides functions for calculating how much time save there is for either single segments or the remainder of an active attempt. This information is based on the best segments. Considering the best segments don't represent theoretically perfect segment times, this information is only an approximation of how much time can actually be saved.

state_helper

Provides different helper functions.

sum_of_segments

Provides functionality for calculating the Sum of Best Segments and the Sum of Worst Segments for whole runs or specific parts. The Sum of Best Segments is the fastest time possible to complete a run of a category, based on information collected from all the previous attempts. This often matches up with the sum of the best segment times of all the segments, but that may not always be the case, as skipped segments may introduce combined segments that may be faster than the actual sum of their best segment times. The name is therefore a bit misleading, but sticks around for historical reasons.

total_playtime

Provides functionality to calculate the total playtime for either a Run or a Timer. For a Run, all the durations stored in the Attempt History are summed together. For a Timer, the current attempt's duration is also factored in.