diff --git a/charmap.txt b/charmap.txt index 4c9f2e0497..e5a901d6d9 100644 --- a/charmap.txt +++ b/charmap.txt @@ -45,6 +45,7 @@ SUPER_ER = 2C LV = 34 '=' = 35 ';' = 36 +V_D_ARROW = 38 '¿' = 51 '¡' = 52 PK = 53 diff --git a/gflib/characters.h b/gflib/characters.h index 8ed440e63a..3725cecce0 100644 --- a/gflib/characters.h +++ b/gflib/characters.h @@ -53,6 +53,7 @@ #define CHAR_EQUALS 0x35 #define CHAR_SEMICOLON 0x36 #define CHAR_BARD_WORD_DELIMIT 0x37 // Empty space to separate words in Bard's song +#define CHAR_V_D_ARROW 0x38 #define CHAR_INV_QUESTION_MARK 0x51 #define CHAR_INV_EXCL_MARK 0x52 #define CHAR_PK 0x53 diff --git a/graphics/fonts/latin_normal.png b/graphics/fonts/latin_normal.png index ade914858f..d1de69d136 100644 Binary files a/graphics/fonts/latin_normal.png and b/graphics/fonts/latin_normal.png differ diff --git a/include/config/battle.h b/include/config/battle.h index 8ddea8e311..99476b4f83 100644 --- a/include/config/battle.h +++ b/include/config/battle.h @@ -203,6 +203,9 @@ // Flag and Var settings #define B_RESET_FLAGS_VARS_AFTER_WHITEOUT TRUE // If TRUE, Overworld_ResetBattleFlagsAndVars will reset battle-related Flags and Vars when the player whites out. +// Ingame partner flag +#define B_SHOW_PARTNER_TARGET FALSE // Shows the battler partner will target. + // Terrain settings #define B_TERRAIN_BG_CHANGE TRUE // If set to TRUE, terrain moves permanently change the default battle background until the effect fades. #define B_THUNDERSTORM_TERRAIN TRUE // If TRUE, overworld Thunderstorm generates Rain and Electric Terrain as in Gen 8. diff --git a/src/battle_controller_player.c b/src/battle_controller_player.c index 52507157e7..5992a03ee6 100644 --- a/src/battle_controller_player.c +++ b/src/battle_controller_player.c @@ -2053,7 +2053,41 @@ static void PlayerHandleChooseAction(u32 battler) ActionSelectionCreateCursorAt(gActionSelectionCursor[battler], 0); PREPARE_MON_NICK_BUFFER(gBattleTextBuff1, battler, gBattlerPartyIndexes[battler]); BattleStringExpandPlaceholdersToDisplayedString(gText_WhatWillPkmnDo); - BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_ACTION_PROMPT); + + if (B_SHOW_PARTNER_TARGET && gBattleTypeFlags & BATTLE_TYPE_INGAME_PARTNER && IsBattlerAlive(B_POSITION_PLAYER_RIGHT)) + { + StringCopy(gStringVar1, COMPOUND_STRING("Partner will use:\n")); + u32 move = gBattleMons[B_POSITION_PLAYER_RIGHT].moves[*(gBattleStruct->chosenMovePositions + B_POSITION_PLAYER_RIGHT)]; + StringAppend(gStringVar1, gMovesInfo[move].name); + if (gMovesInfo[move].target == MOVE_TARGET_SELECTED) + { + if (gBattleStruct->aiChosenTarget[B_POSITION_PLAYER_RIGHT] == B_POSITION_OPPONENT_LEFT) + StringAppend(gStringVar1, COMPOUND_STRING(" -{UP_ARROW}")); + else if (gBattleStruct->aiChosenTarget[B_POSITION_PLAYER_RIGHT] == B_POSITION_OPPONENT_RIGHT) + StringAppend(gStringVar1, COMPOUND_STRING(" {UP_ARROW}-")); + else if (gBattleStruct->aiChosenTarget[B_POSITION_PLAYER_RIGHT] == B_POSITION_PLAYER_LEFT) + StringAppend(gStringVar1, COMPOUND_STRING(" {DOWN_ARROW}-")); + else if (gBattleStruct->aiChosenTarget[B_POSITION_PLAYER_RIGHT] == B_POSITION_PLAYER_RIGHT) + StringAppend(gStringVar1, COMPOUND_STRING(" {DOWN_ARROW}-")); + } + else if (gMovesInfo[move].target == MOVE_TARGET_BOTH) + { + StringAppend(gStringVar1, COMPOUND_STRING(" {UP_ARROW}{UP_ARROW}")); + } + else if (gMovesInfo[move].target == MOVE_TARGET_FOES_AND_ALLY) + { + StringAppend(gStringVar1, COMPOUND_STRING(" {V_D_ARROW}{UP_ARROW}")); + } + else if (gMovesInfo[move].target == MOVE_TARGET_ALL_BATTLERS) + { + StringAppend(gStringVar1, COMPOUND_STRING(" {V_D_ARROW}{V_D_ARROW}")); + } + BattlePutTextOnWindow(gStringVar1, B_WIN_ACTION_PROMPT); + } + else + { + BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_ACTION_PROMPT); + } } static void PlayerHandleYesNoBox(u32 battler) diff --git a/src/fonts.c b/src/fonts.c index 6bd2d35e83..3f2c536985 100644 --- a/src/fonts.c +++ b/src/fonts.c @@ -149,7 +149,7 @@ ALIGNED(4) const u8 gFontNormalLatinGlyphWidths[] = { 3, 6, 6, 6, 6, 6, 6, 6, 6, 6, 3, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 6, 6, 3, 6, 6, 6, 6, 6, 6, 3, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 6, 9, 7, 6, 3, - 3, 3, 3, 3, 10, 8, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 10, 8, 3, 3, 7, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 6, 6, 4, 8, 8, 8, 7, 8, 8, 4, 6, 6, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 6, 3, 3, 3, 3, 3, 3, 6,