mirror of
https://github.com/osukey/osukey.git
synced 2025-07-01 16:29:58 +09:00
Align logo correctly between intro and main menu.
Kinda hacky but will do for now.
This commit is contained in:
@ -36,11 +36,16 @@ namespace osu.Game.Graphics.Containers
|
||||
this.input = input;
|
||||
}
|
||||
|
||||
bool firstUpdate = true;
|
||||
|
||||
protected override void Update()
|
||||
{
|
||||
base.Update();
|
||||
content.MoveTo((ToLocalSpace(input.CurrentState.Mouse.NativeState.Position) - DrawSize / 2) * ParallaxAmount, 1000, EasingTypes.OutQuint);
|
||||
|
||||
content.MoveTo((ToLocalSpace(input.CurrentState.Mouse.NativeState.Position) - DrawSize / 2) * ParallaxAmount, firstUpdate ? 0 : 1000, EasingTypes.OutQuint);
|
||||
content.Scale = new Vector2(1 + ParallaxAmount);
|
||||
|
||||
firstUpdate = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ using osu.Framework.Audio.Track;
|
||||
using osu.Framework.GameModes;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Transformations;
|
||||
using osu.Game.Graphics.Containers;
|
||||
using osu.Game.Screens.Backgrounds;
|
||||
using OpenTK.Graphics;
|
||||
|
||||
@ -32,6 +33,11 @@ namespace osu.Game.Screens.Menu
|
||||
|
||||
public Intro()
|
||||
{
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new ParallaxContainer
|
||||
{
|
||||
ParallaxAmount = 0.01f,
|
||||
Children = new Drawable[]
|
||||
{
|
||||
logo = new OsuLogo
|
||||
@ -43,6 +49,8 @@ namespace osu.Game.Screens.Menu
|
||||
Colour = Color4.DarkGray,
|
||||
Ripple = false
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user