Rewrite VisualiserLine + add VisualiserContainer.

This commit is contained in:
smoogipooo
2017-03-03 15:43:16 +09:00
parent a70b1ae108
commit 777996d884
4 changed files with 213 additions and 225 deletions

View File

@ -60,8 +60,6 @@ namespace osu.Game.Screens.Tournament
drawingsConfig = new DrawingsConfigManager(storage);
Container visualiserContainer;
Children = new Drawable[]
{
new Box()
@ -90,7 +88,7 @@ namespace osu.Game.Screens.Tournament
Children = new Drawable[]
{
// Visualiser
visualiserContainer = new Container()
new VisualiserContainer()
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
@ -98,7 +96,9 @@ namespace osu.Game.Screens.Tournament
RelativeSizeAxes = Axes.X,
Size = new Vector2(1, 10),
Colour = new Color4(255, 204, 34, 255)
Colour = new Color4(255, 204, 34, 255),
Lines = 6
},
// Groups
groupsContainer = new GroupsContainer(drawingsConfig.Get<int>(DrawingsConfig.Groups), drawingsConfig.Get<int>(DrawingsConfig.TeamsPerGroup))
@ -230,17 +230,6 @@ namespace osu.Game.Screens.Tournament
}
};
float offset = 0;
for (int i = 0; i < 6; i++)
{
visualiserContainer.Add(new VisualiserLine(2 * (float)Math.PI, offset, RNG.Next(10000, 12000))
{
RelativeSizeAxes = Axes.Both,
});
offset += (float)Math.PI / 6f;
}
teamsContainer.OnSelected += onTeamSelected;
teamsContainer.OnScrollStarted += () => fullTeamNameText.FadeOut(200);