forked from Mirror/GodMode9
Allow overriding the default font via gm9/support/font.pbm
This commit is contained in:
parent
b63de24c26
commit
84bfac6a1b
@ -1946,6 +1946,16 @@ u32 GodMode(int entrypoint) {
|
|||||||
InitNandCrypto(entrypoint != ENTRY_B9S);
|
InitNandCrypto(entrypoint != ENTRY_B9S);
|
||||||
InitExtFS();
|
InitExtFS();
|
||||||
|
|
||||||
|
// custom font handling
|
||||||
|
if (CheckSupportFile("font.pbm")) {
|
||||||
|
u8* pbm = (u8*) malloc(0x10000); // arbitrary, should be enough by far
|
||||||
|
if (pbm) {
|
||||||
|
u32 pbm_size = LoadSupportFile("font.pbm", pbm, 0x10000);
|
||||||
|
if (pbm_size) SetFontFromPbm(pbm, pbm_size);
|
||||||
|
free(pbm);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// check for embedded essential backup
|
// check for embedded essential backup
|
||||||
if (((entrypoint == ENTRY_NANDBOOT) || (entrypoint == ENTRY_B9S)) &&
|
if (((entrypoint == ENTRY_NANDBOOT) || (entrypoint == ENTRY_B9S)) &&
|
||||||
!PathExist("S:/essential.exefs") && CheckGenuineNandNcsd() &&
|
!PathExist("S:/essential.exefs") && CheckGenuineNandNcsd() &&
|
||||||
@ -2310,7 +2320,7 @@ u32 GodMode(int entrypoint) {
|
|||||||
ShowPrompt(false, "Not allowed in XORpad drive");
|
ShowPrompt(false, "Not allowed in XORpad drive");
|
||||||
} else if ((curr_drvtype & DRV_CART) && (pad_state & BUTTON_Y)) {
|
} else if ((curr_drvtype & DRV_CART) && (pad_state & BUTTON_Y)) {
|
||||||
ShowPrompt(false, "Not allowed in gamecart drive");
|
ShowPrompt(false, "Not allowed in gamecart drive");
|
||||||
}else if (pad_state & BUTTON_Y) { // paste files
|
} else if (pad_state & BUTTON_Y) { // paste files
|
||||||
const char* optionstr[2] = { "Copy path(s)", "Move path(s)" };
|
const char* optionstr[2] = { "Copy path(s)", "Move path(s)" };
|
||||||
char promptstr[64];
|
char promptstr[64];
|
||||||
u32 flags = 0;
|
u32 flags = 0;
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
// known file names inside VRAM0 TAR
|
// known file names inside VRAM0 TAR
|
||||||
#define VRAM0_AUTORUN_GM9 "autorun.gm9"
|
#define VRAM0_AUTORUN_GM9 "autorun.gm9"
|
||||||
#define VRAM0_FONT_PBM "font.pbm"
|
#define VRAM0_FONT_PBM "font_default.pbm"
|
||||||
#define VRAM0_SCRIPTS "scripts"
|
#define VRAM0_SCRIPTS "scripts"
|
||||||
#define VRAM0_README_MD "README.md"
|
#define VRAM0_README_MD "README.md"
|
||||||
#define VRAM0_SPLASH_PCX FLAVOR "_splash.pcx"
|
#define VRAM0_SPLASH_PCX FLAVOR "_splash.pcx"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user