1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-07 09:27:24 +08:00
Commit Graph

1963 Commits

Author SHA1 Message Date
Naxess
e9dfa2860a Add xmldoc note about path being relative 2021-04-20 13:44:06 +02:00
Naxess
d7a81471c8 Add xmldoc to GetPathForFile 2021-04-20 13:40:38 +02:00
Naxess
0e6b66f457
Merge branch 'master' into bg-audio-quality-checks 2021-04-20 02:36:13 +02:00
Naxess
1478bcfa8e Improve xmldoc consistency 2021-04-20 02:30:27 +02:00
Naxess
67e4fe4284 Add xmldoc to GetStream 2021-04-20 02:28:38 +02:00
Naxess
f168247254 Add Track as a property to IWorkingBeatmap
This is implemented by `WorkingBeatmap` already, and is much better to use than loading the track every time we need it.
2021-04-20 01:35:41 +02:00
Bartłomiej Dach
d5829fe638 Merge branch 'master' into playlist-unicode 2021-04-19 19:24:04 +02:00
Dean Herbert
a10a8680d0 Add new display for timing row attributes 2021-04-19 16:23:06 +09:00
PercyDan54
38a7c590c4
Make versionString private 2021-04-18 20:57:25 +08:00
PercyDan54
646403b826
Fix CI errors 2021-04-18 10:54:42 +08:00
PercyDan54
cfaaf2e83e
Add ToRomanisableString() 2021-04-18 09:52:25 +08:00
Naxess
bf8789528a Add GetStream to IWorkingBeatmap 2021-04-18 01:13:57 +02:00
Naxess
b36da2664c Add GetPathForFile to BeatmapSetInfo
This is used in several places, and so should probably have a function rather than remaining as duplicated code.

Also applies this together with the previous commit to `BeatmapManagerWorkingBeatmap`.
2021-04-17 17:49:10 +02:00
Naxess
400f8b3938 Add GetStream to IWorkingBeatmap
This is necessary to obtain the filesize of the audio and background files.
2021-04-17 17:47:13 +02:00
Dean Herbert
be08b9d1ef Combine logic of Difficulty and Timing pieces where feasible 2021-04-14 20:55:34 +09:00
Dean Herbert
a8df2388eb Update design for TimingControlPoint 2021-04-14 20:11:47 +09:00
Dean Herbert
b5954a55ad Remove empty <returns> xmldoc 2021-04-12 17:46:14 +09:00
Dean Herbert
1dbc7e821e
Merge branch 'master' into add-slider-whistle 2021-04-09 17:11:48 +09:00
smoogipoo
9b0ce2999f Fix legacy encoder 2021-04-09 15:28:42 +09:00
smoogipoo
8293b06c0a Remove obsolete code 2021-04-09 13:56:58 +09:00
Leon Gebler
dd902441b0 Add tests for consecutive perfect-curve segments 2021-04-06 13:32:17 +02:00
Leon Gebler
d81f270e21 Always encode perfect curves as explicit segments 2021-04-06 13:29:31 +02:00
smoogipoo
a2544100d4 Fix floating point error in slider path encoding 2021-04-06 14:10:59 +09:00
smoogipoo
d0510222ae Fix legacy beatmap encoding 2021-04-05 19:59:54 +09:00
PercyDan54
dde255980b
Fix formatting 2021-04-03 12:45:42 +08:00
PercyDan54
bd7da9eb39
Make beatmap title use unicode 2021-04-03 12:43:17 +08:00
Dean Herbert
6d4d574a65 Fix exported replay filenames not having full metadata 2021-04-02 14:10:25 +09:00
Dean Herbert
4f8edcd336 Don't strip comments from metadata during parsin 2021-03-25 13:35:54 +09:00
Bartłomiej Dach
a16c0641b2 Revert EF Core to version 2.2
This reverts commit f3faad74d5, reversing
changes made to 712e7bc7bf.

