Example #1
0
 public void method_0()
 {
     byte[] byte_;
     ZIPManager.smethod_3(this.saveLocation, out byte_, "songs.info", "SGH9ZIP2PASS4MXKR");
     zzGenericNode1 @class = new zzGenericNode1("songs", KeyGenerator.smethod_8(byte_, "SNG4AES4KEY9MXKR"));
     foreach (StructurePointerNode class302_ in @class.Nodes)
     {
         GH3Song gH3Song = new GH3Song(class302_);
         gH3Song.editable = true;
         this.gh3SongList.method_0(gH3Song, this.string_0 != null);
     }
     ZIPManager.smethod_3(this.saveLocation, out byte_, "setlist.info", "SGH9ZIP2PASS4MXKR");
     this.setlistToExport.method_1(new GH3Setlist((StructureHeaderNode)new zzGenericNode1("setlist", KeyGenerator.smethod_8(byte_, "SET4AES4KEY9MXKR")).Nodes[0], this.gh3SongList));
     if (this.string_0 != null)
     {
         List<string> list = new List<string>();
         List<string> list2 = new List<string>();
         foreach (GH3Tier current in this.setlistToExport.tiers)
         {
             foreach (GH3Song current2 in current.songs)
             {
                 if (current2.editable)
                 {
                     list.Add(current2.name + "_song.pak.xen");
                     list2.Add(this.string_0 + "songs\\" + current2.name + "_song.pak.xen");
                     list.Add(current2.name + ".dat.xen");
                     list2.Add(this.string_0 + "music\\" + current2.name + ".dat.xen");
                     list.Add(current2.name + ".fsb.xen");
                     list2.Add(this.string_0 + "music\\" + current2.name + ".fsb.xen");
                 }
             }
         }
         ZIPManager.smethod_11(this.saveLocation, list2, list, "SGH9ZIP2PASS4MXKR");
     }
 }
Example #2
0
 public virtual void vmethod_0(Interface16 interface16_0)
 {
     if (interface16_0 is GH3Song)
     {
         GH3Song gH3Song = interface16_0 as GH3Song;
         this.original_artist     = gH3Song.original_artist;
         this.not_bass            = gH3Song.not_bass;
         this.no_rhythm_track     = gH3Song.no_rhythm_track;
         this.use_coop_notetracks = gH3Song.use_coop_notetracks;
         this.keyboard            = gH3Song.keyboard;
         this.band_vol            = gH3Song.band_vol;
         this.guitar_vol          = gH3Song.guitar_vol;
         this.hammer_on           = gH3Song.hammer_on;
         this.gem_offset          = gH3Song.gem_offset;
         this.fretbar_offset      = gH3Song.fretbar_offset;
         this.input_offset        = gH3Song.input_offset;
         this.version             = gH3Song.version;
         this.title       = gH3Song.title;
         this.artist      = gH3Song.artist;
         this.year        = gH3Song.year;
         this.countoff    = gH3Song.countoff;
         this.bassist     = gH3Song.bassist;
         this.singer      = gH3Song.singer;
         this.boss        = gH3Song.boss;
         this.artist_text = gH3Song.artist_text;
     }
 }
Example #3
0
 public SongProperties(string songName)
 {
     this.InitializeComponent();
     this.Song = new GH3Song();
     this.Text = this.Text + " (" + songName + ")";
     this.SingerBox.SelectedIndex = 0;
     this.CountOffBox.SelectedIndex = 0;
     this.BassistBox.SelectedIndex = 0;
     this.BossBox.SelectedIndex = 0;
 }
