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

Move DrawableStoryboard's aspect application to inside its own class

This commit is contained in:
Dean Herbert 2021-05-25 16:06:39 +09:00
parent 6263ebf9da
commit e3507d5453
2 changed files with 5 additions and 6 deletions

View File

@ -58,6 +58,9 @@ namespace osu.Game.Storyboards.Drawables
{
Storyboard = storyboard;
Size = new Vector2(640, 480);
Width = Height * (storyboard.BeatmapInfo.WidescreenStoryboard ? 16 / 9f : 4 / 3f);
Anchor = Anchor.Centre;
Origin = Anchor.Centre;

View File

@ -85,12 +85,8 @@ namespace osu.Game.Storyboards
}
}
public DrawableStoryboard CreateDrawable(WorkingBeatmap working = null)
{
var drawable = new DrawableStoryboard(this);
drawable.Width = drawable.Height * (BeatmapInfo.WidescreenStoryboard ? 16 / 9f : 4 / 3f);
return drawable;
}
public DrawableStoryboard CreateDrawable(WorkingBeatmap working = null) =>
new DrawableStoryboard(this);
public Drawable CreateSpriteFromResourcePath(string path, TextureStore textureStore)
{