forked from DizzyEggg/pokeemerald
-
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
Add B_SHOW_TYPES and cleaned up IsDoubleBattle #5131
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Type icons
AlexOn1ine
reviewed
Aug 10, 2024
AlexOn1ine
previously approved these changes
Aug 10, 2024
Removed BATTLE_TYPE_IS_DOUBLE Removed IS_DOUBLE_BATTLE
pkmnsnfrn
changed the title
Add B_SHOW_TYPES and BATTLE_TYPE_IS_DOUBLE
Add B_SHOW_TYPES and cleaned up IsDoubleBattle
Aug 10, 2024
AlexOn1ine
reviewed
Aug 10, 2024
Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
AlexOn1ine
reviewed
Aug 10, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
few more things and then it is done
AlexOn1ine
reviewed
Aug 11, 2024
pkmnsnfrn
commented
Aug 11, 2024
AlexOn1ine
approved these changes
Aug 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
B_SHOW_TYPES
toinclude/config/battle.h
. When set to a non-zero value, the types of all Pokemon on the field are shown when the player is selecting a move.gBattleTypeFlags & BATTLE_TYPE_DOUBLE
withIsDoubleBattle()
.Details
Usage
In
include/config/battle.h
, developers must define which settingB_SHOW_TYPES
should use.B_SHOW_TYPES == SHOW_TYPES_NEVER
libero.mp4
This feature is completely disabled.
B_SHOW_TYPES == SHOW_TYPES_ALWAYS
stellarillusion.mp4
The types of enemy Pokemon are always shown.
B_SHOW_TYPES == SHOW_TYPES_CAUGHT
caught.mp4
If the player has registered the enemy Pokemon in the Pokedex, their types are shown. Otherwise
TYPE_MYSTERY
is shown.Special Cases
Unknown Types
When a Pokemon type is
TYPE_NONE
orTYPE_MYSTERY
, the icon forTYPE_MYSTERY
is shown.Third Types
This feature does not display third types.
Type Changes
When a Pokemon's type changes, the mon's current type is shown.
Transform
If a Pokemon is transformed into another species, the types from the target species is shown.
Tera
When a Pokemon uses the Terastal phenomenon, its Tera Type is shown.
Stellar
When a Pokemon uses the Terastal phenomenon,
TYPE_STELLAR
as its Tera Type, the Pokemon's original typing is shown.Illusion
If a Pokemon is casting an Illusion as another mon, the types from the target species is shown.
Illusion and Stellar
If a Pokemon is casting an Illusion as another mon, but then uses the Terastal phenomenon and has
TYPE_STELLAR
as its Tera Type, the types from the target species is shown.Testing
Clean Branch
You can recreate this branch by applying a patch or pulling the repo. From a clean version of expansion's upcoming, you can either:
Patch
wget https://files.catbox.moe/nqyk6d.patch -O typeIcons.patch ; git apply typeIcons.patch ; rm typeIcons.patch
Repo
git remote add psf-expansion https://github.com/PokemonSanFran/pokeemerald-expansion/ ; git pull psf-expansion typeIcons
Manual Tests
After replicating the branch, to recreate my testing environment, you can either directly download the debug script, or manually create the changes.
Download
B_SHOW_TYPES == SHOW_TYPES_ALWAYS
wget https://files.catbox.moe/ytgdqh.h -O include/config/battle.h && wget https://files.catbox.moe/y1ydoe.inc -O data/scripts/debug.inc
B_SHOW_TYPES == SHOW_TYPES_CAUGHT
wget https://files.catbox.moe/w22acw.h -O include/config/battle.h && wget https://files.catbox.moe/y1ydoe.inc -O data/scripts/debug.inc
Manual Testing
B_SHOW_TYPES
to its desired value in include/config/battle.hVerified Scenarios
B_SHOW_TYPES == SHOW_TYPES_NEVER
never.mp4
B_SHOW_TYPES == SHOW_TYPES_ALWAYS
libero.mp4
B_SHOW_TYPES == SHOW_TYPES_CAUGHT
caught.mp4
Pokemon gets Third Type via Forest's Curse // Script 2
forestcurse.mp4
Pokemon loses type from Burn Up // Script 2
burnup.mp4
Pokemon changes its type via Color Change // Script 2
colorchange.mp4
Pokemon changes its type via Libero // Script 6
libero.mp4
Pokemon transforms into another Pokemon // Script 3
transform.mp4
Pokemon triggers Mega Evolution // Script 5
megaillusion.mp4
Pokemon casts an Illusion // Script 5
megaillusion.mp4
Pokemon casts an Illusion and uses the Terastal phenomenon // Script 5
megaillusion.mp4
Pokemon casts an Illusion and uses the Terastal phenomenon with Stellar Type // Script 7
stellarillusion.mp4
People who collaborated with me in this PR
This was taken from CRFU, written by @Skeli789 @fdeblasio, @ravepossum, @TeamAquasHideout all helped.
Features this PR does NOT handle:
Discord Contact Info
I am
pkmnsnfrn
on Discord.