mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 11:44:17 +01:00
Merge remote-tracking branch 'RHH/battle_engine' into MergedBranchUltimate
This commit is contained in:
commit
2b7a2c4d09
@ -467,16 +467,16 @@ BattleScript_EffectCourtChange::
|
||||
attackanimation
|
||||
waitanimation
|
||||
printstring STRINGID_COURTCHANGE
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
goto BattleScript_MoveEnd
|
||||
|
||||
BattleScript_BeakBlastSetUp::
|
||||
setbeakblast BS_ATTACKER
|
||||
printstring STRINGID_EMPTYSTRING3
|
||||
waitmessage 0x1
|
||||
waitmessage 1
|
||||
playanimation BS_ATTACKER, B_ANIM_BEAK_BLAST_SETUP, NULL
|
||||
printstring STRINGID_HEATUPBEAK
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
end2
|
||||
|
||||
BattleScript_BeakBlastBurn::
|
||||
@ -506,7 +506,7 @@ BattleScript_FirstChargingTurnMeteorBeam::
|
||||
seteffectprimary
|
||||
copybyte cMULTISTRING_CHOOSER, sTWOTURN_STRINGID
|
||||
printfromtable gFirstTurnOfTwoStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
setmoveeffect MOVE_EFFECT_SP_ATK_PLUS_1 | MOVE_EFFECT_AFFECTS_USER
|
||||
seteffectsecondary
|
||||
return
|
||||
@ -539,24 +539,24 @@ BattleScript_ScaleShotDoMultiHit::
|
||||
healthbarupdate BS_TARGET
|
||||
datahpupdate BS_TARGET
|
||||
critmessage
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
multihitresultmessage
|
||||
printstring STRINGID_EMPTYSTRING3
|
||||
waitmessage 0x1
|
||||
waitmessage 1
|
||||
addbyte sMULTIHIT_STRING + 4, 0x1
|
||||
moveendto MOVEEND_NEXT_TARGET
|
||||
jumpifbyte CMP_COMMON_BITS, gMoveResultFlags, MOVE_RESULT_FOE_ENDURED, BattleScript_ScaleShotPrintStrings
|
||||
decrementmultihit BattleScript_ScaleShotLoop
|
||||
goto BattleScript_ScaleShotPrintStrings
|
||||
BattleScript_ScaleShotMultiHitNoMoreHits::
|
||||
pause 0x20
|
||||
pause B_WAIT_TIME_SHORT
|
||||
BattleScript_ScaleShotPrintStrings::
|
||||
resultmessage
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
jumpifmovehadnoeffect BattleScript_ScaleShotEnd
|
||||
copyarray gBattleTextBuff1, sMULTIHIT_STRING, 0x6
|
||||
printstring STRINGID_HITXTIMES
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ScaleShotEnd::
|
||||
setmoveeffect MOVE_EFFECT_SCALE_SHOT | MOVE_EFFECT_AFFECTS_USER | MOVE_EFFECT_CERTAIN
|
||||
seteffectwithchance
|
||||
@ -9519,7 +9519,7 @@ BattleScript_ZMoveActivateDamaging::
|
||||
printstring STRINGID_ZPOWERSURROUNDS
|
||||
playanimation BS_ATTACKER, B_ANIM_ZMOVE_ACTIVATE, NULL
|
||||
printstring STRINGID_ZMOVEUNLEASHED
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
return
|
||||
|
||||
BattleScript_ZMoveActivateStatus::
|
||||
@ -9533,14 +9533,14 @@ BattleScript_ZMoveActivateStatus::
|
||||
|
||||
BattleScript_ZEffectPrintString::
|
||||
printfromtable gZEffectStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
return
|
||||
|
||||
BattleScript_RecoverHPZMove::
|
||||
healthbarupdate BS_SCRIPTING
|
||||
datahpupdate BS_SCRIPTING
|
||||
printfromtable gZEffectStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
return
|
||||
|
||||
BattleScript_StatUpZMove::
|
||||
@ -9549,16 +9549,16 @@ BattleScript_StatUpZMove::
|
||||
setgraphicalstatchangevalues
|
||||
playanimation BS_ATTACKER, B_ANIM_STATS_CHANGE, sB_ANIM_ARG1
|
||||
printstring STRINGID_ZMOVESTATUP
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_StatUpZMoveEnd:
|
||||
return
|
||||
|
||||
BattleScript_HealReplacementZMove::
|
||||
playanimation BS_SCRIPTING B_ANIM_WISH_HEAL 0x0
|
||||
printfromtable gZEffectStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
healthbarupdate BS_SCRIPTING
|
||||
datahpupdate BS_SCRIPTING
|
||||
return
|
||||
@ -9582,27 +9582,27 @@ BattleScript_ExtremeEvoboostAtk::
|
||||
setstatchanger STAT_ATK, 2, FALSE
|
||||
statbuffchange MOVE_EFFECT_AFFECTS_USER | STAT_BUFF_ALLOW_PTR, BattleScript_ExtremeEvoboostDef
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ExtremeEvoboostDef::
|
||||
setstatchanger STAT_DEF, 2, FALSE
|
||||
statbuffchange MOVE_EFFECT_AFFECTS_USER | STAT_BUFF_ALLOW_PTR, BattleScript_ExtremeEvoboostSpeed
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ExtremeEvoboostSpeed::
|
||||
setstatchanger STAT_SPEED, 2, FALSE
|
||||
statbuffchange MOVE_EFFECT_AFFECTS_USER | STAT_BUFF_ALLOW_PTR, BattleScript_ExtremeEvoboostSpAtk
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ExtremeEvoboostSpAtk::
|
||||
setstatchanger STAT_SPATK, 2, FALSE
|
||||
statbuffchange MOVE_EFFECT_AFFECTS_USER | STAT_BUFF_ALLOW_PTR, BattleScript_ExtremeEvoboostSpDef
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ExtremeEvoboostSpDef::
|
||||
setstatchanger STAT_SPDEF, 2, FALSE
|
||||
statbuffchange MOVE_EFFECT_AFFECTS_USER | STAT_BUFF_ALLOW_PTR, BattleScript_ExtremeEvoboostEnd
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
BattleScript_ExtremeEvoboostEnd::
|
||||
goto BattleScript_MoveEnd
|
||||
|
||||
@ -9622,9 +9622,9 @@ BattleScript_EffectTerrainHit:
|
||||
healthbarupdate BS_TARGET
|
||||
datahpupdate BS_TARGET
|
||||
critmessage
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
resultmessage
|
||||
waitmessage 0x40
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
setterrain BattleScript_TryFaint
|
||||
playanimation BS_ATTACKER, B_ANIM_RESTORE_BG
|
||||
printfromtable gTerrainStringIds
|
||||
|
@ -212,7 +212,7 @@ bool32 IsViableZMove(u8 battlerId, u16 move)
|
||||
|
||||
if (move != MOVE_NONE && zMove != MOVE_Z_STATUS && gBattleMoves[move].type == ItemId_GetSecondaryId(item))
|
||||
{
|
||||
if (IS_MOVE_STATUS(gBattleMoves[move].split))
|
||||
if (IS_MOVE_STATUS(move))
|
||||
gBattleStruct->zmove.chosenZMove = move;
|
||||
else
|
||||
gBattleStruct->zmove.chosenZMove = GetTypeBasedZMove(move, battlerId);
|
||||
@ -501,7 +501,7 @@ bool32 MoveSelectionDisplayZMove(u16 zmove)
|
||||
break;
|
||||
}
|
||||
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, 5); // Slot of Move 3
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MOVE_NAME_3);
|
||||
gDisplayedStringBattle[0] = CHAR_Z;
|
||||
gDisplayedStringBattle[1] = CHAR_HYPHEN;
|
||||
StringCopy(gDisplayedStringBattle + 2, gMoveNames[move]);
|
||||
@ -510,7 +510,7 @@ bool32 MoveSelectionDisplayZMove(u16 zmove)
|
||||
{
|
||||
// Damaging move -> status z move
|
||||
StringCopy(gDisplayedStringBattle, sText_StatsPlus2);
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, 5); // Slot of Move 3
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MOVE_NAME_3);
|
||||
StringCopy(gDisplayedStringBattle, GetZMoveName(zmove));
|
||||
}
|
||||
else
|
||||
@ -518,7 +518,7 @@ bool32 MoveSelectionDisplayZMove(u16 zmove)
|
||||
ZMoveSelectionDisplayPower(move, zmove);
|
||||
StringCopy(gDisplayedStringBattle, GetZMoveName(zmove));
|
||||
}
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, 3); // First move slot
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MOVE_NAME_1);
|
||||
|
||||
ZMoveSelectionDisplayPpNumber();
|
||||
MoveSelectionCreateCursorAt(0, 0);
|
||||
@ -540,7 +540,7 @@ static void ZMoveSelectionDisplayPower(u16 move, u16 zMove)
|
||||
{
|
||||
txtPtr = StringCopy(gDisplayedStringBattle, sText_PowerColon);
|
||||
ConvertIntToDecimalStringN(txtPtr, power, STR_CONV_MODE_LEFT_ALIGN, 3);
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, 5); // Bottom left
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MOVE_NAME_3);
|
||||
}
|
||||
}
|
||||
|
||||
@ -557,7 +557,7 @@ static void ZMoveSelectionDisplayPpNumber(void)
|
||||
txtPtr = ConvertIntToDecimalStringN(gDisplayedStringBattle, 1, STR_CONV_MODE_RIGHT_ALIGN, 2);
|
||||
*(txtPtr)++ = CHAR_SLASH;
|
||||
ConvertIntToDecimalStringN(txtPtr, 1, STR_CONV_MODE_RIGHT_ALIGN, 2);
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, 9);
|
||||
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_PP_REMAINING);
|
||||
}
|
||||
|
||||
const u8* GetZMoveName(u16 move)
|
||||
|
Loading…
Reference in New Issue
Block a user