Skip to content
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

Identify AI info in card data, rename AI score routines #156

Merged
merged 1 commit into from
Nov 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions bugs_and_glitches.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ DetermineAIScoreOfAttackEnergyRequirement:
jr nc, .check_evolution
.atk_kos_defending
ld a, 20
call AddToAIScore
call AIEncourage

-; this is possibly a bug.
-; this is an identical check as above to test whether this card is active.
Expand All @@ -72,7 +72,7 @@ DetermineAIScoreOfAttackEnergyRequirement:
or a
jr nz, .check_evolution
ld a, 10
call AddToAIScore
call AIEncourage
...
```

Expand Down
14 changes: 12 additions & 2 deletions src/constants/card_data_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@ DEF CARD_DATA_WEAKNESS EQU $33
DEF CARD_DATA_RESISTANCE EQU $34
DEF CARD_DATA_CATEGORY EQU $35
DEF CARD_DATA_POKEDEX_NUMBER EQU $37
DEF CARD_DATA_UNKNOWN1 EQU $38
DEF CARD_DATA_UNUSED EQU $38
DEF CARD_DATA_LEVEL EQU $39
DEF CARD_DATA_LENGTH EQU $3a
DEF CARD_DATA_WEIGHT EQU $3c
DEF CARD_DATA_PKMN_DESCRIPTION EQU $3e
DEF CARD_DATA_UNKNOWN2 EQU $40
DEF CARD_DATA_AI_INFO EQU $40

DEF PKMN_CARD_DATA_LENGTH EQU $41

Expand Down Expand Up @@ -251,3 +251,13 @@ DEF SECOND_ATTACK EQU $1
; has limit on attached energy cards boost.
DEF MAX_ENERGY_BOOST_IS_LIMITED EQU $2
DEF MAX_ENERGY_BOOST_IS_NOT_LIMITED EQU $3

; CARD_DATA_AI_INFO constants
DEF AI_INFO_BENCH_UTILITY EQU $1
DEF AI_INFO_ENCOURAGE_EVO EQU $2
DEF AI_INFO_UNK_03 EQU $3
DEF AI_INFO_UNK_05 EQU $5
DEF AI_INFO_UNK_08 EQU $8

DEF HAS_EVOLUTION_F EQU 4
DEF HAS_EVOLUTION EQU 1 << HAS_EVOLUTION_F
Loading