1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-13 07:43:00 +08:00

Migrate DefaultPerformancePointsCounter and rename it

This commit is contained in:
Salman Ahmed 2024-03-05 04:34:41 +03:00
parent b1477c30f2
commit 49b3e81e8a
5 changed files with 9 additions and 5 deletions

View File

@ -18,6 +18,7 @@ using osu.Game.Rulesets.Osu.Scoring;
using osu.Game.Rulesets.Scoring; using osu.Game.Rulesets.Scoring;
using osu.Game.Screens.Play; using osu.Game.Screens.Play;
using osu.Game.Screens.Play.HUD; using osu.Game.Screens.Play.HUD;
using osu.Game.Skinning.Triangles;
using osu.Game.Tests.Gameplay; using osu.Game.Tests.Gameplay;
namespace osu.Game.Tests.Visual.Gameplay namespace osu.Game.Tests.Visual.Gameplay
@ -32,7 +33,7 @@ namespace osu.Game.Tests.Visual.Gameplay
private int iteration; private int iteration;
protected override Drawable CreateDefaultImplementation() => new DefaultPerformancePointsCounter(); protected override Drawable CreateDefaultImplementation() => new TrianglesPerformancePointsCounter();
protected override Drawable CreateArgonImplementation() => new ArgonPerformancePointsCounter(); protected override Drawable CreateArgonImplementation() => new ArgonPerformancePointsCounter();
protected override Drawable CreateLegacyImplementation() => Empty(); protected override Drawable CreateLegacyImplementation() => Empty();

View File

@ -27,7 +27,7 @@ using osu.Game.Skinning;
namespace osu.Game.Screens.Play.HUD namespace osu.Game.Screens.Play.HUD
{ {
public partial class PerformancePointsCounter : RollingCounter<int>, ISerialisableDrawable public abstract partial class PerformancePointsCounter : RollingCounter<int>, ISerialisableDrawable
{ {
public bool UsesFixedAnchor { get; set; } public bool UsesFixedAnchor { get; set; }

View File

@ -153,6 +153,7 @@ namespace osu.Game.Skinning
// handle namespace changes... // handle namespace changes...
jsonContent = jsonContent.Replace(@"osu.Game.Screens.Play.SongProgress", @"osu.Game.Screens.Play.HUD.DefaultSongProgress"); jsonContent = jsonContent.Replace(@"osu.Game.Screens.Play.SongProgress", @"osu.Game.Screens.Play.HUD.DefaultSongProgress");
jsonContent = jsonContent.Replace(@"osu.Game.Screens.Play.HUD.LegacyComboCounter", @"osu.Game.Skinning.LegacyComboCounter"); jsonContent = jsonContent.Replace(@"osu.Game.Screens.Play.HUD.LegacyComboCounter", @"osu.Game.Skinning.LegacyComboCounter");
jsonContent = jsonContent.Replace(@"osu.Game.Screens.Play.HUD.PerformancePointsCounter", @"osu.Game.Skinning.Triangles.TrianglesPerformancePointsCounter");
var deserializedContent = JsonConvert.DeserializeObject<IEnumerable<SerialisedDrawableInfo>>(jsonContent); var deserializedContent = JsonConvert.DeserializeObject<IEnumerable<SerialisedDrawableInfo>>(jsonContent);

View File

@ -11,11 +11,12 @@ using osu.Framework.Localisation;
using osu.Game.Graphics; using osu.Game.Graphics;
using osu.Game.Graphics.Sprites; using osu.Game.Graphics.Sprites;
using osu.Game.Resources.Localisation.Web; using osu.Game.Resources.Localisation.Web;
using osu.Game.Screens.Play.HUD;
using osuTK; using osuTK;
namespace osu.Game.Screens.Play.HUD namespace osu.Game.Skinning.Triangles
{ {
public partial class DefaultPerformancePointsCounter : PerformancePointsCounter public partial class TrianglesPerformancePointsCounter : PerformancePointsCounter
{ {
protected override bool IsRollingProportional => true; protected override bool IsRollingProportional => true;

View File

@ -14,6 +14,7 @@ using osu.Game.Extensions;
using osu.Game.IO; using osu.Game.IO;
using osu.Game.Screens.Play.HUD; using osu.Game.Screens.Play.HUD;
using osu.Game.Screens.Play.HUD.HitErrorMeters; using osu.Game.Screens.Play.HUD.HitErrorMeters;
using osu.Game.Skinning.Triangles;
using osuTK; using osuTK;
using osuTK.Graphics; using osuTK.Graphics;
@ -167,7 +168,7 @@ namespace osu.Game.Skinning
new DefaultKeyCounterDisplay(), new DefaultKeyCounterDisplay(),
new BarHitErrorMeter(), new BarHitErrorMeter(),
new BarHitErrorMeter(), new BarHitErrorMeter(),
new PerformancePointsCounter() new TrianglesPerformancePointsCounter()
} }
}; };