Commit Graph

1258 Commits

Author SHA1 Message Date
a1e64f4e3c Use the existing toolbox design 2021-04-30 14:41:06 +09:00
ae9d1dc40b Add component list to main editor interface and enable basic placement 2021-04-30 13:10:42 +09:00
6442fb819f Split out component from test scene and fix SongProgress 2021-04-30 13:10:42 +09:00
4770a64709 Add proof of concept components list 2021-04-30 13:10:42 +09:00
de73ac7cec Allow skin editor to be invoked from any context
This is kind of how I see things working going forward, where the editor
can be applied to anything in the game which supports it (ie. a results
screen, gameplay screen, etc.) and it will immediately allow changing
the interface.

This adds a test scene which shows this working with gameplay.
2021-04-29 16:12:15 +09:00
74c6fdc4b8 Add DrawableRuleset to the skin editor test to get a hit error meter to display 2021-04-29 16:12:15 +09:00
fd587a82ff Replace abstract class with interface, attached to the actual components (not skinnable wrapper) 2021-04-29 16:12:15 +09:00
defa350aa7 Set defaults on SkinnableHUDComponent to cancel out relative size default
Specifying locally on each HUD component looks to make more sense.
2021-04-29 16:12:15 +09:00
1cb8fc9a24 Extract editor classes out of test namespace and add anchor support 2021-04-29 16:12:15 +09:00
74fb7cd180 Extract storable attributes to bindables 2021-04-29 16:12:15 +09:00
99b428ee4b Add very basic skin editor test 2021-04-29 16:12:14 +09:00
fca173225a Refactor editor selection/blueprint components to be generic 2021-04-29 16:12:14 +09:00
2d17219c8f Setup basic test and classes for scale adjustment 2021-04-29 16:12:14 +09:00
120fb8974d Combine more instances of test player IDs 2021-04-26 17:22:16 +09:00
daafa41dc1 Merge branch 'master' into fix-initial-spectator-state-callback 2021-04-22 16:22:04 +09:00
e78ef05fcf Merge branch 'gcc-abstraction' into multiplayer-spectator-screen 2021-04-21 17:11:14 +09:00
156a518068 Merge branch 'master' into fix-initial-spectator-state-callback 2021-04-20 21:16:05 +09:00
c5d6b6ea8d Fix tests failing intermittently
This was due to this code happening in UpdateAfterChildren(), after the
GCC has processed one frame. During this time, the clock could have
advanced an arbitrary amount.

The cause of this is the removal of the Task.Run() to set the clock in
Restart() (now called Reset()) which changed the timing, so it only worked before due to pure
luck.
2021-04-20 18:41:09 +09:00
80473a356e Merge branch 'fix-pre-seek-sample-lifetime' into gcc-abstraction 2021-04-20 17:27:01 +09:00
c12848ce4d Apply fixes to tests 2021-04-19 17:02:59 +09:00
fd1241cc85 Added tests
New tests:
- storyboard ending during the failing animation
- showResults = false
- storyboard ending before score processor completion

Co-Authored-By: Marlina José <marlina@umich.edu>
2021-04-18 23:26:50 -04:00
98460c8feb Rename IStoryboardElementHasDuration, remove unnecessary step in tests, add Duration field 2021-04-18 20:20:14 -04:00
7b1d40db7d Remove redundant string interpolation 2021-04-17 22:13:28 -04:00
e9f8fa64b8 Added a test for toggling the storyboard after the map is loaded 2021-04-17 21:49:29 -04:00
7f5b1e84a1 Update TestSceneStoryboardWithOutro.cs
- Construct storyboard in CreateWorkingBeatmap()
- Use GameplayClockContainer.GameplayClock.CurrentTime
- Remove unnecessary lines
2021-04-17 13:57:32 -04:00
5e82f40d67 Merge branch 'master' into gcc-abstraction 2021-04-16 20:14:53 +09:00
65a6f9f8a4 Merge branch 'fix-initial-spectator-state-callback' into multiplayer-spectator-screen 2021-04-16 18:26:46 +09:00
46d2181d42 Remove now unnecessary (duplicating) test 2021-04-16 18:21:56 +09:00
377e5ce6b3 Fix test incorrect sending state too often 2021-04-16 18:21:35 +09:00
ca74f413cd Change to explicit method instead 2021-04-16 17:31:02 +09:00
5652490d61 Fix OnUserBeganPlaying not being invoked if already watching 2021-04-16 14:11:55 +09:00
b15838b220 Move storyboard outro logic to DrawableStoryboard 2021-04-16 00:59:10 -04:00
45c2b72a25 Merge branch 'master' into play-storyboard-outro 2021-04-15 15:11:35 -04:00
25b8c2f257 Allow skipping storyboard outro
Reuses SkipOverlay by calculating the endtime of the storyboard and using that as a "start point". Upon skipping the outro the score is instantly shown.
When the end of the storyboard is reached the score screen automatically shows up. If the player holds ESC (pause) during the outro, the score is displayed

