4 Commits

Author SHA1 Message Date
59f80c4687 Changed version string 2024-07-03 16:55:41 -05:00
2dd6e0b0ff Fix invisible mod entries (#1) 2024-07-03 16:46:21 -05:00
727563e665 added desktop icon to installer 2024-07-03 16:29:06 -05:00
87d5dad7e5 whoops 2024-07-03 16:22:30 -05:00
6 changed files with 20 additions and 6 deletions

View File

@@ -0,0 +1,3 @@
#!/bin/sh
cd /usr/share/java/firestar/
PATH="/usr/lib/jvm/java-17-openjdk/bin/:$PATH" java -jar firestar.jar "$@"

View File

@@ -43,6 +43,7 @@ Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{
[Files] [Files]
Source: "Z:\home\bonkyboo\repos\firestar\out\artifacts\firestar_jar\{#MyAppExeName}"; DestDir: "{app}"; Flags: ignoreversion Source: "Z:\home\bonkyboo\repos\firestar\out\artifacts\firestar_jar\{#MyAppExeName}"; DestDir: "{app}"; Flags: ignoreversion
Source: "Z:\home\bonkyboo\repos\firestar\titleIcon.ico"; DestDir: "{app}"; Flags: ignoreversion
Source: "Z:\home\bonkyboo\repos\firestar\resources\*"; DestDir: "{app}\resources"; Flags: ignoreversion recursesubdirs createallsubdirs Source: "Z:\home\bonkyboo\repos\firestar\resources\*"; DestDir: "{app}\resources"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files ; NOTE: Don't use "Flags: ignoreversion" on any shared system files
@@ -54,6 +55,6 @@ Root: HKA; Subkey: "Software\Classes\{#MyAppAssocKey}\shell\open\command"; Value
Root: HKA; Subkey: "Software\Classes\Applications\{#MyAppExeName}\SupportedTypes"; ValueType: string; ValueName: ".myp"; ValueData: "" Root: HKA; Subkey: "Software\Classes\Applications\{#MyAppExeName}\SupportedTypes"; ValueType: string; ValueName: ".myp"; ValueData: ""
[Icons] [Icons]
Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; IconFilename: "{app}\titleIcon.ico";
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; IconFilename: "{app}\titleIcon.ico"; Tasks: desktopicon

View File

@@ -139,6 +139,10 @@ public class Clifford implements ActionListener {
mod.description = fDescription.getText(); mod.description = fDescription.getText();
JSONObject container = new JSONObject(); JSONObject container = new JSONObject();
if (mod.friendlyName.isEmpty()) {
JOptionPane.showMessageDialog(frame, "Mod name cannot be empty.", "Error", JOptionPane.ERROR_MESSAGE);
return;
}
container.put("version", mod.version); container.put("version", mod.version);
container.put("friendlyName", mod.friendlyName); container.put("friendlyName", mod.friendlyName);
container.put("author", mod.author); container.put("author", mod.author);
@@ -158,6 +162,10 @@ public class Clifford implements ActionListener {
invoker.InitializeModListInGUI(); invoker.InitializeModListInGUI();
frame.dispose(); frame.dispose();
} else if (actionEvent.getSource() == savebtn && creating) { } else if (actionEvent.getSource() == savebtn && creating) {
if (fName.getText().isEmpty()) {
JOptionPane.showMessageDialog(frame, "Mod name cannot be empty.", "Error", JOptionPane.ERROR_MESSAGE);
return;
}
try { try {
Integer.parseInt(fVersion.getText()); Integer.parseInt(fVersion.getText());
} catch (NumberFormatException e) { } catch (NumberFormatException e) {

View File

@@ -169,7 +169,7 @@ public class Gonzo {
System.out.println("The deletion queue is " + dQarray.length + " files long!"); //debug System.out.println("The deletion queue is " + dQarray.length + " files long!"); //debug
for (String file : dQarray) { for (String file : dQarray) {
if(file.contains("..")) { //todo: find all possible hazardous paths and blacklist them with regex if(file.contains("..")) { //todo: is this safe enough?
System.out.println("WARNING: Firestar skipped a potentially dangerous delete command. Please ensure the mod you're installing is from someone you trust!"); System.out.println("WARNING: Firestar skipped a potentially dangerous delete command. Please ensure the mod you're installing is from someone you trust!");
consoleDisplay.append("WARNING: Firestar skipped a potentially dangerous delete command. Please ensure the mod you're installing is from someone you trust!\n"); consoleDisplay.append("WARNING: Firestar skipped a potentially dangerous delete command. Please ensure the mod you're installing is from someone you trust!\n");
} else { } else {

View File

@@ -27,7 +27,7 @@ import javax.swing.JOptionPane;
public class Main { public class Main {
// Build Information // Build Information
public static final String vstr = "Release 1.1"; public static final String vstr = "Release 1.2";
public static final String vcode = "Dekka"; public static final String vcode = "Dekka";
public static final int vint = 0; public static final int vint = 0;

View File

@@ -286,12 +286,14 @@ public class MissPiggy implements ActionListener {
/*JLabel[]*/String[] contents = new String[Main.Mods.size()]; /*JLabel[]*/String[] contents = new String[Main.Mods.size()];
System.out.println("Initializing modList to GUI with length of " + Main.Mods.size() + " units"); //debug System.out.println("Initializing modList to GUI with length of " + Main.Mods.size() + " units"); //debug
while (i < Main.Mods.size()) { while (i < Main.Mods.size()) {
if (Main.Mods.get(i).friendlyName == null || Main.Mods.get(i).friendlyName.isEmpty())
{Main.Mods.get(i).friendlyName = Main.Mods.get(i).path;}
if (Main.Mods.get(i).enabled) {contents[i] = Main.Mods.get(i).friendlyName;} if (Main.Mods.get(i).enabled) {contents[i] = Main.Mods.get(i).friendlyName;}
else {contents[i] = Main.Mods.get(i).friendlyName + " (Disabled)";} else {contents[i] = Main.Mods.get(i).friendlyName + " (Disabled)";}
//debug //debug
String authorDisplay; String authorDisplay;
if (Main.Mods.get(i).author == null) {authorDisplay = "Anonymous";} else {authorDisplay = "\"" + Main.Mods.get(i).author + "\"";} if (Main.Mods.get(i).author == null || Main.Mods.get(i).author.isEmpty()) {authorDisplay = "Anonymous";} else {authorDisplay = "\"" + Main.Mods.get(i).author + "\"";}
System.out.println("Added " + Main.Mods.get(i).friendlyName + " by " + authorDisplay); System.out.println("Added " + Main.Mods.get(i).friendlyName + " by " + authorDisplay);
i++; i++;
@@ -546,7 +548,7 @@ public class MissPiggy implements ActionListener {
modFileSizeStr = String.valueOf(df.format(modFileSize / (1024 * 1024 * 1024))); modFileSizeStr = String.valueOf(df.format(modFileSize / (1024 * 1024 * 1024)));
modFileSizeUnits = "Gigabytes"; modFileSizeUnits = "Gigabytes";
} }
if (Main.Mods.get(modList.getSelectedIndex()).author == null) { if (Main.Mods.get(modList.getSelectedIndex()).author == null || Main.Mods.get(modList.getSelectedIndex()).author.isEmpty()) {
authorDisplay = "an Unknown Author"; authorDisplay = "an Unknown Author";
} else { } else {
authorDisplay = Main.Mods.get(modList.getSelectedIndex()).author; authorDisplay = Main.Mods.get(modList.getSelectedIndex()).author;