1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 18:37:27 +08:00
Commit Graph

90 Commits

Author SHA1 Message Date
Dean Herbert
f060e6a780 Implement hold "sliding" samples in osu!mania 2022-10-11 16:31:37 +09:00
Dan Balasescu
e0c82d11ab Convert == usages to ReferenceEquals 2022-06-20 16:56:19 +09:00
Dan Balasescu
f8830c6850 Automated #nullable processing 2022-06-17 16:37:17 +09:00
Dean Herbert
8676a2587c Add the ability for HitObjects to specify auxiliary samples 2022-03-14 17:19:48 +09:00
Bartłomiej Dach
afce976f08
Fix oversubscription to StartTimeBindable.ValueChanged 2022-01-12 19:29:49 +01:00
Bartłomiej Dach
80ccff9068
Remove no longer necessary guards against default control points
The subscription in which the guards were present was moved from
constructor to `ApplyDefaults()`, and at that point neither the sample
control point or the difficulty point can be the default point, because
there are explicit paths that overwrite those with blank points in the
same methods, prior to the subscription's registration.

The only worry would be that someone would set the default point on the
object themselves, but at that point that is most likely programmer
error anyhow.
2022-01-11 22:14:47 +01:00
Bartłomiej Dach
7a25fe79b7
Fix sample control point time being calculated before defaults applied
In editor contexts, the `StartTimeBindable` subscription in `HitObject`
was firing before defaults were applied, which in the case of sliders
manifested in an infinite end time. `ApplyDefaults()` also did not
always set the time of the control point to the correct value, which
matters when the beatmap is encoded.

Ensure that the control points receive the correct time values during
default application, and only register the `StartTimeBindable` change
callback after defaults have been successfully applied.
2022-01-11 21:38:59 +01:00
Dean Herbert
dae7cdc4c5 Ensure HitObject-local control points are non-default after ApplyDefaults
We will probably want to make this whole flow more efficient in the
future, but this should suffice for now.
2021-10-26 16:06:03 +09:00
smoogipoo
bc37cb6f43 Merge branch 'master' into no-more-difficulty-control-points-info 2021-10-08 18:41:17 +09:00
Dean Herbert
a92d499d7a Convert usages of BeatmapDifficulty to IBeatmapDifficultyInfo 2021-10-01 16:55:50 +09:00
Dean Herbert
46bafb6252 Merge branch 'master' into no-more-difficulty-control-points-info 2021-09-28 13:53:56 +09:00
Dean Herbert
16e60eed56 Reduce NestedHitObject enumerator overhead
This was especially bad due to it allocating on any and every start time
change, even the first (see usage in `HitObject.ctor`).
2021-09-20 15:09:27 +09:00
Dean Herbert
a7ae3cc03e Change SampleControlPoint time to use leniency in bindable changed event too 2021-09-14 16:24:55 +09:00
Dean Herbert
cd227213e6 Ensure time of HitObject related ControlPoints are kept in sync with the hitobject 2021-09-10 15:59:30 +09:00
Dean Herbert
714f55b6bc Clone control points when copying to HitObjects 2021-09-10 14:36:39 +09:00
Dean Herbert
6894ed3426 Fix new ordering of retrieval meaning EndTime is not available in time 2021-09-03 17:11:12 +09:00
Dean Herbert
74f385bad8 Assign default control points earlier in HitObject construction 2021-09-03 17:11:12 +09:00
Dean Herbert
1aff4c2238 Ensure all hitobject level control points are populated before calling virtual defaults application 2021-09-03 17:11:12 +09:00
Dean Herbert
b41b1e2394 Write out DifficultyControlPoints into HitObjects 2021-09-03 16:58:16 +09:00
Dean Herbert
d988aa1680 Actually serialise SampleControlPoints along with HitObjects 2021-08-31 15:14:03 +09:00
Dean Herbert
4da2dca339 Apply the default SampleControlPoint if not externally provided
This is mostly to handle tests for now, as generally this should be
provided by an external source in all other cases.
2021-08-30 17:21:07 +09:00
Dean Herbert
ccacf56dd8 Move to legacy namespace 2021-08-30 17:14:53 +09:00
Dean Herbert
7257aae7f2 Move samples to LegacyControlPointInfo 2021-08-30 17:14:53 +09:00
Salman Ahmed
523c154f15 Add ComboIndexWithOffsetsBindable and bind similar to ComboIndexBindable 2021-07-22 16:40:33 +03:00
smoogipoo
8293b06c0a Remove obsolete code 2021-04-09 13:56:58 +09:00
Dean Herbert
a8151d5c63 Fix HitWindows getting serialized alongside HitObjects
These were being serialized as the base type. On deserialization, due to
the HitWindow of objects being non-null, they would not get correctly
initialised by the CreateHitWindows() virtual method.