Example #4
0
 public void qbcCreator(string fileLocation, GH3Song song)
 {
     this.gh3Song_0 = song;
     StreamWriter streamWriter = new StreamWriter(fileLocation);
     streamWriter.WriteLine("[Song]");
     streamWriter.WriteLine("{");
     streamWriter.WriteLine("\tName = \"" + this.gh3Song_0.title + "\"");
     streamWriter.WriteLine("\tArtist = \"" + this.gh3Song_0.artist + "\"");
     streamWriter.WriteLine("\tYear = \"" + this.gh3Song_0.year + "\"");
     streamWriter.WriteLine("\tPlayer2 = " + (this.gh3Song_0.not_bass ? "Rhythm" : "Bass"));
     streamWriter.WriteLine("\tArtistText = \"" + ((this.gh3Song_0.artist_text is bool) ? (((bool)this.gh3Song_0.artist_text) ? "by" : "as made famous by") : ((string)this.gh3Song_0.artist_text)) + "\"");
     streamWriter.WriteLine("\tOffset = " + (double)this.gh3Song_0.input_offset / -1000.0);
     if (!this.gh3Song_0.singer.Equals(""))
     {
         streamWriter.WriteLine("\tSinger = \"" + this.gh3Song_0.singer + "\"");
     }
     if (!this.gh3Song_0.bassist.Equals("Generic Bassist"))
     {
         streamWriter.WriteLine("\tBassist = \"" + this.gh3Song_0.bassist + "\"");
     }
     if (!this.gh3Song_0.boss.Equals(""))
     {
         streamWriter.WriteLine("\tBoss = \"" + this.gh3Song_0.boss + "\"");
     }
     streamWriter.WriteLine("\tCountOff = \"" + this.gh3Song_0.countoff + "\"");
     streamWriter.WriteLine("\tGuitarVol = " + this.gh3Song_0.guitar_vol);
     streamWriter.WriteLine("\tBandVol = " + this.gh3Song_0.band_vol);
     streamWriter.WriteLine("\tHoPo = " + this.gh3Song_0.hammer_on);
     streamWriter.WriteLine("\tOriginalArtist = " + (this.gh3Song_0.original_artist ? "true" : "false"));
     streamWriter.WriteLine("\tResolution = " + this.int_1);
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[SyncTrack]");
     streamWriter.WriteLine("{");
     foreach (int current in this.tsList.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current,
             " = TS ",
             this.tsList[current][0],
             " ",
             this.tsList[current][1]
         }));
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[FretBars]");
     streamWriter.WriteLine("{");
     foreach (int current2 in this.class239_0)
     {
         streamWriter.WriteLine("\t" + current2);
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[Events]");
     streamWriter.WriteLine("{");
     foreach (int current3 in this.class228_1.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current3,
             " = S \"",
             this.class228_1[current3],
             "\""
         }));
     }
     streamWriter.WriteLine("}");
     string[] array = new string[]
     {
         "",
         "rhythm_",
         "guitarcoop_",
         "rhythmcoop_"
     };
     for (int i = 0; i < array.Length; i++)
     {
         string str = array[i];
         string[] array2 = new string[]
         {
             "easy",
             "medium",
             "hard",
             "expert"
         };
         for (int j = 0; j < array2.Length; j++)
         {
             string str2 = array2[j];
             string text = str + str2;
             Track<int, NotesAtOffset> @class = this.noteList.ContainsKey(text) ? this.noteList[text] : new Track<int, NotesAtOffset>();
             Track<int, int[]> class2 = this.spList.ContainsKey(text) ? this.spList[text] : new Track<int, int[]>();
             Track<int, int[]> class3 = this.battleNoteList.ContainsKey(text) ? this.battleNoteList[text] : new Track<int, int[]>();
             Class221<int> class4 = new Class221<int>(@class.Keys);
             class4.vmethod_1(class2.Keys);
             class4.vmethod_1(class3.Keys);
             class4.Sort();
             StringBuilder stringBuilder = new StringBuilder(text);
             stringBuilder[0] = char.ToUpper(stringBuilder[0]);
             if (text.Contains("_"))
             {
                 stringBuilder[text.IndexOf('_') + 1] = char.ToUpper(stringBuilder[text.IndexOf('_') + 1]);
             }
             streamWriter.WriteLine("[" + stringBuilder.ToString() + "]");
             streamWriter.WriteLine("{");
             foreach (int current4 in class4)
             {
                 if (@class.ContainsKey(current4))
                 {
                     streamWriter.WriteLine(string.Concat(new object[]
                     {
                         "\t",
                         current4,
                         " = N ",
                         @class[current4].method_0(),
                         " ",
                         @class[current4].sustainLength
                     }));
                 }
                 if (class2.ContainsKey(current4))
                 {
                     streamWriter.WriteLine(string.Concat(new object[]
                     {
                         "\t",
                         current4,
                         " = S ",
                         class2[current4][1],
                         " ",
                         class2[current4][0]
                     }));
                 }
                 if (class3.ContainsKey(current4))
                 {
                     streamWriter.WriteLine(string.Concat(new object[]
                     {
                         "\t",
                         current4,
                         " = B ",
                         class3[current4][1],
                         " ",
                         class3[current4][0]
                     }));
                 }
             }
             streamWriter.WriteLine("}");
         }
     }
     streamWriter.WriteLine("[FaceOffP1]");
     streamWriter.WriteLine("{");
     foreach (int current5 in this.class228_2.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current5,
             " = F ",
             this.class228_2[current5]
         }));
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[FaceOffP2]");
     streamWriter.WriteLine("{");
     foreach (int current6 in this.class228_3.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current6,
             " = F ",
             this.class228_3[current6]
         }));
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[BossBattleP1]");
     streamWriter.WriteLine("{");
     foreach (int current7 in this.bpmList.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current7,
             " = B ",
             this.bpmList[current7]
         }));
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[BossBattleP2]");
     streamWriter.WriteLine("{");
     foreach (int current8 in this.class228_5.Keys)
     {
         streamWriter.WriteLine(string.Concat(new object[]
         {
             "\t",
             current8,
             " = B ",
             this.class228_5[current8]
         }));
     }
     streamWriter.WriteLine("}");
     streamWriter.Close();
 }
