item
Some checks failed
Build Dusk / run-tests (push) Failing after 1m31s
Build Dusk / build-linux (push) Failing after 1m8s
Build Dusk / build-psp (push) Failing after 1m32s

This commit is contained in:
2026-01-25 15:01:25 -06:00
parent e1d7b7308f
commit f71c271c97
17 changed files with 480 additions and 51 deletions

View File

@@ -18,11 +18,6 @@ errorret_t assetInit(void) {
// Engine may have been provided the launch path
if(ENGINE.argc > 0) {
// This first arg is the executable, so on most platforms it is say
// "/path/file" or "C:\Path\file.exe". On PSP this would be something
// like "ms0:/PSP/GAME/DUSK/EBOOT.PBP" or if we are debugging it is
// "host0:/Dusk.prx"
// Get the directory of the executable
char_t buffer[FILENAME_MAX];
stringCopy(buffer, ENGINE.argv[0], FILENAME_MAX);
@@ -55,11 +50,15 @@ errorret_t assetInit(void) {
// Default system path, intended to be overridden by the platform
stringCopy(ASSET.systemPath, ".", FILENAME_MAX);
// PSP specific time.
// PSP specific asset loading.
#if PSP
assertTrue(ENGINE.argc >= 1, "PSP requires launch argument.");
// PSP is given either host0:/Dusk.prx (debugging) OR the PBP file.
// PSP is given either the prx OR the PBP file.
// In the format of "ms0:/PSP/GAME/DUSK/EBOOT.PBP" or "host0:/Dusk.prx"
// IF the file is the PBP file, we are loading directly on the PSP itself.
// IF the file is the .prx then we are debugging and fopen will return
// relative filepaths correctly, e.g. host0:/dusk.dsk will be on host.
if(
stringEndsWithCaseInsensitive(ENGINE.argv[0], ".pbp") ||
ASSET_PBP_READ_PBP_FROM_HOST
@@ -143,7 +142,6 @@ errorret_t assetInit(void) {
}
#endif
// Open zip file
char_t searchPath[FILENAME_MAX];
const char_t **path = ASSET_SEARCH_PATHS;

View File

@@ -56,6 +56,7 @@ typedef struct {
char_t systemPath[FILENAME_MAX];
uint8_t assetCount;
// PSP specific information.
#if PSP
FILE *pbpFile;
assetpbp_t pbpHeader;