- Closes #10403
2020-10-07 13:45:42 +09:00
smoogipoo
73a7b759cb Add missing obsoletion notice 2020-09-17 17:04:44 +09:00
smoogipoo
f3b5149648 Move some suggestions to warnings, resolve issues 2020-06-03 16:48:44 +09:00
Dean Herbert
cbd563e80b Rename to IHasDuration 2020-05-27 12:38:39 +09:00
smoogipoo
6f4cd6111c Drop obsoletion status for now 2020-05-25 16:50:49 +09:00
smoogipoo
98125102a7 Add cancellation token support to CreateNestedHitObjects() 2020-05-15 18:07:41 +09:00
smoogipoo
efff2bf15d Add HitObject to DefaultsApplied event 2020-05-08 18:49:19 +09:00
Dean Herbert
36079236e6
Remove pointless comment
Co-Authored-By: Dan Balasescu <smoogipoo@smgi.me>
2020-02-25 19:22:51 +09:00
Dean Herbert
a047456354 Revert changes to make HitObject abstract 2020-02-25 19:07:15 +09:00
Dean Herbert
ffc7eaa3f2 Fix hitobjects with unknown lifetimes by enforcing non-null judgement
We've seen multiple cases where DrawableHitObject are stuck in the lifetime management container
due to not implementing a judgement (meaning they are never "hit" or "missed"). To avoid this going forward
CreateJudgement() must be implemented and return a non-null judgement.

This fixes BananaShower and JuiceStreams in osu!catch.

This also makes HitObject abstract and cleans up convert HitObject implementations.
2020-02-23 13:49:06 +09:00
Bartłomiej Dach
434c0d92e4 Use Bindable{Float,Double}s everywhere
To avoid further floating-point comparison bugs, remove all usages of
Bindable<{float,double}>, replacing them with their
Bindable<Float,Double> counterparts.
2020-02-01 22:50:29 +01:00
Huo Yaoyuan
ddb2cfc46d Use GetEndTime in Taiko and Mania 2019-12-14 18:16:13 +08:00
Dean Herbert
709ec1404f Centralise End/StartTime retrieval to extension method 2019-11-25 19:09:14 +09:00
smoogipoo
6fc1be64c2 Make hitobject samples a bindable list 2019-11-08 14:04:57 +09:00
smoogipoo
9a896d52bf Fix nested hitobjects not updating 2019-10-18 13:18:41 +09:00
Dean Herbert
51bf600ea7 Use empty hitwindows instead of null 2019-10-09 19:08:31 +09:00
smoogipoo
897b3233af Add start time tracking to EditorBeatmap 2019-10-03 14:23:48 +09:00
smoogipoo
45f2bcc440 Fix combo bindings not being bound to nested hitobjects 2019-09-26 17:39:19 +09:00
Dean Herbert
f925e781a9 Refactor HitWindows for legibility 2019-09-06 15:24:14 +09:00
smoogipoo
f20e07136a Add attribute to catch potential future nullrefs 2019-09-02 17:48:41 +09:00
smoogipoo
f6102b4d92 Adjust xmldoc 2019-09-02 17:15:36 +09:00
Dean Herbert
60ea3d4e1a Fix skinning support for combobreak 2019-06-30 21:58:30 +09:00
smoogipoo
0bd35ab7bb Turn on warnings, resolve issues 2019-04-25 17:36:17 +09:00
Dean Herbert
8617aaa2a7 Update licence header (and remove year) 2019-01-24 17:43:03 +09:00
smoogipoo
9fdd48ded2 Add 1ms offset to controlpoint lookup times 2018-12-04 12:08:46 +09:00