Example #5
0
 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)
                         {
                             int num4 = this.method_0(current7);
                             int num5 = this.method_0(current7 + class7[current7].sustainLength - this.int_0) - num4;
                             class6.noteList.Add(num4, new NotesAtOffset(class7[current7].noteValues, (num5 <= this.int_1 / 4) ? 0 : num5));
                         }
                         class6.alwaysTrue = false;
                         if (this.spList.ContainsKey(key))
                         {
                             Track<int, int[]> class8 = this.spList[key];
                             foreach (int current8 in class8.Keys)
                             {
                                 int num4 = this.method_0(current8);
                                 int num5 = this.method_0(current8 + class8[current8][0] - this.int_0) - num4;
                                 class6.class228_1.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
                             }
                         }
                         if (this.battleNoteList.ContainsKey(key))
                         {
                             Track<int, int[]> class9 = this.spList[key];
                             foreach (int current9 in class9.Keys)
                             {
                                 int num4 = this.method_0(current9);
                                 int num5 = this.method_0(current9 + class9[current9][0] - this.int_0) - num4;
                                 class6.class228_4.Add(num4, (num5 <= this.int_1 / 4) ? 0 : num5);
                             }
                         }
                         class6.class228_2 = class2;
                         class6.class228_3 = class3;
                         class6.class228_5 = class4;
                         class6.class228_6 = class5;
                         @class.difficultyWithNotes.Add(text3 + text + text2, class6);
                     }
                 }
             }
         }
         this.class228_6.Clear();
         this.class228_6 = null;
         return @class;
     }
     return null;
 }
Example #6
0
 public QBCParser(GH3Song gh3Song_1)
     : this()
 {
     this.gh3Song_0 = gh3Song_1;
 }
