Commit Graph

31570 Commits

Author SHA1 Message Date
f95e753adb Rename double-container variable name 2022-03-13 16:10:06 +09:00
d1a9b88fe7 Fix typo in comment
Co-authored-by: Salman Ahmed <frenzibyte@gmail.com>
2022-03-13 16:05:45 +09:00
9a1ade4f79 Refactor SkinEditor to support switching target screens without full reload 2022-03-11 23:08:40 +09:00
32c7a023f8 Make OsuGame.ScreenChanged private and non-virtual
Just reducing complexity scope here.
2022-03-11 19:54:15 +09:00
398af246a5 Merge branch 'master' into blueprint-container-selected-items-bind 2022-03-11 00:37:45 +01:00
68aedd63a7 Move SelectionHandler's SelectedItems binding to the base implementation
Until now it was up to each implementation to connect
`BlueprintContainer` to its `SelectionHandler`, which didn't make much
sense at all.
2022-03-10 23:22:19 +09:00
e31b174cc2 Merge pull request #17198 from smoogipoo/fix-beatmap-wedge-async-mutation
Fix beatmap wedge possibly applying transforms incorrectly and crashing
2022-03-10 23:12:58 +09:00
cee6a12d0b Merge pull request #17199 from smoogipoo/fix-multiplayer-test-failures
Fix potential multiplayer crash with async disposal
2022-03-10 23:07:05 +09:00
717ddbba4e Fix skin components toolbox not autosizing properly 2022-03-10 16:30:20 +03:00
885cb3ce5b Add current screen checks for added safety 2022-03-10 20:03:02 +09:00
2de7795844 Fix always rolling up from zero
Co-authored-by: Dean Herbert <pe@ppy.sh>
2022-03-10 19:59:05 +09:00
2d135e5be6 Explain purpose of Schedule call in MultiplayerPlayer.onResultsReady 2022-03-10 19:56:13 +09:00
d1f8fd01df Merge pull request #17180 from jai-x/new-chat-channel-listing
Implement `ChannelListing` for new chat design
2022-03-10 19:27:58 +09:00
dfe98c6536 Merge pull request #17162 from peppy/realm-offset-feedback-fix-2
Fix feedback from realm writes causing offset slider to jump around
2022-03-10 18:53:08 +09:00
45d537ef72 Fix potential multiplayer crash with async disposal 2022-03-10 18:50:53 +09:00
671d614c92 Fix beatmap wedge mutating transforms incorrectly 2022-03-10 17:54:33 +09:00
db5c2c15dc Merge pull request #17164 from smoogipoo/scoreprocessor-rework
Rework ScoreProcessor score calculation methods to fix various issues
2022-03-10 16:48:58 +09:00
c61397cc22 Fix whitespace/inspection 2022-03-10 16:22:27 +09:00
13a4058efd Merge pull request #17191 from peppy/fix-mod-conversion-exceptions
Change `ToMod` to return an `UnknownMod` rather than throw if a mod isn't available
2022-03-10 16:20:50 +09:00
cf91353009 Merge branch 'master' into scoreprocessor-rework 2022-03-10 16:14:28 +09:00
46f2db1712 Move ChannelListingItem spacing into item so input is always handled by an item in the list
Without this change, there would be a couple of pixels between each list
item where nothing would be hovered. This is a pretty annoying UX which
we should be avoiding we possible.
2022-03-10 15:58:57 +09:00
1a187d4dec Add animation to checkbox when joning/leaving a channel 2022-03-10 15:54:42 +09:00
0155519343 Merge branch 'master' into new-chat-channel-listing 2022-03-10 15:49:06 +09:00
eaef27595c Also mark UnknownMod as not user-playable 2022-03-10 15:33:50 +09:00
03d7d1e6ca Merge pull request #17195 from smoogipoo/classic-score-multiplier
Tune classic mod scaling per-ruleset
2022-03-10 14:32:52 +09:00
c17dba4948 Merge pull request #17193 from peppy/update-dependencies
Update dependencies
2022-03-10 12:26:13 +09:00
c36badab4b Add per-ruleset score multipliers for classic scoring 2022-03-10 10:26:09 +09:00
b67f9269f9 Remove NewChat namespace 2022-03-09 18:13:56 +00:00
94ff6a338f Merge branch 'master' into scoreprocessor-rework 2022-03-09 23:04:18 +09:00
df500dec04 Merge pull request #17187 from smoogipoo/fix-playlist-copy
Fix unable to copy playlist rooms without first opening
2022-03-09 23:03:43 +09:00
5fb51b578f Update dependencies
Mainly for a `Clowd.Squirrel` bump to fix https://github.com/ppy/osu/discussions/17190.
2022-03-09 19:09:51 +09:00
02f44d7061 Merge branch 'master' into fix-mod-conversion-exceptions 2022-03-09 18:07:42 +09:00
2eb3365f46 Fix regressing issues when attempting to exit Player after an unsuccessful beatmap load 2022-03-09 17:57:58 +09:00
1ee0be5e39 Ensure gameplay can't start when an UnknownMod is present 2022-03-09 17:57:58 +09:00
0267aed846 Change ToMod to return an UnknownMod rather than throw if a mod isn't available
As seen by this kind of crash, having the `.ToMod` method throw can be
very problematic and also hidden (as it is used inside of models in
places where exceptions are not expected to occur).

Given there are tens of usages of this method, returning a placeholder
mod seems like a better idea than outright throwing.

