mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-01-27 13:53:52 +01:00
Merge pull request #2335 from AsparagusEduardo/RHH/pr/MultiBattleFix
Multi battle interface fix
This commit is contained in:
commit
ff42806e04
@ -767,7 +767,9 @@ static void InitLastUsedBallAssets(void)
|
|||||||
// This function is here to cover a specific case - one player's mon in a 2 vs 1 double battle. In this scenario - display singles layout.
|
// This function is here to cover a specific case - one player's mon in a 2 vs 1 double battle. In this scenario - display singles layout.
|
||||||
u32 WhichBattleCoords(u32 battlerId) // 0 - singles, 1 - doubles
|
u32 WhichBattleCoords(u32 battlerId) // 0 - singles, 1 - doubles
|
||||||
{
|
{
|
||||||
if (GetBattlerPosition(battlerId) == B_POSITION_PLAYER_LEFT && gPlayerPartyCount == 1)
|
if (GetBattlerPosition(battlerId) == B_POSITION_PLAYER_LEFT
|
||||||
|
&& gPlayerPartyCount == 1
|
||||||
|
&& !(gBattleTypeFlags & BATTLE_TYPE_MULTI))
|
||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
return IsDoubleBattle();
|
return IsDoubleBattle();
|
||||||
|
@ -6157,10 +6157,10 @@ void ChooseMonForWirelessMinigame(void)
|
|||||||
|
|
||||||
static u8 GetPartyLayoutFromBattleType(void)
|
static u8 GetPartyLayoutFromBattleType(void)
|
||||||
{
|
{
|
||||||
if (!IsDoubleBattle() || gPlayerPartyCount == 1) // Draw the single layout in a double battle where the player has only one pokemon.
|
|
||||||
return PARTY_LAYOUT_SINGLE;
|
|
||||||
if (IsMultiBattle() == TRUE)
|
if (IsMultiBattle() == TRUE)
|
||||||
return PARTY_LAYOUT_MULTI;
|
return PARTY_LAYOUT_MULTI;
|
||||||
|
if (!IsDoubleBattle() || gPlayerPartyCount == 1) // Draw the single layout in a double battle where the player has only one pokemon.
|
||||||
|
return PARTY_LAYOUT_SINGLE;
|
||||||
return PARTY_LAYOUT_DOUBLE;
|
return PARTY_LAYOUT_DOUBLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user