Add two routine mirroring functions.
I think the Alter Menu is getting a bit big. Maybe I should borrow from the help menus...they scroll nicely.
This commit is contained in:
@@ -13,6 +13,11 @@ StepMania 5.0 ????????? | 20110???
|
|||||||
* [ScreenEdit] Add a function to switch the notes the routine players have to
|
* [ScreenEdit] Add a function to switch the notes the routine players have to
|
||||||
hit. In simple terms, Player 1's notes are now Player 2's and vice~versa.
|
hit. In simple terms, Player 1's notes are now Player 2's and vice~versa.
|
||||||
Check it out in the Alter Menu. [Wolfman2000]
|
Check it out in the Alter Menu. [Wolfman2000]
|
||||||
|
* [ScreenEdit] Add two routine mirroring functions. Now you can build sections
|
||||||
|
of a chart for one player, and mirror the effect for the other player when
|
||||||
|
finished. For Pump players, it is not a straight mirror, but is more akin
|
||||||
|
to what is found via normal routine charts. In other words, you'll be happy.
|
||||||
|
Check it out in the Alter Menu. [Wolfman2000]
|
||||||
|
|
||||||
2011/07/03
|
2011/07/03
|
||||||
----------
|
----------
|
||||||
|
|||||||
@@ -932,6 +932,8 @@ MenuTimer=Menu Timer
|
|||||||
Meter=Meter
|
Meter=Meter
|
||||||
Min BPM=Min Specified BPM
|
Min BPM=Min Specified BPM
|
||||||
Mines=Mines
|
Mines=Mines
|
||||||
|
Mirror Player 1 to 2=Mirror P1's notes to P2 (routine only)
|
||||||
|
Mirror Player 2 to 1=Mirror P2's notes to P1 (routine only)
|
||||||
MoveRandomToEnd=Random At End
|
MoveRandomToEnd=Random At End
|
||||||
More Options=More Options
|
More Options=More Options
|
||||||
MovieColorDepth=Movie Color
|
MovieColorDepth=Movie Color
|
||||||
|
|||||||
+58
-2
@@ -568,6 +568,10 @@ static MenuDef g_AlterMenu(
|
|||||||
MenuRowDef(ScreenEdit::convert_to_fake, "Convert selection to fake", true,
|
MenuRowDef(ScreenEdit::convert_to_fake, "Convert selection to fake", true,
|
||||||
EditMode_Full, true, true, 0, NULL ),
|
EditMode_Full, true, true, 0, NULL ),
|
||||||
MenuRowDef(ScreenEdit::routine_invert_notes, "Invert notes' player", true,
|
MenuRowDef(ScreenEdit::routine_invert_notes, "Invert notes' player", true,
|
||||||
|
EditMode_Full, true, true, 0, NULL ),
|
||||||
|
MenuRowDef(ScreenEdit::routine_mirror_1_to_2, "Mirror Player 1 to 2", true,
|
||||||
|
EditMode_Full, true, true, 0, NULL ),
|
||||||
|
MenuRowDef(ScreenEdit::routine_mirror_2_to_1, "Mirror Player 2 to 1", true,
|
||||||
EditMode_Full, true, true, 0, NULL )
|
EditMode_Full, true, true, 0, NULL )
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -1759,7 +1763,10 @@ void ScreenEdit::InputEdit( const InputEventPlus &input, EditButton EditB )
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
g_AlterMenu.rows[routine_invert_notes].bEnabled = (m_InputPlayerNumber != PLAYER_INVALID);
|
bool isRoutine = (m_InputPlayerNumber != PLAYER_INVALID);
|
||||||
|
g_AlterMenu.rows[routine_invert_notes].bEnabled = isRoutine;
|
||||||
|
g_AlterMenu.rows[routine_mirror_1_to_2].bEnabled = isRoutine;
|
||||||
|
g_AlterMenu.rows[routine_mirror_2_to_1].bEnabled = isRoutine;
|
||||||
EditMiniMenu(&g_AlterMenu, SM_BackFromAlterMenu);
|
EditMiniMenu(&g_AlterMenu, SM_BackFromAlterMenu);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -4082,7 +4089,56 @@ void ScreenEdit::HandleAlterMenuChoice(AlterMenuChoice c, const vector<int> &iAn
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case routine_mirror_1_to_2:
|
||||||
|
case routine_mirror_2_to_1:
|
||||||
|
{
|
||||||
|
PlayerNumber oPN = (c == routine_mirror_1_to_2 ?
|
||||||
|
PLAYER_1 : PLAYER_2);
|
||||||
|
PlayerNumber nPN = (c == routine_mirror_1_to_2 ?
|
||||||
|
PLAYER_2 : PLAYER_1);
|
||||||
|
int nTrack = -1;
|
||||||
|
NoteData &nd = this->m_NoteDataEdit;
|
||||||
|
NoteField &nf = this->m_NoteFieldEdit;
|
||||||
|
int tracks = nd.GetNumTracks();
|
||||||
|
FOREACH_NONEMPTY_ROW_ALL_TRACKS_RANGE(nd, r,
|
||||||
|
nf.m_iBeginMarker,
|
||||||
|
nf.m_iEndMarker)
|
||||||
|
{
|
||||||
|
for (int t = 0; t < tracks; t++)
|
||||||
|
{
|
||||||
|
const TapNote &tn = nd.GetTapNote(t, r);
|
||||||
|
if (tn.type != TapNote::empty && tn.pn == oPN)
|
||||||
|
{
|
||||||
|
TapNote nTap = tn;
|
||||||
|
nTap.pn = nPN;
|
||||||
|
StepsType curType = GAMESTATE->m_pCurSteps[PLAYER_1]->m_StepsType;
|
||||||
|
if (curType == StepsType_dance_routine)
|
||||||
|
{
|
||||||
|
nTrack = tracks - t - 1;
|
||||||
|
}
|
||||||
|
else if (curType == StepsType_pump_routine)
|
||||||
|
{
|
||||||
|
switch (t)
|
||||||
|
{
|
||||||
|
case 0: nTrack = 8; break;
|
||||||
|
case 1: nTrack = 9; break;
|
||||||
|
case 2: nTrack = 7; break;
|
||||||
|
case 3: nTrack = 5; break;
|
||||||
|
case 4: nTrack = 6; break;
|
||||||
|
case 5: nTrack = 3; break;
|
||||||
|
case 6: nTrack = 4; break;
|
||||||
|
case 7: nTrack = 2; break;
|
||||||
|
case 8: nTrack = 0; break;
|
||||||
|
case 9: nTrack = 1; break;
|
||||||
|
default: FAIL_M(ssprintf("Invalid column %d for pump-routine", t)); break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
m_NoteDataEdit.SetTapNote(nTrack, r, nTap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -409,6 +409,8 @@ public:
|
|||||||
convert_to_warp, /**< Convert the range into a WarpSegment. */
|
convert_to_warp, /**< Convert the range into a WarpSegment. */
|
||||||
convert_to_fake, /**< Convert the range into a FakeSegment. */
|
convert_to_fake, /**< Convert the range into a FakeSegment. */
|
||||||
routine_invert_notes, /**< Switch which player hits the note. */
|
routine_invert_notes, /**< Switch which player hits the note. */
|
||||||
|
routine_mirror_1_to_2, /**< Mirror Player 1's notes for Player 2. */
|
||||||
|
routine_mirror_2_to_1, /**< Mirror Player 2's notes for Player 1. */
|
||||||
NUM_ALTER_MENU_CHOICES
|
NUM_ALTER_MENU_CHOICES
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user