mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 15:44:04 +09:00
Make heatmap support dynamic sizing
This commit is contained in:
@ -20,7 +20,7 @@ namespace osu.Game.Tests.Visual.Ranking
|
||||
private readonly Box background;
|
||||
private readonly Drawable object1;
|
||||
private readonly Drawable object2;
|
||||
private readonly Heatmap heatmap;
|
||||
private readonly TestHeatmap heatmap;
|
||||
|
||||
public TestSceneAccuracyHeatmap()
|
||||
{
|
||||
@ -40,10 +40,11 @@ namespace osu.Game.Tests.Visual.Ranking
|
||||
{
|
||||
Position = new Vector2(500, 300),
|
||||
},
|
||||
heatmap = new Heatmap(new List<HitOffset>())
|
||||
heatmap = new TestHeatmap(new List<HitOffset>())
|
||||
{
|
||||
Anchor = Anchor.Centre,
|
||||
Origin = Anchor.Centre,
|
||||
Size = new Vector2(130)
|
||||
}
|
||||
};
|
||||
}
|
||||
@ -70,6 +71,17 @@ namespace osu.Game.Tests.Visual.Ranking
|
||||
return true;
|
||||
}
|
||||
|
||||
private class TestHeatmap : Heatmap
|
||||
{
|
||||
public TestHeatmap(IReadOnlyList<HitOffset> offsets)
|
||||
: base(offsets)
|
||||
{
|
||||
}
|
||||
|
||||
public new void AddPoint(Vector2 start, Vector2 end, Vector2 hitPoint, float radius)
|
||||
=> base.AddPoint(start, end, hitPoint, radius);
|
||||
}
|
||||
|
||||
private class BorderCircle : CircularContainer
|
||||
{
|
||||
public BorderCircle()
|
||||
|
Reference in New Issue
Block a user