summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--baserom.ipsbin2351950 -> 2347251 bytes
-rw-r--r--data/data_83FECCC.s18
-rw-r--r--graphics/diploma/unk_84147C0.pngbin0 -> 2863 bytes
-rw-r--r--graphics/diploma/unk_84154E8.binbin0 -> 4096 bytes
-rw-r--r--graphics/diploma/unk_8415954.pal35
-rw-r--r--include/strings.h9
-rw-r--r--ld_script.txt1
-rw-r--r--src/diploma.c81
8 files changed, 99 insertions, 45 deletions
diff --git a/baserom.ips b/baserom.ips
index de64cf2e6..b378e7da4 100644
--- a/baserom.ips
+++ b/baserom.ips
Binary files differ
diff --git a/data/data_83FECCC.s b/data/data_83FECCC.s
index 0808116d9..6aade55b6 100644
--- a/data/data_83FECCC.s
+++ b/data/data_83FECCC.s
@@ -345,24 +345,6 @@ gUnknown_8414588:: @ 8414588
gUnknown_84145BC:: @ 84145BC
.incbin "baserom.gba", 0x4145BC, 0x204
-gUnknown_84147C0:: @ 84147C0
- .incbin "baserom.gba", 0x4147C0, 0xD28
-
-gUnknown_84154E8:: @ 84154E8
- .incbin "baserom.gba", 0x4154E8, 0x46C
-
-gUnknown_8415954:: @ 8415954
- .incbin "baserom.gba", 0x415954, 0xB0
-
-gUnknown_8415A04:: @ 8415A04
- .incbin "baserom.gba", 0x415A04, 0x4
-
-gUnknown_8415A08:: @ 8415A08
- .incbin "baserom.gba", 0x415A08, 0x8
-
-gUnknown_8415A10:: @ 8415A10
- .incbin "baserom.gba", 0x415A10, 0x10
-
@ strings
.section .rodata.841EE44
diff --git a/graphics/diploma/unk_84147C0.png b/graphics/diploma/unk_84147C0.png
new file mode 100644
index 000000000..ac6e113f8
--- /dev/null
+++ b/graphics/diploma/unk_84147C0.png
Binary files differ
diff --git a/graphics/diploma/unk_84154E8.bin b/graphics/diploma/unk_84154E8.bin
new file mode 100644
index 000000000..38c32e5b2
--- /dev/null
+++ b/graphics/diploma/unk_84154E8.bin
Binary files differ
diff --git a/graphics/diploma/unk_8415954.pal b/graphics/diploma/unk_8415954.pal
new file mode 100644
index 000000000..3ba0bc65d
--- /dev/null
+++ b/graphics/diploma/unk_8415954.pal
@@ -0,0 +1,35 @@
+JASC-PAL
+0100
+32
+123 205 172
+255 0 255
+222 230 139
+205 246 156
+230 222 164
+197 238 172
+205 230 213
+213 246 172
+205 230 164
+238 255 156
+197 238 172
+222 230 238
+222 238 238
+213 246 172
+246 238 172
+238 238 139
+123 205 172
+255 0 255
+255 0 255
+246 246 205
+230 230 148
+230 230 148
+230 230 148
+238 238 164
+222 222 148
+255 238 180
+238 230 164
+238 222 180
+246 246 164
+246 230 131
+246 230 172
+222 238 222
diff --git a/include/strings.h b/include/strings.h
index 0ccf9c071..8fb15be76 100644
--- a/include/strings.h
+++ b/include/strings.h
@@ -175,9 +175,14 @@ extern const u8 gUnknown_841665C[];
extern const u8 gUnknown_8416690[];
extern const u8 gUnknown_84166A7[];
extern const u8 gUnknown_84169DC[];
-
+extern const u8 gUnknown_841623D[];
extern const u8 gUnknown_84162BD[];
-extern const u8 gUnknown_841623D[];
+// diploma
+extern const u8 gUnknown_841B60E[];
+extern const u8 gUnknown_841B619[];
+extern const u8 gUnknown_841B684[];
+extern const u8 gUnknown_841B68F[];
+extern const u8 gUnknown_841B698[];
#endif //GUARD_STRINGS_H
diff --git a/ld_script.txt b/ld_script.txt
index ea53227e3..dae8f4887 100644
--- a/ld_script.txt
+++ b/ld_script.txt
@@ -420,6 +420,7 @@ SECTIONS {
data/data_83FECCC.o(.rodata);
src/intro.o(.rodata);
data/data_83FECCC.o(.rodata.battle_anim_special);
+ src/diploma.o(.rodata);
data/strings.o(.rodata);
data/data_83FECCC.o(.rodata.841EE44);
src/new_menu_helpers.o(.rodata);
diff --git a/src/diploma.c b/src/diploma.c
index 74343e82f..517ee8aa0 100644
--- a/src/diploma.c
+++ b/src/diploma.c
@@ -15,45 +15,76 @@
#include "scanline_effect.h"
#include "sound.h"
#include "sprite.h"
+#include "strings.h"
#include "task.h"
#include "text.h"
#include "window.h"
#include "diploma.h"
+struct Diploma
+{
+ u8 state;
+ u8 gfxStep;
+ u8 callbackStep;
+ u16 tilemapBuffer[0x800];
+};
+
+static EWRAM_DATA struct Diploma *gDiploma = NULL;
+
static void DiplomaBgInit(void);
static void DiplomaPrintText(void);
static u8 DiplomaLoadGfx(void);
static void DiplomaVblankHandler(void);
-
static void CB2_DiplomaInit(void);
-
static void Task_WaitForExit(u8);
static void Task_DiplomaInit(u8);
static void Task_DiplomaReturnToOverworld(u8);
-extern const struct BgTemplate gUnknown_8415A08[2];
-extern const struct WindowTemplate gUnknown_8415A10[];
-extern const u8 gUnknown_8402650[];
-extern const u8 gUnknown_841B60E[];
-extern const u8 gUnknown_841B684[];
-extern u8 gUnknown_84147C0[];
-extern u8 gUnknown_8415954[];
-extern u8 gUnknown_841B698[];
-extern u8 gUnknown_841B68F[];
-extern u8 gUnknown_841B619[];
-extern u8 gUnknown_8415A04[];
+static const u32 gUnknown_84147C0[] = INCBIN_U32("graphics/diploma/unk_84147C0.4bpp.lz");
+static const u32 gUnknown_84154E8[] = INCBIN_U32("graphics/diploma/unk_84154E8.bin.lz");
+static const u16 gUnknown_8415954[] = INCBIN_U16("graphics/diploma/unk_8415954.gbapal");
-struct Diploma
-{
- u8 state;
- u8 gfxStep;
- u8 callbackStep;
- u16 tilemapBuffer[0x800];
-};
+static const u8 gUnknown_8415994[] = _("{HIGHLIGHT TRANSPARENT}プレイヤー");
+static const u8 gUnknown_841599D[] = _("{HIGHLIGHT TRANSPARENT}さま");
+static const u8 gUnknown_84159A3[] = _("{HIGHLIGHT TRANSPARENT}ホウエン");
+static const u8 gUnknown_84159AB[] = _("{HIGHLIGHT TRANSPARENT}ぜんこく");
+static const u8 gUnknown_84159B3[] = _("{HIGHLIGHT TRANSPARENT}     ポケモンずかんを\nみごと かんせい させた\nいだいなこうせきを たたえ\nここに しょうめい します");
+static const u8 gUnknown_84159ED[] = _("{COLOR RED}{HIGHLIGHT TRANSPARENT}ゲームフリーク");
+static const u8 gUnknown_84159FB[] = _("{COLOR RED}{HIGHLIGHT TRANSPARENT}");
-static EWRAM_DATA struct Diploma *gDiploma = NULL;
+static const ALIGNED(4) struct TextColor gUnknown_8415A04 = {0, 2, 3};
-extern const u32 gUnknown_84154E8[];
+static const struct BgTemplate gUnknown_8415A08[] = {
+ {
+ .bg = 0,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 31,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 0,
+ .baseTile = 1,
+ }, {
+ .bg = 1,
+ .charBaseIndex = 1,
+ .mapBaseIndex = 29,
+ .screenSize = 1,
+ .paletteMode = 0,
+ .priority = 1,
+ .baseTile = 0,
+ }
+};
+
+static const struct WindowTemplate gUnknown_8415A10[] = {
+ {
+ .bg = 0,
+ .tilemapLeft = 0,
+ .tilemapTop = 2,
+ .width = 29,
+ .height = 16,
+ .paletteNum = 15,
+ .baseBlock = 0x000
+ }, DUMMY_WIN_TEMPLATE
+};
static void VCBC_DiplomaOam(void)
{
@@ -245,10 +276,10 @@ static void DiplomaPrintText(void)
FillWindowPixelBuffer(0, 0);
DynamicPlaceholderTextUtil_ExpandPlaceholders(arr, gUnknown_841B60E);
width = GetStringWidth(2, arr, -1);
- AddTextPrinterParameterized3(0, 2, 0x78 - (width / 2), 4, gUnknown_8415A04, -1, arr);
+ AddTextPrinterParameterized3(0, 2, 0x78 - (width / 2), 4, &gUnknown_8415A04, -1, arr);
DynamicPlaceholderTextUtil_ExpandPlaceholders(arr, gUnknown_841B619);
width = GetStringWidth(2, arr, -1);
- AddTextPrinterParameterized3(0, 0x2, 0x78 - (width / 2), 0x1E, gUnknown_8415A04, -1, arr);
- AddTextPrinterParameterized3(0, 0x2, 0x78, 0x69, gUnknown_8415A04, 0, gUnknown_841B684);
+ AddTextPrinterParameterized3(0, 0x2, 0x78 - (width / 2), 0x1E, &gUnknown_8415A04, -1, arr);
+ AddTextPrinterParameterized3(0, 0x2, 0x78, 0x69, &gUnknown_8415A04, 0, gUnknown_841B684);
PutWindowTilemap(0);
}