|
|
|
|
@ -39,6 +39,7 @@ public partial class ModPacker : Form
|
|
|
|
|
|
|
|
|
|
var dialog = new SelectFolderDialog();
|
|
|
|
|
// TODO: .config on linux
|
|
|
|
|
|
|
|
|
|
dialog.Directory = Environment.GetEnvironmentVariable("LocalAppData");
|
|
|
|
|
while (!wasSuccessful)
|
|
|
|
|
{
|
|
|
|
|
@ -94,7 +95,6 @@ public partial class ModPacker : Form
|
|
|
|
|
windowsLabel.Visible = false;
|
|
|
|
|
windowsPath = "";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
UpdateCreateButton();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -203,8 +203,11 @@ public partial class ModPacker : Form
|
|
|
|
|
createLabel.Text = "Packaging mod(s)... This could take a while!";
|
|
|
|
|
|
|
|
|
|
string output;
|
|
|
|
|
bool successful;
|
|
|
|
|
string errorCode;
|
|
|
|
|
|
|
|
|
|
// TODO: make windows optional
|
|
|
|
|
if (windowsCheckBox.Checked.Value)
|
|
|
|
|
{
|
|
|
|
|
using (var saveFile = new SaveFileDialog { Title = "Save Windows mod profile", Filters = { zipFileFilter } })
|
|
|
|
|
{
|
|
|
|
|
if (saveFile.ShowDialog(this) == DialogResult.Ok)
|
|
|
|
|
@ -216,13 +219,13 @@ public partial class ModPacker : Form
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
LoadProfileParameters(ProfileOperatingSystems.Windows);
|
|
|
|
|
|
|
|
|
|
(bool successful, string errorcode) = Core.CreateModPack(profile, windowsPath,originalPath, apkPath, output);
|
|
|
|
|
(successful, errorCode) = Core.CreateModPack(profile, windowsPath, originalPath, apkPath, output);
|
|
|
|
|
if (!successful)
|
|
|
|
|
{
|
|
|
|
|
MessageBox.Show(errorcode, "Error", MessageBoxButtons.OK, MessageBoxType.Error);
|
|
|
|
|
MessageBox.Show(errorCode, "Error", MessageBoxButtons.OK, MessageBoxType.Error);
|
|
|
|
|
AbortPatch();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (linuxCheckBox.Checked.Value)
|
|
|
|
|
{
|
|
|
|
|
@ -237,10 +240,10 @@ public partial class ModPacker : Form
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
LoadProfileParameters(ProfileOperatingSystems.Linux);
|
|
|
|
|
(successful, errorcode) = Core.CreateModPack(profile, linuxPath, originalPath, apkPath, output);
|
|
|
|
|
(successful, errorCode) = Core.CreateModPack(profile, linuxPath, originalPath, apkPath, output);
|
|
|
|
|
if (!successful)
|
|
|
|
|
{
|
|
|
|
|
MessageBox.Show(errorcode, "Error", MessageBoxButtons.OK, MessageBoxType.Error);
|
|
|
|
|
MessageBox.Show(errorCode, "Error", MessageBoxButtons.OK, MessageBoxType.Error);
|
|
|
|
|
AbortPatch();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|