You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: LuteBot/PartitionsForm.cs
+17-10Lines changed: 17 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -49,23 +49,30 @@ public PartitionsForm(TrackSelectionManager tsm, MidiPlayer player)
49
49
exportSelectedButton.Enabled=false;
50
50
renameSelectedButton.Enabled=false;
51
51
52
-
if(!LuteBotForm.luteBotForm.IsLuteModInstalled())
52
+
try
53
53
{
54
-
using(varpopup=newPopupForm("Install LuteMod","Would you like to update/install LuteMod?","You need this to play music.\n\nIf you already have a working LuteMod installed, this means there's an important update\n\nThanks to Monty for LuteMod, and cswic for the autoloader\n\nFor more information, see:",
55
-
newDictionary<string,string>(){
54
+
if(!LuteBotForm.luteBotForm.IsLuteModInstalled())
55
+
{
56
+
using(varpopup=newPopupForm("Install LuteMod","Would you like to update/install LuteMod?","You need this to play music.\n\nIf you already have a working LuteMod installed, this means there's an important update\n\nThanks to Monty for LuteMod, and cswic for the autoloader\n\nFor more information, see:",
57
+
newDictionary<string,string>(){
56
58
{"What is LuteMod","https://mordhau-bards-guild.fandom.com/wiki/LuteMod"},
// MessageBox.Show(null, $"Lutebot has crashed: {e.Message}, and could not write a crash report: {ex.Message}\nYou may need to run Lutebot as administrator", "Lutebot has crashed", MessageBoxButtons.OK);
45
-
// }
46
-
// var result = MessageBox.Show(null, $"Lutebot has crashed: {e.Message}\n\nThe crash report has been saved to {savePath}\n\nWould you like to open the folder?", "Lutebot has crashed", MessageBoxButtons.YesNo);
content+=$"{currentException.Message}\n{currentException.StackTrace}\nIn method {currentException.TargetSite.Name}\nIn class {currentException.TargetSite.ReflectedType.Name}\n\n";
36
+
currentException=currentException.InnerException;
37
+
}while(currentException!=null);
38
+
content+="\n\n";
39
+
Directory.CreateDirectory(saveFolder);
40
+
File.AppendAllText(savePath,content);
41
+
}
42
+
catch(Exceptionex)
43
+
{
44
+
MessageBox.Show(null,$"Lutebot has crashed: {e.Message}, and could not write a crash report: {ex.Message}\nYou may need to run Lutebot as administrator","Lutebot has crashed",MessageBoxButtons.OK);
45
+
}
46
+
varresult=MessageBox.Show(null,$"Lutebot has crashed: {e.Message}\n\nThe crash report has been saved to {savePath}\n\nWould you like to open the folder?","Lutebot has crashed",MessageBoxButtons.YesNo);
privatestaticstringlutemodPakName="FLuteMod_2.6.pak";// TODO: Get this dynamically or something. Really, get the file itself from github, but this will do for now
59
+
privatestaticstringlutemodPakName="FLuteMod_2.61.pak";// TODO: Get this dynamically or something. Really, get the file itself from github, but this will do for now
0 commit comments