From d79a5e31ddf20bb8abdc7b397489e5e5bf223232 Mon Sep 17 00:00:00 2001 From: MinaciousGrace Date: Fri, 9 Jun 2017 22:16:34 -0400 Subject: [PATCH] fix inability to skip screeninit --- src/ScreenAttract.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/ScreenAttract.cpp b/src/ScreenAttract.cpp index 719bcc504d..32b71df164 100644 --- a/src/ScreenAttract.cpp +++ b/src/ScreenAttract.cpp @@ -82,6 +82,18 @@ bool ScreenAttract::AttractInput( const InputEventPlus &input, ScreenWithMenuEle break; // fall through case GAME_BUTTON_START: + case GAME_BUTTON_COIN: + // If we're not in a game and there aren't enough credits to start, + // eat the input and do nothing. + if( pScreen->IsTransitioning() ) + return false; + + // HandleGlobalInputs() already played the coin sound. Don't play it again. + if( input.MenuI != GAME_BUTTON_COIN ) + SCREENMAN->PlayStartSound(); + + pScreen->Cancel( SM_GoToStartScreen ); + return true; default: break; }