15 Commits
Author SHA1 Message Date
McSchneidar d48426b04d Fixes for progress bar and applause sounds (#906)
* Control score sounds from UpdateGame instead of the thread pool

_PlayProgressBarSound started a Task that waited for the progress bar
duration and then closed whatever stream was stored in
_ProgressBarSoundStream. When switching rounds on the score screen
before that time had passed, an old task closed the progress bar
sound of the new round too early and played the applause of the
previous round, while the applause of the new round never played.

Remember when the progress bar sound was started and check it in
UpdateGame on the main thread instead. Starting a new progress bar
sound and leaving the screen now also stop a running applause.

* Sync progress bar sound with the score bar animation

The sound duration was computed from the points (10,000 points =
5 seconds), while the bar animation duration depends on the bar size
in the theme and only starts when the bar is first drawn. Both only
matched approximately and drifted apart with other themes.

Add CProgressBar.AnimatesMovement and CProgressBar.IsAnimating. The
score screen now stops the progress bar sound and starts the applause
as soon as no visible score bar is animating anymore. If the theme
has no movement animation, the previous duration is used.

* Make stream id allocation in CPlaybackBase thread-safe

Load assigned stream ids with _NextId++ outside of the lock. Load is
also called from other threads, so two streams could get the same id
and a later Close or Play could hit the wrong stream.

Use Interlocked.Increment instead. Ids still start at 0.

* Do not play the progress bar sound for 0 points

With 0 points the score bars do not move, so the progress bar sound
started and stopped again right away, which could be heard as a short
click. Do not start it at all if the highest score is 0.
2026-10-16 05:21:34 +02:00
Quentin Bray 6ffa63b923 Apply R# clean-up for reliability (#877)
* Apply R# clean-up for reliability

- Migrate to NUnit4 Assert.That
- Update dependencise versions
- Fix LangVersion to 9.0 (until net core migration)
- Reformat code
- Apply 'var' style (easier for refactoring)
- Remove redundant parentheses
- Add braces on every condition blocks (1 line)
- Uses new null checking patterns
- Uses AutoProperties when possible
- Uses string scalar type instead of class
- Clean usings
- Add .orig files in git ignore
- Rename some properties to respect defined conventions and US format definition
	- ID -> Id
	- BPM -> Bpm
	- Finish -> End

* Update R# settings according to the clean-up made
2026-06-22 19:52:06 +02:00
Edi316andFlorian Ostertag f6e56f70b9 Elevating sound for Progress Bar on Score screen (#772)
* Speed Fix

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Update Applause Sound

* Update Applause Sound

* Update Applause Sound

* Update Applause Sound

* Add Elevating Sound

* Add Elevating Sound

* Add Elevating Sound

* Speed Fix

* Add Elevating Sound

---------

Co-authored-by: Florian Ostertag <flokuep@users.noreply.github.com>
2025-04-21 07:54:29 +02:00
GRaff844 4b253c2c8d Reset Animation (#726) 2024-11-14 20:54:53 +01:00
GRaff844 160fbac07c Fix Animation for Progress Bar (#725) 2024-11-13 06:01:21 +01:00
Jiiniasu 53d22b1082 Merge remote-tracking branch 'refs/remotes/Vocaluxe/develop' into Multimonitor
Modify CProgressBar to transfer properties to code-generated progressbars that does not exist in the screen xml
2017-09-23 15:28:25 +02:00
Florian Küpper 770247248e Removed old theme loading after merge 2017-09-12 08:26:34 +02:00
Florian Küpper 08ba18053e Fixed alpha wasn't applied to progress 2017-09-10 12:33:34 +02:00
Florian Küpper 9acfcfb7da Fixed wrong color of rating-bar 2017-09-10 11:44:53 +02:00
Florian Küpper 5dfdad61c4 Use ProgressBar on ScoreScreen, removed unused stuff 2017-09-10 11:17:21 +02:00
Florian Küpper 6ebbfb37bd Finished progress bar animation 2017-09-10 10:16:48 +02:00
Florian Küpper 742332b92d Fixed rating bar size calculation 2017-09-09 17:14:58 +02:00
Florian Küpper e82ffd7f31 Added possibility to define progress colors 2017-09-07 23:44:05 +02:00
Florian Küpper 22338194b5 Respect ratio of bar left/right textures 2017-09-07 22:28:25 +02:00
Florian Küpper 222cc0ba03 initial work on rating bar 2017-09-07 22:14:53 +02:00