The storyboard endtime is calculated by getting the latest endtime of the storyboard's elements, or simply returning 0 if there is no storyboard.

Co-Authored-By: Marlina José <marlina@umich.edu>
2021-04-15 13:20:40 -04:00
ac8e462d32 Merge branch 'master' into refactor-framed-replay-input-hander 2021-04-15 21:48:58 +09:00
5b06a68b93 Merge pull request #12330 from Cublibre/master
Send a warning notification if device is unplugged and at low battery
2021-04-15 19:21:04 +09:00
346e36d32a Make Mod.Description abstract and add missing descriptions 2021-04-15 14:36:26 +09:00
1aa36818df Abstractify GameplayClockContainer 2021-04-14 17:47:11 +09:00
f66306a81a Remove IsLowBattery 2021-04-12 11:15:24 -04:00
43b97fe0ad Refactor PowerStatus (now called BatteryInfo) 2021-04-12 10:52:52 -04:00
359fae895f Rename property 2021-04-12 18:50:25 +09:00
e19e8ff2a3 Rewrite FramedReplayInputHandler for robustness
This commit changes the semantics of `CurrentFrame` and `NextFrame` of the class.
The ordering of `NextFrame.Time` and `CurrentFrame.Time` was dependent on the current direction.
Now, it should always satisfy `CurrentFrame.Time <= CurrentTime <= NextFrame.Time` except at the start/end.
This change, however, doesn't break existing deriving classes if the template code pattern usage of interpolation is used.
The deriving class code can be simplified due to the elimination of nullable types. I didn't include those changes in this commit.

I removed `StreamingFramedReplayInputHandlerTest` for now, as it is almost-duplicate of `FramedReplayInputHandlerTest`. I'll include more tests in later commits.

This commit fixes #6150.
2021-04-12 16:18:11 +09:00
d6d8ea5b6b Throw when getting a frame of an empty replay 2021-04-12 11:17:56 +09:00
cb947a3b27 Add expected output in test case rather than determining internally 2021-04-11 13:18:25 -04:00
1fd4cb8963 Merge branch 'master' into master 2021-04-11 10:19:16 +03:00
08311abc5e Remove setters, cache CreatePowerStatus() and use a dummy LocalPowerStatus class in test scene 2021-04-10 00:00:21 -04:00
59d13b0dd3 Fixed indentation
sorry about the style fixes... I'm using JetBrains Rider from now on.
2021-04-08 21:53:42 -04:00
6b6a71d3c3 trim whitespace 2021-04-08 20:39:17 -04:00
493c095535 Fixed code style 2021-04-08 20:28:23 -04:00
6bccb3aab6 Use DI to implement battery detection, add BatteryCutoff property
- Removed the Xamarin.Essentials package from osu.Game and added it to osu.iOS and osu.Android only.
- iOS and Android implementations use Xamarin.Essentials.Battery, while the Desktop implementation
only returns 100% battery for now.
- Added a BatteryCutoff property to PowerStatus so it can be different for each platform (default 20%, 25% on iOS)
2021-04-08 19:55:11 -04:00