//Calculates the average of the top ten % of speeds between hitpoints in the given beatmap //(speeds = change in position / change in time) public double CalculateDistances() { List <double> speeds = new List <double>(); for (int i = 1; i < positions.Length; i++) { //Cast to make division operation a double speeds.Add(Math.Abs(positions[i] - positions[i - 1]) / (double)(times[i] - times[i - 1])); } return(Dewlib.SumScaledList(speeds.ToArray(), 0.95)); }
//Gets the difficulty of the entire map public double GetDifficulty() { HitPoint[] notes = this.GetNoteDifficulty(); List <double> notedifficulties = new List <double>(); foreach (HitPoint notepoint in notes) { notedifficulties.Add(notepoint.HitDifficulty); } return(Dewlib.SumScaledList(notedifficulties.ToArray(), 0.95)); }