```
 An unhandled has occurred.
 System.InvalidOperationException:
There is no mod in the ruleset (osu) matching the acronym AS.
 at osu.Game.Online.API.APIMod.ToMod(Ruleset ruleset) in /Users/dean/Projects/osu/osu.Game/Online/API/APIMod.cs:line 54
 at osu.Game.Scoring.ScoreInfo.<get_Mods>b__117_0(APIMod m) in /Users/dean/Projects/osu/osu.Game/Scoring/ScoreInfo.cs:line 193
 at System.Linq.Enumerable.SelectArrayIterator`2.ToArray()
 at osu.Game.Scoring.ScoreInfo.get_Mods() in /Users/dean/Projects/osu/osu.Game/Scoring/ScoreInfo.cs:line 193
 at osu.Game.Screens.Select.Leaderboards.BeatmapLeaderboard.<>c.<subscribeToLocalScores>b__40_2(ScoreInfo s) in /Users/dean/Projects/osu/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs:line 199
 at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
 at osu.Game.Database.RealmObjectExtensions.Detach[T](IEnumerable`1 items) in /Users/dean/Projects/osu/osu.Game/Database/RealmObjectExtensions.cs:line 180
 at osu.Game.Screens.Select.Leaderboards.BeatmapLeaderboard.<>c__DisplayClass40_0.<subscribeToLocalScores>g__localScoresChanged|1(IRealmCollection`1 sender, ChangeSet changes, Exception exception) in /Users/dean/Projects/osu/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs:line
209
 at Realms.RealmCollectionBase`1.Realms.INotifiable<Realms.NotifiableObjectHandleBase.CollectionChangeSet>.NotifyCallbacks(Nullable`1 changes, Nullable`1 exception)
 at Realms.NotifiableObjectHandleBase.NotifyObjectChanged(IntPtr managedHandle, IntPtr changes, IntPtr exception)
```
2022-03-09 17:57:55 +09:00
8bb07f83cd Merge pull request #17054 from hlysine/mod-adaptive-speed
Implement Adaptive Speed mod
2022-03-09 17:56:34 +09:00
4839bd8044 Notify if copying room fails
Co-authored-by: Dean Herbert <pe@ppy.sh>
2022-03-09 16:47:47 +09:00
520d2d6cfa Fix beatmap carousel panels accepting input while marked as not-visible
This is an issue as carousel panels manage their own animated state. If
they are marked as not-visible (done at a higher level, from filtering
or update pathways) but clicked while fading out, they will animate back
to a visible state but not be marked as visible.

No tests for this one as it's probably not worthwhile to test (and hard
to do so). Manual testing can be done with the following patch:

```diff
diff --git a/osu.Game/Screens/Select/BeatmapCarousel.cs
b/osu.Game/Screens/Select/BeatmapCarousel.cs
index c3d340ac61..3372242acc 100644
--- a/osu.Game/Screens/Select/BeatmapCarousel.cs
+++ b/osu.Game/Screens/Select/BeatmapCarousel.cs
@@ -255,7 +255,7 @@ private void
beatmapSetsChanged(IRealmCollection<BeatmapSetInfo> sender, ChangeS
             }

             foreach (int i in changes.NewModifiedIndices)
-                UpdateBeatmapSet(sender[i].Detach());
+                Scheduler.AddDelayed(() =>
                 UpdateBeatmapSet(sender[i].Detach()), 100, true);

             foreach (int i in changes.InsertedIndices)
                 UpdateBeatmapSet(sender[i].Detach());

```

- Enter gameplay and adjust beatmap offset then return to song select
  and click the flashing panel.
OR
- Enter editor and save then return to song select and click the
  flashing panel.

Closes https://github.com/ppy/osu/discussions/17171.
2022-03-09 16:08:52 +09:00
b07a1e8d09 Fix unable to copy playlist rooms without first opening 2022-03-09 15:38:00 +09:00
ad0ca5673a Fix avatar not clickable after watching replay 2022-03-09 14:39:02 +09:00
6bf436cd62 Only null the realm write task if it actually completed 2022-03-09 13:52:58 +09:00
affcf5180b Merge pull request #17161 from smoogipoo/fix-listing-score-conversion
Fix scores not being recalculated in beatmap overlay
2022-03-09 13:32:45 +09:00
58aef25ad5 Merge pull request #17152 from bdach/mod-overlay/difficulty-multiplier
Implement difficulty multiplier display for new mod select design
2022-03-09 12:11:16 +09:00
b3fd156f10 Merge pull request #17158 from peppy/realm-recover-from-newer-database-version
Add flow to allow recovery after running an older release (with a different realm database version)
2022-03-09 11:30:58 +09:00
7daa2d0ea4 Use correct fonts and colours in ChannelListingItem 2022-03-09 00:36:19 +00:00
7dd51a9c4a Reorder class attributes 2022-03-09 00:12:44 +00:00
a3477c3841 Implement ChannelListing for new chat design
Adds components `ChannelListing` and `ChannelListing` item with visual
test. Essentially a more simplified version of the existing
`ChannelSelectionOverlay` component.

Correctly implements `IFilterable` behaviour to filter child channel
items. Channel joined state is based on the underlying `Joined` bindable
of the `Channel` class.

Channel join/leave events are exposed via `OnRequestJoin` and
`OnRequestLeave` events which should be handled by parent component.

Requires a cached `OverlayColourScheme` instance to be provided by the
parent overlay component when added.
2022-03-08 22:30:58 +00:00
a2ef086c1f Fix potential crash on rare incorrect firing of skin dropdown update methods
As brought to light by https://gist.github.com/smoogipoo/56eda7ab56b9d1966556f2ca7a80a847.

There's a chance that the dropdown is not populated by the time
`updateSelectedSkinFromConfig` is fired via an external means (config
changes).
2022-03-09 01:08:13 +09:00
6fd8b4d891 Safeguard method against invalid invocation 2022-03-08 22:30:44 +09:00
f1c40bd9ed Rework GetScore() method signatures + implementations
Rename legacy-facing overload to mention as much
2022-03-08 22:30:44 +09:00