本文整理汇总了C#中Track.Add方法的典型用法代码示例。如果您正苦于以下问题:C# Track.Add方法的具体用法?C# Track.Add怎么用?C# Track.Add使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Track
的用法示例。
在下文中一共展示了Track.Add方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: method_2
public ChartParser method_2(GH3Song gh3Song_1)
{
ChartParser @class = new ChartParser(this.gh3Song_0);
@class.constant480 = this.int_1;
if (gh3Song_1 != null)
{
@class.gh3SongInfo.vmethod_0(gh3Song_1);
}
this.class228_6 = new Track<int, int>();
if (this.class239_0 != null)
{
int value = this.class239_0[0];
this.class239_0[0] = 0;
int num = 0;
for (int i = 1; i < this.class239_0.Count; i++)
{
int num2 = this.class239_0[i] - this.class239_0[i - 1];
int num3 = Convert.ToInt32(60000000.0 / (double)num2);
if (num3 != num)
{
@class.bpmInterpreter.bpmList.Add((i - 1) * this.int_1, num3);
num = num3;
}
this.class228_6.Add(this.class239_0[i - 1], num2);
}
this.class239_0[0] = value;
@class.sectionInterpreter.otherList.Add(this.method_0(this.class239_0[this.class239_0.Count - 1]), new List<string>(new string[]
{
"end"
}));
foreach (int current in this.class228_1.Keys)
{
@class.sectionInterpreter.sectionList.Add(this.method_0(current), this.class228_1[current]);
}
foreach (int current2 in this.tsList.Keys)
{
@class.bpmInterpreter.TSList.Add(this.method_0(current2), this.tsList[current2][0]);
}
Track<int, int> class2 = new Track<int, int>();
Track<int, int> class3 = new Track<int, int>();
foreach (int current3 in this.class228_2.Keys)
{
int num4 = this.method_0(current3);
int num5 = this.method_0(current3 + this.class228_2[current3] - this.int_0) - num4;
class2.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
}
foreach (int current4 in this.class228_3.Keys)
{
int num4 = this.method_0(current4);
int num5 = this.method_0(current4 + this.class228_3[current4] - this.int_0) - num4;
class3.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
}
Track<int, int> class4 = new Track<int, int>();
Track<int, int> class5 = new Track<int, int>();
foreach (int current5 in this.bpmList.Keys)
{
int num4 = this.method_0(current5);
int num5 = this.method_0(current5 + this.bpmList[current5] - this.int_0) - num4;
class4.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
}
foreach (int current6 in this.class228_5.Keys)
{
int num4 = this.method_0(current6);
int num5 = this.method_0(current6 + this.class228_5[current6] - this.int_0) - num4;
class5.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
}
string[] array = new string[]
{
"Easy",
"Medium",
"Hard",
"Expert"
};
string[] array2 = new string[]
{
"Single",
"Double"
};
for (int j = 0; j < array2.Length; j++)
{
string text = array2[j];
string[] array3 = new string[]
{
"Guitar",
"Rhythm"
};
for (int k = 0; k < array3.Length; k++)
{
string text2 = array3[k];
string[] array4 = array;
for (int l = 0; l < array4.Length; l++)
{
string text3 = array4[l];
string key = (text2.ToLower() + ((text == "Double") ? "coop" : "") + "_" + text3.ToLower()).Replace("guitar_", "");
if (this.noteList.ContainsKey(key))
{
NoteEventInterpreter class6 = new NoteEventInterpreter();
Track<int, NotesAtOffset> class7 = this.noteList[key];
foreach (int current7 in class7.Keys)
{
//.........这里部分代码省略.........
示例2: QBCParser
//.........这里部分代码省略.........
this.gh3Song_0.hammer_on = Convert.ToSingle(text4);
break;
case "originalartist":
this.gh3Song_0.original_artist = text4.Equals("true");
break;
case "resolution":
this.int_1 = Convert.ToInt32(text4);
break;
}
}
}
goto IL_A3C;
}
goto IL_514;
case 1:
goto IL_514;
case 2:
goto IL_5AE;
case 3:
using (List<string>.Enumerator enumerator2 = list.GetEnumerator())
{
while (enumerator2.MoveNext())
{
string current2 = enumerator2.Current;
string[] array2 = current2.Split(new char[]
{
' ',
'\t',
'='
}, StringSplitOptions.RemoveEmptyEntries);
string a;
if ((a = array2[1]) != null && a == "S")
{
this.class228_1.Add(Convert.ToInt32(array2[0]), array2[2]);
}
}
goto IL_A3C;
}
break;
case 4:
break;
case 5:
goto IL_72D;
case 6:
goto IL_7AC;
case 7:
goto IL_82B;
default:
goto IL_8AA;
}
using (List<string>.Enumerator enumerator3 = list.GetEnumerator())
{
while (enumerator3.MoveNext())
{
string current3 = enumerator3.Current;
string[] array3 = current3.Split(new char[]
{
' ',
'\t',
'='
}, StringSplitOptions.RemoveEmptyEntries);
string a2;
if ((a2 = array3[1]) != null && a2 == "F")
{
this.class228_2.Add(Convert.ToInt32(array3[0]), Convert.ToInt32(array3[2]));
}
示例3: method_6
private void method_6(Track<int, int> class228_1, Track<int, int> class228_2)
{
if (class228_2 == null)
{
return;
}
foreach (int current in class228_2.Keys)
{
int num = this.calculateOffset(current);
int value = (class228_2[current] == 0) ? 1 : (this.calculateOffset(current + class228_2[current]) - num);
class228_1.Add(num, value);
}
}
示例4: method_5
private void method_5(Track<int, int[]> difficulty, Track<int, int> sp, Track<int, NotesAtOffset> notes)
{
foreach (int current in sp.Keys)
{
int num = this.calculateOffset(current);
int num2 = 0;
if (sp[current] == 0)
{
num2 = 1;
}
else
{
int num4 = 0;
if ((sp.Keys[sp.method_1(current + sp[current])] > current))
{
num4 = notes.Keys[notes.method_1(sp.Keys[sp.method_1(current + sp[current])] - 1)];
}
else
{
num4 = (current + sp[current]);
}
int num3 = this.calculateOffset(num4);
//int num3 = this.method_2((sp.Keys[sp.method_1(current + sp[current])] > current) ? notes.Keys[notes.method_1(sp.Keys[sp.method_1(current + sp[current])] - 1)] : (current + sp[current]));
num2 = (num3 - num);
}
//int num2 = (sp[current] == 0) ? 1 : (this.method_2((sp.Keys[sp.method_1(current + sp[current])] > current) ? notes.Keys[notes.method_1(sp.Keys[sp.method_1(current + sp[current])] - 1)] : (current + sp[current])) - num);
difficulty.Add(num, new int[]
{
num2,
notes.method_3(current, current + sp[current])
});
}
}
示例5: method_4
private void method_4(Track<int, NotesAtOffset> class228_1, Track<int, NotesAtOffset> class228_2)
{
foreach (int current in class228_2.Keys)
{
int num = this.calculateOffset(current);
int int_ = (class228_2[current].sustainLength == 0) ? 1 : (this.calculateOffset(current + class228_2[current].sustainLength) - num);
if (class228_1.ContainsKey(num))
{
for (int i = 0; i < 32; i++)
{
if (class228_2[current].noteValues[i])
{
class228_1[num].noteValues[i] = true;
}
}
}
else
{
class228_1.Add(num, new NotesAtOffset(class228_2[current].noteValues, int_));
}
}
}