1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-15 14:37:30 +08:00
Commit Graph

21 Commits

Author SHA1 Message Date
OliBomby
0a78eb9628
Implement auto additions editor-only 2024-10-01 16:40:48 +09:00
Bartłomiej Dach
e8a394f894
Fix argon volume-aware hitsounds not correctly playing immediately after object placement
Closes https://github.com/ppy/osu/issues/29832.

The underlying reason for the incorrect sample playback was an equality
comparer failure.

Samples are contained in several pools which are managed by the
playfield. In particular, the pools are keyed by `ISampleInfo`
instances. This means that for correct operation, `ISampleInfo` has to
implement `IEquatable<ISampleInfo>` and also provide an appropriately
correct `GetHashCode()` implementation. Different audible samples must
not compare equal to each other when represented by `ISampleInfo`.

As it turns out, `VolumeAwareHitSampleInfo` failed on this, due to not
overriding equality members. Therefore, a `new
HitSampleInfo(HitSampleInfo.HIT_NORMAL, HitSampleInfo.BANK_NORMAL,
volume: 70)` was allowed to compare equal to a
`VolumeAwareHitSampleInfo` wrapping it, *even though they correspond to
completely different sounds and go through entirely different lookup
path sequences*.

Therefore, to fix, provide more proper equality implementations for
`VolumeAwareHitSampleInfo`.

When testing note that this issue *only occurs immediately after
placing an object*. Saving and re-entering editor makes this issue go
away. I haven't looked too long into why, but the general gist of it is
ordering; it appears that a `normal-hitnormal` pool exists at point
of query of a new object placement, but does not seem to exist when
entering editor afresh. That said I'm not sure that ordering aspect of
this bug matters much if at all, since the two `IHitSampleInfo`s should
never be allowed to alias with each other at all wrt equality.
2024-09-23 13:38:26 +02:00
Jamie Taylor
27d78fdb08
Add fallback to find spinner samples without a bank prefix 2024-03-09 01:10:28 +09:00
Dean Herbert
27af07b74b Add basic implementation of argon osu!taiko hitsounds (volume / flourish / strong) 2023-07-05 18:44:27 +09:00
Dean Herbert
298989ffd2 Merge branch 'master' into sample-set-controls 2023-05-24 14:03:04 +09:00
Dean Herbert
510ebe1f23 Fix weird optional usage in HitSampleInfo.With 2023-05-17 14:11:52 +09:00
Dean Herbert
a8bc337006 Change default volume when constructing a HitSampleInfo to non-zero 2023-05-17 14:06:02 +09:00
Dean Herbert
83dcd78826 Make HitSampleInfo.Bank non-nullable 2023-05-16 18:12:56 +09:00
Dean Herbert
579d5b51eb Add and consume sample bank constants 2022-10-19 20:47:58 +09:00
Dean Herbert
25028bb7fa Fix editor clap/finish buttons being ordered against expectations 2022-07-19 22:36:11 +09:00
Dan Balasescu
f8830c6850 Automated #nullable processing 2022-06-17 16:37:17 +09:00
smoogipoo
2150cf1c52 Rename parameters 2020-12-02 10:55:48 +09:00
smoogipoo
2840405112 Volume should be 0 by default 2020-12-01 18:14:14 +09:00
smoogipoo
6b4a6c12c8 Fix bad equality comparer implementations 2020-12-01 18:13:53 +09:00
smoogipoo
c61f00525d Ignore lookup types for JSON serialisation 2020-12-01 18:13:53 +09:00
smoogipoo
199710b941 Implement equality comparers for HitSampleInfo 2020-12-01 16:04:08 +09:00
smoogipoo
5760e1c1fc Make HitSampleInfo immutable 2020-12-01 15:37:51 +09:00
Dean Herbert
0b28cca7e6 Don't force Gameplay prefix on all skin sample lookups 2020-10-30 11:59:40 +09:00
Dean Herbert
b8e9f19b92 Move common HitSampleInfo lookup to static method 2020-09-25 17:30:31 +09:00
smoogipoo
0f8a76afde Remove manual hitobject sample namespacing 2020-01-02 14:27:27 +09:00
Dean Herbert
60ea3d4e1a Fix skinning support for combobreak 2019-06-30 21:58:30 +09:00