Several issues arose after migrating to 5.0, including, but possibly not
limited to, performance regressions in song select, as well as failures
when attempting to save beatmaps after metadata changes in the editor.
2021-03-21 11:05:15 +01:00
Dean Herbert
0195d654ca Increase the precision of speed multiplier to match osu-stable 2021-03-19 17:09:49 +09:00
Dan Balasescu
53ae24db9b
Merge pull request #12058 from peppy/fix-whitespace-in-ini
Fix skin parser not stripping whitespace before parsing
2021-03-18 18:46:28 +09:00
Dean Herbert
5b0d75ee56 Only trim trailing spaces to avoid breakage in storyboard parsing 2021-03-18 16:30:30 +09:00
Dean Herbert
bb3c3f302a Fix skin parser not stripping whitespace before parsing 2021-03-18 15:36:11 +09:00
Dean Herbert
eda891223c Start the editor with empty artist/creator/difficulty name fields 2021-03-17 16:47:12 +09:00
Dean Herbert
f3faad74d5
Merge pull request #12003 from UselessToucan/ef_core_5 2021-03-15 15:05:32 +09:00
Dean Herbert
6d4c1ba2ae Fix a couple of new inspections introduced in Rider EAPs 2021-03-15 13:35:08 +09:00
Roman Kapustin
0a1e325fc7 Extract requerying of navigational properties from DbContext 2021-03-14 19:34:53 +03:00
Roman Kapustin
47b80d2474 Workaround InvalidOperation exceptions 2021-03-11 20:51:54 +03:00
Dean Herbert
b1cd01ceb8 Apply ConfigureAwait changes to game side 2021-03-08 14:36:35 +09:00
Dean Herbert
103dd4a6ce Remove WorkingBeatmap's finalizer 2021-03-02 16:14:43 +09:00
Dan Balasescu
46ea0f44eb
Merge branch 'master' into beatmap-difficulty-cache-nullable 2021-02-25 22:52:15 +09:00
Dean Herbert
5fa9bf61b6 Update xmldoc 2021-02-25 16:22:40 +09:00
Dean Herbert
03771ce8ec Allow determining a BeatmapDifficultyCache's bindable return's completion state via nullability 2021-02-25 16:19:01 +09:00
smoogipoo
dff1d80f39 Update HasFlag usages to HasFlagFast 2021-02-25 15:38:56 +09:00
Dean Herbert
dfedea9ea2 Move preview point logic to a specific method in WorkingBeatmap 2021-02-18 14:55:44 +09:00
Dean Herbert
e7308193e7 Add xmldoc explaining how PreviewTime is intended to work 2021-02-18 13:03:29 +09:00
Dean Herbert
a080a9bdbc
Merge pull request #11603 from Game4all/handle-stable-imports-custom-songs-folder
Handle beatmap import from a stable installation with a custom Songs directory
2021-02-12 21:42:36 +09:00
smoogipoo
a1be3c8bfd Fix header background being invisible in multiplayer/playlists 2021-02-12 15:27:37 +09:00
Dean Herbert
5f23bd7259 Revert most of the changes to ArchiveModeManager by using better code 2021-02-12 12:48:32 +09:00
smoogipoo
18e3f8c233 Sort beat lengths rather than linear search 2021-02-08 19:03:19 +09:00
smoogipoo
b40b159acb Round beatlength 2021-02-08 18:52:50 +09:00
smoogipoo
69ca440ae5 Merge branch 'master' into more-accurate-most-common-bpm 2021-02-08 18:40:58 +09:00
Bartłomiej Dach
b9a49d5589 Coerce undefined animation loop types to Forever 2021-01-31 15:43:58 +01:00
Dean Herbert
16f3d1815f Fix SQLite exception thrown is a beatmap lookup is attempted without an OnlineBeatmapID present
It turns out the SQLite API isn't smart enough to handle nullables
directly, so we need to help it out a bit.

Stops the following from being thrown:

```
System.InvalidOperationException: Value must be set.
   at Microsoft.Data.Sqlite.SqliteParameter.Bind(sqlite3_stmt stmt) = 3
at
   at Microsoft.Data.Sqlite.SqliteParameterCollection.Bind(sqlite3_stmt
stmt) = 3 at
   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior
behavior)
   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader()
   at
osu.Game.Beatmaps.BeatmapManager.BeatmapOnlineLookupQueue.checkLocalCache(BeatmapSetInfo
set, BeatmapInfo beatmap) in
/Users/dean/Projects/osu/osu.Game/Beatmaps/BeatmapManager_BeatmapOnlineLookupQueue.cs:line
166 = 166
```
2021-01-29 19:53:57 +09:00
Dean Herbert
c3d4044017 Avoid using Dapper to fix iOS compatibility of beatmap lookup cache 2021-01-28 16:53:56 +09:00
Lucas A
383c40b992 Address remaining reviews suggestions. 2021-01-26 20:35:42 +01:00
Lucas A
9f9206726a Fix typos. 2021-01-26 18:11:54 +01:00
Dean Herbert
4ac362ee1a Move cloning local to editor 2021-01-25 18:29:00 +09:00
Dean Herbert
f054b38105 Merge branch 'master' into revert-beatmap-controlpointinfo-cloning 2021-01-25 18:25:53 +09:00
Lucas A
51d4da565c Fix ArchiveModelManagers lookup paths. 2021-01-24 22:25:49 +01:00
Salman Ahmed
acfb2d2980 Refactor beatmap set covers into using ModelBackedDrawable<T> 2021-01-24 00:32:33 +03:00
Salman Ahmed
d83abfa7d2 Add test scene with failing test case 2021-01-24 00:32:20 +03:00
Dean Herbert
edb6d3907b
Merge pull request #11472 from frenzibyte/explicit-beatmap-markers
Add explicit content markers to beatmap panels and overlay
2021-01-17 21:44:10 +09:00
Dean Herbert
d6e6b4bbee Revert forced cloning of ControlPointInfo
This reverts commit 3c3e860dbc.

Closes https://github.com/ppy/osu/issues/11491.
2021-01-15 17:34:59 +09:00
smoogipoo
24e991a5ef Actually return beat length and not BPM 2021-01-15 14:35:09 +09:00
smoogipoo
c6e9a6cd5a Make most common BPM more accurate 2021-01-15 14:28:49 +09:00
Dean Herbert
8a0b975d71 Fix deadlock scenario when calculating fallback difficulty
The previous code would run a calcaulation for the beatmap's own ruleset
if the current one failed. While this does make sense, with the current
way we use this component (and the implementation flow) it is quite unsafe.

The to the call on `.Result` in the `catch` block, this would 100%
deadlock due to the thread concurrency of the `ThreadedTaskScheduler`
being 1. Even if the nested run could be run inline (it should be), the
task scheduler won't even get to the point of checking whether this is
feasible due to it being saturated by the already running task.

I'm not sure if we still need this fallback lookup logic. After removing
it, it's feasible that 0 stars will be returned during the scenario that
previously caused a deadlock, but I don't necessarily think this is
incorrect. There may be another reason for this needing to exist which
I'm not aware of (diffcalc?) but if that's the case we may want to move
the try-catch handling to the point of usage.

To reproduce the deadlock scenario with 100% success (the repro
instructions in the linked issue aren't that simple and require some
patience and good timing), the main portion of the lookup can be changed
to randomly trigger a nested lookup:

```
if (RNG.NextSingle() > 0.5f)
    return GetAsync(new
DifficultyCacheLookup(key.Beatmap, key.Beatmap.Ruleset,
key.OrderedMods)).Result;
else
    return new StarDifficulty(attributes);
```

