UltraStar-Deluxe / Play

Free and open source singing game with song editor for desktop, mobile, and smart TV
https://ultrastar-play.com
MIT License
381 stars 72 forks source link

Change playback position freely during singing #449

Open achimmihca opened 2 months ago

achimmihca commented 2 months ago

Actual behaviour

Currently, one can "skip to next lyrics" when singing. But there is no way to jump back in the song.

Expected behaviour

One should be able to change the playback position freely (forward and backward) via the progress bar, like in other media players.

Note that this would make a dedicated learning mode obsolete: https://steamcommunity.com/app/2394070/discussions/0/4349990283304041849/

Implementation

Changing the playback position of the SongAudioPlayer is not an issue. However, when jumping back in the song, then it should adjust the player's state accordingly, e.g., reset the score and sung notes.

Further, it would be nice if the timebar would show some indication of the position on hover, e.g., the time at this point or the next lyrics. This would make it clearer where the skip will lead before actually doing it.

Kisandara commented 1 month ago

I'm looking forward to this!

basisbit commented 1 month ago

Using this feature should immediately set the collected points for the current song back to 0.

DariusRDev commented 1 month ago

Currently there is my Mod for skipping back and forwards. But it doesn't reset the score.

sheriffkeppo commented 1 month ago

Currently there is my Mod for skipping back and forwards. But it doesn't reset the score.

Unfortunately, it works with some bugs. Sometimes, it skips only the lyrics, leaving the audio intact. And if you scroll back, the lyrics do not return.

DariusRDev commented 1 month ago
singSceneControl.SkipToPosition(singSceneControl.PositionInMillis - secondsToSkip * 1000);

I use this API of the SingSceneControl. So that would be a Bug in SingSceneControl in my opinion.

achimmihca commented 1 month ago

I agree that the score should be reset to the value that the players had at this point in time when skipping backwards.

However, the current skip function was intended to skip forward in the song, so no reset logic has been implemented yet. Note that maybe futher game state may need to be updated when skipping backwards, e.g., the upcoming notes and phrases to show them again.

marwin89 commented 1 month ago

I'm sorry to be so hard, but I think this feature goes in the wrong direction. It blows up the code, making it more complex and messes up the core experience of the game. Is any commercial singing game doing this?

sheriffkeppo commented 1 month ago

I'm sorry to be so hard, but I think this feature goes in the wrong direction. It blows up the code, making it more complex and messes up the core experience of the game. Is any commercial singing game doing this?

This feature is implemented in Smule. it is adapted to the mobile interface. You need to click on the text located at the bottom of the screen, the full text will open along the text lines with the selection line, you need to slide to the desired line in the song and click on the text again to continue the song. In this application, this is implemented to record individual fragments of a song. It seems to me that in Melody Mania this can be used for training

achimmihca commented 1 month ago

From a media player perspective, I think it makes sense to scroll back and forth through the song. A possible UI design for this has already been established by e.g. YouTube.

So I think complexity for this feature is less on the user side and more on the development side. But I would not disqualify this only because it may be tricky to implement.

Taking a step back and rethinking the current implementation might yield a better, more generic solution. Depends on implementation. Anyway, this is not a prio for me.