diff --git a/osu.Game.Rulesets.Mania/Beatmaps/Patterns/Legacy/DistanceObjectPatternGenerator.cs b/osu.Game.Rulesets.Mania/Beatmaps/Patterns/Legacy/DistanceObjectPatternGenerator.cs index 2d1f75e196..7e9615a703 100644 --- a/osu.Game.Rulesets.Mania/Beatmaps/Patterns/Legacy/DistanceObjectPatternGenerator.cs +++ b/osu.Game.Rulesets.Mania/Beatmaps/Patterns/Legacy/DistanceObjectPatternGenerator.cs @@ -448,7 +448,6 @@ namespace osu.Game.Rulesets.Mania.Beatmaps.Patterns.Legacy return curveData.RepeatSamples[index]; } - /// /// Constructs and adds a note to a pattern. /// @@ -480,7 +479,6 @@ namespace osu.Game.Rulesets.Mania.Beatmaps.Patterns.Legacy Tail = { Samples = sampleInfoListAt(endTime) } }; - newObject = holdNote; } diff --git a/osu.Game/Graphics/Cursor/CursorTrail.cs b/osu.Game/Graphics/Cursor/CursorTrail.cs index 11475a0f19..754390047f 100644 --- a/osu.Game/Graphics/Cursor/CursorTrail.cs +++ b/osu.Game/Graphics/Cursor/CursorTrail.cs @@ -136,7 +136,7 @@ namespace osu.Game.Graphics.Cursor for (float d = interval; d < distance; d += interval) { - lastPosition = pos1 + direction * d; + lastPosition = pos1 + (direction * d); addPosition(lastPosition.Value); } } @@ -213,7 +213,7 @@ namespace osu.Game.Graphics.Cursor colour.BottomRight.Linear.A = Parts[i].Time + colour.BottomRight.Linear.A; Texture.DrawQuad( - new Quad(pos.X - Size.X / 2, pos.Y - Size.Y / 2, Size.X, Size.Y), + new Quad(pos.X - (Size.X / 2), pos.Y - (Size.Y / 2), Size.X, Size.Y), colour, null, v => Shared.VertexBuffer.Vertices[end++] = v); diff --git a/osu.Game/OsuGame.cs b/osu.Game/OsuGame.cs index 2c952ee514..a8bee97eb4 100644 --- a/osu.Game/OsuGame.cs +++ b/osu.Game/OsuGame.cs @@ -148,7 +148,7 @@ namespace osu.Game RelativeSizeAxes = Axes.Both, }, volume = new VolumeControl(), - overlayContent = new Container{ RelativeSizeAxes = Axes.Both }, + overlayContent = new Container { RelativeSizeAxes = Axes.Both }, new OnScreenDisplay(), new GlobalHotkeys //exists because UserInputManager is at a level below us. { diff --git a/osu.Game/Screens/Menu/Button.cs b/osu.Game/Screens/Menu/Button.cs index fe9f7b4bf6..b874d8bfed 100644 --- a/osu.Game/Screens/Menu/Button.cs +++ b/osu.Game/Screens/Menu/Button.cs @@ -66,7 +66,7 @@ namespace osu.Game.Screens.Menu Scale = new Vector2(0, 1), Size = boxSize, Shear = new Vector2(ButtonSystem.WEDGE_WIDTH / boxSize.Y, 0), - Children = new [] + Children = new[] { new Box { @@ -143,7 +143,7 @@ namespace osu.Game.Screens.Menu StartValue = -10, EndValue = 10, StartTime = startTime, - EndTime = startTime + duration * 2, + EndTime = startTime + (duration * 2), Easing = EasingTypes.InOutSine, LoopCount = -1, LoopDelay = duration * 2 @@ -176,7 +176,7 @@ namespace osu.Game.Screens.Menu StartValue = new Vector2(0, -10), EndValue = Vector2.Zero, StartTime = startTime + duration, - EndTime = startTime + duration * 2, + EndTime = startTime + (duration * 2), Easing = EasingTypes.In, LoopCount = -1, LoopDelay = duration @@ -187,7 +187,7 @@ namespace osu.Game.Screens.Menu StartValue = Vector2.One, EndValue = new Vector2(1, 0.9f), StartTime = startTime + duration, - EndTime = startTime + duration * 2, + EndTime = startTime + (duration * 2), Easing = EasingTypes.In, LoopCount = -1, LoopDelay = duration @@ -197,8 +197,8 @@ namespace osu.Game.Screens.Menu { StartValue = 10, EndValue = -10, - StartTime = startTime + duration * 2, - EndTime = startTime + duration * 4, + StartTime = startTime + (duration * 2), + EndTime = startTime + (duration * 4), Easing = EasingTypes.InOutSine, LoopCount = -1, LoopDelay = duration * 2 @@ -282,10 +282,13 @@ namespace osu.Game.Screens.Menu public ButtonState State { - get { return state; } + get + { + return state; + } + set { - if (state == value) return; diff --git a/osu.Game/Screens/Menu/OsuLogo.cs b/osu.Game/Screens/Menu/OsuLogo.cs index 44b7b6bceb..4ae6f70d6c 100644 --- a/osu.Game/Screens/Menu/OsuLogo.cs +++ b/osu.Game/Screens/Menu/OsuLogo.cs @@ -51,10 +51,7 @@ namespace osu.Game.Screens.Menu public bool Triangles { - set - { - colourAndTriangles.Alpha = value ? 1 : 0; - } + set { colourAndTriangles.Alpha = value ? 1 : 0; } } protected override bool InternalContains(Vector2 screenSpacePos) => logoContainer.Contains(screenSpacePos); @@ -62,10 +59,7 @@ namespace osu.Game.Screens.Menu public bool Ripple { get { return rippleContainer.Alpha > 0; } - set - { - rippleContainer.Alpha = value ? 1 : 0; - } + set { rippleContainer.Alpha = value ? 1 : 0; } } public bool Interactive = true; @@ -237,7 +231,7 @@ namespace osu.Game.Screens.Menu if (beatIndex < 0) return; - logoBeatContainer.ScaleTo(1 - 0.02f * amplitudeAdjust, beat_in_time, EasingTypes.Out); + logoBeatContainer.ScaleTo(1 - (0.02f * amplitudeAdjust), beat_in_time, EasingTypes.Out); using (logoBeatContainer.BeginDelayedSequence(beat_in_time)) logoBeatContainer.ScaleTo(1, beatLength * 2, EasingTypes.OutQuint); @@ -246,7 +240,7 @@ namespace osu.Game.Screens.Menu ripple.ScaleTo(logoAmplitudeContainer.Scale); ripple.Alpha = 0.15f * amplitudeAdjust; - ripple.ScaleTo(logoAmplitudeContainer.Scale * (1 + 0.04f * amplitudeAdjust), beatLength, EasingTypes.OutQuint); + ripple.ScaleTo(logoAmplitudeContainer.Scale * (1 + (0.04f * amplitudeAdjust)), beatLength, EasingTypes.OutQuint); ripple.FadeOut(beatLength, EasingTypes.OutQuint); if (effectPoint.KiaiMode && flashLayer.Alpha < 0.4f) diff --git a/osu.Game/Screens/Play/Player.cs b/osu.Game/Screens/Play/Player.cs index d4b8445ed9..c38ea65f90 100644 --- a/osu.Game/Screens/Play/Player.cs +++ b/osu.Game/Screens/Play/Player.cs @@ -278,7 +278,6 @@ namespace osu.Game.Screens.Play { if (!pauseContainer.IsPaused) decoupledClock.Start(); - }); pauseContainer.Alpha = 0; diff --git a/osu.Game/Screens/Select/BeatmapCarousel.cs b/osu.Game/Screens/Select/BeatmapCarousel.cs index 26820fc388..3f8d6af320 100644 --- a/osu.Game/Screens/Select/BeatmapCarousel.cs +++ b/osu.Game/Screens/Select/BeatmapCarousel.cs @@ -244,7 +244,7 @@ namespace osu.Game.Screens.Select private BeatmapGroup createGroup(BeatmapSetInfo beatmapSet) { - foreach(var b in beatmapSet.Beatmaps) + foreach (var b in beatmapSet.Beatmaps) { if (b.Metadata == null) b.Metadata = beatmapSet.Metadata; diff --git a/osu.Game/Screens/Select/BeatmapDetails.cs b/osu.Game/Screens/Select/BeatmapDetails.cs index abe54375cc..81db49b658 100644 --- a/osu.Game/Screens/Select/BeatmapDetails.cs +++ b/osu.Game/Screens/Select/BeatmapDetails.cs @@ -46,7 +46,11 @@ namespace osu.Game.Screens.Select public BeatmapInfo Beatmap { - get { return beatmap; } + get + { + return beatmap; + } + set { if (beatmap == value) return; @@ -165,7 +169,7 @@ namespace osu.Game.Screens.Select Direction = FillDirection.Vertical, LayoutDuration = 200, LayoutEasing = EasingTypes.OutQuint, - Children = new [] + Children = new[] { description = new MetadataSegment("Description"), source = new MetadataSegment("Source"), @@ -199,9 +203,9 @@ namespace osu.Game.Screens.Select RelativeSizeAxes = Axes.X, AutoSizeAxes = Axes.Y, Direction = FillDirection.Vertical, - Spacing = new Vector2(0,5), + Spacing = new Vector2(0, 5), Padding = new MarginPadding(10), - Children = new [] + Children = new[] { circleSize = new DifficultyRow("Circle Size", 7), drainRate = new DifficultyRow("HP Drain"), @@ -479,7 +483,7 @@ namespace osu.Game.Screens.Select RelativeSizeAxes = Axes.X, AutoSizeAxes = Axes.Y, Direction = FillDirection.Full, - Spacing = new Vector2(5,0), + Spacing = new Vector2(5, 0), Margin = new MarginPadding { Top = header.TextSize } } }; diff --git a/osu.Game/Screens/Tournament/ScrollingTeamContainer.cs b/osu.Game/Screens/Tournament/ScrollingTeamContainer.cs index 3eea239f55..d3d2a18cfa 100644 --- a/osu.Game/Screens/Tournament/ScrollingTeamContainer.cs +++ b/osu.Game/Screens/Tournament/ScrollingTeamContainer.cs @@ -82,7 +82,11 @@ namespace osu.Game.Screens.Tournament private ScrollState _scrollState; private ScrollState scrollState { - get { return _scrollState; } + get + { + return _scrollState; + } + set { if (_scrollState == value) @@ -261,7 +265,7 @@ namespace osu.Game.Screens.Tournament else { c.MoveToX(pos, 100); - c.FadeTo(1.0f - Math.Abs(pos - DrawWidth / 2f) / (DrawWidth / 2.5f), 100); + c.FadeTo(1.0f - (Math.Abs(pos - (DrawWidth / 2f)) / (DrawWidth / 2.5f)), 100); } pos += ScrollingTeam.WIDTH; @@ -328,7 +332,11 @@ namespace osu.Game.Screens.Tournament private bool selected; public bool Selected { - get { return selected; } + get + { + return selected; + } + set { selected = value;