mirror of
https://github.com/thornAvery/jep-hack.git
synced 2026-02-06 16:15:24 +13:00
First Commit
Upload literally everything from the pokecrystal16 expand-move-ID branch
This commit is contained in:
commit
2f8a41f833
4618 changed files with 480386 additions and 0 deletions
46
engine/events/battle_tower/get_trainer_class.asm
Normal file
46
engine/events/battle_tower/get_trainer_class.asm
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
GetMobileOTTrainerClass: ; mobile function
|
||||
ld h, b
|
||||
ld l, c
|
||||
call .GetMobileOTTrainerClass
|
||||
ld c, a
|
||||
ret
|
||||
|
||||
.GetMobileOTTrainerClass:
|
||||
ld a, [hli]
|
||||
xor [hl]
|
||||
ld c, a
|
||||
jr z, .skip_male_trainers
|
||||
srl c
|
||||
srl c
|
||||
.male_trainer_loop
|
||||
srl c
|
||||
ld a, c
|
||||
cp MaleTrainers.End - MaleTrainers - 1
|
||||
jr nc, .male_trainer_loop
|
||||
inc c
|
||||
|
||||
.skip_male_trainers
|
||||
ld a, [de]
|
||||
cp FEMALE
|
||||
ld hl, MaleTrainers
|
||||
jr nz, .finished
|
||||
|
||||
ld hl, FemaleTrainers
|
||||
ld a, c
|
||||
and a
|
||||
jr z, .finished
|
||||
|
||||
.female_trainer_loop
|
||||
srl c
|
||||
ld a, c
|
||||
cp FemaleTrainers.End - FemaleTrainers - 1
|
||||
jr nc, .female_trainer_loop
|
||||
inc c
|
||||
|
||||
.finished
|
||||
ld b, $0
|
||||
add hl, bc
|
||||
ld a, [hl]
|
||||
ret
|
||||
|
||||
INCLUDE "data/trainers/gendered_trainers.asm"
|
||||
Loading…
Add table
Add a link
Reference in a new issue