diff --git a/osu.Game.Tournament/Screens/Gameplay/MatchHeader.cs b/osu.Game.Tournament/Screens/Gameplay/MatchHeader.cs index 2ff5ee7bf6..5765c9cd12 100644 --- a/osu.Game.Tournament/Screens/Gameplay/MatchHeader.cs +++ b/osu.Game.Tournament/Screens/Gameplay/MatchHeader.cs @@ -6,13 +6,13 @@ using osu.Framework.Configuration; using osu.Framework.Graphics; using osu.Framework.Graphics.Containers; using osu.Framework.Graphics.Shapes; -using osu.Framework.Graphics.Sprites; using osu.Framework.Graphics.Textures; using osu.Framework.Input.Events; using osu.Game.Graphics.Sprites; using osu.Game.Graphics.UserInterface; using osu.Game.Tournament.Components; using osu.Game.Tournament.Screens.Ladder.Components; +using osu.Game.Tournament.Screens.Showcase; using OpenTK; using OpenTK.Graphics; using OpenTK.Input; @@ -28,16 +28,7 @@ namespace osu.Game.Tournament.Screens.Gameplay Height = 100; Children = new Drawable[] { - new Sprite - { - Y = 5, - Texture = textures.Get("game-screen-logo"), - Anchor = Anchor.TopCentre, - Origin = Anchor.TopCentre, - FillMode = FillMode.Fit, - RelativeSizeAxes = Axes.Both, - Size = Vector2.One - }, + new TournamentLogo(), new RoundDisplay { Y = 10, diff --git a/osu.Game.Tournament/Screens/Showcase/ShowcaseScreen.cs b/osu.Game.Tournament/Screens/Showcase/ShowcaseScreen.cs index ce458413a5..6950b940fe 100644 --- a/osu.Game.Tournament/Screens/Showcase/ShowcaseScreen.cs +++ b/osu.Game.Tournament/Screens/Showcase/ShowcaseScreen.cs @@ -1,9 +1,17 @@ // Copyright (c) 2007-2018 ppy Pty Ltd . // Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE +using osu.Framework.Allocation; +using osu.Framework.Graphics.Textures; + namespace osu.Game.Tournament.Screens.Showcase { public class ShowcaseScreen : BeatmapInfoScreen { + [BackgroundDependencyLoader] + private void load(TextureStore textures) + { + Add(new TournamentLogo()); + } } } diff --git a/osu.Game.Tournament/Screens/Showcase/TournamentLogo.cs b/osu.Game.Tournament/Screens/Showcase/TournamentLogo.cs new file mode 100644 index 0000000000..135081a641 --- /dev/null +++ b/osu.Game.Tournament/Screens/Showcase/TournamentLogo.cs @@ -0,0 +1,33 @@ +using osu.Framework.Allocation; +using osu.Framework.Graphics; +using osu.Framework.Graphics.Containers; +using osu.Framework.Graphics.Sprites; +using osu.Framework.Graphics.Textures; +using OpenTK; + +namespace osu.Game.Tournament.Screens.Showcase +{ + public class TournamentLogo : CompositeDrawable + { + public TournamentLogo() + { + RelativeSizeAxes = Axes.X; + Height = 100; + Margin = new MarginPadding { Vertical = 5 }; + } + + [BackgroundDependencyLoader] + private void load(TextureStore textures) + { + InternalChild = new Sprite + { + Texture = textures.Get("game-screen-logo"), + Anchor = Anchor.TopCentre, + Origin = Anchor.TopCentre, + FillMode = FillMode.Fit, + RelativeSizeAxes = Axes.Both, + Size = Vector2.One + }; + } + } +} diff --git a/osu.Game.Tournament/Screens/TeamIntro/TeamIntroScreen.cs b/osu.Game.Tournament/Screens/TeamIntro/TeamIntroScreen.cs index 63ca968aef..05746c07d0 100644 --- a/osu.Game.Tournament/Screens/TeamIntro/TeamIntroScreen.cs +++ b/osu.Game.Tournament/Screens/TeamIntro/TeamIntroScreen.cs @@ -1,17 +1,18 @@ // Copyright (c) 2007-2018 ppy Pty Ltd . // Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE -using System; using osu.Framework.Allocation; using osu.Framework.Configuration; using osu.Framework.Graphics; using osu.Framework.Graphics.Containers; +using osu.Framework.Graphics.Textures; using osu.Framework.Graphics.Video; using osu.Framework.Platform; using osu.Game.Graphics; using osu.Game.Graphics.Sprites; using osu.Game.Tournament.Components; using osu.Game.Tournament.Screens.Ladder.Components; +using osu.Game.Tournament.Screens.Showcase; using OpenTK; using OpenTK.Graphics; @@ -24,7 +25,7 @@ namespace osu.Game.Tournament.Screens.TeamIntro private readonly Bindable currentMatch = new Bindable(); [BackgroundDependencyLoader] - private void load(LadderInfo ladder, Storage storage) + private void load(TextureStore textures, LadderInfo ladder, Storage storage) { RelativeSizeAxes = Axes.Both; @@ -35,6 +36,7 @@ namespace osu.Game.Tournament.Screens.TeamIntro RelativeSizeAxes = Axes.Both, Loop = true, }, + new TournamentLogo(), mainContainer = new Container { RelativeSizeAxes = Axes.Both,