Merge pull request #1200 from FunkinCrew/bugfix/hide-pause-button-and-bring-resume-back

This commit is contained in:
MoonDroid
2025-06-12 12:00:35 +07:00
committed by GitHub
4 changed files with 18 additions and 4 deletions
+1 -1
Submodule assets updated: 80cabb3d9b...bf85a69507
-2
View File
@@ -80,9 +80,7 @@ class PauseSubState extends MusicBeatSubState
* Pause menu entries for when the game is paused during a video cutscene.
*/
static final PAUSE_MENU_ENTRIES_VIDEO_CUTSCENE:Array<PauseMenuEntry> = [
#if !mobile
{text: 'Resume', callback: resume},
#end
{text: 'Skip Cutscene', callback: skipVideoCutscene},
{text: 'Restart Cutscene', callback: restartVideoCutscene},
{text: 'Exit to Menu', callback: quitToMenu},
+10 -1
View File
@@ -845,6 +845,14 @@ class PlayState extends MusicBeatSubState
refresh();
}
public function togglePauseButton(visible:Bool = false):Void
{
#if mobile
pauseCircle.alpha = visible ? 0.1 : 0;
pauseButton.alpha = visible ? 1 : 0;
#end
}
function assertChartExists():Bool
{
// Returns null if the song failed to load or doesn't have the selected difficulty.
@@ -3153,7 +3161,8 @@ class PlayState extends MusicBeatSubState
#if mobile
// Hide the buttons while the song is ending.
hitbox.visible = pauseButton.visible = false;
hitbox.visible = false;
pauseButton.visible = false;
pauseCircle.visible = false;
#end
@@ -89,6 +89,13 @@ class VideoCutscene
VideoCutscene.cutsceneType = cutsceneType;
#if mobile
if (cutsceneType == ENDING)
{
PlayState.instance.togglePauseButton();
}
#end
#if html5
playVideoHTML5(rawFilePath);
#elseif hxvlc