Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
cf85abc
Remove unused messages
AsparagusEduardo Jun 26, 2025
57da461
Ability status immunity
AsparagusEduardo Jun 26, 2025
c87d3b1
Merge branch '_RHH/upcoming' into _RHH/pr/upcoming/messages
AsparagusEduardo Aug 11, 2025
db0ca2c
Merge branch '_RHH/upcoming' into _RHH/pr/upcoming/messages
AsparagusEduardo Aug 11, 2025
d2acc2d
Changed instances of "But it failed" to "It doesn't affect X"
AsparagusEduardo Aug 11, 2025
b501fe7
Removed B_ABILITY_POP_UP
AsparagusEduardo Aug 11, 2025
02fea82
Cleaning up checks if battler benefits from status. Better logic for …
surskitty Aug 15, 2025
c37a689
Logic cleanup; making it non-static.
surskitty Aug 17, 2025
68127d0
Renaming function for clarity.
surskitty Aug 20, 2025
2ab1bc8
Start of 1.14 cycle
Aug 28, 2025
04622b2
Start of 1.14 (#7637)
pkmnsnfrn Aug 28, 2025
a2e1835
Separates FRB and FRZ animations (#7611)
grintoul1 Aug 28, 2025
f07112b
Text rendering optimizations (#7497)
mrgriffin Aug 28, 2025
5344d1e
Merge branch '_RHH/upcoming' into _RHH/pr/upcoming/messages
AsparagusEduardo Aug 28, 2025
9bfae7f
AI uses Magnetic Flux. (#7642)
surskitty Aug 29, 2025
16fa6c8
AI uses Flower Shield. (#7640)
surskitty Aug 29, 2025
3ff23ef
AI uses Life Dew. (#7643)
surskitty Aug 29, 2025
e1381dd
AI uses Gear Up. (#7641)
surskitty Aug 29, 2025
33686c3
Update multiple battle messages (#7529)
Bassoonian Aug 30, 2025
70068bf
Battle debug menu now checks correct parties depending on battler pa…
grintoul1 Aug 30, 2025
4fa26b2
Improved move additional effect handling; now accounts for Shield Dus…
surskitty Aug 30, 2025
cdaba90
Correcting test AI won't use status moves if partner chose Helping Ha…
surskitty Aug 30, 2025
674cd13
Added sortType to Douse Drive (#7664)
fdeblasio Aug 31, 2025
406e5b1
IncreaseStatUpScore adjustments for Simple, +3 moves, Acupressure, ma…
surskitty Sep 1, 2025
927f189
AI handling for Coaching. (#7661)
surskitty Sep 1, 2025
0a0d574
Simplifying calls to IsBattlerTrapped; treats being unable to switch …
surskitty Sep 1, 2025
84f5aa6
Helping Hand bugfix; used FOE instead of BATTLE_OPPOSITE. (#7659)
surskitty Sep 1, 2025
2f75c6a
Score adjustments towards guaranteed stat drops. (#7670)
surskitty Sep 2, 2025
cfcdd5f
Fix crashing tests duplicating tests from another thread (#7683)
hedara90 Sep 2, 2025
837047e
Merge branch 'master' into master-to-upcoming
Sep 2, 2025
619ee56
Mark failing test that was masked
Sep 2, 2025
ee0953a
Master to upcoming, 2025-09-02 (#7684)
pkmnsnfrn Sep 2, 2025
02123bf
Merge branch 'upcoming' of https://github.com/rh-hideout/pokeemerald-…
surskitty Sep 2, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions data/battle_anim_scripts.s
Original file line number Diff line number Diff line change
Expand Up @@ -31084,6 +31084,17 @@ gBattleAnimStatus_Nightmare::
clearmonbg ANIM_DEF_PARTNER
end

gBattleAnimStatus_Frostbite::
playsewithpan SE_M_ICY_WIND, 0
loadspritegfx ANIM_TAG_ICE_CRYSTALS
monbg ANIM_DEF_PARTNER
splitbgprio ANIM_TARGET
call IceCrystalEffectShort
createsprite gSimplePaletteBlendSpriteTemplate, ANIM_ATTACKER, 2, F_PAL_TARGET, 5, 7, 0, RGB(0, 20, 31)
waitforvisualfinish
clearmonbg ANIM_DEF_PARTNER
end

gBattleAnimGeneral_StatsChange::
createvisualtask AnimTask_StatsChange, 5
waitforvisualfinish
Expand Down
33 changes: 1 addition & 32 deletions data/battle_scripts_1.s
Original file line number Diff line number Diff line change
Expand Up @@ -207,10 +207,8 @@ BattleScript_EffectDoodle::
BattleScript_EffectDoodle_CopyAbility:
trycopyability BS_ATTACKER, BattleScript_EffectDoodleMoveEnd
BattleScript_EffectDoodle_AfterCopy:
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerAttacker
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_ATTACKER
printstring STRINGID_PKMNCOPIEDFOE
waitmessage B_WAIT_TIME_LONG
Expand Down Expand Up @@ -2226,10 +2224,8 @@ BattleScript_EffectSimpleBeam::
setsimplebeam BattleScript_ButItFailed
attackanimation
waitanimation
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerTarget
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_TARGET
printstring STRINGID_PKMNACQUIREDSIMPLE
waitmessage B_WAIT_TIME_LONG
Expand Down Expand Up @@ -2328,10 +2324,8 @@ BattleScript_EffectWorrySeed::
tryworryseed BattleScript_ButItFailed
attackanimation
waitanimation
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerTarget
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_TARGET
printstring STRINGID_PKMNACQUIREDABILITY
waitmessage B_WAIT_TIME_LONG
Expand Down Expand Up @@ -2804,14 +2798,6 @@ BattleScript_AromaVeilProtects:
setmoveresultflags MOVE_RESULT_FAILED
goto BattleScript_MoveEnd

BattleScript_PastelVeilProtects:
pause B_WAIT_TIME_SHORT
call BattleScript_AbilityPopUp
printstring STRINGID_PASTELVEILPROTECTED
waitmessage B_WAIT_TIME_LONG
setmoveresultflags MOVE_RESULT_FAILED
goto BattleScript_MoveEnd

BattleScript_AbilityProtectsDoesntAffectRet::
pause B_WAIT_TIME_SHORT
call BattleScript_AbilityPopUp
Expand Down Expand Up @@ -3127,10 +3113,7 @@ BattleScript_AlreadyPoisoned::

BattleScript_ImmunityProtected::
call BattleScript_AbilityPopUp
pause B_WAIT_TIME_SHORT
printfromtable gStatusPreventionStringIds
waitmessage B_WAIT_TIME_LONG
goto BattleScript_MoveEnd
goto BattleScript_DoesntAffectTargetAtkString

BattleScript_EffectAuroraVeil::
attackcanceler
Expand Down Expand Up @@ -4671,10 +4654,8 @@ BattleScript_EffectRolePlay::
trycopyability BS_ATTACKER, BattleScript_ButItFailed
attackanimation
waitanimation
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerAttacker
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_ATTACKER
printstring STRINGID_PKMNCOPIEDFOE
waitmessage B_WAIT_TIME_LONG
Expand Down Expand Up @@ -4806,13 +4787,11 @@ BattleScript_EffectSkillSwap::
attackanimation
waitanimation
jumpiftargetally BattleScript_EffectSkillSwap_AfterAbilityPopUp
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerAttacker
call BattleScript_AbilityPopUpOverwriteThenNormal
copybyte gBattlerAbility, gBattlerTarget
copyhword sABILITY_OVERWRITE, gLastUsedAbility
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
BattleScript_EffectSkillSwap_AfterAbilityPopUp:
recordability BS_ATTACKER
recordability BS_TARGET
Expand Down Expand Up @@ -7102,10 +7081,8 @@ BattleScript_AbilityPopUpTarget::
copybyte gBattlerAbility, gBattlerTarget
BattleScript_AbilityPopUp::
tryactivateabilityshield BS_ABILITY_BATTLER
.if B_ABILITY_POP_UP == TRUE
showabilitypopup
pause B_WAIT_TIME_SHORT
.endif
recordability BS_ABILITY_BATTLER
sethword sABILITY_OVERWRITE, 0
return
Expand Down Expand Up @@ -7156,11 +7133,9 @@ BattleScript_MoodyEnd:
end3

BattleScript_EmergencyExit::
.if B_ABILITY_POP_UP == TRUE
pause 5
call BattleScript_AbilityPopUpScripting
pause B_WAIT_TIME_LONG
.endif
playanimation BS_SCRIPTING, B_ANIM_SLIDE_OFFSCREEN
waitanimation
openpartyscreen BS_SCRIPTING, BattleScript_EmergencyExitRet
Expand All @@ -7179,11 +7154,9 @@ BattleScript_EmergencyExitRet:
return

BattleScript_EmergencyExitWild::
.if B_ABILITY_POP_UP == TRUE
pause 5
call BattleScript_AbilityPopUpScripting
pause B_WAIT_TIME_LONG
.endif
playanimation BS_SCRIPTING, B_ANIM_SLIDE_OFFSCREEN
waitanimation
setteleportoutcome BS_SCRIPTING
Expand Down Expand Up @@ -7914,13 +7887,11 @@ BattleScript_CursedBodyActivates::
return

BattleScript_MummyActivates::
.if B_ABILITY_POP_UP == TRUE
setbyte sFIXED_ABILITY_POPUP, TRUE
call BattleScript_AbilityPopUpTarget
copybyte gBattlerAbility, gBattlerAttacker
copyhword sABILITY_OVERWRITE, gLastUsedAbility
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_TARGET
recordability BS_ATTACKER
printstring STRINGID_ATTACKERACQUIREDABILITY
Expand All @@ -7930,14 +7901,12 @@ BattleScript_MummyActivates::
BattleScript_WanderingSpiritActivates::
saveattacker
savetarget
.if B_ABILITY_POP_UP == TRUE
copybyte gBattlerAbility, gBattlerTarget
sethword sABILITY_OVERWRITE, ABILITY_WANDERING_SPIRIT
call BattleScript_AbilityPopUpOverwriteThenNormal
copybyte gBattlerAbility, gBattlerAttacker
copyhword sABILITY_OVERWRITE, gLastUsedAbility
call BattleScript_AbilityPopUpOverwriteThenNormal
.endif
recordability BS_TARGET
recordability BS_ATTACKER
printstring STRINGID_SWAPPEDABILITIES
Expand Down
5 changes: 5 additions & 0 deletions include/battle_ai_main.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ enum StatChange
STAT_CHANGE_SPEED_2,
STAT_CHANGE_SPATK_2,
STAT_CHANGE_SPDEF_2,
STAT_CHANGE_ATK_3,
STAT_CHANGE_DEF_3,
STAT_CHANGE_SPEED_3,
STAT_CHANGE_SPATK_3,
STAT_CHANGE_SPDEF_3,
STAT_CHANGE_ACC,
STAT_CHANGE_EVASION
};
Expand Down
1 change: 1 addition & 0 deletions include/battle_ai_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ bool32 CanTargetFaintAiWithMod(u32 battlerDef, u32 battlerAtk, s32 hpMod, s32 dm
s32 AI_DecideKnownAbilityForTurn(u32 battlerId);
enum ItemHoldEffect AI_DecideHoldEffectForTurn(u32 battlerId);
bool32 DoesBattlerIgnoreAbilityChecks(u32 battlerAtk, u32 atkAbility, u32 move);
bool32 DoesBattlerBenefitFromNonvolatileStatus(u32 battler, u32 ability, u32 status);
u32 AI_GetWeather(void);
u32 AI_GetSwitchinWeather(struct BattlePokemon battleMon);
enum WeatherState IsWeatherActive(u32 flags);
Expand Down
1 change: 1 addition & 0 deletions include/battle_anim_scripts.h
Original file line number Diff line number Diff line change
Expand Up @@ -948,6 +948,7 @@ extern const u8 gBattleAnimStatus_Paralysis[];
extern const u8 gBattleAnimStatus_Freeze[];
extern const u8 gBattleAnimStatus_Curse[];
extern const u8 gBattleAnimStatus_Nightmare[];
extern const u8 gBattleAnimStatus_Frostbite[];

// general animations
extern const u8 gBattleAnimGeneral_StatsChange[];
Expand Down
1 change: 0 additions & 1 deletion include/config/battle.h
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,6 @@
#define B_NEW_TERRAIN_BACKGROUNDS FALSE // If set to TRUE, uses new terrain backgrounds for Electric, Misty, Grassy and Psychic Terrain.

// Interface settings
#define B_ABILITY_POP_UP TRUE // In Gen5+, the Pokémon abilities are displayed in a pop-up, when they activate in battle.
#define B_FAST_INTRO_PKMN_TEXT TRUE // If set to TRUE, battle intro texts print at the same time as animation of a Pokémon, as opposing to waiting for the animation to end.
#define B_FAST_INTRO_NO_SLIDE FALSE // If set to TRUE, the slide animation that happens at the beginning of the battle is skipped.
#define B_FAST_HP_DRAIN TRUE // If set to TRUE, HP bars will move faster.
Expand Down
3 changes: 2 additions & 1 deletion include/constants/battle_anim.h
Original file line number Diff line number Diff line change
Expand Up @@ -616,8 +616,9 @@
#define B_ANIM_STATUS_FRZ 6
#define B_ANIM_STATUS_CURSED 7
#define B_ANIM_STATUS_NIGHTMARE 8
#define B_ANIM_STATUS_FRB 9

#define NUM_B_ANIMS_STATUS 9
#define NUM_B_ANIMS_STATUS 10

// Tasks with return values often assign them to gBattleAnimArgs[7].
#define ARG_RET_ID 7
Expand Down
27 changes: 0 additions & 27 deletions include/constants/battle_string_ids.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,19 +61,15 @@ enum StringID
STRINGID_PKMNISPARALYZED,
STRINGID_PKMNISALREADYPARALYZED,
STRINGID_PKMNHEALEDPARALYSIS,
STRINGID_PKMNDREAMEATEN,
STRINGID_STATSWONTINCREASE,
STRINGID_STATSWONTDECREASE,
STRINGID_TEAMSTOPPEDWORKING,
STRINGID_FOESTOPPEDWORKING,
STRINGID_PKMNISCONFUSED,
STRINGID_PKMNHEALEDCONFUSION,
STRINGID_PKMNWASCONFUSED,
STRINGID_PKMNALREADYCONFUSED,
STRINGID_PKMNFELLINLOVE,
STRINGID_PKMNINLOVE,
STRINGID_PKMNIMMOBILIZEDBYLOVE,
STRINGID_PKMNBLOWNAWAY,
STRINGID_PKMNCHANGEDTYPE,
STRINGID_PKMNFLINCHED,
STRINGID_PKMNREGAINEDHEALTH,
Expand Down Expand Up @@ -179,7 +175,6 @@ enum StringID
STRINGID_PKMNREADYTOHELP,
STRINGID_PKMNSWITCHEDITEMS,
STRINGID_PKMNCOPIEDFOE,
STRINGID_PKMNMADEWISH,
STRINGID_PKMNWISHCAMETRUE,
STRINGID_PKMNPLANTEDROOTS,
STRINGID_PKMNABSORBEDNUTRIENTS,
Expand All @@ -201,9 +196,7 @@ enum StringID
STRINGID_PKMNPREVENTSUSAGE,
STRINGID_PKMNRESTOREDHPUSING,
STRINGID_PKMNCHANGEDTYPEWITH,
STRINGID_PKMNPREVENTSPARALYSISWITH,
STRINGID_PKMNPREVENTSROMANCEWITH,
STRINGID_PKMNPREVENTSPOISONINGWITH,
STRINGID_PKMNPREVENTSCONFUSIONWITH,
STRINGID_PKMNRAISEDFIREPOWERWITH,
STRINGID_PKMNANCHORSITSELFWITH,
Expand Down Expand Up @@ -250,7 +243,6 @@ enum StringID
STRINGID_HAILSTOPPED,
STRINGID_FAILEDTOSPITUP,
STRINGID_FAILEDTOSWALLOW,
STRINGID_WINDBECAMEHEATWAVE,
STRINGID_STATCHANGESGONE,
STRINGID_COINSSCATTERED,
STRINGID_TOOWEAKFORSUBSTITUTE,
Expand Down Expand Up @@ -307,7 +299,6 @@ enum StringID
STRINGID_ITEMALLOWSONLYYMOVE,
STRINGID_PKMNHUNGONWITHX,
STRINGID_EMPTYSTRING3,
STRINGID_PKMNSXPREVENTSBURNS,
STRINGID_PKMNSXBLOCKSY,
STRINGID_PKMNSXRESTOREDHPALITTLE2,
STRINGID_PKMNSXWHIPPEDUPSANDSTORM,
Expand All @@ -326,7 +317,6 @@ enum StringID
STRINGID_PLAYERDEFEATEDTRAINER1,
STRINGID_SOOTHINGAROMA,
STRINGID_ITEMSCANTBEUSEDNOW,
STRINGID_FORXCOMMAYZ,
STRINGID_USINGITEMSTATOFPKMNROSE,
STRINGID_PKMNUSEDXTOGETPUMPED,
STRINGID_PKMNSXMADEYUSELESS,
Expand All @@ -343,7 +333,6 @@ enum StringID
STRINGID_PKMNFLEDUSINGITS,
STRINGID_PKMNFLEDUSING,
STRINGID_PKMNWASDRAGGEDOUT,
STRINGID_PREVENTEDFROMWORKING,
STRINGID_PKMNSITEMNORMALIZEDSTATUS,
STRINGID_TRAINER1USEDITEM,
STRINGID_BOXISFULL,
Expand All @@ -354,17 +343,13 @@ enum StringID
STRINGID_STATSWONTDECREASE2,
STRINGID_PKMNSXBLOCKSY2,
STRINGID_PKMNSXWOREOFF,
STRINGID_PKMNRAISEDDEFALITTLE,
STRINGID_PKMNRAISEDSPDEFALITTLE,
STRINGID_THEWALLSHATTERED,
STRINGID_PKMNSXPREVENTSYSZ,
STRINGID_PKMNSXCUREDITSYPROBLEM,
STRINGID_ATTACKERCANTESCAPE,
STRINGID_PKMNOBTAINEDX,
STRINGID_PKMNOBTAINEDX2,
STRINGID_PKMNOBTAINEDXYOBTAINEDZ,
STRINGID_BUTNOEFFECT,
STRINGID_PKMNSXHADNOEFFECTONY,
STRINGID_TWOENEMIESDEFEATED,
STRINGID_TRAINER2LOSETEXT,
STRINGID_PKMNINCAPABLEOFPOWER,
Expand Down Expand Up @@ -597,7 +582,6 @@ enum StringID
STRINGID_BROKETHROUGHPROTECTION,
STRINGID_ABILITYALLOWSONLYMOVE,
STRINGID_SWAPPEDABILITIES,
STRINGID_PASTELVEILPROTECTED,
STRINGID_PASTELVEILENTERS,
STRINGID_BATTLERTYPECHANGEDTO,
STRINGID_BOTHCANNOLONGERESCAPE,
Expand Down Expand Up @@ -1049,17 +1033,6 @@ enum GotStatusedStringID
B_MSG_STATUSED_BY_ABILITY,
};

// gStatusPreventionStringIds
enum StatusPreventionStringID
{
B_MSG_ABILITY_PREVENTS_MOVE_BURN,
B_MSG_ABILITY_PREVENTS_MOVE_PARALYSIS,
B_MSG_ABILITY_PREVENTS_MOVE_POISON,
B_MSG_ABILITY_PREVENTS_ABILITY_STATUS,
B_MSG_STATUS_HAD_NO_EFFECT,
B_MSG_ABILITY_PASTEL_VEIL,
};

// gGotDefrostedStringIds
enum GotDefrostedStringID
{
Expand Down
4 changes: 2 additions & 2 deletions include/constants/expansion.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

// Last version: 1.13.0
#define EXPANSION_VERSION_MAJOR 1
#define EXPANSION_VERSION_MINOR 13
#define EXPANSION_VERSION_PATCH 1
#define EXPANSION_VERSION_MINOR 14
#define EXPANSION_VERSION_PATCH 0

// FALSE if this this version of Expansion is not a tagged commit, i.e.
// it contains unreleased changes.
Expand Down
2 changes: 1 addition & 1 deletion include/window.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ struct WindowTemplate
struct Window
{
struct WindowTemplate window;
u8 *tileData;
ALIGNED(4) u8 *tileData;
};

bool32 InitWindows(const struct WindowTemplate *templates);
Expand Down
Loading