Example #7
0
 public QBCParser(string string_0, zzGenericNode1 class308_0, zzGenericNode1 class308_1, zzGenericNode1 class308_2)
 {
     string[] array = new string[]
     {
         "Easy",
         "Medium",
         "Hard",
         "Expert"
     };
     string[] array2 = new string[]
     {
         "Single",
         "Double"
     };
     ArrayPointerRootNode @class;
     for (int i = 0; i < array2.Length; i++)
     {
         string a = array2[i];
         string[] array3 = new string[]
         {
             "Guitar",
             "Rhythm"
         };
         for (int j = 0; j < array3.Length; j++)
         {
             string text = array3[j];
             string[] array4 = array;
             for (int k = 0; k < array4.Length; k++)
             {
                 string text2 = array4[k];
                 string text3 = (text.ToLower() + ((a == "Double") ? "coop" : "") + "_" + text2.ToLower()).Replace("guitar_", "");
                 @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_song_" + text3));
                 if (@class != null && @class.method_7() is IntegerArrayNode)
                 {
                     Track<int, NotesAtOffset> class2 = new Track<int, NotesAtOffset>();
                     int[] array5 = @class.method_7().method_7<int>();
                     for (int l = 0; l < array5.Length; l += 3)
                     {
                         class2.Add(array5[l], new NotesAtOffset(array5[l + 2], array5[l + 1]));
                     }
                     this.noteList.Add(text3, class2);
                 }
                 @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_" + text3 + "_star"));
                 if (@class != null && @class.method_7() is ListArrayNode)
                 {
                     Track<int, int[]> class3 = new Track<int, int[]>();
                     foreach (IntegerArrayNode current in @class.method_7().method_8<IntegerArrayNode>())
                     {
                         class3.Add(current[0], new int[]
                         {
                             current[1],
                             current[2]
                         });
                     }
                     this.spList.Add(text3, class3);
                 }
                 @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_" + text3 + "_starbattlemode"));
                 if (@class != null && @class.method_7() is ListArrayNode)
                 {
                     Track<int, int[]> class4 = new Track<int, int[]>();
                     foreach (IntegerArrayNode current2 in @class.method_7().method_8<IntegerArrayNode>())
                     {
                         class4.Add(current2[0], new int[]
                         {
                             current2[1],
                             current2[2]
                         });
                     }
                     this.battleNoteList.Add(text3, class4);
                 }
             }
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_faceoffp1"));
     if (@class != null && @class.method_7() is ListArrayNode)
     {
         foreach (IntegerArrayNode current3 in @class.method_7().method_8<IntegerArrayNode>())
         {
             this.class228_2.Add(current3[0], current3[1]);
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_faceoffp2"));
     if (@class != null && @class.method_7() is ListArrayNode)
     {
         foreach (IntegerArrayNode current4 in @class.method_7().method_8<IntegerArrayNode>())
         {
             this.class228_3.Add(current4[0], current4[1]);
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_bossbattlep1"));
     if (@class != null && @class.method_7() is ListArrayNode)
     {
         foreach (IntegerArrayNode current5 in @class.method_7().method_8<IntegerArrayNode>())
         {
             this.bpmList.Add(current5[0], current5[1]);
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_bossbattlep2"));
     if (@class != null && @class.method_7() is ListArrayNode)
     {
         foreach (IntegerArrayNode current6 in @class.method_7().method_8<IntegerArrayNode>())
         {
             this.class228_5.Add(current6[0], current6[1]);
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_timesig"));
     if (@class != null && @class.method_7() is ListArrayNode)
     {
         foreach (IntegerArrayNode current7 in @class.method_7().method_8<IntegerArrayNode>())
         {
             this.tsList.Add(current7[0], new int[]
             {
                 current7[1],
                 current7[2]
             });
         }
     }
     @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_fretbars"));
     if (@class != null && @class.method_7() is IntegerArrayNode)
     {
         this.class239_0 = new Class239<int>(@class.method_7().method_8<int>());
         this.int_0 = (this.class239_0[1] - this.class239_0[0]) / 4;
         try
         {
             Dictionary<int, string> dictionary = new Dictionary<int, string>();
             @class = class308_0.method_5<ArrayPointerRootNode>(new ArrayPointerRootNode(string_0 + "_markers"));
             if (class308_1 != null && @class != null && @class.method_7() is StructureArrayNode)
             {
                 foreach (UnicodeRootNode class5 in class308_1.Nodes)
                 {
                     dictionary.Add(class5.int_0, class5.method_7());
                 }
                 using (List<StructureHeaderNode>.Enumerator enumerator9 = @class.method_7().method_8<StructureHeaderNode>().GetEnumerator())
                 {
                     while (enumerator9.MoveNext())
                     {
                         StructureHeaderNode current8 = enumerator9.Current;
                         this.class228_1.Add(((IntegerStructureNode)current8[0]).method_8(), dictionary[((FileTagStructureNode)current8[1]).method_9()]);
                     }
                     goto IL_7C2;
                 }
             }
             if (@class != null && @class.method_7() is StructureArrayNode)
             {
                 foreach (StructureHeaderNode current9 in @class.method_7().method_8<StructureHeaderNode>())
                 {
                     this.class228_1.Add(((IntegerStructureNode)current9[0]).method_8(), ((UnicodeStructureNode)current9[1]).method_8());
                 }
             }
             IL_7C2:;
         }
         catch
         {
         }
         try
         {
             if (class308_2 != null)
             {
                 this.gh3Song_0 = new GH3Song(class308_2.method_5<StructurePointerNode>(new StructurePointerNode(string_0)));
             }
             return;
         }
         catch
         {
             return;
         }
     }
     throw new Exception("Not a MID.QB!");
 }
Example #8
0
 public SongProperties(GH3Song song)
     : this(song.name)
 {
     this.Song = song;
     if (this.Song is GHASong)
     {
         this.BassistBox.Enabled = false;
         this.BossBox.Items.Add("Joe Perry Props");
         this.BossBox.Items.Add("Tom Morello Props");
     }
     else
     {
         this.AeroGroupBox.Enabled = false;
         this.SingerBox.Items.Add("Bret Michaels");
         this.BossBox.Items.Add("Tom Morello Props");
         this.BossBox.Items.Add("Slash Props");
         this.BossBox.Items.Add("Lou Props");
     }
     this.btnApply.Enabled = true; // this.gh3Song_0.editable;
     this.TitleTxt.Text = this.Song.title;
     this.ArtistTxt.Text = this.Song.artist;
     this.YearTxt.Text = this.Song.year;
     this.chkOriginal.Checked = this.Song.original_artist;
     this.chkRhythm.Checked = !this.Song.no_rhythm_track;
     this.chkKeyboard.Checked = this.Song.keyboard;
     this.chkCoop.Checked = this.Song.use_coop_notetracks;
     this.rBtnBass.Checked = !(this.rBtnRhythm.Checked = this.Song.not_bass);
     if (this.Song.artist_text is bool)
     {
         this.FamousByBtn.Checked = !(this.ByBtn.Checked = (bool)this.Song.artist_text);
     }
     else
     {
         this.ArtistTextBox.Text = (string)this.Song.artist_text;
         this.CustomTxtBtn.Checked = true;
     }
     this.GuitarVolBox.Value = (decimal)this.Song.guitar_vol;
     this.BandVolBox.Value = (decimal)this.Song.band_vol;
     this.HammerOnBox.Value = (decimal)this.Song.hammer_on;
     this.OffsetBox.Value = this.Song.gem_offset;
     if (this.Song.singer.Equals(""))
     {
         this.SingerBox.SelectedIndex = 0;
     }
     else if (this.Song.singer.Equals("male"))
     {
         this.SingerBox.SelectedIndex = 1;
     }
     else if (this.Song.singer.Equals("female"))
     {
         this.SingerBox.SelectedIndex = 2;
     }
     else if (this.Song.singer.Equals("bret"))
     {
         this.SingerBox.SelectedItem = "Bret Michaels";
     }
     this.CountOffBox.SelectedItem = this.Song.countoff.ToLower();
     this.BassistBox.SelectedItem = this.Song.bassist;
     if (this.Song.boss.Equals(""))
     {
         this.BossBox.SelectedIndex = 0;
     }
     else if (this.Song.boss.Equals("boss_tommorello_props"))
     {
         this.BossBox.SelectedItem = "Tom Morello Props";
     }
     else if (this.Song.boss.Equals("boss_slash_props"))
     {
         this.BossBox.SelectedItem = "Slash Props";
     }
     else if (this.Song.boss.Equals("boss_devil_props"))
     {
         this.BossBox.SelectedItem = "Lou Props";
     }
     else if (this.Song.boss.Equals("boss_joe_props"))
     {
         this.BossBox.SelectedItem = "Joe Perry Props";
     }
     if (this.AeroGroupBox.Enabled)
     {
         GHASong gHASong = (GHASong)this.Song;
         this.CoveredTxt.Text = gHASong.covered_by;
         this.SingAnimPakTxt.Text = gHASong.singer_anim_pak;
         this.BandBox.SelectedItem = gHASong.band;
         this.BPM8NoteBox.Value = gHASong.thin_fretbar_8note_params_high_bpm;
         this.AeroGuitaristBox.Checked = gHASong.guitarist_checksum;
         this.PerryMicBox.Checked = gHASong.perry_mic_stand;
     }
 }
Example #9
0
 public void dbcCreator(string fileLocation, GH3Song gh3Song)
 {
     this.gh3SongInfo = gh3Song;
     StreamWriter streamWriter = new StreamWriter(fileLocation);
     streamWriter.WriteLine("[Song]");
     streamWriter.WriteLine("{");
     streamWriter.WriteLine("\tName = \"" + this.gh3SongInfo.title + "\"");
     streamWriter.WriteLine("\tArtist = \"" + this.gh3SongInfo.artist + "\"");
     streamWriter.WriteLine("\tYear = \"" + this.gh3SongInfo.year + "\"");
     streamWriter.WriteLine("\tPlayer2 = " + (this.gh3SongInfo.not_bass ? "Rhythm" : "Bass"));
     streamWriter.WriteLine("\tArtistText = \"" + ((this.gh3SongInfo.artist_text is bool) ? (((bool)this.gh3SongInfo.artist_text) ? "by" : "as made famous by") : ((string)this.gh3SongInfo.artist_text)) + "\"");
     streamWriter.WriteLine("\tOffset = " + (double)this.gh3SongInfo.input_offset / -1000.0);
     if (!this.gh3SongInfo.singer.Equals(""))
     {
         streamWriter.WriteLine("\tSinger = \"" + this.gh3SongInfo.singer + "\"");
     }
     if (!this.gh3SongInfo.bassist.Equals("Generic Bassist"))
     {
         streamWriter.WriteLine("\tBassist = \"" + this.gh3SongInfo.bassist + "\"");
     }
     if (!this.gh3SongInfo.boss.Equals(""))
     {
         streamWriter.WriteLine("\tBoss = \"" + this.gh3SongInfo.boss + "\"");
     }
     streamWriter.WriteLine("\tCountOff = \"" + this.gh3SongInfo.countoff + "\"");
     streamWriter.WriteLine("\tGuitarVol = " + this.gh3SongInfo.guitar_vol);
     streamWriter.WriteLine("\tBandVol = " + this.gh3SongInfo.band_vol);
     streamWriter.WriteLine("\tHoPo = " + this.gh3SongInfo.hammer_on);
     streamWriter.WriteLine("\tOriginalArtist = " + (this.gh3SongInfo.original_artist ? "true" : "false"));
     streamWriter.WriteLine("\tResolution = " + this.constant480);
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[SyncTrack]");
     streamWriter.WriteLine("{");
     List<int> list = new List<int>(this.bpmInterpreter.TSList.Keys);
     foreach (int current in this.bpmInterpreter.bpmList.Keys)
     {
         if (!list.Contains(current))
         {
             list.Add(current);
         }
     }
     list.Sort();
     foreach (int current2 in list)
     {
         if (this.bpmInterpreter.bpmList.ContainsKey(current2))
         {
             streamWriter.WriteLine(string.Concat(new object[]
             {
                 "\t",
                 current2,
                 " = B ",
                 this.bpmInterpreter.bpmList[current2]
             }));
         }
         if (this.bpmInterpreter.TSList.ContainsKey(current2))
         {
             streamWriter.WriteLine(string.Concat(new object[]
             {
                 "\t",
                 current2,
                 " = TS ",
                 this.bpmInterpreter.TSList[current2]
             }));
         }
     }
     streamWriter.WriteLine("}");
     streamWriter.WriteLine("[Events]");
     streamWriter.WriteLine("{");
     list = new List<int>(this.sectionInterpreter.sectionList.Keys);
     foreach (int current3 in this.sectionInterpreter.otherList.Keys)
     {
         if (!list.Contains(current3))
         {
             list.Add(current3);
         }
     }
     list.Sort();
     foreach (int current4 in list)
     {
         if (this.sectionInterpreter.sectionList.ContainsKey(current4))
         {
             streamWriter.WriteLine(string.Concat(new object[]
             {
                 "\t",
                 current4,
                 " = E \"section ",
                 this.sectionInterpreter.sectionList[current4].Replace(" ", "_").ToLower(),
                 "\""
             }));
         }
         if (this.sectionInterpreter.otherList.ContainsKey(current4))
         {
             List<string> list2 = this.sectionInterpreter.otherList[current4];
             foreach (string current5 in list2)
             {
                 streamWriter.WriteLine(string.Concat(new object[]
                 {
                     "\t",
                     current4,
                     " = E \"",
                     current5,
                     "\""
                 }));
             }
         }
     }
     streamWriter.WriteLine("}");
     new ArrayList(this.difficultyWithNotes.Keys);
     string[] array = new string[]
     {
         "Easy",
         "Medium",
         "Hard",
         "Expert"
     };
     for (int i = 0; i < array.Length; i++)
     {
         string str = array[i];
         string[] array2 = new string[]
         {
             "Single",
             "Double"
         };
         for (int j = 0; j < array2.Length; j++)
         {
             string str2 = array2[j];
             string[] array3 = new string[]
             {
                 "Guitar",
                 "Rhythm"
             };
             for (int k = 0; k < array3.Length; k++)
             {
                 string str3 = array3[k];
                 if (this.difficultyWithNotes.ContainsKey(str + str2 + str3))
                 {
                     string text = str + str2 + str3;
                     NoteEventInterpreter @class = this.difficultyWithNotes[text];
                     streamWriter.WriteLine("[" + text + "]");
                     streamWriter.WriteLine("{");
                     list = new List<int>(@class.noteList.Keys);
                     foreach (int current6 in @class.class228_2.Keys)
                     {
                         if (!list.Contains(current6))
                         {
                             list.Add(current6);
                         }
                     }
                     foreach (int current7 in @class.class228_3.Keys)
                     {
                         if (!list.Contains(current7))
                         {
                             list.Add(current7);
                         }
                     }
                     foreach (int current8 in @class.class228_1.Keys)
                     {
                         if (!list.Contains(current8))
                         {
                             list.Add(current8);
                         }
                     }
                     foreach (int current9 in @class.class228_4.Keys)
                     {
                         if (!list.Contains(current9))
                         {
                             list.Add(current9);
                         }
                     }
                     foreach (int current10 in @class.class228_5.Keys)
                     {
                         if (!list.Contains(current10))
                         {
                             list.Add(current10);
                         }
                     }
                     foreach (int current11 in @class.class228_6.Keys)
                     {
                         if (!list.Contains(current11))
                         {
                             list.Add(current11);
                         }
                     }
                     foreach (int current12 in @class.eventList.Keys)
                     {
                         if (!list.Contains(current12))
                         {
                             list.Add(current12);
                         }
                     }
                     list.Sort();
                     foreach (int current13 in list)
                     {
                         if (@class.eventList.ContainsKey(current13))
                         {
                             List<string> list2 = @class.eventList[current13];
                             foreach (string current14 in list2)
                             {
                                 streamWriter.WriteLine(string.Concat(new object[]
                                 {
                                     "\t",
                                     current13,
                                     " = E ",
                                     current14
                                 }));
                             }
                         }
                         if (@class.noteList.ContainsKey(current13))
                         {
                             NotesAtOffset class2 = @class.noteList[current13];
                             for (int l = 0; l < class2.noteValues.Length; l++)
                             {
                                 if (class2.noteValues[l])
                                 {
                                     streamWriter.WriteLine(string.Concat(new object[]
                                     {
                                         "\t",
                                         current13,
                                         " = N ",
                                         l,
                                         " ",
                                         class2.sustainLength
                                     }));
                                 }
                             }
                         }
                         if (@class.class228_2.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 0 ",
                                 @class.class228_2[current13]
                             }));
                         }
                         if (@class.class228_3.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 1 ",
                                 @class.class228_3[current13]
                             }));
                         }
                         if (@class.class228_1.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 2 ",
                                 @class.class228_1[current13]
                             }));
                         }
                         if (@class.class228_4.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 3 ",
                                 @class.class228_4[current13]
                             }));
                         }
                         if (@class.class228_5.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 4 ",
                                 @class.class228_5[current13]
                             }));
                         }
                         if (@class.class228_6.ContainsKey(current13))
                         {
                             streamWriter.WriteLine(string.Concat(new object[]
                             {
                                 "\t",
                                 current13,
                                 " = S 5 ",
                                 @class.class228_6[current13]
                             }));
                         }
                     }
                     streamWriter.WriteLine("}");
                 }
             }
         }
         array2 = new string[]
         {
             "Drums",
             "Keyboard"
         };
         for (int j = 0; j < array2.Length; j++)
         {
             string str4 = array2[j];
             if (this.instrumentList.ContainsKey(str + str4))
             {
                 string text2 = str + str4;
                 InstrumentType class3 = this.instrumentList[text2];
                 streamWriter.WriteLine("[" + text2 + "]");
                 streamWriter.WriteLine("{");
                 list = new List<int>(class3.Keys);
                 list.Sort();
                 foreach (int current15 in list)
                 {
                     foreach (string current16 in class3[current15])
                     {
                         streamWriter.WriteLine(string.Concat(new object[]
                         {
                             "\t",
                             current15,
                             " = E ",
                             current16
                         }));
                     }
                 }
                 streamWriter.WriteLine("}");
             }
         }
     }
     streamWriter.Close();
 }
Example #10
0
 public ChartParser(GH3Song gh3Song_1)
     : this()
 {
     this.gh3SongInfo = gh3Song_1;
 }