Removes all tap notes except for those with PLAYER_INVALID and those matching that player.

This commit is contained in:
Steve Checkoway
2006-07-09 20:11:46 +00:00
parent e830771ad9
commit 025997d453
2 changed files with 18 additions and 0 deletions
+17
View File
@@ -893,6 +893,23 @@ void NoteDataUtil::RemoveAllButOneTap( NoteData &inout, int row )
}
}
void NoteDataUtil::RemoveAllButPlayer( NoteData &inout, PlayerNumber pn )
{
for( int track = 0; track < inout.GetNumTracks(); ++track )
{
NoteData::iterator i = inout.begin( track );
while( i != inout.end(track) )
{
if( i->second.pn != pn && i->second.pn != PLAYER_INVALID )
inout.RemoveTapNote( track, i++ );
else
++i;
}
}
}
static void GetTrackMapping( StepsType st, NoteDataUtil::TrackMapping tt, int NumTracks, int *iTakeFromTrack )
{
// Identity transform for cases not handled below.