1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 10:52:53 +08:00

Merge pull request #229 from peppy/general-fixes

General improvements
This commit is contained in:
Dean Herbert 2016-12-08 13:32:27 +09:00 committed by GitHub
commit 01a35ed448
13 changed files with 46 additions and 45 deletions

@ -1 +1 @@
Subproject commit 8dbc789266c1bc3e46e364be824d69bcfac74e83 Subproject commit 1b0d7a584cad85efcdf25c5155e6e62a4ccb5758

View File

@ -85,11 +85,5 @@ namespace osu.Desktop.VisualTests.Tests
} }
}); });
} }
protected override void Update()
{
base.Update();
Clock.ProcessFrame();
}
} }
} }

View File

@ -58,11 +58,5 @@ namespace osu.Desktop.VisualTests.Tests
Add(d); Add(d);
} }
} }
protected override void Update()
{
base.Update();
Clock.ProcessFrame();
}
} }
} }

View File

@ -32,11 +32,5 @@ namespace osu.Desktop.VisualTests.Tests
Add(mc); Add(mc);
AddToggle(@"Show", mc.ToggleVisibility); AddToggle(@"Show", mc.ToggleVisibility);
} }
protected override void Update()
{
base.Update();
Clock.ProcessFrame();
}
} }
} }

View File

@ -82,11 +82,5 @@ namespace osu.Desktop.VisualTests.Tests
Beatmap = beatmap Beatmap = beatmap
}); });
} }
protected override void Update()
{
base.Update();
Clock.ProcessFrame();
}
} }
} }

View File

