Skip to content

Commit 9b693f2

Browse files
author
HyperPolygon64
committed
Added mod stacking debug feature
modified: Sonic-06-Mod-Manager/Properties/AssemblyInfo.cs modified: Sonic-06-Mod-Manager/Properties/Settings.Designer.cs modified: Sonic-06-Mod-Manager/Properties/Settings.settings modified: Sonic-06-Mod-Manager/app.config modified: Sonic-06-Mod-Manager/src/Environment3/RushInterface.Designer.cs modified: Sonic-06-Mod-Manager/src/Environment3/RushInterface.cs modified: Sonic-06-Mod-Manager/src/UnifyProgram.cs
1 parent a7b0175 commit 9b693f2

File tree

7 files changed

+75
-15
lines changed

7 files changed

+75
-15
lines changed

Sonic-06-Mod-Manager/Properties/AssemblyInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
[assembly: ComVisible(false)]
1313
[assembly: Guid("277111e3-79d8-41b5-b0d7-7609dff6e36f")]
1414
[assembly: AssemblyVersion("2.0.0.6")]
15-
[assembly: AssemblyFileVersion("3.2.3.0")]
15+
[assembly: AssemblyFileVersion("3.2.4.0")]

Sonic-06-Mod-Manager/Properties/Settings.Designer.cs

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Sonic-06-Mod-Manager/Properties/Settings.settings

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,5 +113,8 @@
113113
<Setting Name="Tweak_BeginWithRings" Type="System.Decimal" Scope="User">
114114
<Value Profile="(Default)">0</Value>
115115
</Setting>
116+
<Setting Name="Debug_AllowModStacking" Type="System.Boolean" Scope="User">
117+
<Value Profile="(Default)">False</Value>
118+
</Setting>
116119
</Settings>
117120
</SettingsFile>

Sonic-06-Mod-Manager/app.config

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,9 @@
118118
<setting name="Tweak_BeginWithRings" serializeAs="String">
119119
<value>0</value>
120120
</setting>
121+
<setting name="Debug_AllowModStacking" serializeAs="String">
122+
<value>False</value>
123+
</setting>
121124
</Unify.Properties.Settings>
122125
</userSettings>
123126
</configuration>

Sonic-06-Mod-Manager/src/Environment3/RushInterface.Designer.cs

Lines changed: 41 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Sonic-06-Mod-Manager/src/Environment3/RushInterface.cs

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,7 @@ private void LoadSettings()
214214
CheckBox_ForceMSAA.Checked = Properties.Settings.Default.Tweak_ForceMSAA;
215215
CheckBox_TailsFlightLimit.Checked = Properties.Settings.Default.Tweak_TailsFlightLimit;
216216
CheckBox_UninstallOnLaunch.Checked = Properties.Settings.Default.General_AutoUninstall;
217+
CheckBox_AllowModStacking.Checked = Properties.Settings.Default.Debug_AllowModStacking;
217218

218219
if (CheckBox_HighContrastText.Checked = Properties.Settings.Default.General_HighContrastText)
219220
Label_Status.ForeColor = SystemColors.ControlText;
@@ -1093,7 +1094,7 @@ private void SectionButton_InstallMods_Click(object sender, EventArgs e) {
10931094
ModEngine.skipped.Clear(); // Clear the skipped list
10941095
SaveChecks(); // Save checked items
10951096
RefreshLists();
1096-
UninstallThread(); // Uninstall everything before installing more mods
1097+
if (!Properties.Settings.Default.Debug_AllowModStacking) UninstallThread(); // Uninstall everything before installing more mods
10971098

10981099
if (_isPathInvalid) {
10991100
DialogResult confirmation = UnifyMessenger.UnifyMessage.ShowDialog("Ensure that your mods directory is outside your game directory! " +
@@ -1164,7 +1165,7 @@ private void SectionButton_InstallMods_Click(object sender, EventArgs e) {
11641165

11651166
// Check skipped list to ensure any errors occurred
11661167
if (ModEngine.skipped.Count != 0)
1167-
UnifyMessenger.UnifyMessage.ShowDialog($"Installation completed, but the following mods need revising:\n\n{string.Join("\n", ModEngine.skipped)}",
1168+
UnifyMessenger.UnifyMessage.ShowDialog($"Installation completed, but the following content needs revising...\n\n{string.Join("\n", ModEngine.skipped)}",
11681169
"Installation completed with warnings...", MessageBoxButtons.OK, MessageBoxIcon.Warning);
11691170

11701171
// Launch the emulator of choice
@@ -2221,5 +2222,16 @@ private void ContextMenu_Debug_Items_Click(object sender, EventArgs e) {
22212222
break;
22222223
}
22232224
}
2225+
2226+
/// <summary>
2227+
/// Checked event handler for Allow Mod Stacking.
2228+
/// </summary>
2229+
private void CheckBox_AllowModStacking_CheckedChanged(object sender, EventArgs e) {
2230+
Properties.Settings.Default.Debug_AllowModStacking = ((CheckBox)sender).Checked;
2231+
Properties.Settings.Default.Save();
2232+
2233+
if (Properties.Settings.Default.General_AutoUninstall && ((CheckBox)sender).Checked)
2234+
UnifyMessenger.UnifyMessage.ShowDialog("Please disable 'Uninstall mods automatically' to use mod stacking correctly.", "Property Violation", MessageBoxButtons.OK, MessageBoxIcon.Warning);
2235+
}
22242236
}
22252237
}

Sonic-06-Mod-Manager/src/UnifyProgram.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ namespace Unify.Environment3
3838
{
3939
static class Program
4040
{
41-
public static readonly string GlobalVersionNumber = "Version 3.23";
41+
public static readonly string GlobalVersionNumber = "Version 3.24";
4242

4343
#if !DEBUG
4444
public static readonly string VersionNumber = GlobalVersionNumber;

0 commit comments

Comments
 (0)