-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Trainer Battle Parameter Consolidation #5982
base: upcoming
Are you sure you want to change the base?
Trainer Battle Parameter Consolidation #5982
Conversation
ready for review again |
is there anything to watch out with this. anything that you suspect might be broken? |
id say the less common battle types need some testing for sure. rematches, multi, facility etc. also some battles that have scripts running after them to make sure those arent broken. |
Consolidates almost all global trainer battle parameter into a global struct
Description
Introduces
gTrainerBattleParameter
a union of typeTrainerBattleParameter
. the struct holds most relevant parameter.the
trainerbattle
macro was changed to always take all parameters and copy them to the struct, instead of taking parameters depending on battle type.changed
TRAINER_BATTLE_SET_TRAINER_A/B
toTRAINER_BATTLE_SET_TRAINERS_FOR_MULTI_BATTLE
which takes both trainers always. for 2v1 multi battles leave the second trainer alsTRAINER_NONE
andNULL
for the defeat text.this PR does NOT handle:
this is part of #5938, which I decided to split into smaller prs. this PR does not do anything but consolidate the parameter.
Things to note in the release changelog:
Breaking: raw uses of
trainerbattle
need to be adjusted to provide all possible parameter. Unused parameter musst be 0 or an alias. already parameterized macros liketrainerbattle_single
work out of the box.Discord contact info
u8-Salem