next step is to implement our first i/o

This commit is contained in:
Downforce Agent 2024-04-21 13:37:17 -05:00
parent 82fc9773a6
commit 3b0c737d39
3 changed files with 22 additions and 6 deletions

View File

@ -5,6 +5,17 @@
Firestar is a mod manager for WipEout 2048 which automatically handles sorting mods by priority and repacking game assets based on selected add-on packs. It runs on a desktop/laptop computer and aims to allow easy installation of mods for users who have only a surface level understanding of hacking the PSVita. Firestar is a mod manager for WipEout 2048 which automatically handles sorting mods by priority and repacking game assets based on selected add-on packs. It runs on a desktop/laptop computer and aims to allow easy installation of mods for users who have only a surface level understanding of hacking the PSVita.
TODO: modlist window screenshot TODO: modlist window screenshot
# System Requirements
- You will need a computer running Microsoft Windows, or POSIX-compliant desktop operating system such as Linux, BSD, or MINIX (Firestar does not run on the PSVita). ***Wayland support has not been tested.***
- You will also need the Java Runtime Environment installed, at least version 17 or newer.
- Please run Firestar on an EXT or NTFS partition as some of the larger file operations it performs may cause glitches in certain filesystems used on memory cards. Do NOT install Firestar directly to your PSVita's storage.
# Mod File Structure
Mod files are contained inside of ZIP archives with the metadata being stored inside of the archive's embedded comments. The "data" folder inside contains the actual game assets for repacking.
Next to it at root level a pack.png will be supplied for displaying your mod's icon in later versions of Firestar. This feature is currently unimplemented.
TODO: More details will be provided once I/O routines are completed.
# FAQ # FAQ
## What is the difference between Compatibility Mode and Fast Mode? ## What is the difference between Compatibility Mode and Fast Mode?
Fast Mode is the most intuitive solution. It simply unpacks all of the assets into a folder for the game to read. This makes it trivial to go back and modify it later without repacking anything and it means you don't need stolen Sony-confidential equipment. However, PSVita and PSTV memory cards use the exFAT filesystem which really does not play nice with WipEout assets and causes all sorts of glitches, so using a genuine PSARC is an absolute necessity when playing on a real console. Compatibility mode uses a real PSARC tool to try and create mod files as similar to the original game files as possible and create minimal friction with the game engine. Fast Mode is the most intuitive solution. It simply unpacks all of the assets into a folder for the game to read. This makes it trivial to go back and modify it later without repacking anything and it means you don't need stolen Sony-confidential equipment. However, PSVita and PSTV memory cards use the exFAT filesystem which really does not play nice with WipEout assets and causes all sorts of glitches, so using a genuine PSARC is an absolute necessity when playing on a real console. Compatibility mode uses a real PSARC tool to try and create mod files as similar to the original game files as possible and create minimal friction with the game engine.

BIN
resources/titleIcon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

View File

@ -16,18 +16,22 @@
* along with this program. If not, see https://www.gnu.org/licenses/. * along with this program. If not, see https://www.gnu.org/licenses/.
*/ */
import javax.imageio.ImageIO;
import javax.swing.*; import javax.swing.*;
import javax.swing.event.ListSelectionListener; import javax.swing.event.ListSelectionListener;
import java.awt.*; import java.awt.*;
import java.awt.event.ActionEvent; import java.awt.event.ActionEvent;
import java.awt.event.ActionListener; import java.awt.event.ActionListener;
import java.awt.image.BufferedImage;
import java.io.File; import java.io.File;
import java.io.IOException;
import java.math.RoundingMode; import java.math.RoundingMode;
import java.text.DecimalFormat; import java.text.DecimalFormat;
import static javax.swing.WindowConstants.EXIT_ON_CLOSE; import static javax.swing.WindowConstants.EXIT_ON_CLOSE;
public class MissPiggy implements ActionListener { public class MissPiggy implements ActionListener {
BufferedImage windowIcon;
JFrame frame = new JFrame(); JFrame frame = new JFrame();
JPanel frameContainer; JPanel frameContainer;
JPanel actionsContainer; JPanel actionsContainer;
@ -55,9 +59,6 @@ public class MissPiggy implements ActionListener {
// Initialize the main window // Initialize the main window
public void Action(/*Main entryPoint*/) { public void Action(/*Main entryPoint*/) {
// todo construct contents
// todo display modlist
/// DEBUG /// /// DEBUG ///
Main.Mod testModEntry = new Main().new Mod(); //this is retarded? we're making a new object of a certain type, why the fuck do you care where it comes from? static or regardless?? Main.Mod testModEntry = new Main().new Mod(); //this is retarded? we're making a new object of a certain type, why the fuck do you care where it comes from? static or regardless??
testModEntry.friendlyName = "Example Mod 1"; testModEntry.friendlyName = "Example Mod 1";
@ -155,6 +156,12 @@ public class MissPiggy implements ActionListener {
);}); );});
// display window // display window
try {
windowIcon = ImageIO.read(new File(System.getProperty("user.dir") + "/resources/titleIcon.png"));
frame.setIconImage(windowIcon);
} catch (IOException e) {
System.out.println("ERROR: Failed to find /resources/titleIcon.png. Window will not have an icon.");
}
frame.setSize(800, 600); // 1280 800 frame.setSize(800, 600); // 1280 800
frame.setMinimumSize(new Dimension(640,480)); frame.setMinimumSize(new Dimension(640,480));
frame.setTitle("Firestar Mod Manager"); frame.setTitle("Firestar Mod Manager");
@ -173,12 +180,10 @@ public class MissPiggy implements ActionListener {
modList.setVisibleRowCount(Main.Mods.size()); modList.setVisibleRowCount(Main.Mods.size());
modList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); modList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
// todo this needs fixing before we can map it to Main.Mods and finish the other functionality around it
// add text entry for each // add text entry for each
int i = 0; int i = 0;
/*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()) {
contents[i] = Main.Mods.get(i).friendlyName; contents[i] = Main.Mods.get(i).friendlyName;