summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Allow-more-trainer-parties,-with-individual-DVs,-stat-experience,-and-nicknames.md40
1 files changed, 20 insertions, 20 deletions
diff --git a/Allow-more-trainer-parties,-with-individual-DVs,-stat-experience,-and-nicknames.md b/Allow-more-trainer-parties,-with-individual-DVs,-stat-experience,-and-nicknames.md
index c3cbbe1..f258d85 100644
--- a/Allow-more-trainer-parties,-with-individual-DVs,-stat-experience,-and-nicknames.md
+++ b/Allow-more-trainer-parties,-with-individual-DVs,-stat-experience,-and-nicknames.md
@@ -284,26 +284,26 @@ Finally, edit [engine/overworld/wildmons.asm](../blob/master/engine/overworld/wi
- ; TRAINERTYPE_ITEM_MOVES
- ld bc, 2 + 1 + NUM_MOVES ; level, species, item, moves
-.got_mon_length
-; b = trainer type
- ld b, a
-; c = mon length
-; All trainers use 2 bytes for level and species
- ld c, 2
-; TRAINERTYPE_ITEM uses 1 more byte
- bit TRAINERTYPE_ITEM_F, b
- jr z, .no_item
- inc c
-.no_item
-; TRAINERTYPE_MOVES uses 4 more bytes
- bit TRAINERTYPE_MOVES_F, b
- jr z, .no_moves
- ld a, 4
- add c
- ld c, a
-.no_moves
-; bc = mon length
- xor a
- ld b, a
++; b = trainer type
++ ld b, a
++; c = mon length
++; All trainers use 2 bytes for level and species
++ ld c, 2
++; TRAINERTYPE_ITEM uses 1 more byte
++ bit TRAINERTYPE_ITEM_F, b
++ jr z, .no_item
++ inc c
++.no_item
++; TRAINERTYPE_MOVES uses 4 more bytes
++ bit TRAINERTYPE_MOVES_F, b
++ jr z, .no_moves
++ ld a, 4
++ add c
++ ld c, a
++.no_moves
++; bc = mon length
++ xor a
++ ld b, a
```
If we stopped here, the code would be cleaner and smaller, but would not do anything new. So let's continue.