StyleI.player duplicates MenuI.player when the style is set. It's
essentially being used as a hack to see if the style is set, and as a shortcut for converting from StyleInput back to GameInput, complicating InputEventPlus in the process. Remove it, and just pass along the PlayerNumber when it's actually needed. (incremental commit)
This commit is contained in:
@@ -831,7 +831,7 @@ bool InputMapper::IsBeingPressed( const MenuInput &MenuI )
|
||||
return false;
|
||||
}
|
||||
|
||||
bool InputMapper::IsBeingPressed( const StyleInput &StyleI, MultiPlayer mp )
|
||||
bool InputMapper::IsBeingPressed( const StyleInput &StyleI, PlayerNumber pn, MultiPlayer mp )
|
||||
{
|
||||
GameInput GameI;
|
||||
StyleToGame( StyleI, GameI );
|
||||
@@ -870,7 +870,7 @@ float InputMapper::GetSecsHeld( const MenuInput &MenuI )
|
||||
return fMaxSecsHeld;
|
||||
}
|
||||
|
||||
float InputMapper::GetSecsHeld( const StyleInput &StyleI, MultiPlayer mp )
|
||||
float InputMapper::GetSecsHeld( const StyleInput &StyleI, PlayerNumber pn, MultiPlayer mp )
|
||||
{
|
||||
GameInput GameI;
|
||||
StyleToGame( StyleI, GameI );
|
||||
|
||||
Reference in New Issue
Block a user