@ -17,7 +17,7 @@ namespace osu.Game.Modes.Osu.UI
protected virtual float PopOutSmallScale => 1.1f; protected virtual float PopOutSmallScale => 1.1f;
protected virtual bool CanPopOutWhileRolling => false; protected virtual bool CanPopOutWhileRolling => false;
public Vector2 PopOutScale = new Vector2(2.5f); public Vector2 PopOutScale = new Vector2(1.6f);
protected override void LoadComplete() protected override void LoadComplete()
{ {

View File

@ -12,18 +12,20 @@ namespace osu.Game.Modes.Osu.UI
{ {
public class OsuScoreOverlay : ScoreOverlay public class OsuScoreOverlay : ScoreOverlay
{ {
protected override PercentageCounter CreateAccuracyCounter() => new PercentageCounter()
{
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
Position = new Vector2(0, 45)
};
protected override ScoreCounter CreateScoreCounter() => new ScoreCounter() protected override ScoreCounter CreateScoreCounter() => new ScoreCounter()
{ {
Anchor = Anchor.TopRight, Anchor = Anchor.TopRight,
Origin = Anchor.TopRight, Origin = Anchor.TopRight,
TextSize = 60 TextSize = 60,
Margin = new MarginPadding { Right = 5 },
};
protected override PercentageCounter CreateAccuracyCounter() => new PercentageCounter()
{
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
Position = new Vector2(0, 55),
Margin = new MarginPadding { Right = 5 },
}; };
protected override ComboCounter CreateComboCounter() => new OsuComboCounter() protected override ComboCounter CreateComboCounter() => new OsuComboCounter()

View File

@ -20,7 +20,7 @@ namespace osu.Game.Graphics.UserInterface
{ {
protected override Type TransformType => typeof(TransformAccuracy); protected override Type TransformType => typeof(TransformAccuracy);
protected override double RollingDuration => 20; protected override double RollingDuration => 150;
protected override bool IsRollingProportional => true; protected override bool IsRollingProportional => true;
private float epsilon => 1e-10f; private float epsilon => 1e-10f;

View File

@ -42,7 +42,7 @@ namespace osu.Game.Graphics.UserInterface
/// <summary> /// <summary>
/// Easing for the counter rollover animation. /// Easing for the counter rollover animation.
/// </summary> /// </summary>
protected virtual EasingTypes RollingEasing => EasingTypes.None; protected virtual EasingTypes RollingEasing => EasingTypes.Out;
private T displayedCount; private T displayedCount;

View File

@ -79,7 +79,7 @@ namespace osu.Game.Overlays.Toolbar
Direction = FlowDirection.HorizontalOnly, Direction = FlowDirection.HorizontalOnly,
Anchor = Anchor.TopCentre, Anchor = Anchor.TopCentre,
Origin = Anchor.TopCentre, Origin = Anchor.TopCentre,
Padding = new MarginPadding { Left = 15, Right = 15 }, Padding = new MarginPadding { Left = 20, Right = 20 },
Spacing = new Vector2(5), Spacing = new Vector2(5),
RelativeSizeAxes = Axes.Y, RelativeSizeAxes = Axes.Y,
AutoSizeAxes = Axes.X, AutoSizeAxes = Axes.X,

View File

@ -67,12 +67,10 @@ namespace osu.Game.Screens.Play
} }
sourceClock = (IAdjustableClock)track ?? new StopwatchClock(); sourceClock = (IAdjustableClock)track ?? new StopwatchClock();
Clock = new InterpolatingFramedClock(sourceClock);
Schedule(() => Schedule(() =>
{ {
sourceClock.Reset(); sourceClock.Reset();
sourceClock.Start();
}); });
var beatmap = Beatmap.Beatmap; var beatmap = Beatmap.Beatmap;
@ -103,6 +101,7 @@ namespace osu.Game.Screens.Play
{ {
new PlayerInputManager(game.Host) new PlayerInputManager(game.Host)
{ {
Clock = new InterpolatingFramedClock(sourceClock),
PassThrough = false, PassThrough = false,
Children = new Drawable[] Children = new Drawable[]
{ {
@ -113,6 +112,21 @@ namespace osu.Game.Screens.Play
}; };
} }
protected override void LoadComplete()
{
base.LoadComplete();
Delay(250, true);
Content.FadeIn(250);
Delay(500, true);
Schedule(() =>
{
sourceClock.Start();
});
}
private void hitRenderer_OnAllJudged() private void hitRenderer_OnAllJudged()
{ {
Delay(1000); Delay(1000);
@ -130,12 +144,8 @@ namespace osu.Game.Screens.Play
base.OnEntering(last); base.OnEntering(last);
(Background as BackgroundModeBeatmap)?.BlurTo(Vector2.Zero, 1000); (Background as BackgroundModeBeatmap)?.BlurTo(Vector2.Zero, 1000);
}
protected override void Update() Content.Alpha = 0;
{
base.Update();
Clock.ProcessFrame();
} }
class PlayerInputManager : UserInputManager class PlayerInputManager : UserInputManager

View File

@ -61,7 +61,6 @@ namespace osu.Game.Screens.Select
(beatmapInfoContainer = new BufferedContainer (beatmapInfoContainer = new BufferedContainer
{ {
Depth = newDepth, Depth = newDepth,
PixelSnapping = true,
CacheDrawnFrameBuffer = true, CacheDrawnFrameBuffer = true,
Shear = -Shear, Shear = -Shear,
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,

View File

@ -25,6 +25,7 @@ using OpenTK.Graphics;
using osu.Game.Screens.Play; using osu.Game.Screens.Play;
using osu.Framework; using osu.Framework;
using osu.Framework.Audio.Sample; using osu.Framework.Audio.Sample;
using osu.Framework.Graphics.Transformations;
using osu.Game.Beatmaps.Drawables; using osu.Game.Beatmaps.Drawables;
using osu.Game.Graphics.Containers; using osu.Game.Graphics.Containers;
@ -188,6 +189,12 @@ namespace osu.Game.Screens.Select
changeBackground(Beatmap); changeBackground(Beatmap);
Content.FadeInFromZero(250); Content.FadeInFromZero(250);
beatmapInfoWedge.MoveTo(wedged_container_start_position + new Vector2(-100, 50));
beatmapInfoWedge.RotateTo(10);
beatmapInfoWedge.MoveTo(wedged_container_start_position, 800, EasingTypes.OutQuint);
beatmapInfoWedge.RotateTo(0, 800, EasingTypes.OutQuint);
} }
protected override void OnResuming(GameMode last) protected override void OnResuming(GameMode last)
@ -197,16 +204,23 @@ namespace osu.Game.Screens.Select
base.OnResuming(last); base.OnResuming(last);
Content.FadeIn(250); Content.FadeIn(250);
Content.ScaleTo(1, 250, EasingTypes.OutSine);
} }
protected override void OnSuspending(GameMode next) protected override void OnSuspending(GameMode next)
{ {
Content.ScaleTo(1.1f, 250, EasingTypes.InSine);
Content.FadeOut(250); Content.FadeOut(250);
base.OnSuspending(next); base.OnSuspending(next);
} }
protected override bool OnExiting(GameMode next) protected override bool OnExiting(GameMode next)
{ {
beatmapInfoWedge.MoveTo(wedged_container_start_position + new Vector2(-100, 50), 800, EasingTypes.InQuint);
beatmapInfoWedge.RotateTo(10, 800, EasingTypes.InQuint);
Content.FadeOut(100); Content.FadeOut(100);
return base.OnExiting(next); return base.OnExiting(next);
} }