mirror of https://github.com/ppy/osu
Fix cinema mod not hiding playfield skin layer
This commit is contained in:
parent
d55fa423e9
commit
11c3d11db9
|
@ -36,6 +36,8 @@ public void ApplyToHUD(HUDOverlay overlay)
|
|||
{
|
||||
overlay.ShowHud.Value = false;
|
||||
overlay.ShowHud.Disabled = true;
|
||||
|
||||
overlay.PlayfieldSkinLayer.Hide();
|
||||
}
|
||||
|
||||
public void ApplyToPlayer(Player player)
|
||||
|
|
|
@ -109,7 +109,10 @@ protected override bool ShouldBeConsideredForInput(Drawable child)
|
|||
|
||||
private readonly List<Drawable> hideTargets;
|
||||
|
||||
private readonly Drawable playfieldComponents;
|
||||
/// <summary>
|
||||
/// The container for skin components attached to <see cref="TargetArea.Playfield"/>
|
||||
/// </summary>
|
||||
internal readonly Drawable PlayfieldSkinLayer;
|
||||
|
||||
public HUDOverlay([CanBeNull] DrawableRuleset drawableRuleset, IReadOnlyList<Mod> mods, bool alwaysShowLeaderboard = true)
|
||||
{
|
||||
|
@ -129,7 +132,7 @@ public HUDOverlay([CanBeNull] DrawableRuleset drawableRuleset, IReadOnlyList<Mod
|
|||
drawableRuleset != null
|
||||
? (rulesetComponents = new HUDComponentsContainer(drawableRuleset.Ruleset.RulesetInfo) { AlwaysPresent = true, })
|
||||
: Empty(),
|
||||
playfieldComponents = drawableRuleset != null
|
||||
PlayfieldSkinLayer = drawableRuleset != null
|
||||
? new SkinComponentsContainer(new SkinComponentsContainerLookup(SkinComponentsContainerLookup.TargetArea.Playfield, drawableRuleset.Ruleset.RulesetInfo)) { AlwaysPresent = true, }
|
||||
: Empty(),
|
||||
topRightElements = new FillFlowContainer
|
||||
|
@ -247,10 +250,10 @@ protected override void Update()
|
|||
{
|
||||
Quad playfieldScreenSpaceDrawQuad = drawableRuleset.Playfield.SkinnableComponentScreenSpaceDrawQuad;
|
||||
|
||||
playfieldComponents.Position = ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft);
|
||||
playfieldComponents.Width = (ToLocalSpace(playfieldScreenSpaceDrawQuad.TopRight) - ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft)).Length;
|
||||
playfieldComponents.Height = (ToLocalSpace(playfieldScreenSpaceDrawQuad.BottomLeft) - ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft)).Length;
|
||||
playfieldComponents.Rotation = drawableRuleset.Playfield.Rotation;
|
||||
PlayfieldSkinLayer.Position = ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft);
|
||||
PlayfieldSkinLayer.Width = (ToLocalSpace(playfieldScreenSpaceDrawQuad.TopRight) - ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft)).Length;
|
||||
PlayfieldSkinLayer.Height = (ToLocalSpace(playfieldScreenSpaceDrawQuad.BottomLeft) - ToLocalSpace(playfieldScreenSpaceDrawQuad.TopLeft)).Length;
|
||||
PlayfieldSkinLayer.Rotation = drawableRuleset.Playfield.Rotation;
|
||||
}
|
||||
|
||||
float? lowestTopScreenSpaceLeft = null;
|
||||
|
|
Loading…
Reference in New Issue