This commit is contained in:
Wirlaburla 2024-07-28 23:37:55 -05:00
parent 780a7d69b3
commit a54c1ea325

View File

@ -196,7 +196,9 @@ public class Clifford implements ActionListener {
JFileChooser fileChooser = new JFileChooser(); JFileChooser fileChooser = new JFileChooser();
fileChooser.setFileFilter(new FileNameExtensionFilter("Firestar Mod Package", "fstar")); fileChooser.setFileFilter(new FileNameExtensionFilter("Firestar Mod Package", "fstar"));
if (fileChooser.showSaveDialog(frame) == JFileChooser.APPROVE_OPTION) { if (fileChooser.showSaveDialog(frame) == JFileChooser.APPROVE_OPTION) {
ZipFile zip = new ZipFile(fileChooser.getSelectedFile()); File modFile = fileChooser.getSelectedFile();
if (!modFile.getName().endsWith(".fstar")) modFile = new File(modFile.toString() + ".fstar");
ZipFile zip = new ZipFile(modFile);
boolean hasScript = false; boolean hasScript = false;
try { try {
zip.addFolder(new File(directory.getAbsolutePath() + "/data")); zip.addFolder(new File(directory.getAbsolutePath() + "/data"));