Added MeasureInfo calculations, and loader/writer for #MEASUREINFO cache
This commit is contained in:
@@ -383,6 +383,30 @@ void SetRadarValues(StepsTagInfo& info)
|
||||
}
|
||||
info.ssc_format= true;
|
||||
}
|
||||
|
||||
void SetMeasureInfo(StepsTagInfo& info)
|
||||
{
|
||||
if (info.from_cache || info.for_load_edit)
|
||||
{
|
||||
std::vector<RString> values;
|
||||
split((*info.params)[1], "|", values, true);
|
||||
|
||||
MeasureInfo v[NUM_PLAYERS];
|
||||
FOREACH_PlayerNumber(pn)
|
||||
{
|
||||
v[pn].FromString(values[pn]);
|
||||
|
||||
}
|
||||
info.steps->SetCachedMeasureInfo(v);
|
||||
}
|
||||
else
|
||||
{
|
||||
// just recalc at time.
|
||||
}
|
||||
info.ssc_format= true;
|
||||
}
|
||||
|
||||
|
||||
void SetCredit(StepsTagInfo& info)
|
||||
{
|
||||
info.steps->SetCredit((*info.params)[1]);
|
||||
@@ -623,6 +647,8 @@ struct ssc_parser_helper_t
|
||||
steps_tag_handlers["SCROLLS"]= &SetStepsScrolls;
|
||||
steps_tag_handlers["FAKES"]= &SetStepsFakes;
|
||||
steps_tag_handlers["LABELS"]= &SetStepsLabels;
|
||||
steps_tag_handlers["MEASUREINFO"] = &SetMeasureInfo;
|
||||
|
||||
/* If this is called, the chart does not use the same attacks
|
||||
* as the Song's timing. No other changes are required. */
|
||||
steps_tag_handlers["ATTACKS"]= &SetStepsAttacks;
|
||||
|
||||
Reference in New Issue
Block a user