mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 10:12:54 +08:00
Move default sample addition to inside PlacementBlueprint
This isn't actually required to fix the behaviour but it does feel like a better place to put this logic.
This commit is contained in:
parent
db79080bc4
commit
e9730d4782
@ -7,6 +7,7 @@ using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Input.Events;
|
||||
using osu.Game.Audio;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Beatmaps.ControlPoints;
|
||||
using osu.Game.Rulesets.Objects;
|
||||
@ -45,6 +46,9 @@ namespace osu.Game.Rulesets.Edit
|
||||
{
|
||||
HitObject = hitObject;
|
||||
|
||||
// adding the default hit sample should be the case regardless of the ruleset.
|
||||
HitObject.Samples.Add(new HitSampleInfo(HitSampleInfo.HIT_NORMAL));
|
||||
|
||||
RelativeSizeAxes = Axes.Both;
|
||||
|
||||
// This is required to allow the blueprint's position to be updated via OnMouseMove/Handle
|
||||
|
@ -211,9 +211,6 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
|
||||
if (blueprint != null)
|
||||
{
|
||||
// doing this post-creations as adding the default hit sample should be the case regardless of the ruleset.
|
||||
blueprint.HitObject.Samples.Add(new HitSampleInfo(HitSampleInfo.HIT_NORMAL));
|
||||
|
||||
placementBlueprintContainer.Child = currentPlacement = blueprint;
|
||||
|
||||
// Fixes a 1-frame position discrepancy due to the first mouse move event happening in the next frame
|
||||
|
Loading…
Reference in New Issue
Block a user