only accept start from player 1
This commit is contained in:
@@ -12,7 +12,9 @@
|
|||||||
#include "song.h"
|
#include "song.h"
|
||||||
#include "ScoreKeeperNormal.h"
|
#include "ScoreKeeperNormal.h"
|
||||||
#include "PercentageDisplay.h"
|
#include "PercentageDisplay.h"
|
||||||
|
#include "LocalizedString.h"
|
||||||
|
#include "InputEventPlus.h"
|
||||||
|
#include "ScreenManager.h"
|
||||||
|
|
||||||
static const char *MultiplayerJudgeLineNames[] = {
|
static const char *MultiplayerJudgeLineNames[] = {
|
||||||
"W1",
|
"W1",
|
||||||
@@ -260,11 +262,33 @@ void ScreenEvaluationMultiplayer::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
ScreenWithMenuElements::HandleScreenMessage( SM );
|
ScreenWithMenuElements::HandleScreenMessage( SM );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static LocalizedString ONLY_PLAYER_1_CAN_CONTINUE ("ScreenJoinMultiplayer", "Only Player 1 can continue.");
|
||||||
void ScreenEvaluationMultiplayer::Input( const InputEventPlus &input )
|
void ScreenEvaluationMultiplayer::Input( const InputEventPlus &input )
|
||||||
{
|
{
|
||||||
if( this->IsTransitioning() )
|
if( this->IsTransitioning() )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if( input.type == IET_FIRST_PRESS &&
|
||||||
|
input.DeviceI.device >= DEVICE_JOY1 &&
|
||||||
|
input.DeviceI.device < DEVICE_JOY1 + NUM_MultiPlayer &&
|
||||||
|
input.MenuI.IsValid() )
|
||||||
|
{
|
||||||
|
switch( input.MenuI.button )
|
||||||
|
{
|
||||||
|
case MENU_BUTTON_START:
|
||||||
|
if( input.mp != MultiPlayer_1 )
|
||||||
|
{
|
||||||
|
SCREENMAN->SystemMessage( ONLY_PLAYER_1_CAN_CONTINUE );
|
||||||
|
SCREENMAN->PlayInvalidSound();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
MenuStart( GAMESTATE->m_MasterPlayerNumber );
|
||||||
|
}
|
||||||
|
return; // input handled
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ScreenWithMenuElements::Input( input );
|
ScreenWithMenuElements::Input( input );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user