After switching beatmap once or twice, pausing debug and viewing the
state of threads should show exactly what is going on.
2021-01-14 18:25:34 +09:00
Salman Ahmed
e8daea91d2 Add online beatmap "explicit content" property 2021-01-13 12:13:14 +03:00
smoogipoo
9a22df2b88 Fix BPM multiplier not working in all cases 2021-01-12 17:50:22 +09:00
Dean Herbert
3c3e860dbc Move ControlPointInfo copying to base Beatmap.Clone method (and remove setter) 2021-01-07 23:52:04 +09:00
Dean Herbert
00dc98e3ab Make legacy control point's BpmMultiplier setter private again 2021-01-07 19:06:52 +09:00
Dean Herbert
69ac22dd7f Fix incorrectly copy pasted xmldoc 2021-01-07 19:06:10 +09:00
Dean Herbert
31a6e9b860 Remove unused using 2021-01-05 14:24:49 +09:00
Dean Herbert
afab35a31a Fix missing copy implementation in LegacySampleControlPiont 2021-01-05 13:41:31 +09:00
Dean Herbert
caa88c6100 Use CreateCopy instead of Clone interface
I was going for conformity by using the IClonable interface, but it
doesn't look like we use it anywhere else in the project.
2021-01-05 13:13:52 +09:00
Dean Herbert
ba4e411422 Clone and copy ControlPointInfo when retrieving a playable beatmap 2021-01-04 16:37:07 +09:00
Dean Herbert
d7279dab40
Merge pull request #11226 from peppy/fix-legacy-skin-texture-loader-store
Fix incorrectly provided texture loader store to skins
2020-12-23 16:41:01 +09:00
Dean Herbert
807c1ecd1f Refactor recommendation iteration code to read better 2020-12-22 14:57:32 +09:00
Dean Herbert
8cc2ed3fae Move from OsuGameBase to OsuGame
Also moves to a more suitable namespace.
2020-12-22 14:28:27 +09:00
Dean Herbert
85518b4d99 Enforce non-null for BeatmapManager WorkingBeatmap resources 2020-12-22 12:06:10 +09:00
Dean Herbert
a97a2b2a66 Add nullability to BeatmapManager's GameHost reference 2020-12-22 12:03:25 +09:00
Dean Herbert
10c2745682 Add region specifications around implicit interface implementations 2020-12-22 12:01:09 +09:00
Dean Herbert
a5bcf1dc20 Expose resources to skin via interface (and share common pieces with beatmap) 2020-12-21 15:18:52 +09:00
Dean Herbert
0ffbe12fcc Expose resources to beatmaps in a saner way 2020-12-21 14:22:34 +09:00
Dean Herbert
7c804be4d3 Rename textureStore to make its purpose more clear 2020-12-21 14:06:33 +09:00
Dean Herbert
a35060ea7a Add a simple cache-busting query string to online.db retrieval
As we are finally pushing updates for this database, this adds a minimum
level of guarantee that a client will request a new version (without
having to worry about multiple levels of server-side caching).
2020-12-11 17:56:02 +09:00
smoogipoo
2150cf1c52 Rename parameters 2020-12-02 10:55:48 +09:00
smoogipoo
5760e1c1fc Make HitSampleInfo immutable 2020-12-01 15:37:51 +09:00
Dean Herbert
25af091409 Fix storyboard animations of very old beatmaps playing too slow
Closes https://github.com/ppy/osu/issues/10772.
2020-11-12 17:03:43 +09:00
Dean Herbert
6cc0bf17a9 Add explicit lock object and some xmldoc for clarity 2020-11-10 14:31:52 +09:00
smoogipoo
66ea1572c7 Fix unsafe list manipulation in BeatmapDifficultyCache 2020-11-10 01:10:00 +09:00
Dan Balasescu
a2877fb00a
Merge pull request #10730 from peppy/fix-patcher-no-object-crash
Fix legacy patcher crash on no objects present
2020-11-09 18:51:00 +09:00
Bartłomiej Dach
6d4bb4316c Fix difficulty retrieval for online-sourced beatmaps 2020-11-08 00:12:25 +01:00
Dean Herbert
c5b6908e71 Always write [HitObjects] to file
I think this is expected. If not, there's an alternative solution.
2020-11-08 00:18:27 +09:00
Dean Herbert
c1c3d37720 Remove non-null assert 2020-11-06 17:24:28 +09:00
Dean Herbert
f51cb0dd14 Add ruleset fallback logic into cache lookup class 2020-11-06 16:58:53 +09:00
Dean Herbert
c5b172d0dd Remove synchronous lookup path from BeatmapDifficultyCache 2020-11-06 14:53:15 +09:00
Dean Herbert
b69ada64e8 Update BeatmapDifficultyCache to use base implementation logic 2020-11-06 14:31:21 +09:00
Dean Herbert
517a656899 Move StarDifficulty to own file 2020-11-06 13:51:25 +09:00
Dean Herbert
74ca2faa31 Remove unused using 2020-11-06 13:48:06 +09:00