summaryrefslogtreecommitdiff
path: root/src/start_menu.c
diff options
context:
space:
mode:
authorSlawter666 <38655737+Slawter666@users.noreply.github.com>2018-11-12 14:14:50 +0000
committerSlawter666 <38655737+Slawter666@users.noreply.github.com>2018-11-12 14:14:50 +0000
commit1b895ff52c011d51a9516791148cd5088ba411b5 (patch)
tree3f1dee86f96098d38131426e11a0f9c39a1244fe /src/start_menu.c
parentbe33878b94cc38913447682d3e34e674df68619f (diff)
parent65f053fd89e09b13e407ac53488043b728660e6e (diff)
Merge branch 'master' of https://github.com/pret/pokeemerald into synchronise
Diffstat (limited to 'src/start_menu.c')
-rw-r--r--src/start_menu.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/start_menu.c b/src/start_menu.c
index dcb2c4154..217d7be6a 100644
--- a/src/start_menu.c
+++ b/src/start_menu.c
@@ -12,7 +12,7 @@
#include "task.h"
#include "overworld.h"
#include "link.h"
-#include "battle_frontier_2.h"
+#include "frontier_util.h"
#include "rom_818CFC8.h"
#include "field_specials.h"
#include "event_object_movement.h"
@@ -35,6 +35,8 @@
#include "field_player_avatar.h"
#include "battle_pyramid_bag.h"
+extern bool8 InBattlePike(void);
+
// Menu actions
enum
{
@@ -383,14 +385,14 @@ static void ShowSafariBallsWindow(void)
static void ShowPyramidFloorWindow(void)
{
- if (gSaveBlock2Ptr->frontier.field_CB2 == 7)
+ if (gSaveBlock2Ptr->frontier.curChallengeBattleNum == 7)
sBattlePyramidFloorWindowId = AddWindow(&sPyramidFloorWindowTemplate_1);
else
sBattlePyramidFloorWindowId = AddWindow(&sPyramidFloorWindowTemplate_2);
PutWindowTilemap(sBattlePyramidFloorWindowId);
NewMenuHelpers_DrawStdWindowFrame(sBattlePyramidFloorWindowId, FALSE);
- StringCopy(gStringVar1, sPyramindFloorNames[gSaveBlock2Ptr->frontier.field_CB2]);
+ StringCopy(gStringVar1, sPyramindFloorNames[gSaveBlock2Ptr->frontier.curChallengeBattleNum]);
StringExpandPlaceholders(gStringVar4, gText_BattlePyramidFloor);
AddTextPrinterParameterized(sBattlePyramidFloorWindowId, 1, gStringVar4, 0, 1, 0xFF, NULL);
CopyWindowToVram(sBattlePyramidFloorWindowId, 2);
@@ -977,14 +979,14 @@ static u8 SaveConfirmSaveCallback(void)
static u8 SaveYesNoCallback(void)
{
- sub_8197930(); // Show Yes/No menu
+ DisplayYesNoMenu(); // Show Yes/No menu
sSaveDialogCallback = SaveConfirmInputCallback;
return SAVE_IN_PROGRESS;
}
static u8 SaveConfirmInputCallback(void)
{
- switch (Menu_ProcessInputNoWrap_())
+ switch (Menu_ProcessInputNoWrapClearOnChoose())
{
case 0: // Yes
switch (gSaveFileStatus)
@@ -1037,14 +1039,14 @@ static u8 SaveConfirmOverwriteNoCallback(void)
static u8 SaveConfirmOverwriteCallback(void)
{
- sub_8197930(); // Show Yes/No menu
+ DisplayYesNoMenu(); // Show Yes/No menu
sSaveDialogCallback = SaveOverwriteInputCallback;
return SAVE_IN_PROGRESS;
}
static u8 SaveOverwriteInputCallback(void)
{
- switch (Menu_ProcessInputNoWrap_())
+ switch (Menu_ProcessInputNoWrapClearOnChoose())
{
case 0: // Yes
sSaveDialogCallback = SaveSavingMessageCallback;
@@ -1168,7 +1170,7 @@ static u8 BattlePyramidRetireYesNoCallback(void)
static u8 BattlePyramidRetireInputCallback(void)
{
- switch (Menu_ProcessInputNoWrap_())
+ switch (Menu_ProcessInputNoWrapClearOnChoose())
{
case 0: // Yes
return SAVE_CANCELED;