summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/battle_records.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/battle_records.c b/src/battle_records.c
new file mode 100644
index 000000000..3290bbebe
--- /dev/null
+++ b/src/battle_records.c
@@ -0,0 +1,27 @@
+#include "global.h"
+#include "menu.h"
+
+extern const u8 gOtherText_BattleResults[];
+extern const u8 gOtherText_WinLoseDraw[];
+
+void PrintLinkBattleWinsLossesDraws(void *);
+
+void PrintLinkBattleRecord(void *, u8);
+
+void ShowLinkBattleRecords(void) {
+ s32 i;
+ MenuDrawTextWindow(1, 0, 28, 18);
+ sub_8072BD8((u8 *) gOtherText_BattleResults, 0, 1, 240);
+
+ PrintLinkBattleWinsLossesDraws(gSaveBlock1.linkBattleRecords);
+#if ENGLISH
+ MenuPrint(gOtherText_WinLoseDraw, 12, 6);
+#elif GERMAN
+ MenuPrint_PixelCoords((u8 *) gOtherText_WinLoseDraw, 88, 48, 1);
+#endif
+
+ for (i = 0; i < 5; i++)
+ {
+ PrintLinkBattleRecord(gSaveBlock1.linkBattleRecords[i], 6 + (i + 1) * 2);
+ }
+}