Check for dependencies before opening any menus that require them

This commit is contained in:
2025-02-20 10:39:19 -06:00
parent b8dbfc9095
commit 9292d8db62
2 changed files with 9 additions and 1 deletions

View File

@@ -345,7 +345,11 @@ public class MissPiggy implements ActionListener {
if (actionEvent.getSource() == toolsMenu.getItem(0)) {metaEditorGUI(modList.getSelectedIndex());} else
if (actionEvent.getSource() == toolsMenu.getItem(1)) {generatorGUI();} else
if (actionEvent.getSource() == toolsMenu.getItem(2)) {new Suggs(frame);} else
if (actionEvent.getSource() == toolsMenu.getItem(2)) {
if (!new File(Main.inpath + "at9tool.exe").exists() || !new File(Main.inpath + "ffmpeg.exe").exists())
JOptionPane.showMessageDialog(frame, "Your AT9 encoders are missing.\nPlease select \"Get Dependencies\" in the Options menu.", "Error", JOptionPane.ERROR_MESSAGE);
else new Suggs(frame);
} else
if (actionEvent.getSource() == helpMenu.getItem(0)) {
try {

View File

@@ -133,6 +133,10 @@ public class Waldorf implements ActionListener {
JOptionPane.showMessageDialog(frame, "PSARC files purged.", "Delete PSARCs", JOptionPane.INFORMATION_MESSAGE);
} else
if (actionEvent.getSource() == dwnARCbtn) {
if (!new File(Main.inpath + "pkg2zip.exe").exists() || !new File(Main.inpath + "psvpfsparser.exe").exists()) {
JOptionPane.showMessageDialog(frame, "Your decryption tools are missing.\nPlease select \"Get Dependencies\" in the Options menu.", "Error", JOptionPane.ERROR_MESSAGE);
return;
}
new Bert(invoker.frame);
frame.dispose();
} else