mirror of
https://github.com/ppy/osu
synced 2024-12-28 09:52:56 +00:00
Convert length retrieved from online to milliseconds
This commit is contained in:
parent
1485c273ab
commit
e73f22eff8
@ -180,7 +180,7 @@ namespace osu.Game.Tournament.Components
|
||||
|
||||
panelContents.Children = new Drawable[]
|
||||
{
|
||||
new DiffPiece(("Length", TimeSpan.FromSeconds(length).ToString(@"mm\:ss")))
|
||||
new DiffPiece(("Length", TimeSpan.FromMilliseconds(length).ToString(@"mm\:ss")))
|
||||
{
|
||||
Anchor = Anchor.CentreLeft,
|
||||
Origin = Anchor.BottomLeft,
|
||||
|
@ -41,7 +41,7 @@ namespace osu.Game.Beatmaps
|
||||
public double MaxStarDifficulty => Beatmaps?.Max(b => b.StarDifficulty) ?? 0;
|
||||
|
||||
/// <summary>
|
||||
/// The maximum playable length of all beatmaps in this set.
|
||||
/// The maximum playable length in milliseconds of all beatmaps in this set.
|
||||
/// </summary>
|
||||
public double MaxLength => Beatmaps?.Max(b => b.Length) ?? 0;
|
||||
|
||||
|
@ -1,6 +1,7 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
using Newtonsoft.Json;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Rulesets;
|
||||
@ -71,7 +72,7 @@ namespace osu.Game.Online.API.Requests.Responses
|
||||
StarDifficulty = starDifficulty,
|
||||
OnlineBeatmapID = OnlineBeatmapID,
|
||||
Version = version,
|
||||
Length = length,
|
||||
Length = TimeSpan.FromSeconds(length).Milliseconds,
|
||||
Status = Status,
|
||||
BeatmapSet = set,
|
||||
Metrics = metrics,
|
||||
|
Loading…
Reference in New Issue
Block a user