From 6bcb78c44b37dc0e7e7e5c54889d4f06a122ef13 Mon Sep 17 00:00:00 2001 From: Aloquendiar <48574329+Aloquendiar@users.noreply.github.com> Date: Thu, 13 Aug 2026 22:37:02 -0600 Subject: [PATCH 1/3] Some small improvements to songdta This is for the future and for improving conversions from RB3 to RB4 (Part 1). --- .../Inspectors/SongDataInspector.Designer.cs | 2 +- .../Inspectors/SongDataInspector.cs | 2 +- LibForge/LibForge/SongData/SongData.cs | 4 ++-- .../LibForge/SongData/SongDataConverter.cs | 18 +++++++++++++++--- LibForge/LibForge/SongData/SongDataReader.cs | 4 ++-- LibForge/LibForge/SongData/SongDataWriter.cs | 4 ++-- 6 files changed, 23 insertions(+), 11 deletions(-) diff --git a/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.Designer.cs b/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.Designer.cs index d8250a9..868268f 100644 --- a/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.Designer.cs +++ b/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.Designer.cs @@ -436,7 +436,7 @@ private void InitializeComponent() this.freestyleCheckBox.Name = "freestyleCheckBox"; this.freestyleCheckBox.Size = new System.Drawing.Size(103, 17); this.freestyleCheckBox.TabIndex = 43; - this.freestyleCheckBox.Text = "Freestyle Vocals"; + this.freestyleCheckBox.Text = "Markup"; this.freestyleCheckBox.UseVisualStyleBackColor = true; // // fakeCheckBox diff --git a/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.cs b/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.cs index 51d3ca3..00ca226 100644 --- a/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.cs +++ b/LibForge/ForgeToolGUI/Inspectors/SongDataInspector.cs @@ -43,7 +43,7 @@ public void UpdateValues(LibForge.SongData.SongData data) vocalPartsTextBox.Text = data.VocalParts.ToString(); vocalGenderTextBox.Text = data.VocalGender.ToString(); mediumTextBox.Text = data.Medium; - freestyleCheckBox.Checked = data.HasFreestyleVocals; + freestyleCheckBox.Checked = data.HasMarkup; fakeCheckBox.Checked = data.Fake; shortnameTextBox.Text = data.Shortname; } diff --git a/LibForge/LibForge/SongData/SongData.cs b/LibForge/LibForge/SongData/SongData.cs index 2cbaa94..2ca3f2e 100644 --- a/LibForge/LibForge/SongData/SongData.cs +++ b/LibForge/LibForge/SongData/SongData.cs @@ -28,9 +28,9 @@ public class SongData public bool Cover; public byte VocalGender; public string Medium; - public bool HasFreestyleVocals; + public bool HasMarkup; public int VocalParts; - public int Flags; + public int Solos; public bool Fake; public string Shortname; } diff --git a/LibForge/LibForge/SongData/SongDataConverter.cs b/LibForge/LibForge/SongData/SongDataConverter.cs index 06206ab..f3a34fb 100644 --- a/LibForge/LibForge/SongData/SongDataConverter.cs +++ b/LibForge/LibForge/SongData/SongDataConverter.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections.Generic; using System.Linq; using System.Text; @@ -12,8 +12,20 @@ public static SongData ToSongData(DataArray songDta) { var songId = songDta.Array("song_id"); var art = songDta.Array("album_art").Any(1); + string markup = songDta.Array("markup")?.Any(1) ?? string.Empty; var shortName = songDta.Array("song").Array("name").Any(1).Split('/').Last(); var songIdNum = (shortName.GetHashCode() & 0xFFFFFF) + 90000000; + int solosValue = 0; + var soloArray = songDta.Array("solo"); + if (soloArray != null) + { + var soloStr = soloArray.ToString(); + if (soloStr.Contains("drum")) solosValue |= 1; + if (soloStr.Contains("guitar")) solosValue |= 2; + if (soloStr.Contains("bass")) solosValue |= 4; + if (soloStr.Contains("keys")) solosValue |= 32; + } + return new SongData { AlbumArt = art == "1" || art == "TRUE", @@ -30,10 +42,10 @@ public static SongData ToSongData(DataArray songDta) VocalsRank = songDta.Array("rank").Array("vocals").Int(1), Cover = false, Fake = false, - Flags = 0, + Solos = solosValue, GameOrigin = songDta.Array("game_origin")?.Any(1) ?? "ugc_plus", Genre = songDta.Array("genre").Symbol(1).ToString(), - HasFreestyleVocals = false, + HasMarkup = markup == "1" || markup == "TRUE", //idea leer la string via dta del con la variable (markup True) Medium = "", Name = songDta.Array("name").String(1), OriginalYear = songDta.Array("year_released").Int(1), diff --git a/LibForge/LibForge/SongData/SongDataReader.cs b/LibForge/LibForge/SongData/SongDataReader.cs index 8e6821f..786daf1 100644 --- a/LibForge/LibForge/SongData/SongDataReader.cs +++ b/LibForge/LibForge/SongData/SongDataReader.cs @@ -41,9 +41,9 @@ public override SongData Read() Cover = Bool(), VocalGender = Byte(), Medium = String(16), - HasFreestyleVocals = Bool().Then(Skip(3)), + HasMarkup = Bool().Then(Skip(3)), VocalParts = Int(), - Flags = Int(), + Solos = Int(), Fake = Bool(), Shortname = String(256) }; diff --git a/LibForge/LibForge/SongData/SongDataWriter.cs b/LibForge/LibForge/SongData/SongDataWriter.cs index 31a1508..5bceef8 100644 --- a/LibForge/LibForge/SongData/SongDataWriter.cs +++ b/LibForge/LibForge/SongData/SongDataWriter.cs @@ -39,10 +39,10 @@ public override void WriteStream(SongData r) Write(r.Cover); Write(r.VocalGender); Write(r.Medium, 16); - Write(r.HasFreestyleVocals); + Write(r.HasMarkup); s.Position += 3; Write(r.VocalParts); - Write(r.Flags); + Write(r.Solos); Write(r.Fake); Write(r.Shortname, 256); s.WriteByte(0); From 132029adcbb17794bb7c1a2ea78ceff5ee2338fa Mon Sep 17 00:00:00 2001 From: Aloquendiar <48574329+Aloquendiar@users.noreply.github.com> Date: Thu, 13 Aug 2026 22:38:52 -0600 Subject: [PATCH 2/3] no comments in spanish --- LibForge/LibForge/SongData/SongDataConverter.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LibForge/LibForge/SongData/SongDataConverter.cs b/LibForge/LibForge/SongData/SongDataConverter.cs index f3a34fb..bbb43ae 100644 --- a/LibForge/LibForge/SongData/SongDataConverter.cs +++ b/LibForge/LibForge/SongData/SongDataConverter.cs @@ -45,7 +45,7 @@ public static SongData ToSongData(DataArray songDta) Solos = solosValue, GameOrigin = songDta.Array("game_origin")?.Any(1) ?? "ugc_plus", Genre = songDta.Array("genre").Symbol(1).ToString(), - HasMarkup = markup == "1" || markup == "TRUE", //idea leer la string via dta del con la variable (markup True) + HasMarkup = markup == "1" || markup == "TRUE", Medium = "", Name = songDta.Array("name").String(1), OriginalYear = songDta.Array("year_released").Int(1), From 8d0f5807b689f28df9c4ffee1f4152cc1a38b0c2 Mon Sep 17 00:00:00 2001 From: Aloquendiar <48574329+Aloquendiar@users.noreply.github.com> Date: Fri, 14 Aug 2026 21:53:54 -0600 Subject: [PATCH 3/3] better rbsong --- LibForge/LibForge/RBSong/RBSongConverter.cs | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/LibForge/LibForge/RBSong/RBSongConverter.cs b/LibForge/LibForge/RBSong/RBSongConverter.cs index 6e28bca..c6986ab 100644 --- a/LibForge/LibForge/RBSong/RBSongConverter.cs +++ b/LibForge/LibForge/RBSong/RBSongConverter.cs @@ -74,6 +74,18 @@ public static RBSongResource MakeRBSong(DtxCS.DataTypes.DataArray array, MidiFil .Replace("sfx", "fusion/patches") .Replace("_bank.milo", ".fusion") ?? "fusion/patches/kit01.fusion"; + var animtempo = array.Array("anim_tempo")?.Any(1) + switch + { + "kTempoSlow" or "16" => "slow", + "kTempoMedium" or "32" => "medium", + "kTempoFast" or "64" => "fast", + _ => "medium" // in the case of unusual values ​​created by the community + }; + var animpercussion = array.Array("bank")?.Any(1) + .Replace("sfx/", "fusion/patches/vox_perc_") + .Replace("_bank.milo", ".fusion") + ?? "fusion/patches/vox_perc_tambourine.fusion"; var animations = ExtractVenuePropAnimsFromMidi(mf); return new RBSongResource { @@ -105,12 +117,12 @@ public static RBSongResource MakeRBSong(DtxCS.DataTypes.DataArray array, MidiFil Unknown2 = 4, Props = new[] { - new Property("tempo", new SymbolValue("medium")), + new Property("tempo", new SymbolValue(animtempo)), new Property("vocal_tonic_note", new LongValue(array.Array("vocal_tonic_note")?.Int(1) ?? 0)), new Property("vocal_track_scroll_duration_ms", new LongValue(array.Array("song_scroll_speed")?.Int(1) ?? 2300)), new Property("global_tuning_offset", new FloatValue(array.Array("tuning_offset_cents")?.Number(1) ?? 0)), new Property("band_fail_sound_event", new SymbolValue("")), - new Property("vocal_percussion_patch", new ResourcePathValue("fusion/patches/vox_perc_tambourine.fusion")), + new Property("vocal_percussion_patch", new ResourcePathValue(animpercussion)), new Property("drum_kit_patch", new ResourcePathValue(drumBank)), new Property("improv_solo_patch", new SymbolValue("gtrsolo_amer_03")), new Property("dynamic_drum_fill_override", new IntValue(10)),