summaryrefslogtreecommitdiff
path: root/engine/predefs17_2.asm
diff options
context:
space:
mode:
Diffstat (limited to 'engine/predefs17_2.asm')
-rwxr-xr-xengine/predefs17_2.asm15
1 files changed, 15 insertions, 0 deletions
diff --git a/engine/predefs17_2.asm b/engine/predefs17_2.asm
new file mode 100755
index 00000000..a1c4ff30
--- /dev/null
+++ b/engine/predefs17_2.asm
@@ -0,0 +1,15 @@
+; updates the types of a party mon (pointed to in hl) to the ones of the mon specified in $d11e
+SetPartyMonTypes: ; 5db5e (17:5b5e)
+ call Load16BitRegisters
+ ld bc, W_PARTYMON1_TYPE1 - W_PARTYMON1DATA ; $5
+ add hl, bc
+ ld a, [$d11e]
+ ld [$d0b5], a
+ push hl
+ call GetMonHeader
+ pop hl
+ ld a, [W_MONHTYPE1]
+ ld [hli], a
+ ld a, [W_MONHTYPE2]
+ ld [hl], a
+ ret