port-mp-setups: a bunch of bug fixes

- only load the MP setup file when loading the agent, instead of when entering CS
- "clear default" was cause the game setup to become invalid upon re-entering it
- all challenges were showing the same text
This commit is contained in:
Raf committed 2025-05-29 15:33:32 -03:00
1 parent d5b4e0916c
commit 20bd9ddcbb
4 files changed
+10 -7

No files matched your search

+5
View File
@@ -19,6 +19,7 @@
#include "lib/str.h"
#include "data.h"
#include "types.h"
#include "mpsetups.h"
// bss
struct fileguid g_FilemgrFileToCopy;
@@ -2732,6 +2733,10 @@ MenuItemHandlerResult filemgrChooseAgentListMenuHandler(s32 operation, struct me
g_GameFileGuid.fileid = file->fileid;
g_GameFileGuid.deviceserial = file->deviceserial;
filemgrSaveOrLoad(&g_GameFileGuid, FILEOP_LOAD_GAME, 0);
// load the setup file when loading the agent
mpsetupCopyAllFromPak();
mpsetupLoadCurrentFile();
}
}
break;
-4
View File
@@ -5394,10 +5394,6 @@ MenuDialogHandlerResult menudialogCombatSimulator(s32 operation, struct menudial
g_Vars.waitingtojoin[1] = false;
g_Vars.waitingtojoin[2] = false;
g_Vars.waitingtojoin[3] = false;
// load the setup file when entering the Combat Simulator
mpsetupCopyAllFromPak();
mpsetupLoadCurrentFile();
}
if (g_Menus[g_MpPlayerNum].curdialog
+4 -2
View File
@@ -3776,8 +3776,10 @@ struct menudata_main {
struct menudata_mpsetup {
u32 slotindex;
u32 slotcount;
u8 showpresets;
u32 unke24;
u32 unke28;
u32 unke2c;
u8 showpresets;
};
struct menudata_mppause {
@@ -3990,9 +3992,9 @@ struct menu {
struct menudata_filemgr fm;
struct menudata_main4mb main4mb;
struct menudata_training training;
struct menudata_mpsetup mpsetup;
};
struct menudata_mpsetup mpsetup;
};
struct gamefile {