summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--asm/battle_4.s10
-rw-r--r--asm/battle_5.s10
-rw-r--r--asm/battle_7.s4290
-rw-r--r--asm/battle_anim_81258BC.s2
-rw-r--r--asm/battle_anim_8137220.s6
-rw-r--r--asm/battle_tower.s4
-rw-r--r--asm/berry_blender.s8
-rw-r--r--asm/cable_car.s4
-rw-r--r--asm/choose_party.s12
-rw-r--r--asm/contest.s6
-rw-r--r--asm/contest_link_80C2020.s2
-rw-r--r--asm/daycare.s4
-rw-r--r--asm/decoration_inventory.s404
-rw-r--r--asm/easy_chat.s6
-rw-r--r--asm/egg_hatch.s8
-rw-r--r--asm/evolution_scene.s16
-rw-r--r--asm/field_effect.s7738
-rw-r--r--asm/field_fadetransition.s28
-rw-r--r--asm/field_specials.s4
-rw-r--r--asm/fldeff_80C5CD4.s12
-rw-r--r--asm/fldeff_flash.s4
-rw-r--r--asm/item_menu.s34
-rw-r--r--asm/learn_move.s4
-rw-r--r--asm/mauville_old_man.s2
-rw-r--r--asm/menu_helpers.s18
-rw-r--r--asm/mon_markings.s4
-rw-r--r--asm/mystery_event_script.s4
-rw-r--r--asm/party_menu.s2
-rw-r--r--asm/player_pc.s1298
-rw-r--r--asm/pokeblock.s18
-rw-r--r--asm/pokedex.s5294
-rw-r--r--asm/pokemon_menu.s40
-rw-r--r--asm/pokemon_storage_system.s10
-rw-r--r--asm/rom_8094928.s411
-rw-r--r--asm/roulette.s8
-rw-r--r--asm/secret_base.s18
-rw-r--r--asm/shop.s16
-rw-r--r--asm/trade.s14
-rw-r--r--asm/trader.s6
-rw-r--r--data/decoration_inventory.s16
-rw-r--r--data/field_effect.s433
-rw-r--r--data/graphics/pokemon/footprint_table.inc415
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082CF564/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082CF564/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082D05D8/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082D05D8/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082D05FC/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082D05FC/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E55C8/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E55C8/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E55EC/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E55EC/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5610/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5610/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5634/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5634/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5658/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5658/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E567C/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E567C/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56A0/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56A0/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56C4/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56C4/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56E8/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E56E8/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E570C/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E570C/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5730/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5730/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5754/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5754/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5778/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E5778/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E579C/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082E579C/map.binbin4 -> 4 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082EDF30/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082EDF30/map.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082FF894/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_082FF894/map.binbin724 -> 724 bytes
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_08302970/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_08302970/map.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_083041B4/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnknownMap_083041B4/map.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnreferencedMap/border.bin0
-rw-r--r--[-rwxr-xr-x]data/maps/UnreferencedMap/map.bin0
-rw-r--r--data/player_pc.s77
-rw-r--r--data/pokedex.s538
-rw-r--r--data/pokedex_entries.inc4164
-rw-r--r--data/pokedex_orders.inc1191
-rw-r--r--data/scripts/maps/LittlerootTown_BrendansHouse_2F.inc2
-rw-r--r--data/scripts/maps/LittlerootTown_MaysHouse_2F.inc2
-rw-r--r--data/text/pokedex_rating.inc63
-rw-r--r--include/asm.h59
-rw-r--r--include/asm.inc.h450
-rw-r--r--include/asm_fieldmap.h23
-rw-r--r--include/battle.h170
-rw-r--r--include/battle_811DA74.h11
-rw-r--r--include/battle_ai.h1
-rw-r--r--include/battle_anim.h9
-rw-r--r--include/battle_anim_80CA710.h6
-rw-r--r--include/battle_anim_81258BC.h7
-rw-r--r--include/battle_anim_8137220.h6
-rw-r--r--include/battle_anim_813F0F4.h6
-rw-r--r--include/battle_interface.h3
-rw-r--r--include/battle_message.h7
-rw-r--r--include/battle_party_menu.h18
-rw-r--r--include/battle_records.h8
-rw-r--r--include/battle_tower.h7
-rw-r--r--include/battle_transition.h8
-rw-r--r--include/berry_blender.h6
-rw-r--r--include/cable_club.h22
-rw-r--r--include/choose_party.h8
-rw-r--r--include/contest.h14
-rw-r--r--include/contest_link_80C2020.h13
-rw-r--r--include/contest_link_80C857C.h10
-rw-r--r--include/contest_painting.h21
-rw-r--r--include/coord_event_weather.h6
-rw-r--r--include/cute_sketch.h28
-rw-r--r--include/data2.h4
-rw-r--r--include/daycare.h14
-rw-r--r--include/debug.h7
-rw-r--r--[-rwxr-xr-x]include/decoration.h5
-rw-r--r--include/decoration_inventory.h10
-rw-r--r--include/dewford_trend.h1
-rw-r--r--include/diploma.h6
-rw-r--r--include/easy_chat.h11
-rw-r--r--include/field_control_avatar.h27
-rw-r--r--include/field_effect.h219
-rw-r--r--include/field_effect_helpers.h16
-rw-r--r--include/field_fadetransition.h31
-rw-r--r--include/field_ground_effect.h30
-rw-r--r--include/field_map_obj.h106
-rw-r--r--include/field_map_obj_helpers.h2
-rw-r--r--include/field_player_avatar.h108
-rw-r--r--include/field_poison.h6
-rw-r--r--include/field_region_map.h10
-rw-r--r--include/field_screen_effect.h7
-rw-r--r--include/field_specials.h13
-rw-r--r--include/field_tasks.h8
-rw-r--r--include/field_weather.h7
-rw-r--r--include/fieldmap.h32
-rw-r--r--include/fldeff_80C5CD4.h9
-rw-r--r--include/fldeff_cut.h13
-rw-r--r--include/fldeff_flash.h8
-rw-r--r--include/fldeff_softboiled.h7
-rw-r--r--include/fldeff_teleport.h7
-rwxr-xr-x[-rw-r--r--]include/gba/defines.h0
-rw-r--r--include/gba/types.h2
-rwxr-xr-x[-rw-r--r--]include/global.h40
-rw-r--r--include/graphics.h2412
-rw-r--r--include/hall_of_fame.h9
-rw-r--r--include/intro_credits_graphics.h24
-rw-r--r--include/item_menu.h29
-rw-r--r--include/item_use.h28
-rw-r--r--include/learn_move.h6
-rw-r--r--include/mail_data.h16
-rw-r--r--include/map_name_popup.h7
-rw-r--r--include/mauville_old_man.h11
-rw-r--r--include/menu.h12
-rw-r--r--include/menu_cursor.h2
-rw-r--r--include/menu_helpers.h15
-rw-r--r--include/mystery_event_script.h8
-rw-r--r--include/party_menu.h113
-rwxr-xr-xinclude/player_pc.h107
-rw-r--r--include/pokeball.h7
-rw-r--r--include/pokeblock.h10
-rw-r--r--include/pokedex.h146
-rw-r--r--include/pokedex_area_screen.h6
-rw-r--r--include/pokedex_cry_screen.h19
-rw-r--r--include/pokemon.h50
-rw-r--r--include/pokemon_icon.h14
-rw-r--r--include/pokemon_item_effect.h6
-rw-r--r--include/pokemon_menu.h14
-rw-r--r--include/pokemon_storage_system.h6
-rw-r--r--include/pokemon_summary_screen.h16
-rw-r--r--include/pokenav.h19
-rw-r--r--include/record_mixing.h4
-rw-r--r--include/region_map.h13
-rw-r--r--include/reset_rtc_screen.h6
-rw-r--r--include/rom3.h25
-rw-r--r--include/rom4.h19
-rw-r--r--include/rom_8077ABC.h59
-rw-r--r--include/rom_8094928.h10
-rw-r--r--include/rotating_gate.h8
-rw-r--r--include/safari_zone.h2
-rw-r--r--include/script_menu.h2
-rw-r--r--include/script_movement.h8
-rw-r--r--include/secret_base.h15
-rw-r--r--include/shop.h18
-rw-r--r--include/slot_machine.h8
-rw-r--r--include/songs.h44
-rw-r--r--include/sprite.h2
-rw-r--r--include/starter_choose.h5
-rw-r--r--include/string_util.h2
-rw-r--r--include/text.h53
-rw-r--r--include/time_events.h8
-rw-r--r--include/title_screen.h2
-rw-r--r--include/trader.h6
-rw-r--r--include/tv.h99
-rw-r--r--include/unknown_task.h14
-rw-r--r--include/util.h13
-rw-r--r--include/wild_encounter.h25
-rwxr-xr-x[-rw-r--r--]ld_script.txt17
-rw-r--r--shared_syms.txt2
-rw-r--r--src/bard_music.c1
-rw-r--r--src/battle_2.c138
-rw-r--r--src/battle_6.c3
-rw-r--r--src/battle_7.c1237
-rw-r--r--src/battle_811DA74.c51
-rw-r--r--src/battle_ai.c11
-rw-r--r--src/battle_anim.c21
-rw-r--r--src/battle_anim_80A7E7C.c15
-rw-r--r--src/battle_anim_81258BC.c10
-rw-r--r--src/battle_interface.c55
-rw-r--r--src/battle_party_menu.c348
-rw-r--r--src/battle_records.c5
-rw-r--r--src/battle_setup.c13
-rw-r--r--src/berry.c4
-rw-r--r--src/berry_tag_screen.c4
-rw-r--r--src/bike.c2
-rw-r--r--src/birch_pc.c106
-rw-r--r--src/braille_puzzles.c3
-rw-r--r--src/cable_club.c13
-rw-r--r--src/calculate_base_damage.c13
-rw-r--r--src/clear_save_data_menu.c2
-rw-r--r--src/clock.c13
-rw-r--r--src/contest_painting.c8
-rw-r--r--src/coord_event_weather.c3
-rw-r--r--src/credits.c27
-rw-r--r--src/data/pokedex_entries_en.h9651
-rw-r--r--src/data/pokedex_orders.h1192
-rwxr-xr-x[-rw-r--r--]src/daycare.c88
-rw-r--r--src/decompress.c1
-rw-r--r--[-rwxr-xr-x]src/decoration.c37
-rw-r--r--src/decoration_inventory.c169
-rw-r--r--src/dewford_trend.c1
-rw-r--r--src/diploma.c3
-rw-r--r--src/easy_chat.c11
-rw-r--r--src/field_camera.c4
-rw-r--r--src/field_control_avatar.c30
-rw-r--r--src/field_door.c2
-rwxr-xr-x[-rw-r--r--]src/field_effect.c3204
-rw-r--r--src/field_fadetransition.c18
-rw-r--r--src/field_ground_effect.c20
-rw-r--r--src/field_map_obj.c37
-rw-r--r--src/field_map_obj_helpers.c22
-rw-r--r--src/field_message_box.c4
-rw-r--r--src/field_player_avatar.c59
-rw-r--r--src/field_poison.c5
-rw-r--r--src/field_region_map.c17
-rw-r--r--src/field_special_scene.c7
-rw-r--r--src/field_specials.c3
-rw-r--r--src/field_weather.c1
-rw-r--r--src/fieldmap.c33
-rw-r--r--src/fldeff_cut.c23
-rw-r--r--src/fldeff_softboiled.c8
-rw-r--r--src/fldeff_strength.c9
-rw-r--r--src/fldeff_sweetscent.c6
-rw-r--r--src/fldeff_teleport.c13
-rw-r--r--src/hof_pc.c5
-rw-r--r--src/intro.c16
-rw-r--r--src/item.c3
-rw-r--r--src/item_use.c75
-rw-r--r--src/link.c5
-rw-r--r--src/load_save.c1
-rw-r--r--src/lottery_corner.c1
-rw-r--r--src/mail.c8
-rw-r--r--src/mail_data.c7
-rw-r--r--src/main.c3
-rw-r--r--src/main_menu.c12
-rw-r--r--src/map_name_popup.c3
-rw-r--r--src/map_obj_lock.c3
-rw-r--r--src/matsuda_debug_menu.c8
-rw-r--r--src/mauville_old_man.c10
-rw-r--r--src/menu.c20
-rw-r--r--src/menu_cursor.c4
-rw-r--r--src/metatile_behavior.c3
-rw-r--r--src/mori_debug_menu.c4
-rw-r--r--src/mystery_event_menu.c2
-rw-r--r--src/mystery_event_script.c3
-rw-r--r--src/name_string_util.c1
-rw-r--r--src/naming_screen.c12
-rw-r--r--src/new_game.c14
-rw-r--r--src/palette.c9
-rw-r--r--src/party_menu.c99
-rw-r--r--src/player_pc.c1289
-rw-r--r--src/pokedex.c4208
-rw-r--r--src/pokedex_cry_screen.c2
-rw-r--r--src/pokemon_1.c8
-rw-r--r--src/pokemon_2.c15
-rw-r--r--src/pokemon_3.c43
-rw-r--r--src/pokemon_size_record.c4
-rw-r--r--src/pokemon_storage_system.c1
-rw-r--r--src/pokemon_summary_screen.c11
-rw-r--r--src/pokenav.c17
-rw-r--r--src/post_battle_event_funcs.c3
-rw-r--r--src/record_mixing.c113
-rw-r--r--src/roamer.c2
-rw-r--r--src/rom3.c37
-rw-r--r--src/rom4.c55
-rw-r--r--src/rom6.c14
-rw-r--r--src/rom_8077ABC.c44
-rw-r--r--src/rom_8094928.c135
-rw-r--r--src/safari_zone.c6
-rw-r--r--src/save.c1
-rw-r--r--src/save_failed_screen.c9
-rw-r--r--src/save_menu_util.c2
-rw-r--r--src/scrcmd.c23
-rw-r--r--src/script.c1
-rw-r--r--src/script_menu.c9
-rw-r--r--src/script_movement.c8
-rw-r--r--src/script_pokemon_util_80C4BF0.c36
-rw-r--r--src/script_pokemon_util_80F99CC.c28
-rw-r--r--src/secret_base.c37
-rw-r--r--src/shop.c29
-rw-r--r--src/slot_machine.c6
-rw-r--r--src/smokescreen.c2
-rw-r--r--src/sound.c4
-rw-r--r--src/sprite.c1
-rw-r--r--src/start_menu.c9
-rw-r--r--src/starter_choose.c6
-rw-r--r--src/strings.c4
-rw-r--r--src/time_events.c8
-rw-r--r--src/title_screen.c3
-rw-r--r--src/trainer_card.c8
-rw-r--r--src/trainer_see.c3
-rw-r--r--src/tv.c113
-rw-r--r--src/unknown_debug_menu.c4
-rw-r--r--src/util.c2
-rw-r--r--src/wallclock.c5
-rw-r--r--src/wild_encounter.c31
-rw-r--r--sym_bss.txt2
-rw-r--r--sym_common.txt2
-rw-r--r--sym_ewram.txt2
335 files changed, 25228 insertions, 30266 deletions
diff --git a/asm/battle_4.s b/asm/battle_4.s
index 0581d1e7d..bbdeb1c6e 100644
--- a/asm/battle_4.s
+++ b/asm/battle_4.s
@@ -13392,7 +13392,7 @@ sub_8022784: @ 8022784
lsls r0, 16
lsrs r0, 16
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
_080227D0:
ldr r2, _08022824 @ =gUnknown_02024C0C
ldr r1, _08022828 @ =gBitTable
@@ -15716,7 +15716,7 @@ sub_8023AD8: @ 8023AD8
movs r2, 0x1D
movs r3, 0xD
bl sub_802BBD4
- bl sub_814A7FC
+ bl DestroyMenuCursor
add sp, 0x4
pop {r0}
bx r0
@@ -31340,7 +31340,7 @@ _0802B73C:
lsls r0, 16
lsrs r0, 16
movs r1, 0x1
- bl sub_8090D90
+ bl GetNationalPokedexFlag
lsls r0, 24
movs r4, 0xA
cmp r0, 0
@@ -31657,7 +31657,7 @@ sub_802B9E0: @ 802B9E0
lsls r0, 16
lsrs r0, 16
movs r1, 0x1
- bl sub_8090D90
+ bl GetNationalPokedexFlag
lsls r0, 24
cmp r0, 0
beq _0802BA2C
@@ -31688,7 +31688,7 @@ _0802BA2C:
lsls r0, 16
lsrs r0, 16
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
ldrb r0, [r6]
adds r2, r0, 0
muls r2, r5
diff --git a/asm/battle_5.s b/asm/battle_5.s
index 01541c120..7c3f005ff 100644
--- a/asm/battle_5.s
+++ b/asm/battle_5.s
@@ -190,7 +190,7 @@ sub_802C098: @ 802C098
beq _0802C13E
movs r0, 0x5
bl PlaySE
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r1, _0802C108 @ =gUnknown_02024E60
ldrb r0, [r4]
adds r0, r1
@@ -398,7 +398,7 @@ _0802C278:
movs r2, 0
bl dp01_build_cmdbuf_x21_a_bb
bl dp01_tbl1_exec_completed
- bl sub_814A7FC
+ bl DestroyMenuCursor
b _0802C2AC
.align 2, 0
_0802C294: .4byte gBattleTypeFlags
@@ -484,7 +484,7 @@ _0802C32E:
ands r0, r1
cmp r0, 0
beq _0802C3A8
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x5
bl PlaySE
ldr r2, _0802C394 @ =gSprites
@@ -1028,7 +1028,7 @@ _0802C7B2:
cmp r0, 0
bne _0802C7DC
_0802C7B8:
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r1, _0802C7D0 @ =gUnknown_02024E64
ldr r0, _0802C7D8 @ =gUnknown_02024A60
ldrb r0, [r0]
@@ -1112,7 +1112,7 @@ _0802C864:
ands r0, r1
cmp r0, 0
beq _0802C8A4
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x5
bl PlaySE
ldr r0, _0802C898 @ =gUnknown_030042A4
diff --git a/asm/battle_7.s b/asm/battle_7.s
deleted file mode 100644
index 593a5bbb1..000000000
--- a/asm/battle_7.s
+++ /dev/null
@@ -1,4290 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start sub_80312F0
-sub_80312F0: @ 80312F0
- push {r4-r7,lr}
- adds r6, r0, 0
- ldrh r0, [r6, 0x30]
- lsls r0, 24
- lsrs r0, 24
- ldr r7, _08031334 @ =gSprites
- lsls r1, r0, 4
- adds r1, r0
- lsls r5, r1, 2
- adds r3, r5, r7
- adds r0, r3, 0
- adds r0, 0x3F
- ldrb r4, [r0]
- lsls r0, r4, 26
- cmp r0, 0
- bge _08031354
- adds r0, r3, 0
- adds r0, 0x3E
- ldrb r0, [r0]
- lsls r0, 29
- cmp r0, 0
- blt _08031354
- adds r1, r3, 0
- adds r1, 0x2C
- ldrb r2, [r1]
- lsls r0, r2, 25
- cmp r0, 0
- bge _08031338
- movs r0, 0x41
- negs r0, r0
- ands r0, r2
- strb r0, [r1]
- b _08031354
- .align 2, 0
-_08031334: .4byte gSprites
-_08031338:
- lsls r0, r4, 27
- cmp r0, 0
- bge _08031354
- adds r0, r7, 0
- adds r0, 0x1C
- adds r0, r5, r0
- ldr r1, _0803135C @ =sub_80105DC
- str r1, [r0]
- adds r0, r3, 0
- movs r1, 0
- bl StartSpriteAffineAnim
- ldr r0, _08031360 @ =SpriteCallbackDummy
- str r0, [r6, 0x1C]
-_08031354:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_0803135C: .4byte sub_80105DC
-_08031360: .4byte SpriteCallbackDummy
- thumb_func_end sub_80312F0
-
- thumb_func_start unref_sub_8031364
-unref_sub_8031364: @ 8031364
- push {r4,lr}
- adds r4, r0, 0
- lsls r1, 24
- adds r3, r4, 0
- adds r3, 0x2C
- ldrb r0, [r3]
- movs r2, 0x40
- orrs r0, r2
- strb r0, [r3]
- ldr r0, _08031388 @ =SpriteCallbackDummy
- str r0, [r4, 0x1C]
- cmp r1, 0
- bne _0803138C
- adds r0, r4, 0
- movs r1, 0x1
- bl StartSpriteAffineAnim
- b _08031394
- .align 2, 0
-_08031388: .4byte SpriteCallbackDummy
-_0803138C:
- adds r0, r4, 0
- movs r1, 0x1
- bl StartSpriteAffineAnim
-_08031394:
- adds r0, r4, 0
- bl AnimateSprite
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end unref_sub_8031364
-
- thumb_func_start sub_80313A0
-sub_80313A0: @ 80313A0
- push {lr}
- adds r2, r0, 0
- ldr r0, _080313C8 @ =gUnknown_02024DE8
- ldrh r1, [r0]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- bne _080313C2
- ldrh r0, [r2, 0x2E]
- ldrh r1, [r2, 0x24]
- adds r0, r1
- strh r0, [r2, 0x24]
- lsls r0, 16
- cmp r0, 0
- bne _080313C2
- ldr r0, _080313CC @ =SpriteCallbackDummy
- str r0, [r2, 0x1C]
-_080313C2:
- pop {r0}
- bx r0
- .align 2, 0
-_080313C8: .4byte gUnknown_02024DE8
-_080313CC: .4byte SpriteCallbackDummy
- thumb_func_end sub_80313A0
-
- thumb_func_start move_anim_start_t2_for_situation
-move_anim_start_t2_for_situation: @ 80313D0
- push {r4-r6,lr}
- adds r4, r1, 0
- lsls r0, 24
- ldr r5, _08031400 @ =gUnknown_02024A60
- ldrb r2, [r5]
- lsls r1, r2, 1
- adds r1, r2
- lsls r1, 2
- ldr r6, _08031404 @ =0x02017810
- adds r1, r6
- ldrb r2, [r1]
- movs r3, 0x10
- orrs r2, r3
- strb r2, [r1]
- cmp r0, 0
- bne _0803144C
- cmp r4, 0x20
- bne _08031408
- ldrb r0, [r5]
- movs r1, 0x6
- bl move_anim_start_t2
- b _080314C2
- .align 2, 0
-_08031400: .4byte gUnknown_02024A60
-_08031404: .4byte 0x02017810
-_08031408:
- cmp r4, 0x8
- beq _08031414
- movs r0, 0x80
- ands r0, r4
- cmp r0, 0
- beq _0803141E
-_08031414:
- ldrb r0, [r5]
- movs r1, 0
- bl move_anim_start_t2
- b _080314C2
-_0803141E:
- cmp r4, 0x10
- bne _0803142C
- ldrb r0, [r5]
- movs r1, 0x2
- bl move_anim_start_t2
- b _080314C2
-_0803142C:
- movs r0, 0x7
- ands r0, r4
- cmp r0, 0
- beq _0803143E
- ldrb r0, [r5]
- movs r1, 0x4
- bl move_anim_start_t2
- b _080314C2
-_0803143E:
- cmp r4, 0x40
- bne _080314AE
- ldrb r0, [r5]
- movs r1, 0x5
- bl move_anim_start_t2
- b _080314C2
-_0803144C:
- movs r0, 0xF0
- lsls r0, 12
- ands r0, r4
- cmp r0, 0
- beq _08031460
- ldrb r0, [r5]
- movs r1, 0x3
- bl move_anim_start_t2
- b _080314C2
-_08031460:
- movs r0, 0x7
- ands r0, r4
- cmp r0, 0
- beq _08031472
- ldrb r0, [r5]
- movs r1, 0x1
- bl move_anim_start_t2
- b _080314C2
-_08031472:
- movs r0, 0x80
- lsls r0, 21
- ands r0, r4
- cmp r0, 0
- beq _08031486
- ldrb r0, [r5]
- movs r1, 0x7
- bl move_anim_start_t2
- b _080314C2
-_08031486:
- movs r0, 0x80
- lsls r0, 20
- ands r0, r4
- cmp r0, 0
- beq _0803149A
- ldrb r0, [r5]
- movs r1, 0x8
- bl move_anim_start_t2
- b _080314C2
-_0803149A:
- movs r0, 0xE0
- lsls r0, 8
- ands r0, r4
- cmp r0, 0
- beq _080314AE
- ldrb r0, [r5]
- movs r1, 0x9
- bl move_anim_start_t2
- b _080314C2
-_080314AE:
- ldrb r0, [r5]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- adds r1, r6
- ldrb r2, [r1]
- movs r0, 0x11
- negs r0, r0
- ands r0, r2
- strb r0, [r1]
-_080314C2:
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end move_anim_start_t2_for_situation
-
- thumb_func_start move_anim_start_t3
-move_anim_start_t3: @ 80314C8
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- ldr r4, [sp, 0x20]
- lsls r0, 24
- lsrs r6, r0, 24
- lsls r1, 24
- lsrs r1, 24
- mov r9, r1
- lsls r2, 24
- lsrs r2, 24
- mov r10, r2
- lsls r3, 24
- lsrs r5, r3, 24
- lsls r4, 16
- lsrs r7, r4, 16
- cmp r5, 0
- bne _0803150C
- movs r0, 0x80
- ands r0, r7
- cmp r0, 0
- beq _0803150C
- ldr r0, _08031508 @ =gBattleMonForms
- adds r0, r6, r0
- movs r2, 0x7F
- adds r1, r7, 0
- ands r1, r2
- strb r1, [r0]
- movs r0, 0x1
- b _080315C2
- .align 2, 0
-_08031508: .4byte gBattleMonForms
-_0803150C:
- lsls r1, r6, 2
- ldr r0, _08031530 @ =0x02017800
- adds r4, r1, r0
- ldrb r1, [r4]
- movs r0, 0x4
- mov r8, r0
- ands r0, r1
- cmp r0, 0
- beq _08031578
- adds r0, r5, 0
- bl sub_803163C
- lsls r0, 24
- cmp r0, 0
- bne _08031534
- movs r0, 0x1
- b _080315C2
- .align 2, 0
-_08031530: .4byte 0x02017800
-_08031534:
- ldrb r1, [r4]
- mov r0, r8
- ands r0, r1
- cmp r0, 0
- beq _08031578
- cmp r5, 0x2
- bne _08031578
- ldr r1, _08031570 @ =gSprites
- ldr r0, _08031574 @ =gUnknown_02024BE0
- adds r0, r6, r0
- ldrb r2, [r0]
- lsls r0, r2, 4
- adds r0, r2
- lsls r0, 2
- adds r0, r1
- adds r0, 0x3E
- ldrb r0, [r0]
- lsls r0, 29
- cmp r0, 0
- bge _08031578
- adds r0, r6, 0
- movs r1, 0x1
- bl refresh_graphics_maybe
- adds r0, r6, 0
- bl sub_80324E0
- movs r0, 0x1
- b _080315C2
- .align 2, 0
-_08031570: .4byte gSprites
-_08031574: .4byte gUnknown_02024BE0
-_08031578:
- ldr r0, _080315D0 @ =gBattleAnimPlayerMonIndex
- mov r1, r9
- strb r1, [r0]
- ldr r0, _080315D4 @ =gBattleAnimEnemyMonIndex
- mov r1, r10
- strb r1, [r0]
- ldr r4, _080315D8 @ =0x02017840
- strh r7, [r4]
- ldr r0, _080315DC @ =gBattleAnims_Unknown1
- adds r1, r5, 0
- movs r2, 0
- bl DoMoveAnim
- ldr r0, _080315E0 @ =sub_80315E8
- movs r1, 0xA
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _080315E4 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- strh r6, [r1, 0x8]
- movs r0, 0x8
- ldrsh r1, [r1, r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- subs r4, 0x30
- adds r0, r4
- ldrb r1, [r0]
- movs r2, 0x20
- orrs r1, r2
- strb r1, [r0]
- movs r0, 0
-_080315C2:
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_080315D0: .4byte gBattleAnimPlayerMonIndex
-_080315D4: .4byte gBattleAnimEnemyMonIndex
-_080315D8: .4byte 0x02017840
-_080315DC: .4byte gBattleAnims_Unknown1
-_080315E0: .4byte sub_80315E8
-_080315E4: .4byte gTasks
- thumb_func_end move_anim_start_t3
-
- thumb_func_start sub_80315E8
-sub_80315E8: @ 80315E8
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r0, _0803162C @ =gAnimScriptCallback
- ldr r0, [r0]
- bl _call_via_r0
- ldr r0, _08031630 @ =gAnimScriptActive
- ldrb r0, [r0]
- cmp r0, 0
- bne _08031626
- ldr r1, _08031634 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- movs r1, 0x8
- ldrsh r0, [r0, r1]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- ldr r0, _08031638 @ =0x02017810
- adds r1, r0
- ldrb r2, [r1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r2
- strb r0, [r1]
- adds r0, r4, 0
- bl DestroyTask
-_08031626:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0803162C: .4byte gAnimScriptCallback
-_08031630: .4byte gAnimScriptActive
-_08031634: .4byte gTasks
-_08031638: .4byte 0x02017810
- thumb_func_end sub_80315E8
-
- thumb_func_start sub_803163C
-sub_803163C: @ 803163C
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0xD
- bgt _08031650
- cmp r0, 0xA
- bge _08031654
- cmp r0, 0x2
- beq _08031654
- b _08031658
-_08031650:
- cmp r0, 0x11
- bne _08031658
-_08031654:
- movs r0, 0x1
- b _0803165A
-_08031658:
- movs r0, 0
-_0803165A:
- pop {r1}
- bx r1
- thumb_func_end sub_803163C
-
- thumb_func_start move_anim_start_t4
-move_anim_start_t4: @ 8031660
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- lsls r3, 24
- lsrs r3, 24
- ldr r0, _080316B4 @ =gBattleAnimPlayerMonIndex
- strb r1, [r0]
- ldr r0, _080316B8 @ =gBattleAnimEnemyMonIndex
- strb r2, [r0]
- ldr r0, _080316BC @ =gBattleAnims_Unknown2
- adds r1, r3, 0
- movs r2, 0
- bl DoMoveAnim
- ldr r0, _080316C0 @ =sub_80316CC
- movs r1, 0xA
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _080316C4 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- strh r4, [r1, 0x8]
- movs r0, 0x8
- ldrsh r1, [r1, r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r1, _080316C8 @ =0x02017810
- adds r0, r1
- ldrb r1, [r0]
- movs r2, 0x40
- orrs r1, r2
- strb r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080316B4: .4byte gBattleAnimPlayerMonIndex
-_080316B8: .4byte gBattleAnimEnemyMonIndex
-_080316BC: .4byte gBattleAnims_Unknown2
-_080316C0: .4byte sub_80316CC
-_080316C4: .4byte gTasks
-_080316C8: .4byte 0x02017810
- thumb_func_end move_anim_start_t4
-
- thumb_func_start sub_80316CC
-sub_80316CC: @ 80316CC
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r0, _08031710 @ =gAnimScriptCallback
- ldr r0, [r0]
- bl _call_via_r0
- ldr r0, _08031714 @ =gAnimScriptActive
- ldrb r0, [r0]
- cmp r0, 0
- bne _0803170A
- ldr r1, _08031718 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- movs r1, 0x8
- ldrsh r0, [r0, r1]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- ldr r0, _0803171C @ =0x02017810
- adds r1, r0
- ldrb r2, [r1]
- movs r0, 0x41
- negs r0, r0
- ands r0, r2
- strb r0, [r1]
- adds r0, r4, 0
- bl DestroyTask
-_0803170A:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08031710: .4byte gAnimScriptCallback
-_08031714: .4byte gAnimScriptActive
-_08031718: .4byte gTasks
-_0803171C: .4byte 0x02017810
- thumb_func_end sub_80316CC
-
- thumb_func_start sub_8031720
-sub_8031720: @ 8031720
- movs r0, 0
- bx lr
- thumb_func_end sub_8031720
-
- thumb_func_start mplay_80342A4
-mplay_80342A4: @ 8031724
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- movs r5, 0
- bl IsSEPlaying
- lsls r0, 24
- cmp r0, 0
- beq _08031764
- lsls r1, r4, 1
- adds r1, r4
- lsls r1, 2
- ldr r2, _0803176C @ =0x02017810
- adds r1, r2
- ldrb r0, [r1, 0x8]
- adds r0, 0x1
- strb r0, [r1, 0x8]
- ldr r0, _08031770 @ =gUnknown_02024A60
- ldrb r1, [r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r0, [r0, 0x8]
- cmp r0, 0x1D
- bls _08031768
- ldr r0, _08031774 @ =gMPlay_SE1
- bl m4aMPlayStop
- ldr r0, _08031778 @ =gMPlay_SE2
- bl m4aMPlayStop
-_08031764:
- cmp r5, 0
- beq _0803177C
-_08031768:
- movs r0, 0x1
- b _0803178A
- .align 2, 0
-_0803176C: .4byte 0x02017810
-_08031770: .4byte gUnknown_02024A60
-_08031774: .4byte gMPlay_SE1
-_08031778: .4byte gMPlay_SE2
-_0803177C:
- lsls r0, r4, 1
- adds r0, r4
- lsls r0, 2
- ldr r1, _08031790 @ =0x02017810
- adds r0, r1
- strb r5, [r0, 0x8]
- movs r0, 0
-_0803178A:
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08031790: .4byte 0x02017810
- thumb_func_end mplay_80342A4
-
- thumb_func_start sub_8031794
-sub_8031794: @ 8031794
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x14
- mov r8, r0
- lsls r1, 24
- lsrs r1, 24
- mov r9, r1
- movs r1, 0
- bl GetMonData
- str r0, [sp, 0xC]
- mov r0, r9
- lsls r1, r0, 2
- ldr r0, _080317D0 @ =0x02017800
- adds r2, r1, r0
- ldrh r0, [r2, 0x2]
- cmp r0, 0
- bne _080317D4
- mov r0, r8
- movs r1, 0xB
- bl GetMonData
- lsls r0, 16
- lsrs r6, r0, 16
- ldr r7, [sp, 0xC]
- b _080317DC
- .align 2, 0
-_080317D0: .4byte 0x02017800
-_080317D4:
- ldrh r6, [r2, 0x2]
- ldr r0, _08031838 @ =gUnknown_02024E70
- adds r0, r1, r0
- ldr r7, [r0]
-_080317DC:
- mov r0, r8
- movs r1, 0x1
- bl GetMonData
- mov r10, r0
- mov r0, r9
- bl battle_get_per_side_status
- lsls r0, 24
- lsls r5, r6, 3
- ldr r1, _0803183C @ =gMonFrontPicTable
- adds r5, r1
- ldr r1, _08031840 @ =gMonFrontPicCoords
- lsls r2, r6, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08031844 @ =gUnknown_081FAF4C
- lsrs r0, 22
- adds r0, r4
- ldr r0, [r0]
- str r0, [sp]
- str r6, [sp, 0x4]
- str r7, [sp, 0x8]
- adds r0, r5, 0
- bl HandleLoadSpecialPokePic
- mov r1, r9
- lsls r2, r1, 4
- movs r0, 0x80
- lsls r0, 1
- adds r7, r2, r0
- lsls r1, 2
- ldr r0, _08031848 @ =0x02017800
- adds r0, r1, r0
- ldrh r0, [r0, 0x2]
- str r1, [sp, 0x10]
- adds r4, r2, 0
- cmp r0, 0
- bne _0803184C
- mov r0, r8
- bl pokemon_get_pal
- b _08031856
- .align 2, 0
-_08031838: .4byte gUnknown_02024E70
-_0803183C: .4byte gMonFrontPicTable
-_08031840: .4byte gMonFrontPicCoords
-_08031844: .4byte gUnknown_081FAF4C
-_08031848: .4byte 0x02017800
-_0803184C:
- adds r0, r6, 0
- mov r1, r10
- ldr r2, [sp, 0xC]
- bl species_and_otid_get_pal
-_08031856:
- adds r5, r0, 0
- ldr r1, _080318E0 @ =0x02000000
- mov r8, r1
- adds r0, r5, 0
- bl sub_800D238
- mov r0, r8
- adds r1, r7, 0
- movs r2, 0x20
- bl LoadPalette
- adds r1, r4, 0
- adds r1, 0x80
- mov r0, r8
- movs r2, 0x20
- bl LoadPalette
- ldr r0, _080318E4 @ =SPECIES_CASTFORM
- cmp r6, r0
- bne _080318A2
- subs r0, 0x81
- adds r7, r4, r0
- movs r4, 0xB2
- lsls r4, 9
- add r4, r8
- adds r0, r5, 0
- adds r1, r4, 0
- bl sub_800D238
- ldr r0, _080318E8 @ =gBattleMonForms
- add r0, r9
- ldrb r0, [r0]
- lsls r0, 5
- adds r0, r4
- adds r1, r7, 0
- movs r2, 0x20
- bl LoadPalette
-_080318A2:
- movs r0, 0xBC
- lsls r0, 9
- add r0, r8
- ldr r1, [sp, 0x10]
- adds r0, r1, r0
- ldrh r0, [r0, 0x2]
- cmp r0, 0
- beq _080318CE
- ldr r3, _080318EC @ =0x00007fff
- adds r0, r7, 0
- movs r1, 0x10
- movs r2, 0x6
- bl BlendPalette
- lsls r1, r7, 1
- ldr r0, _080318F0 @ =gPlttBufferFaded
- adds r0, r1, r0
- ldr r2, _080318F4 @ =gPlttBufferUnfaded
- adds r1, r2
- ldr r2, _080318F8 @ =REG_BG0CNT
- bl CpuSet
-_080318CE:
- add sp, 0x14
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080318E0: .4byte 0x02000000
-_080318E4: .4byte SPECIES_CASTFORM
-_080318E8: .4byte gBattleMonForms
-_080318EC: .4byte 0x00007fff
-_080318F0: .4byte gPlttBufferFaded
-_080318F4: .4byte gPlttBufferUnfaded
-_080318F8: .4byte REG_BG0CNT
- thumb_func_end sub_8031794
-
- thumb_func_start sub_80318FC
-sub_80318FC: @ 80318FC
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x14
- mov r8, r0
- lsls r1, 24
- lsrs r1, 24
- mov r9, r1
- movs r1, 0
- bl GetMonData
- str r0, [sp, 0xC]
- mov r0, r9
- lsls r1, r0, 2
- ldr r0, _08031938 @ =0x02017800
- adds r2, r1, r0
- ldrh r0, [r2, 0x2]
- cmp r0, 0
- bne _0803193C
- mov r0, r8
- movs r1, 0xB
- bl GetMonData
- lsls r0, 16
- lsrs r6, r0, 16
- ldr r7, [sp, 0xC]
- b _08031944
- .align 2, 0
-_08031938: .4byte 0x02017800
-_0803193C:
- ldrh r6, [r2, 0x2]
- ldr r0, _080319A0 @ =gUnknown_02024E70
- adds r0, r1, r0
- ldr r7, [r0]
-_08031944:
- mov r0, r8
- movs r1, 0x1
- bl GetMonData
- mov r10, r0
- mov r0, r9
- bl battle_get_per_side_status
- lsls r0, 24
- lsls r5, r6, 3
- ldr r1, _080319A4 @ =gMonBackPicTable
- adds r5, r1
- ldr r1, _080319A8 @ =gMonBackPicCoords
- lsls r2, r6, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _080319AC @ =gUnknown_081FAF4C
- lsrs r0, 22
- adds r0, r4
- ldr r0, [r0]
- str r0, [sp]
- str r6, [sp, 0x4]
- str r7, [sp, 0x8]
- adds r0, r5, 0
- bl HandleLoadSpecialPokePic
- mov r1, r9
- lsls r2, r1, 4
- movs r0, 0x80
- lsls r0, 1
- adds r7, r2, r0
- lsls r1, 2
- ldr r0, _080319B0 @ =0x02017800
- adds r0, r1, r0
- ldrh r0, [r0, 0x2]
- str r1, [sp, 0x10]
- adds r4, r2, 0
- cmp r0, 0
- bne _080319B4
- mov r0, r8
- bl pokemon_get_pal
- b _080319BE
- .align 2, 0
-_080319A0: .4byte gUnknown_02024E70
-_080319A4: .4byte gMonBackPicTable
-_080319A8: .4byte gMonBackPicCoords
-_080319AC: .4byte gUnknown_081FAF4C
-_080319B0: .4byte 0x02017800
-_080319B4:
- adds r0, r6, 0
- mov r1, r10
- ldr r2, [sp, 0xC]
- bl species_and_otid_get_pal
-_080319BE:
- adds r5, r0, 0
- ldr r1, _08031A48 @ =0x02000000
- mov r8, r1
- adds r0, r5, 0
- bl sub_800D238
- mov r0, r8
- adds r1, r7, 0
- movs r2, 0x20
- bl LoadPalette
- adds r1, r4, 0
- adds r1, 0x80
- mov r0, r8
- movs r2, 0x20
- bl LoadPalette
- ldr r0, _08031A4C @ =SPECIES_CASTFORM
- cmp r6, r0
- bne _08031A0A
- subs r0, 0x81
- adds r7, r4, r0
- movs r4, 0xB2
- lsls r4, 9
- add r4, r8
- adds r0, r5, 0
- adds r1, r4, 0
- bl sub_800D238
- ldr r0, _08031A50 @ =gBattleMonForms
- add r0, r9
- ldrb r0, [r0]
- lsls r0, 5
- adds r0, r4
- adds r1, r7, 0
- movs r2, 0x20
- bl LoadPalette
-_08031A0A:
- movs r0, 0xBC
- lsls r0, 9
- add r0, r8
- ldr r1, [sp, 0x10]
- adds r0, r1, r0
- ldrh r0, [r0, 0x2]
- cmp r0, 0
- beq _08031A36
- ldr r3, _08031A54 @ =0x00007fff
- adds r0, r7, 0
- movs r1, 0x10
- movs r2, 0x6
- bl BlendPalette
- lsls r1, r7, 1
- ldr r0, _08031A58 @ =gPlttBufferFaded
- adds r0, r1, r0
- ldr r2, _08031A5C @ =gPlttBufferUnfaded
- adds r1, r2
- ldr r2, _08031A60 @ =REG_BG0CNT
- bl CpuSet
-_08031A36:
- add sp, 0x14
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08031A48: .4byte 0x02000000
-_08031A4C: .4byte SPECIES_CASTFORM
-_08031A50: .4byte gBattleMonForms
-_08031A54: .4byte 0x00007fff
-_08031A58: .4byte gPlttBufferFaded
-_08031A5C: .4byte gPlttBufferUnfaded
-_08031A60: .4byte REG_BG0CNT
- thumb_func_end sub_80318FC
-
- thumb_func_start unref_sub_8031A64
-unref_sub_8031A64: @ 8031A64
- bx lr
- thumb_func_end unref_sub_8031A64
-
- thumb_func_start nullsub_9
-nullsub_9: @ 8031A68
- bx lr
- thumb_func_end nullsub_9
-
- thumb_func_start sub_8031A6C
-sub_8031A6C: @ 8031A6C
- push {r4-r6,lr}
- sub sp, 0x10
- adds r4, r0, 0
- adds r0, r1, 0
- lsls r4, 16
- lsrs r4, 16
- lsls r0, 24
- lsrs r0, 24
- bl battle_get_per_side_status
- lsls r0, 24
- lsls r6, r4, 3
- ldr r5, _08031ADC @ =gTrainerFrontPicTable
- adds r5, r6, r5
- ldr r1, _08031AE0 @ =gTrainerFrontPicCoords
- lsls r4, 2
- adds r4, r1
- ldrb r1, [r4]
- ldrb r2, [r4, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08031AE4 @ =gUnknown_081FAF4C
- lsrs r0, 22
- adds r0, r4
- ldr r4, [r0]
- str r4, [sp]
- movs r0, 0
- str r0, [sp, 0x4]
- adds r0, r5, 0
- bl DecompressPicFromTable_2
- str r4, [sp, 0x8]
- ldrh r2, [r5, 0x4]
- ldr r0, _08031AE8 @ =0xffff0000
- ldr r1, [sp, 0xC]
- ands r1, r0
- orrs r1, r2
- str r1, [sp, 0xC]
- ldrh r2, [r5, 0x6]
- lsls r2, 16
- ldr r0, _08031AEC @ =0x0000ffff
- ands r0, r1
- orrs r0, r2
- str r0, [sp, 0xC]
- add r0, sp, 0x8
- bl LoadCompressedObjectPic
- ldr r0, _08031AF0 @ =gTrainerFrontPicPaletteTable
- adds r6, r0
- adds r0, r6, 0
- bl LoadCompressedObjectPalette
- add sp, 0x10
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08031ADC: .4byte gTrainerFrontPicTable
-_08031AE0: .4byte gTrainerFrontPicCoords
-_08031AE4: .4byte gUnknown_081FAF4C
-_08031AE8: .4byte 0xffff0000
-_08031AEC: .4byte 0x0000ffff
-_08031AF0: .4byte gTrainerFrontPicPaletteTable
- thumb_func_end sub_8031A6C
-
- thumb_func_start sub_8031AF4
-sub_8031AF4: @ 8031AF4
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- sub sp, 0x8
- adds r4, r0, 0
- adds r5, r1, 0
- lsls r4, 16
- lsrs r4, 16
- lsls r5, 24
- lsrs r5, 24
- adds r0, r5, 0
- bl battle_get_per_side_status
- lsls r0, 24
- lsls r1, r4, 3
- mov r8, r1
- ldr r6, _08031B60 @ =gTrainerBackPicTable
- add r6, r8
- ldr r1, _08031B64 @ =gTrainerBackPicCoords
- lsls r4, 2
- adds r4, r1
- ldrb r1, [r4]
- ldrb r2, [r4, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08031B68 @ =gUnknown_081FAF4C
- lsrs r0, 22
- adds r0, r4
- ldr r0, [r0]
- str r0, [sp]
- movs r0, 0
- str r0, [sp, 0x4]
- adds r0, r6, 0
- bl DecompressPicFromTable_2
- ldr r0, _08031B6C @ =gTrainerBackPicPaletteTable
- add r8, r0
- mov r1, r8
- ldr r0, [r1]
- lsls r5, 20
- movs r1, 0x80
- lsls r1, 17
- adds r5, r1
- lsrs r5, 16
- adds r1, r5, 0
- movs r2, 0x20
- bl LoadCompressedPalette
- add sp, 0x8
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08031B60: .4byte gTrainerBackPicTable
-_08031B64: .4byte gTrainerBackPicCoords
-_08031B68: .4byte gUnknown_081FAF4C
-_08031B6C: .4byte gTrainerBackPicPaletteTable
- thumb_func_end sub_8031AF4
-
- thumb_func_start nullsub_10
-nullsub_10: @ 8031B70
- bx lr
- thumb_func_end nullsub_10
-
- thumb_func_start sub_8031B74
-sub_8031B74: @ 8031B74
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 16
- ldr r0, _08031B98 @ =gTrainerFrontPicPaletteTable
- lsrs r4, 13
- adds r0, r4, r0
- ldrh r0, [r0, 0x4]
- bl FreeSpritePaletteByTag
- ldr r0, _08031B9C @ =gTrainerFrontPicTable
- adds r4, r0
- ldrh r0, [r4, 0x6]
- bl FreeSpriteTilesByTag
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08031B98: .4byte gTrainerFrontPicPaletteTable
-_08031B9C: .4byte gTrainerFrontPicTable
- thumb_func_end sub_8031B74
-
- thumb_func_start unref_sub_8031BA0
-unref_sub_8031BA0: @ 8031BA0
- push {r4-r7,lr}
- ldr r4, _08031BCC @ =gUnknown_0820A4D4
- adds r0, r4, 0
- bl LoadSpritePalette
- adds r4, 0x8
- adds r0, r4, 0
- bl LoadSpritePalette
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- bne _08031BD8
- ldr r0, _08031BD0 @ =gUnknown_0820A47C
- bl LoadCompressedObjectPic
- ldr r0, _08031BD4 @ =gUnknown_0820A484
- bl LoadCompressedObjectPic
- movs r5, 0x2
- b _08031BFA
- .align 2, 0
-_08031BCC: .4byte gUnknown_0820A4D4
-_08031BD0: .4byte gUnknown_0820A47C
-_08031BD4: .4byte gUnknown_0820A484
-_08031BD8:
- ldr r4, _08031C20 @ =gUnknown_0820A48C
- adds r0, r4, 0
- bl LoadCompressedObjectPic
- adds r4, 0x8
- adds r0, r4, 0
- bl LoadCompressedObjectPic
- ldr r4, _08031C24 @ =gUnknown_0820A49C
- adds r0, r4, 0
- bl LoadCompressedObjectPic
- adds r4, 0x8
- adds r0, r4, 0
- bl LoadCompressedObjectPic
- movs r5, 0x4
-_08031BFA:
- movs r4, 0
- cmp r4, r5
- bcs _08031C1A
- ldr r7, _08031C28 @ =gUnknown_02024A72
- ldr r6, _08031C2C @ =gUnknown_0820A4B4
-_08031C04:
- adds r0, r4, r7
- ldrb r0, [r0]
- lsls r0, 3
- adds r0, r6
- bl LoadCompressedObjectPic
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, r5
- bcc _08031C04
-_08031C1A:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08031C20: .4byte gUnknown_0820A48C
-_08031C24: .4byte gUnknown_0820A49C
-_08031C28: .4byte gUnknown_02024A72
-_08031C2C: .4byte gUnknown_0820A4B4
- thumb_func_end unref_sub_8031BA0
-
- thumb_func_start sub_8031C30
-sub_8031C30: @ 8031C30
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- adds r5, r4, 0
- movs r6, 0
- cmp r4, 0
- bne _08031C40
- b _08031D52
-_08031C40:
- cmp r4, 0x1
- bne _08031C5C
- ldr r4, _08031C58 @ =gUnknown_0820A4D4
- adds r0, r4, 0
- bl LoadSpritePalette
- adds r4, 0x8
- adds r0, r4, 0
- bl LoadSpritePalette
- b _08031D52
- .align 2, 0
-_08031C58: .4byte gUnknown_0820A4D4
-_08031C5C:
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- bne _08031CC4
- cmp r4, 0x2
- bne _08031C94
- ldr r0, _08031C80 @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _08031C88
- ldr r0, _08031C84 @ =gUnknown_0820A4AC
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031C80: .4byte gBattleTypeFlags
-_08031C84: .4byte gUnknown_0820A4AC
-_08031C88:
- ldr r0, _08031C90 @ =gUnknown_0820A47C
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031C90: .4byte gUnknown_0820A47C
-_08031C94:
- cmp r4, 0x3
- bne _08031CA4
- ldr r0, _08031CA0 @ =gUnknown_0820A484
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031CA0: .4byte gUnknown_0820A484
-_08031CA4:
- cmp r4, 0x4
- bne _08031CB4
- ldr r0, _08031CB0 @ =gUnknown_02024A72
- ldrb r0, [r0]
- b _08031D3C
- .align 2, 0
-_08031CB0: .4byte gUnknown_02024A72
-_08031CB4:
- cmp r4, 0x5
- bne _08031D50
- ldr r0, _08031CC0 @ =gUnknown_02024A72
- ldrb r0, [r0, 0x1]
- b _08031D3C
- .align 2, 0
-_08031CC0: .4byte gUnknown_02024A72
-_08031CC4:
- cmp r4, 0x2
- bne _08031CD4
- ldr r0, _08031CD0 @ =gUnknown_0820A48C
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031CD0: .4byte gUnknown_0820A48C
-_08031CD4:
- cmp r4, 0x3
- bne _08031CE4
- ldr r0, _08031CE0 @ =gUnknown_0820A494
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031CE0: .4byte gUnknown_0820A494
-_08031CE4:
- cmp r4, 0x4
- bne _08031CF4
- ldr r0, _08031CF0 @ =gUnknown_0820A49C
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031CF0: .4byte gUnknown_0820A49C
-_08031CF4:
- cmp r4, 0x5
- bne _08031D04
- ldr r0, _08031D00 @ =gUnknown_0820A4A4
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031D00: .4byte gUnknown_0820A4A4
-_08031D04:
- cmp r4, 0x6
- bne _08031D14
- ldr r0, _08031D10 @ =gUnknown_02024A72
- ldrb r0, [r0]
- b _08031D3C
- .align 2, 0
-_08031D10: .4byte gUnknown_02024A72
-_08031D14:
- cmp r4, 0x7
- bne _08031D24
- ldr r0, _08031D20 @ =gUnknown_02024A72
- ldrb r0, [r0, 0x1]
- b _08031D3C
- .align 2, 0
-_08031D20: .4byte gUnknown_02024A72
-_08031D24:
- cmp r4, 0x8
- bne _08031D34
- ldr r0, _08031D30 @ =gUnknown_02024A72
- ldrb r0, [r0, 0x2]
- b _08031D3C
- .align 2, 0
-_08031D30: .4byte gUnknown_02024A72
-_08031D34:
- cmp r5, 0x9
- bne _08031D50
- ldr r0, _08031D48 @ =gUnknown_02024A72
- ldrb r0, [r0, 0x3]
-_08031D3C:
- lsls r0, 3
- ldr r1, _08031D4C @ =gUnknown_0820A4B4
- adds r0, r1
- bl LoadCompressedObjectPic
- b _08031D52
- .align 2, 0
-_08031D48: .4byte gUnknown_02024A72
-_08031D4C: .4byte gUnknown_0820A4B4
-_08031D50:
- movs r6, 0x1
-_08031D52:
- adds r0, r6, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- thumb_func_end sub_8031C30
-
- thumb_func_start load_gfxc_health_bar
-load_gfxc_health_bar: @ 8031D5C
- push {lr}
- ldr r0, _08031D6C @ =gUnknown_08D09C48
- movs r1, 0x80
- lsls r1, 18
- bl sub_800D238
- pop {r0}
- bx r0
- .align 2, 0
-_08031D6C: .4byte gUnknown_08D09C48
- thumb_func_end load_gfxc_health_bar
-
- thumb_func_start battle_load_something
-battle_load_something: @ 8031D70
- push {r4-r6,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- movs r6, 0
- ldrb r0, [r5]
- cmp r0, 0x6
- bls _08031D80
- b _08031EDE
-_08031D80:
- lsls r0, 2
- ldr r1, _08031D8C @ =_08031D90
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08031D8C: .4byte _08031D90
- .align 2, 0
-_08031D90:
- .4byte _08031DAC
- .4byte _08031DB2
- .4byte _08031EBC
- .4byte _08031DC8
- .4byte _08031DF8
- .4byte _08031E34
- .4byte _08031ED4
-_08031DAC:
- bl sub_8031F0C
- b _08031EBC
-_08031DB2:
- ldrb r0, [r4]
- bl sub_8031C30
- lsls r0, 24
- cmp r0, 0
- beq _08031DC0
- b _08031EB8
-_08031DC0:
- ldrb r0, [r4]
- adds r0, 0x1
- strb r0, [r4]
- b _08031EDE
-_08031DC8:
- ldr r0, _08031DE0 @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _08031DE4
- ldrb r0, [r4]
- cmp r0, 0
- bne _08031DE4
- bl battle_make_oam_safari_battle
- b _08031DEA
- .align 2, 0
-_08031DE0: .4byte gBattleTypeFlags
-_08031DE4:
- ldrb r0, [r4]
- bl battle_make_oam_normal_battle
-_08031DEA:
- ldr r2, _08031DF4 @ =gUnknown_03004340
- ldrb r1, [r4]
- adds r1, r2
- strb r0, [r1]
- b _08031EA6
- .align 2, 0
-_08031DF4: .4byte gUnknown_03004340
-_08031DF8:
- ldrb r0, [r4]
- bl sub_8043F44
- ldr r0, _08031E18 @ =gUnknown_02024A72
- ldrb r1, [r4]
- adds r0, r1, r0
- ldrb r0, [r0]
- cmp r0, 0x1
- bhi _08031E20
- ldr r0, _08031E1C @ =gUnknown_03004340
- adds r0, r1, r0
- ldrb r0, [r0]
- movs r1, 0
- bl nullsub_11
- b _08031EA6
- .align 2, 0
-_08031E18: .4byte gUnknown_02024A72
-_08031E1C: .4byte gUnknown_03004340
-_08031E20:
- ldr r0, _08031E30 @ =gUnknown_03004340
- adds r0, r1, r0
- ldrb r0, [r0]
- movs r1, 0x1
- bl nullsub_11
- b _08031EA6
- .align 2, 0
-_08031E30: .4byte gUnknown_03004340
-_08031E34:
- ldrb r0, [r4]
- bl battle_side_get_owner
- lsls r0, 24
- cmp r0, 0
- bne _08031E7C
- ldr r0, _08031E6C @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08031E9A
- ldr r0, _08031E70 @ =gUnknown_03004340
- ldrb r1, [r4]
- adds r0, r1, r0
- ldrb r0, [r0]
- ldr r2, _08031E74 @ =gUnknown_02024A6A
- lsls r1, 1
- adds r1, r2
- ldrh r2, [r1]
- movs r1, 0x64
- muls r1, r2
- ldr r2, _08031E78 @ =gPlayerParty
- adds r1, r2
- movs r2, 0
- bl sub_8045A5C
- b _08031E9A
- .align 2, 0
-_08031E6C: .4byte gBattleTypeFlags
-_08031E70: .4byte gUnknown_03004340
-_08031E74: .4byte gUnknown_02024A6A
-_08031E78: .4byte gPlayerParty
-_08031E7C:
- ldr r0, _08031EC4 @ =gUnknown_03004340
- ldrb r1, [r4]
- adds r0, r1, r0
- ldrb r0, [r0]
- ldr r2, _08031EC8 @ =gUnknown_02024A6A
- lsls r1, 1
- adds r1, r2
- ldrh r2, [r1]
- movs r1, 0x64
- muls r1, r2
- ldr r2, _08031ECC @ =gEnemyParty
- adds r1, r2
- movs r2, 0
- bl sub_8045A5C
-_08031E9A:
- ldr r1, _08031EC4 @ =gUnknown_03004340
- ldrb r0, [r4]
- adds r0, r1
- ldrb r0, [r0]
- bl sub_8043DB0
-_08031EA6:
- ldrb r0, [r4]
- adds r0, 0x1
- strb r0, [r4]
- ldr r1, _08031ED0 @ =gUnknown_02024A68
- lsls r0, 24
- lsrs r0, 24
- ldrb r1, [r1]
- cmp r0, r1
- bne _08031EDE
-_08031EB8:
- movs r0, 0
- strb r0, [r4]
-_08031EBC:
- ldrb r0, [r5]
- adds r0, 0x1
- strb r0, [r5]
- b _08031EDE
- .align 2, 0
-_08031EC4: .4byte gUnknown_03004340
-_08031EC8: .4byte gUnknown_02024A6A
-_08031ECC: .4byte gEnemyParty
-_08031ED0: .4byte gUnknown_02024A68
-_08031ED4:
- bl sub_80327CC
- bl sub_8094958
- movs r6, 0x1
-_08031EDE:
- adds r0, r6, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- thumb_func_end battle_load_something
-
- thumb_func_start sub_8031EE8
-sub_8031EE8: @ 8031EE8
- push {r4,lr}
- ldr r4, _08031F08 @ =0x02017810
- adds r0, r4, 0
- movs r1, 0
- movs r2, 0x30
- bl memset
- adds r4, 0x30
- adds r0, r4, 0
- movs r1, 0
- movs r2, 0x10
- bl memset
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08031F08: .4byte 0x02017810
- thumb_func_end sub_8031EE8
-
- thumb_func_start sub_8031F0C
-sub_8031F0C: @ 8031F0C
- push {lr}
- bl sub_8031EE8
- ldr r0, _08031F20 @ =0x02017800
- movs r1, 0
- movs r2, 0x10
- bl memset
- pop {r0}
- bx r0
- .align 2, 0
-_08031F20: .4byte 0x02017800
- thumb_func_end sub_8031F0C
-
- thumb_func_start sub_8031F24
-sub_8031F24: @ 8031F24
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- movs r4, 0
- ldr r5, _08031F78 @ =gUnknown_02024A68
- ldrb r0, [r5]
- cmp r4, r0
- bge _08031F6E
- ldr r0, _08031F7C @ =gSprites
- mov r8, r0
- movs r7, 0x1
- movs r0, 0x2
- negs r0, r0
- mov r12, r0
- ldr r6, _08031F80 @ =gUnknown_02024BE0
- ldr r3, _08031F84 @ =0x02017800
-_08031F44:
- adds r0, r4, r6
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- add r0, r8
- adds r0, 0x3E
- ldrb r1, [r0]
- lsls r1, 29
- lsrs r1, 31
- ands r1, r7
- ldrb r2, [r3]
- mov r0, r12
- ands r0, r2
- orrs r0, r1
- strb r0, [r3]
- adds r3, 0x4
- adds r4, 0x1
- ldrb r0, [r5]
- cmp r4, r0
- blt _08031F44
-_08031F6E:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08031F78: .4byte gUnknown_02024A68
-_08031F7C: .4byte gSprites
-_08031F80: .4byte gUnknown_02024BE0
-_08031F84: .4byte 0x02017800
- thumb_func_end sub_8031F24
-
- thumb_func_start sub_8031F88
-sub_8031F88: @ 8031F88
- lsls r0, 24
- lsrs r0, 24
- lsls r3, r0, 2
- ldr r1, _08031FB8 @ =0x02017800
- adds r3, r1
- ldr r2, _08031FBC @ =gSprites
- ldr r1, _08031FC0 @ =gUnknown_02024BE0
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- adds r0, 0x3E
- ldrb r1, [r0]
- lsls r1, 29
- lsrs r1, 31
- ldrb r2, [r3]
- movs r0, 0x2
- negs r0, r0
- ands r0, r2
- orrs r0, r1
- strb r0, [r3]
- bx lr
- .align 2, 0
-_08031FB8: .4byte 0x02017800
-_08031FBC: .4byte gSprites
-_08031FC0: .4byte gUnknown_02024BE0
- thumb_func_end sub_8031F88
-
- thumb_func_start sub_8031FC4
-sub_8031FC4: @ 8031FC4
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x10
- lsls r0, 24
- lsrs r0, 24
- mov r8, r0
- lsls r1, 24
- lsrs r1, 24
- str r1, [sp, 0xC]
- lsls r2, 24
- cmp r2, 0
- beq _08032088
- ldr r0, _08032064 @ =gUnknown_02024BE0
- mov r1, r8
- adds r6, r1, r0
- ldrb r1, [r6]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r7, _08032068 @ =gSprites
- adds r0, r7
- ldr r4, _0803206C @ =0x02017840
- ldrb r1, [r4]
- bl StartSpriteAnim
- mov r2, r8
- lsls r0, r2, 20
- movs r5, 0x80
- lsls r5, 17
- adds r0, r5
- lsrs r5, r0, 16
- ldrh r0, [r4]
- lsls r0, 5
- ldr r2, _08032070 @ =0xffffebc0
- adds r1, r4, r2
- adds r0, r1
- adds r1, r5, 0
- movs r2, 0x20
- bl LoadPalette
- ldr r0, _08032074 @ =gBattleMonForms
- add r0, r8
- ldrh r1, [r4]
- strb r1, [r0]
- mov r1, r8
- lsls r0, r1, 2
- subs r4, 0x40
- adds r0, r4
- ldrh r0, [r0, 0x2]
- cmp r0, 0
- beq _0803204C
- ldr r3, _08032078 @ =0x00007fff
- adds r0, r5, 0
- movs r1, 0x10
- movs r2, 0x6
- bl BlendPalette
- lsls r1, r5, 1
- ldr r0, _0803207C @ =gPlttBufferFaded
- adds r0, r1, r0
- ldr r2, _08032080 @ =gPlttBufferUnfaded
- adds r1, r2
- ldr r2, _08032084 @ =REG_BG0CNT
- bl CpuSet
-_0803204C:
- mov r0, r8
- bl sub_8077F68
- ldrb r2, [r6]
- lsls r1, r2, 4
- adds r1, r2
- lsls r1, 2
- adds r1, r7
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r1, 0x22]
- b _080322F6
- .align 2, 0
-_08032064: .4byte gUnknown_02024BE0
-_08032068: .4byte gSprites
-_0803206C: .4byte 0x02017840
-_08032070: .4byte 0xffffebc0
-_08032074: .4byte gBattleMonForms
-_08032078: .4byte 0x00007fff
-_0803207C: .4byte gPlttBufferFaded
-_08032080: .4byte gPlttBufferUnfaded
-_08032084: .4byte REG_BG0CNT
-_08032088:
- bl IsContest
- lsls r0, 24
- cmp r0, 0
- beq _080320D0
- movs r2, 0
- mov r10, r2
- ldr r5, _080320C0 @ =0x02019348
- ldrh r7, [r5, 0x2]
- ldr r4, [r5, 0x8]
- mov r9, r4
- ldr r6, [r5, 0xC]
- lsls r0, r7, 3
- ldr r1, _080320C4 @ =gMonBackPicTable
- adds r0, r1
- ldr r1, _080320C8 @ =gMonBackPicCoords
- lsls r2, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _080320CC @ =gUnknown_081FAF4C
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- ldr r4, [r5, 0x10]
- b _08032184
- .align 2, 0
-_080320C0: .4byte 0x02019348
-_080320C4: .4byte gMonBackPicTable
-_080320C8: .4byte gMonBackPicCoords
-_080320CC: .4byte gUnknown_081FAF4C
-_080320D0:
- mov r0, r8
- bl battle_get_per_side_status
- lsls r0, 24
- lsrs r0, 24
- mov r10, r0
- ldr r0, [sp, 0xC]
- bl battle_side_get_owner
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _08032104
- ldr r1, _080320FC @ =gUnknown_02024A6A
- ldr r5, [sp, 0xC]
- lsls r0, r5, 1
- adds r0, r1
- ldrh r1, [r0]
- movs r0, 0x64
- muls r0, r1
- ldr r1, _08032100 @ =gEnemyParty
- b _08032114
- .align 2, 0
-_080320FC: .4byte gUnknown_02024A6A
-_08032100: .4byte gEnemyParty
-_08032104:
- ldr r1, _0803218C @ =gUnknown_02024A6A
- ldr r2, [sp, 0xC]
- lsls r0, r2, 1
- adds r0, r1
- ldrh r1, [r0]
- movs r0, 0x64
- muls r0, r1
- ldr r1, _08032190 @ =gPlayerParty
-_08032114:
- adds r0, r1
- movs r1, 0xB
- bl GetMonData
- lsls r0, 16
- lsrs r7, r0, 16
- mov r0, r8
- bl battle_side_get_owner
- lsls r0, 24
- cmp r0, 0
- bne _080321A4
- ldr r0, _0803218C @ =gUnknown_02024A6A
- mov r5, r8
- lsls r4, r5, 1
- adds r4, r0
- ldrh r0, [r4]
- movs r6, 0x64
- muls r0, r6
- ldr r5, _08032190 @ =gPlayerParty
- adds r0, r5
- movs r1, 0
- bl GetMonData
- mov r9, r0
- ldrh r0, [r4]
- muls r0, r6
- adds r0, r5
- movs r1, 0x1
- bl GetMonData
- adds r6, r0, 0
- lsls r0, r7, 3
- ldr r1, _08032194 @ =gMonBackPicTable
- adds r0, r1
- ldr r1, _08032198 @ =gMonBackPicCoords
- lsls r2, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _0803219C @ =gUnknown_081FAF4C
- mov r12, r4
- mov r5, r10
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- ldr r4, _080321A0 @ =gUnknown_02024E70
- mov r12, r4
- mov r5, r8
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
-_08032184:
- str r4, [sp, 0x8]
- bl HandleLoadSpecialPokePic
- b _08032202
- .align 2, 0
-_0803218C: .4byte gUnknown_02024A6A
-_08032190: .4byte gPlayerParty
-_08032194: .4byte gMonBackPicTable
-_08032198: .4byte gMonBackPicCoords
-_0803219C: .4byte gUnknown_081FAF4C
-_080321A0: .4byte gUnknown_02024E70
-_080321A4:
- ldr r0, _08032308 @ =gUnknown_02024A6A
- mov r1, r8
- lsls r4, r1, 1
- adds r4, r0
- ldrh r0, [r4]
- movs r6, 0x64
- muls r0, r6
- ldr r5, _0803230C @ =gEnemyParty
- adds r0, r5
- movs r1, 0
- bl GetMonData
- mov r9, r0
- ldrh r0, [r4]
- muls r0, r6
- adds r0, r5
- movs r1, 0x1
- bl GetMonData
- adds r6, r0, 0
- lsls r0, r7, 3
- ldr r1, _08032310 @ =gMonFrontPicTable
- adds r0, r1
- ldr r1, _08032314 @ =gMonFrontPicCoords
- lsls r2, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08032318 @ =gUnknown_081FAF4C
- mov r12, r4
- mov r5, r10
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- ldr r4, _0803231C @ =gUnknown_02024E70
- mov r12, r4
- mov r5, r8
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp, 0x8]
- bl HandleLoadSpecialPokePic
-_08032202:
- ldr r1, _08032318 @ =gUnknown_081FAF4C
- mov r2, r10
- lsls r0, r2, 2
- adds r0, r1
- ldr r2, [r0]
- ldr r0, _08032320 @ =gUnknown_02024BE0
- add r0, r8
- mov r10, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r4, _08032324 @ =gSprites
- adds r0, r4
- ldrh r0, [r0, 0x4]
- lsls r0, 22
- lsrs r0, 17
- ldr r1, _08032328 @ =0x06010000
- adds r0, r1
- ldr r1, _0803232C @ =0x040000d4
- str r2, [r1]
- str r0, [r1, 0x4]
- ldr r0, _08032330 @ =0x84000200
- str r0, [r1, 0x8]
- ldr r0, [r1, 0x8]
- mov r5, r8
- lsls r0, r5, 20
- movs r1, 0x80
- lsls r1, 17
- adds r0, r1
- lsrs r5, r0, 16
- adds r0, r7, 0
- adds r1, r6, 0
- mov r2, r9
- bl species_and_otid_get_pal
- adds r6, r0, 0
- ldr r2, _08032334 @ =0x02000000
- mov r9, r2
- mov r1, r9
- bl sub_800D238
- mov r0, r9
- adds r1, r5, 0
- movs r2, 0x20
- bl LoadPalette
- ldr r0, _08032338 @ =SPECIES_CASTFORM
- cmp r7, r0
- bne _08032288
- movs r4, 0xB2
- lsls r4, 9
- add r4, r9
- adds r0, r6, 0
- adds r1, r4, 0
- bl sub_800D238
- ldr r0, _0803233C @ =gBattleMonForms
- ldr r1, [sp, 0xC]
- adds r0, r1, r0
- ldrb r0, [r0]
- lsls r0, 5
- adds r0, r4
- adds r1, r5, 0
- movs r2, 0x20
- bl LoadPalette
-_08032288:
- ldr r3, _08032340 @ =0x00007fff
- adds r0, r5, 0
- movs r1, 0x10
- movs r2, 0x6
- bl BlendPalette
- lsls r1, r5, 1
- ldr r0, _08032344 @ =gPlttBufferFaded
- adds r0, r1, r0
- ldr r2, _08032348 @ =gPlttBufferUnfaded
- adds r1, r2
- ldr r2, _0803234C @ =REG_BG0CNT
- bl CpuSet
- bl IsContest
- lsls r0, 24
- cmp r0, 0
- bne _080322C8
- mov r2, r8
- lsls r0, r2, 2
- movs r1, 0xBC
- lsls r1, 9
- add r1, r9
- adds r0, r1
- strh r7, [r0, 0x2]
- ldr r0, _0803233C @ =gBattleMonForms
- adds r1, r2, r0
- ldr r4, [sp, 0xC]
- adds r0, r4, r0
- ldrb r0, [r0]
- strb r0, [r1]
-_080322C8:
- mov r0, r8
- bl sub_8077F68
- mov r5, r10
- ldrb r2, [r5]
- lsls r1, r2, 4
- adds r1, r2
- lsls r1, 2
- ldr r2, _08032324 @ =gSprites
- adds r1, r2
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r1, 0x22]
- ldrb r1, [r5]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldr r1, _0803233C @ =gBattleMonForms
- add r1, r8
- ldrb r1, [r1]
- bl StartSpriteAnim
-_080322F6:
- add sp, 0x10
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08032308: .4byte gUnknown_02024A6A
-_0803230C: .4byte gEnemyParty
-_08032310: .4byte gMonFrontPicTable
-_08032314: .4byte gMonFrontPicCoords
-_08032318: .4byte gUnknown_081FAF4C
-_0803231C: .4byte gUnknown_02024E70
-_08032320: .4byte gUnknown_02024BE0
-_08032324: .4byte gSprites
-_08032328: .4byte 0x06010000
-_0803232C: .4byte 0x040000d4
-_08032330: .4byte 0x84000200
-_08032334: .4byte 0x02000000
-_08032338: .4byte SPECIES_CASTFORM
-_0803233C: .4byte gBattleMonForms
-_08032340: .4byte 0x00007fff
-_08032344: .4byte gPlttBufferFaded
-_08032348: .4byte gPlttBufferUnfaded
-_0803234C: .4byte REG_BG0CNT
- thumb_func_end sub_8031FC4
-
- thumb_func_start sub_8032350
-sub_8032350: @ 8032350
- push {r4-r7,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- adds r5, r4, 0
- lsls r1, 24
- cmp r1, 0
- bne _08032408
- bl IsContest
- lsls r0, 24
- cmp r0, 0
- beq _0803236C
- movs r4, 0
- b _08032376
-_0803236C:
- adds r0, r4, 0
- bl battle_get_per_side_status
- lsls r0, 24
- lsrs r4, r0, 24
-_08032376:
- bl IsContest
- lsls r0, 24
- cmp r0, 0
- beq _08032388
- ldr r0, _08032384 @ =gSubstituteDollTilemap
- b _08032396
- .align 2, 0
-_08032384: .4byte gSubstituteDollTilemap
-_08032388:
- adds r0, r5, 0
- bl battle_side_get_owner
- lsls r0, 24
- cmp r0, 0
- beq _080323AC
- ldr r0, _080323A4 @ =gSubstituteDollGfx
-_08032396:
- ldr r1, _080323A8 @ =gUnknown_081FAF4C
- lsls r4, 2
- adds r1, r4, r1
- ldr r1, [r1]
- bl LZDecompressVram
- b _080323BA
- .align 2, 0
-_080323A4: .4byte gSubstituteDollGfx
-_080323A8: .4byte gUnknown_081FAF4C
-_080323AC:
- ldr r0, _080323F4 @ =gSubstituteDollTilemap
- ldr r1, _080323F8 @ =gUnknown_081FAF4C
- lsls r4, 2
- adds r1, r4, r1
- ldr r1, [r1]
- bl LZDecompressVram
-_080323BA:
- lsls r7, r5, 4
- ldr r0, _080323FC @ =gSubstituteDollPal
- mov r12, r0
- ldr r0, _080323F8 @ =gUnknown_081FAF4C
- adds r0, r4, r0
- ldr r4, [r0]
- ldr r3, _08032400 @ =0x040000d4
- ldr r6, _08032404 @ =0x84000200
- movs r0, 0x80
- lsls r0, 4
- adds r2, r4, r0
- adds r5, r0, 0
- movs r1, 0x2
-_080323D4:
- str r4, [r3]
- str r2, [r3, 0x4]
- str r6, [r3, 0x8]
- ldr r0, [r3, 0x8]
- adds r2, r5
- subs r1, 0x1
- cmp r1, 0
- bge _080323D4
- movs r0, 0x80
- lsls r0, 1
- adds r1, r7, r0
- mov r0, r12
- movs r2, 0x20
- bl LoadCompressedPalette
- b _08032456
- .align 2, 0
-_080323F4: .4byte gSubstituteDollTilemap
-_080323F8: .4byte gUnknown_081FAF4C
-_080323FC: .4byte gSubstituteDollPal
-_08032400: .4byte 0x040000d4
-_08032404: .4byte 0x84000200
-_08032408:
- bl IsContest
- lsls r0, 24
- cmp r0, 0
- bne _08032456
- adds r0, r4, 0
- bl battle_side_get_owner
- lsls r0, 24
- cmp r0, 0
- beq _08032440
- ldr r1, _08032438 @ =gUnknown_02024A6A
- lsls r0, r4, 1
- adds r0, r1
- ldrh r1, [r0]
- movs r0, 0x64
- muls r0, r1
- ldr r1, _0803243C @ =gEnemyParty
- adds r0, r1
- adds r1, r4, 0
- bl sub_8031794
- b _08032456
- .align 2, 0
-_08032438: .4byte gUnknown_02024A6A
-_0803243C: .4byte gEnemyParty
-_08032440:
- ldr r1, _0803245C @ =gUnknown_02024A6A
- lsls r0, r5, 1
- adds r0, r1
- ldrh r1, [r0]
- movs r0, 0x64
- muls r0, r1
- ldr r1, _08032460 @ =gPlayerParty
- adds r0, r1
- adds r1, r5, 0
- bl sub_80318FC
-_08032456:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_0803245C: .4byte gUnknown_02024A6A
-_08032460: .4byte gPlayerParty
- thumb_func_end sub_8032350
-
- thumb_func_start refresh_graphics_maybe
-refresh_graphics_maybe: @ 8032464
- push {r4-r6,lr}
- adds r5, r1, 0
- adds r4, r2, 0
- lsls r0, 24
- lsrs r6, r0, 24
- lsls r5, 24
- lsrs r5, 24
- lsls r4, 24
- lsrs r4, 24
- adds r0, r6, 0
- adds r1, r5, 0
- bl sub_8032350
- lsls r0, r4, 4
- adds r0, r4
- lsls r0, 2
- ldr r1, _080324A0 @ =gSprites
- adds r4, r0, r1
- ldr r0, _080324A4 @ =gBattleMonForms
- adds r0, r6, r0
- ldrb r1, [r0]
- adds r0, r4, 0
- bl StartSpriteAnim
- cmp r5, 0
- bne _080324A8
- adds r0, r6, 0
- bl sub_8077F7C
- b _080324AE
- .align 2, 0
-_080324A0: .4byte gSprites
-_080324A4: .4byte gBattleMonForms
-_080324A8:
- adds r0, r6, 0
- bl sub_8077F68
-_080324AE:
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x22]
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end refresh_graphics_maybe
-
- thumb_func_start sub_80324BC
-sub_80324BC: @ 80324BC
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 16
- lsrs r1, 16
- cmp r1, 0xA4
- bne _080324D8
- lsls r2, r0, 2
- ldr r0, _080324DC @ =0x02017800
- adds r2, r0
- ldrb r0, [r2]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r2]
-_080324D8:
- pop {r0}
- bx r0
- .align 2, 0
-_080324DC: .4byte 0x02017800
- thumb_func_end sub_80324BC
-
- thumb_func_start sub_80324E0
-sub_80324E0: @ 80324E0
- lsls r0, 24
- lsrs r0, 22
- ldr r1, _080324F4 @ =0x02017800
- adds r0, r1
- ldrb r2, [r0]
- movs r1, 0x5
- negs r1, r1
- ands r1, r2
- strb r1, [r0]
- bx lr
- .align 2, 0
-_080324F4: .4byte 0x02017800
- thumb_func_end sub_80324E0
-
- thumb_func_start sub_80324F8
-sub_80324F8: @ 80324F8
- push {r4-r7,lr}
- adds r5, r0, 0
- lsls r1, 24
- lsrs r6, r1, 24
- adds r7, r6, 0
- movs r1, 0x39
- bl GetMonData
- adds r4, r0, 0
- lsls r4, 16
- lsrs r4, 16
- adds r0, r5, 0
- movs r1, 0x3A
- bl GetMonData
- adds r1, r0, 0
- lsls r4, 16
- asrs r4, 16
- lsls r1, 16
- asrs r1, 16
- adds r0, r4, 0
- bl GetHPBarLevel
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _08032568
- lsls r0, r6, 2
- ldr r3, _08032564 @ =0x02017800
- adds r4, r0, r3
- ldrb r1, [r4]
- movs r5, 0x2
- movs r2, 0x2
- adds r0, r2, 0
- ands r0, r1
- cmp r0, 0
- bne _080325B2
- adds r0, r6, 0
- eors r0, r5
- lsls r0, 2
- adds r0, r3
- ldrb r1, [r0]
- adds r0, r2, 0
- ands r0, r1
- cmp r0, 0
- bne _0803255A
- movs r0, 0x5A
- bl PlaySE
-_0803255A:
- ldrb r0, [r4]
- orrs r0, r5
- strb r0, [r4]
- b _080325B2
- .align 2, 0
-_08032564: .4byte 0x02017800
-_08032568:
- lsls r1, r6, 2
- ldr r4, _0803258C @ =0x02017800
- adds r1, r4
- ldrb r2, [r1]
- movs r0, 0x3
- negs r0, r0
- ands r0, r2
- strb r0, [r1]
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- bne _08032590
- movs r0, 0x5A
- bl m4aSongNumStop
- b _080325B2
- .align 2, 0
-_0803258C: .4byte 0x02017800
-_08032590:
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _080325B2
- movs r0, 0x2
- eors r7, r0
- lsls r0, r7, 2
- adds r0, r4
- ldrb r1, [r0]
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- bne _080325B2
- movs r0, 0x5A
- bl m4aSongNumStop
-_080325B2:
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_80324F8
-
- thumb_func_start sub_80325B8
-sub_80325B8: @ 80325B8
- push {r4-r6,lr}
- movs r0, 0
- bl battle_get_side_with_given_state
- lsls r0, 24
- lsrs r4, r0, 24
- lsls r1, r4, 2
- ldr r6, _08032600 @ =0x02017800
- adds r1, r6
- ldrb r2, [r1]
- movs r5, 0x3
- negs r5, r5
- adds r0, r5, 0
- ands r0, r2
- strb r0, [r1]
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _080325F2
- movs r0, 0x2
- adds r1, r4, 0
- eors r1, r0
- lsls r1, 2
- adds r1, r6
- ldrb r2, [r1]
- adds r0, r5, 0
- ands r0, r2
- strb r0, [r1]
-_080325F2:
- movs r0, 0x5A
- bl m4aSongNumStop
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08032600: .4byte 0x02017800
- thumb_func_end sub_80325B8
-
- thumb_func_start unref_sub_8032604
-unref_sub_8032604: @ 8032604
- push {r4,r5,lr}
- adds r5, r0, 0
- movs r1, 0x39
- bl GetMonData
- adds r4, r0, 0
- lsls r4, 16
- lsrs r4, 16
- adds r0, r5, 0
- movs r1, 0x3A
- bl GetMonData
- adds r1, r0, 0
- lsls r4, 16
- asrs r4, 16
- lsls r1, 16
- asrs r1, 16
- adds r0, r4, 0
- bl GetHPBarLevel
- lsls r0, 24
- lsrs r0, 24
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end unref_sub_8032604
-
- thumb_func_start sub_8032638
-sub_8032638: @ 8032638
- push {r4-r7,lr}
- mov r7, r9
- mov r6, r8
- push {r6,r7}
- ldr r0, _080326DC @ =gMain
- ldr r1, _080326E0 @ =0x0000043d
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _080326CE
- movs r0, 0
- bl battle_get_side_with_given_state
- lsls r0, 24
- lsrs r0, 24
- mov r8, r0
- movs r0, 0x2
- bl battle_get_side_with_given_state
- lsls r0, 24
- lsrs r0, 24
- mov r9, r0
- ldr r5, _080326E4 @ =gUnknown_02024A6A
- mov r1, r8
- lsls r0, r1, 1
- adds r0, r5
- ldrb r0, [r0]
- bl pokemon_order_func
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- mov r1, r9
- lsls r0, r1, 1
- adds r0, r5
- ldrb r0, [r0]
- bl pokemon_order_func
- lsls r0, 24
- lsrs r5, r0, 24
- movs r7, 0x64
- adds r0, r4, 0
- muls r0, r7
- ldr r6, _080326E8 @ =gPlayerParty
- adds r4, r0, r6
- adds r0, r4, 0
- movs r1, 0x39
- bl GetMonData
- cmp r0, 0
- beq _080326AA
- adds r0, r4, 0
- mov r1, r8
- bl sub_80324F8
-_080326AA:
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _080326CE
- adds r0, r5, 0
- muls r0, r7
- adds r4, r0, r6
- adds r0, r4, 0
- movs r1, 0x39
- bl GetMonData
- cmp r0, 0
- beq _080326CE
- adds r0, r4, 0
- mov r1, r9
- bl sub_80324F8
-_080326CE:
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080326DC: .4byte gMain
-_080326E0: .4byte 0x0000043d
-_080326E4: .4byte gUnknown_02024A6A
-_080326E8: .4byte gPlayerParty
- thumb_func_end sub_8032638
-
- thumb_func_start sub_80326EC
-sub_80326EC: @ 80326EC
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- lsls r0, 24
- lsrs r0, 24
- mov r8, r0
- movs r5, 0
- ldr r0, _08032778 @ =gUnknown_02024A68
- ldrb r0, [r0]
- cmp r5, r0
- bge _080327B4
- movs r0, 0x3
- mov r10, r8
- mov r1, r10
- ands r1, r0
- mov r10, r1
- movs r6, 0
- movs r2, 0x3F
- negs r2, r2
- mov r9, r2
-_08032718:
- lsls r0, r5, 24
- lsrs r0, 24
- bl sub_8078874
- lsls r0, 24
- cmp r0, 0
- beq _080327A8
- ldr r4, _0803277C @ =gSprites
- ldr r0, _08032780 @ =gUnknown_02024BE0
- adds r3, r5, r0
- ldrb r1, [r3]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0, 0x1]
- movs r7, 0x4
- negs r7, r7
- adds r2, r7, 0
- ands r1, r2
- mov r2, r10
- orrs r1, r2
- strb r1, [r0, 0x1]
- mov r7, r8
- cmp r7, 0
- bne _08032788
- ldr r2, _08032784 @ =0x02017810
- adds r2, r6, r2
- ldrb r1, [r3]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- ldrb r0, [r0, 0x3]
- lsls r0, 26
- lsrs r0, 27
- strb r0, [r2, 0x6]
- ldrb r1, [r3]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0, 0x3]
- mov r2, r9
- ands r1, r2
- strb r1, [r0, 0x3]
- b _080327A8
- .align 2, 0
-_08032778: .4byte gUnknown_02024A68
-_0803277C: .4byte gSprites
-_08032780: .4byte gUnknown_02024BE0
-_08032784: .4byte 0x02017810
-_08032788:
- ldrb r0, [r3]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r4
- ldr r0, _080327C4 @ =0x02017810
- adds r0, r6, r0
- ldrb r1, [r0, 0x6]
- movs r0, 0x1F
- ands r1, r0
- lsls r1, 1
- ldrb r0, [r2, 0x3]
- mov r3, r9
- ands r0, r3
- orrs r0, r1
- strb r0, [r2, 0x3]
-_080327A8:
- adds r6, 0xC
- adds r5, 0x1
- ldr r0, _080327C8 @ =gUnknown_02024A68
- ldrb r0, [r0]
- cmp r5, r0
- blt _08032718
-_080327B4:
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080327C4: .4byte 0x02017810
-_080327C8: .4byte gUnknown_02024A68
- thumb_func_end sub_80326EC
-
- thumb_func_start sub_80327CC
-sub_80327CC: @ 80327CC
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- ldr r0, _08032894 @ =gUnknown_081FAF24
- bl LoadCompressedObjectPic
- movs r0, 0x1
- bl battle_get_side_with_given_state
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- ldr r0, _08032898 @ =gSpriteTemplate_81FAF34
- mov r8, r0
- adds r0, r5, 0
- movs r1, 0
- bl sub_8077ABC
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r5, 0
- movs r1, 0x1
- bl sub_8077ABC
- adds r2, r0, 0
- lsls r2, 24
- lsrs r2, 8
- movs r0, 0x80
- lsls r0, 14
- adds r2, r0
- asrs r2, 16
- mov r0, r8
- adds r1, r4, 0
- movs r3, 0xC8
- bl CreateSprite
- lsls r1, r5, 1
- adds r1, r5
- lsls r1, 2
- ldr r6, _0803289C @ =0x02017810
- adds r1, r6
- strb r0, [r1, 0x7]
- ldr r7, _080328A0 @ =gSprites
- ldrb r1, [r1, 0x7]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r7
- strh r5, [r0, 0x2E]
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _0803288A
- movs r0, 0x3
- bl battle_get_side_with_given_state
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- adds r0, r5, 0
- movs r1, 0
- bl sub_8077ABC
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r5, 0
- movs r1, 0x1
- bl sub_8077ABC
- adds r2, r0, 0
- lsls r2, 24
- lsrs r2, 8
- movs r0, 0x80
- lsls r0, 14
- adds r2, r0
- asrs r2, 16
- mov r0, r8
- adds r1, r4, 0
- movs r3, 0xC8
- bl CreateSprite
- lsls r1, r5, 1
- adds r1, r5
- lsls r1, 2
- adds r1, r6
- strb r0, [r1, 0x7]
- ldrb r1, [r1, 0x7]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r7
- strh r5, [r0, 0x2E]
-_0803288A:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08032894: .4byte gUnknown_081FAF24
-_08032898: .4byte gSpriteTemplate_81FAF34
-_0803289C: .4byte 0x02017810
-_080328A0: .4byte gSprites
- thumb_func_end sub_80327CC
-
- thumb_func_start sub_80328A4
-sub_80328A4: @ 80328A4
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- adds r5, r0, 0
- movs r0, 0
- mov r8, r0
- ldrh r0, [r5, 0x2E]
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r0, _080328E8 @ =gUnknown_02024BE0
- adds r0, r4, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _080328EC @ =gSprites
- adds r7, r0, r1
- adds r6, r7, 0
- adds r6, 0x3E
- ldrb r1, [r6]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _080328E0
- adds r0, r4, 0
- bl sub_8078874
- lsls r0, 24
- cmp r0, 0
- bne _080328F4
-_080328E0:
- ldr r0, _080328F0 @ =sub_8032978
- str r0, [r5, 0x1C]
- b _08032964
- .align 2, 0
-_080328E8: .4byte gUnknown_02024BE0
-_080328EC: .4byte gSprites
-_080328F0: .4byte sub_8032978
-_080328F4:
- ldr r0, _08032910 @ =gAnimScriptActive
- ldrb r0, [r0]
- cmp r0, 0
- bne _08032906
- ldrb r1, [r6]
- movs r0, 0x4
- ands r0, r1
- cmp r0, 0
- beq _08032918
-_08032906:
- movs r0, 0x1
- mov r8, r0
- lsls r4, 2
- ldr r6, _08032914 @ =0x02017800
- b _08032938
- .align 2, 0
-_08032910: .4byte gAnimScriptActive
-_08032914: .4byte 0x02017800
-_08032918:
- lsls r0, r4, 2
- ldr r1, _08032970 @ =0x02017800
- adds r3, r0, r1
- ldrh r2, [r3, 0x2]
- adds r4, r0, 0
- adds r6, r1, 0
- cmp r2, 0
- beq _08032938
- ldr r0, _08032974 @ =gEnemyMonElevation
- adds r1, r2, 0
- adds r1, r0
- ldrb r0, [r1]
- cmp r0, 0
- bne _08032938
- movs r0, 0x1
- mov r8, r0
-_08032938:
- adds r0, r4, r6
- ldrb r1, [r0]
- movs r0, 0x4
- ands r0, r1
- cmp r0, 0
- beq _08032948
- movs r0, 0x1
- mov r8, r0
-_08032948:
- ldrh r0, [r7, 0x20]
- strh r0, [r5, 0x20]
- ldrh r0, [r7, 0x24]
- strh r0, [r5, 0x24]
- adds r2, r5, 0
- adds r2, 0x3E
- mov r0, r8
- lsls r3, r0, 2
- ldrb r1, [r2]
- movs r0, 0x5
- negs r0, r0
- ands r0, r1
- orrs r0, r3
- strb r0, [r2]
-_08032964:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08032970: .4byte 0x02017800
-_08032974: .4byte gEnemyMonElevation
- thumb_func_end sub_80328A4
-
- thumb_func_start sub_8032978
-sub_8032978: @ 8032978
- adds r0, 0x3E
- ldrb r1, [r0]
- movs r2, 0x4
- orrs r1, r2
- strb r1, [r0]
- bx lr
- thumb_func_end sub_8032978
-
- thumb_func_start sub_8032984
-sub_8032984: @ 8032984
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- adds r6, r4, 0
- lsls r1, 16
- lsrs r5, r1, 16
- adds r0, r4, 0
- bl battle_side_get_owner
- lsls r0, 24
- cmp r0, 0
- beq _080329FA
- lsls r0, r4, 2
- ldr r3, _080329D0 @ =0x02017800
- adds r1, r0, r3
- ldrh r0, [r1, 0x2]
- cmp r0, 0
- beq _080329AA
- adds r5, r0, 0
-_080329AA:
- ldr r0, _080329D4 @ =gEnemyMonElevation
- adds r0, r5, r0
- ldrb r0, [r0]
- cmp r0, 0
- beq _080329E0
- ldr r2, _080329D8 @ =gSprites
- lsls r0, r4, 1
- adds r0, r4
- lsls r0, 2
- adds r0, r3, r0
- ldrb r1, [r0, 0x17]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _080329DC @ =sub_80328A4
- b _080329F8
- .align 2, 0
-_080329D0: .4byte 0x02017800
-_080329D4: .4byte gEnemyMonElevation
-_080329D8: .4byte gSprites
-_080329DC: .4byte sub_80328A4
-_080329E0:
- ldr r2, _08032A00 @ =gSprites
- lsls r0, r6, 1
- adds r0, r6
- lsls r0, 2
- adds r0, r3, r0
- ldrb r1, [r0, 0x17]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _08032A04 @ =sub_8032978
-_080329F8:
- str r1, [r0]
-_080329FA:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08032A00: .4byte gSprites
-_08032A04: .4byte sub_8032978
- thumb_func_end sub_8032984
-
- thumb_func_start sub_8032A08
-sub_8032A08: @ 8032A08
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08032A2C @ =gSprites
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- ldr r0, _08032A30 @ =0x02017810
- adds r1, r0
- ldrb r1, [r1, 0x7]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _08032A34 @ =sub_8032978
- str r1, [r0]
- bx lr
- .align 2, 0
-_08032A2C: .4byte gSprites
-_08032A30: .4byte 0x02017810
-_08032A34: .4byte sub_8032978
- thumb_func_end sub_8032A08
-
- thumb_func_start sub_8032A38
-sub_8032A38: @ 8032A38
- push {r4-r6,lr}
- ldr r3, _08032AA4 @ =0x06000240
- movs r0, 0
- movs r6, 0xF0
- lsls r6, 8
-_08032A42:
- adds r5, r0, 0x1
- movs r4, 0xF
-_08032A46:
- ldrh r1, [r3]
- adds r0, r6, 0
- ands r0, r1
- cmp r0, 0
- bne _08032A56
- adds r0, r6, 0
- orrs r0, r1
- strh r0, [r3]
-_08032A56:
- ldrh r1, [r3]
- movs r2, 0xF0
- lsls r2, 4
- adds r0, r2, 0
- ands r0, r1
- cmp r0, 0
- bne _08032A6A
- adds r0, r2, 0
- orrs r0, r1
- strh r0, [r3]
-_08032A6A:
- ldrh r1, [r3]
- movs r2, 0xF0
- movs r0, 0xF0
- ands r0, r1
- cmp r0, 0
- bne _08032A7C
- adds r0, r1, 0
- orrs r0, r2
- strh r0, [r3]
-_08032A7C:
- ldrh r1, [r3]
- movs r2, 0xF
- movs r0, 0xF
- ands r0, r1
- cmp r0, 0
- bne _08032A8E
- adds r0, r1, 0
- orrs r0, r2
- strh r0, [r3]
-_08032A8E:
- adds r3, 0x2
- subs r4, 0x1
- cmp r4, 0
- bge _08032A46
- adds r0, r5, 0
- cmp r0, 0x8
- ble _08032A42
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08032AA4: .4byte 0x06000240
- thumb_func_end sub_8032A38
-
- thumb_func_start sub_8032AA8
-sub_8032AA8: @ 8032AA8
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- lsls r1, 24
- lsls r2, r4, 2
- ldr r0, _08032AD4 @ =0x02017800
- adds r2, r0
- movs r3, 0
- movs r0, 0
- strh r0, [r2, 0x2]
- ldr r0, _08032AD8 @ =gBattleMonForms
- adds r0, r4, r0
- strb r3, [r0]
- cmp r1, 0
- bne _08032ACC
- adds r0, r4, 0
- bl sub_80324E0
-_08032ACC:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08032AD4: .4byte 0x02017800
-_08032AD8: .4byte gBattleMonForms
- thumb_func_end sub_8032AA8
-
- thumb_func_start nullsub_45
-nullsub_45: @ 8032ADC
- bx lr
- thumb_func_end nullsub_45
-
- thumb_func_start sub_8032AE0
-sub_8032AE0: @ 8032AE0
- ldr r1, _08032AF0 @ =gUnknown_03004330
- ldr r0, _08032AF4 @ =gUnknown_02024A60
- ldrb r0, [r0]
- lsls r0, 2
- adds r0, r1
- ldr r1, _08032AF8 @ =sub_8032AFC
- str r1, [r0]
- bx lr
- .align 2, 0
-_08032AF0: .4byte gUnknown_03004330
-_08032AF4: .4byte gUnknown_02024A60
-_08032AF8: .4byte sub_8032AFC
- thumb_func_end sub_8032AE0
-
- thumb_func_start sub_8032AFC
-sub_8032AFC: @ 8032AFC
- push {lr}
- ldr r2, _08032B30 @ =gUnknown_02024A64
- ldr r1, _08032B34 @ =gBitTable
- ldr r0, _08032B38 @ =gUnknown_02024A60
- ldrb r3, [r0]
- lsls r0, r3, 2
- adds r0, r1
- ldr r1, [r2]
- ldr r0, [r0]
- ands r1, r0
- cmp r1, 0
- beq _08032B48
- ldr r0, _08032B3C @ =gUnknown_02023A60
- lsls r1, r3, 9
- adds r1, r0
- ldrb r0, [r1]
- cmp r0, 0x38
- bhi _08032B44
- ldr r0, _08032B40 @ =gUnknown_081FAF5C
- ldrb r1, [r1]
- lsls r1, 2
- adds r1, r0
- ldr r0, [r1]
- bl _call_via_r0
- b _08032B48
- .align 2, 0
-_08032B30: .4byte gUnknown_02024A64
-_08032B34: .4byte gBitTable
-_08032B38: .4byte gUnknown_02024A60
-_08032B3C: .4byte gUnknown_02023A60
-_08032B40: .4byte gUnknown_081FAF5C
-_08032B44:
- bl sub_80334EC
-_08032B48:
- pop {r0}
- bx r0
- thumb_func_end sub_8032AFC
-
- thumb_func_start sub_8032B4C
-sub_8032B4C: @ 8032B4C
- push {lr}
- ldr r2, _08032B74 @ =gSprites
- ldr r1, _08032B78 @ =gUnknown_02024BE0
- ldr r0, _08032B7C @ =gUnknown_02024A60
- ldrb r0, [r0]
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, [r0]
- ldr r0, _08032B80 @ =SpriteCallbackDummy
- cmp r1, r0
- bne _08032B70
- bl sub_80334EC
-_08032B70:
- pop {r0}
- bx r0
- .align 2, 0
-_08032B74: .4byte gSprites
-_08032B78: .4byte gUnknown_02024BE0
-_08032B7C: .4byte gUnknown_02024A60
-_08032B80: .4byte SpriteCallbackDummy
- thumb_func_end sub_8032B4C
-
- thumb_func_start sub_8032B84
-sub_8032B84: @ 8032B84
- push {lr}
- ldr r2, _08032BAC @ =gSprites
- ldr r1, _08032BB0 @ =gUnknown_02024BE0
- ldr r0, _08032BB4 @ =gUnknown_02024A60
- ldrb r0, [r0]
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, [r0]
- ldr r0, _08032BB8 @ =SpriteCallbackDummy
- cmp r1, r0
- bne _08032BA8
- bl sub_80334EC
-_08032BA8:
- pop {r0}
- bx r0
- .align 2, 0
-_08032BAC: .4byte gSprites
-_08032BB0: .4byte gUnknown_02024BE0
-_08032BB4: .4byte gUnknown_02024A60
-_08032BB8: .4byte SpriteCallbackDummy
- thumb_func_end sub_8032B84
-
- thumb_func_start sub_8032BBC
-sub_8032BBC: @ 8032BBC
- push {r4-r6,lr}
- ldr r4, _08032C34 @ =gSprites
- ldr r6, _08032C38 @ =gUnknown_02024BE0
- ldr r5, _08032C3C @ =gUnknown_02024A60
- ldrb r0, [r5]
- adds r0, r6
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r2, r0, 2
- adds r0, r4, 0
- adds r0, 0x1C
- adds r0, r2, r0
- ldr r1, [r0]
- ldr r0, _08032C40 @ =SpriteCallbackDummy
- cmp r1, r0
- bne _08032C2C
- adds r0, r2, r4
- ldrh r0, [r0, 0x6]
- bl sub_8031B74
- ldrb r0, [r5]
- adds r0, r6
- ldrb r0, [r0]
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r1, r4
- ldrh r0, [r1, 0x38]
- ldr r2, _08032C44 @ =0x000003ff
- ands r2, r0
- ldrh r3, [r1, 0x4]
- ldr r0, _08032C48 @ =0xfffffc00
- ands r0, r3
- orrs r0, r2
- strh r0, [r1, 0x4]
- ldrb r0, [r5]
- adds r0, r6
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- bl FreeSpriteOamMatrix
- ldrb r0, [r5]
- adds r0, r6
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- bl DestroySprite
- bl sub_80334EC
-_08032C2C:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08032C34: .4byte gSprites
-_08032C38: .4byte gUnknown_02024BE0
-_08032C3C: .4byte gUnknown_02024A60
-_08032C40: .4byte SpriteCallbackDummy
-_08032C44: .4byte 0x000003ff
-_08032C48: .4byte 0xfffffc00
- thumb_func_end sub_8032BBC
-
- thumb_func_start sub_8032C4C
-sub_8032C4C: @ 8032C4C
- push {lr}
- ldr r3, _08032C80 @ =gUnknown_02024A60
- ldrb r0, [r3]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- ldr r2, _08032C84 @ =0x02017810
- adds r1, r2
- ldrb r0, [r1, 0x9]
- subs r0, 0x1
- strb r0, [r1, 0x9]
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0xFF
- bne _08032C7C
- ldrb r0, [r3]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- adds r1, r2
- movs r0, 0
- strb r0, [r1, 0x9]
- bl sub_80334EC
-_08032C7C:
- pop {r0}
- bx r0
- .align 2, 0
-_08032C80: .4byte gUnknown_02024A60
-_08032C84: .4byte 0x02017810
- thumb_func_end sub_8032C4C
-
- thumb_func_start sub_8032C88
-sub_8032C88: @ 8032C88
- push {r4-r7,lr}
- movs r6, 0
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _08032CAC
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _08032CE0
- ldr r0, _08032CCC @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _08032CE0
-_08032CAC:
- ldr r2, _08032CD0 @ =gSprites
- ldr r1, _08032CD4 @ =gUnknown_03004340
- ldr r0, _08032CD8 @ =gUnknown_02024A60
- ldrb r0, [r0]
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, [r0]
- ldr r0, _08032CDC @ =SpriteCallbackDummy
- cmp r1, r0
- bne _08032D16
- b _08032D14
- .align 2, 0
-_08032CCC: .4byte gBattleTypeFlags
-_08032CD0: .4byte gSprites
-_08032CD4: .4byte gUnknown_03004340
-_08032CD8: .4byte gUnknown_02024A60
-_08032CDC: .4byte SpriteCallbackDummy
-_08032CE0:
- ldr r2, _08032DC4 @ =gSprites
- ldr r5, _08032DC8 @ =gUnknown_03004340
- ldr r0, _08032DCC @ =gUnknown_02024A60
- ldrb r3, [r0]
- adds r0, r3, r5
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r4, [r0]
- ldr r0, _08032DD0 @ =SpriteCallbackDummy
- cmp r4, r0
- bne _08032D16
- movs r0, 0x2
- eors r3, r0
- adds r0, r3, r5
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldr r0, [r0]
- cmp r0, r4
- bne _08032D16
-_08032D14:
- movs r6, 0x1
-_08032D16:
- bl IsCryPlayingOrClearCrySongs
- lsls r0, 24
- cmp r0, 0
- beq _08032D22
- movs r6, 0
-_08032D22:
- cmp r6, 0
- beq _08032E0E
- ldr r7, _08032DCC @ =gUnknown_02024A60
- ldrb r2, [r7]
- lsls r0, r2, 1
- adds r0, r2
- lsls r0, 2
- ldr r5, _08032DD4 @ =0x02017810
- adds r4, r0, r5
- ldrb r1, [r4, 0x1]
- movs r3, 0x1
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- beq _08032E0E
- movs r6, 0x2
- adds r1, r6, 0
- eors r1, r2
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r5
- ldrb r1, [r0, 0x1]
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- beq _08032E0E
- ldrb r1, [r4]
- movs r3, 0x7F
- adds r0, r3, 0
- ands r0, r1
- strb r0, [r4]
- ldrb r0, [r7]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- adds r1, r5
- ldrb r2, [r1, 0x1]
- movs r4, 0x2
- negs r4, r4
- adds r0, r4, 0
- ands r0, r2
- strb r0, [r1, 0x1]
- ldrb r0, [r7]
- adds r1, r6, 0
- eors r1, r0
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r5
- ldrb r1, [r0]
- ands r3, r1
- strb r3, [r0]
- ldrb r0, [r7]
- adds r1, r6, 0
- eors r1, r0
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r5
- ldrb r1, [r0, 0x1]
- ands r4, r1
- strb r4, [r0, 0x1]
- ldr r4, _08032DD8 @ =0x000027f9
- adds r0, r4, 0
- bl FreeSpriteTilesByTag
- adds r0, r4, 0
- bl FreeSpritePaletteByTag
- ldr r0, _08032DDC @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _08032DE4
- ldr r0, _08032DE0 @ =gMPlay_BGM
- bl m4aMPlayContinue
- b _08032DF0
- .align 2, 0
-_08032DC4: .4byte gSprites
-_08032DC8: .4byte gUnknown_03004340
-_08032DCC: .4byte gUnknown_02024A60
-_08032DD0: .4byte SpriteCallbackDummy
-_08032DD4: .4byte 0x02017810
-_08032DD8: .4byte 0x000027f9
-_08032DDC: .4byte gBattleTypeFlags
-_08032DE0: .4byte gMPlay_BGM
-_08032DE4:
- ldr r0, _08032E14 @ =gMPlay_BGM
- ldr r1, _08032E18 @ =0x0000ffff
- movs r2, 0x80
- lsls r2, 1
- bl m4aMPlayVolumeControl
-_08032DF0:
- ldr r2, _08032E1C @ =gUnknown_02024A60
- ldrb r1, [r2]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r1, _08032E20 @ =0x02017810
- adds r0, r1
- movs r1, 0x3
- strb r1, [r0, 0x9]
- ldr r1, _08032E24 @ =gUnknown_03004330
- ldrb r0, [r2]
- lsls r0, 2
- adds r0, r1
- ldr r1, _08032E28 @ =sub_8032C4C
- str r1, [r0]
-_08032E0E:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08032E14: .4byte gMPlay_BGM
-_08032E18: .4byte 0x0000ffff
-_08032E1C: .4byte gUnknown_02024A60
-_08032E20: .4byte 0x02017810
-_08032E24: .4byte gUnknown_03004330
-_08032E28: .4byte sub_8032C4C
- thumb_func_end sub_8032C88
-
- thumb_func_start sub_8032E2C
-sub_8032E2C: @ 8032E2C
- push {r4-r7,lr}
- mov r7, r9
- mov r6, r8
- push {r6,r7}
- ldr r0, _08032FEC @ =gUnknown_02024A60
- mov r9, r0
- ldrb r2, [r0]
- lsls r3, r2, 1
- adds r0, r3, r2
- lsls r0, 2
- ldr r4, _08032FF0 @ =0x02017810
- adds r0, r4
- ldrb r1, [r0]
- movs r5, 0x88
- adds r0, r5, 0
- ands r0, r1
- cmp r0, 0
- bne _08032E64
- ldr r0, _08032FF4 @ =gUnknown_02024A6A
- adds r0, r3, r0
- ldrh r1, [r0]
- movs r0, 0x64
- muls r1, r0
- ldr r0, _08032FF8 @ =gEnemyParty
- adds r1, r0
- adds r0, r2, 0
- bl sub_8141828
-_08032E64:
- mov r1, r9
- ldrb r0, [r1]
- movs r7, 0x2
- adds r2, r7, 0
- eors r2, r0
- lsls r3, r2, 1
- adds r0, r3, r2
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0]
- adds r0, r5, 0
- ands r0, r1
- cmp r0, 0
- bne _08032E94
- ldr r0, _08032FF4 @ =gUnknown_02024A6A
- adds r0, r3, r0
- ldrh r1, [r0]
- movs r0, 0x64
- muls r1, r0
- ldr r0, _08032FF8 @ =gEnemyParty
- adds r1, r0
- adds r0, r2, 0
- bl sub_8141828
-_08032E94:
- mov r0, r9
- ldrb r2, [r0]
- lsls r0, r2, 1
- adds r0, r2
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0]
- movs r3, 0x8
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- beq _08032EAE
- b _08032FE0
-_08032EAE:
- adds r1, r7, 0
- eors r1, r2
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0]
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- beq _08032EC6
- b _08032FE0
-_08032EC6:
- bl IsDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _08032F58
- ldr r0, _08032FFC @ =gBattleTypeFlags
- ldrh r1, [r0]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- bne _08032F58
- ldr r1, _08033000 @ =gUnknown_0300434C
- mov r2, r9
- ldrb r0, [r2]
- eors r0, r7
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08033004 @ =gSprites
- adds r0, r1
- bl DestroySprite
- ldr r4, _08033008 @ =gUnknown_03004340
- mov r1, r9
- ldrb r0, [r1]
- adds r1, r7, 0
- eors r1, r0
- adds r0, r1, r4
- ldrb r0, [r0]
- ldr r2, _08032FF4 @ =gUnknown_02024A6A
- mov r8, r2
- lsls r1, 1
- add r1, r8
- ldrh r1, [r1]
- movs r6, 0x64
- muls r1, r6
- ldr r5, _08032FF8 @ =gEnemyParty
- adds r1, r5
- movs r2, 0
- bl sub_8045A5C
- mov r1, r9
- ldrb r0, [r1]
- eors r0, r7
- bl sub_804777C
- mov r2, r9
- ldrb r0, [r2]
- eors r0, r7
- adds r0, r4
- ldrb r0, [r0]
- bl sub_8043DFC
- mov r1, r9
- ldrb r0, [r1]
- adds r4, r7, 0
- eors r4, r0
- lsls r0, r4, 1
- add r0, r8
- ldrh r0, [r0]
- muls r0, r6
- adds r0, r5
- movs r1, 0xB
- bl GetMonData
- adds r1, r0, 0
- lsls r1, 16
- lsrs r1, 16
- adds r0, r4, 0
- bl sub_8032984
-_08032F58:
- ldr r1, _08033000 @ =gUnknown_0300434C
- ldr r4, _08032FEC @ =gUnknown_02024A60
- ldrb r0, [r4]
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08033004 @ =gSprites
- adds r0, r1
- bl DestroySprite
- ldr r5, _08033008 @ =gUnknown_03004340
- ldrb r1, [r4]
- adds r0, r1, r5
- ldrb r0, [r0]
- ldr r2, _08032FF4 @ =gUnknown_02024A6A
- mov r9, r2
- lsls r1, 1
- add r1, r9
- ldrh r1, [r1]
- movs r2, 0x64
- mov r8, r2
- mov r2, r8
- muls r2, r1
- adds r1, r2, 0
- ldr r6, _08032FF8 @ =gEnemyParty
- adds r1, r6
- movs r2, 0
- bl sub_8045A5C
- ldrb r0, [r4]
- bl sub_804777C
- ldrb r0, [r4]
- adds r0, r5
- ldrb r0, [r0]
- bl sub_8043DFC
- ldrb r5, [r4]
- lsls r0, r5, 1
- add r0, r9
- ldrh r0, [r0]
- mov r1, r8
- muls r1, r0
- adds r0, r1, 0
- adds r0, r6
- movs r1, 0xB
- bl GetMonData
- adds r1, r0, 0
- lsls r1, 16
- lsrs r1, 16
- adds r0, r5, 0
- bl sub_8032984
- ldr r2, _0803300C @ =0x02017840
- ldrb r1, [r2, 0x9]
- movs r0, 0x2
- negs r0, r0
- ands r0, r1
- strb r0, [r2, 0x9]
- ldr r1, _08033010 @ =gUnknown_03004330
- ldrb r0, [r4]
- lsls r0, 2
- adds r0, r1
- ldr r1, _08033014 @ =sub_8032C88
- str r1, [r0]
-_08032FE0:
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08032FEC: .4byte gUnknown_02024A60
-_08032FF0: .4byte 0x02017810
-_08032FF4: .4byte gUnknown_02024A6A
-_08032FF8: .4byte gEnemyParty
-_08032FFC: .4byte gBattleTypeFlags
-_08033000: .4byte gUnknown_0300434C
-_08033004: .4byte gSprites
-_08033008: .4byte gUnknown_03004340
-_0803300C: .4byte 0x02017840
-_08033010: .4byte gUnknown_03004330
-_08033014: .4byte sub_8032C88
- thumb_func_end sub_8032E2C
-
- thumb_func_start sub_8033018
-sub_8033018: @ 8033018
- push {r4-r7,lr}
- ldr r2, _08033070 @ =gSprites
- ldr r0, _08033074 @ =gUnknown_02024BE0
- ldr r7, _08033078 @ =gUnknown_02024A60
- ldrb r3, [r7]
- adds r0, r3, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r1, r0, r2
- adds r0, r1, 0
- adds r0, 0x3F
- ldrb r0, [r0]
- lsls r0, 27
- lsrs r2, r0, 31
- cmp r2, 0x1
- bne _080330BC
- movs r4, 0x24
- ldrsh r0, [r1, r4]
- cmp r0, 0
- bne _080330BC
- lsls r4, r3, 1
- adds r0, r4, r3
- lsls r0, 2
- ldr r6, _0803307C @ =0x02017810
- adds r1, r0, r6
- ldrb r5, [r1]
- movs r0, 0x80
- ands r0, r5
- cmp r0, 0
- bne _08033088
- ldr r0, _08033080 @ =gUnknown_02024A6A
- adds r0, r4, r0
- ldrh r1, [r0]
- movs r0, 0x64
- muls r1, r0
- ldr r0, _08033084 @ =gEnemyParty
- adds r1, r0
- adds r0, r3, 0
- bl sub_8141828
- b _080330BC
- .align 2, 0
-_08033070: .4byte gSprites
-_08033074: .4byte gUnknown_02024BE0
-_08033078: .4byte gUnknown_02024A60
-_0803307C: .4byte 0x02017810
-_08033080: .4byte gUnknown_02024A6A
-_08033084: .4byte gEnemyParty
-_08033088:
- ldrb r0, [r1, 0x1]
- ands r2, r0
- cmp r2, 0
- beq _080330BC
- movs r0, 0x7F
- ands r0, r5
- strb r0, [r1]
- ldrb r0, [r7]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- adds r1, r6
- ldrb r2, [r1, 0x1]
- movs r0, 0x2
- negs r0, r0
- ands r0, r2
- strb r0, [r1, 0x1]
- ldr r4, _080330C4 @ =0x000027f9
- adds r0, r4, 0
- bl FreeSpriteTilesByTag
- adds r0, r4, 0
- bl FreeSpritePaletteByTag
- bl sub_80334EC
-_080330BC:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080330C4: .4byte 0x000027f9
- thumb_func_end sub_8033018
-
- thumb_func_start sub_80330C8
-sub_80330C8: @ 80330C8
- push {r4-r6,lr}
- ldr r6, _08033108 @ =gUnknown_02024A60
- ldrb r0, [r6]
- ldr r5, _0803310C @ =gUnknown_03004340
- adds r1, r0, r5
- ldrb r1, [r1]
- movs r2, 0
- movs r3, 0
- bl sub_8045C78
- adds r4, r0, 0
- lsls r4, 16
- lsrs r4, 16
- ldrb r0, [r6]
- adds r0, r5
- ldrb r0, [r0]
- bl sub_8043DFC
- lsls r4, 16
- asrs r1, r4, 16
- movs r0, 0x1
- negs r0, r0
- cmp r1, r0
- beq _08033110
- ldrb r0, [r6]
- adds r0, r5
- ldrb r0, [r0]
- movs r2, 0
- bl sub_80440EC
- b _08033114
- .align 2, 0
-_08033108: .4byte gUnknown_02024A60
-_0803310C: .4byte gUnknown_03004340
-_08033110:
- bl sub_80334EC
-_08033114:
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end sub_80330C8
-
- thumb_func_start sub_803311C
-sub_803311C: @ 803311C
- push {lr}
- ldr r2, _08033150 @ =gSprites
- ldr r0, _08033154 @ =gUnknown_02024BE0
- ldr r1, _08033158 @ =gUnknown_02024A60
- ldrb r3, [r1]
- adds r0, r3, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- adds r0, 0x3E
- ldrb r0, [r0]
- lsls r0, 31
- cmp r0, 0
- bne _0803314A
- ldr r0, _0803315C @ =gUnknown_03004340
- adds r0, r3, r0
- ldrb r0, [r0]
- bl sub_8043DB0
- bl sub_80334EC
-_0803314A:
- pop {r0}
- bx r0
- .align 2, 0
-_08033150: .4byte gSprites
-_08033154: .4byte gUnknown_02024BE0
-_08033158: .4byte gUnknown_02024A60
-_0803315C: .4byte gUnknown_03004340
- thumb_func_end sub_803311C
-
- thumb_func_start sub_8033160
-sub_8033160: @ 8033160
- push {r4-r6,lr}
- ldr r6, _080331BC @ =gUnknown_02024A60
- ldrb r2, [r6]
- lsls r0, r2, 1
- adds r0, r2
- lsls r0, 2
- ldr r1, _080331C0 @ =0x02017810
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- bne _080331B6
- ldr r5, _080331C4 @ =gUnknown_02024BE0
- adds r0, r2, r5
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r4, _080331C8 @ =gSprites
- adds r0, r4
- bl FreeSpriteOamMatrix
- ldrb r0, [r6]
- adds r0, r5
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- bl DestroySprite
- ldrb r0, [r6]
- bl sub_8032A08
- ldr r1, _080331CC @ =gUnknown_03004340
- ldrb r0, [r6]
- adds r0, r1
- ldrb r0, [r0]
- bl sub_8043DB0
- bl sub_80334EC
-_080331B6:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080331BC: .4byte gUnknown_02024A60
-_080331C0: .4byte 0x02017810
-_080331C4: .4byte gUnknown_02024BE0
-_080331C8: .4byte gSprites
-_080331CC: .4byte gUnknown_03004340
- thumb_func_end sub_8033160
-
- thumb_func_start sub_80331D0
-sub_80331D0: @ 80331D0
- push {lr}
- ldr r0, _080331E4 @ =gUnknown_03004210
- ldrh r0, [r0, 0x16]
- cmp r0, 0
- bne _080331DE
- bl sub_80334EC
-_080331DE:
- pop {r0}
- bx r0
- .align 2, 0
-_080331E4: .4byte gUnknown_03004210
- thumb_func_end sub_80331D0
-
- thumb_func_start bx_blink_t7
-bx_blink_t7: @ 80331E8
- push {r4,lr}
- ldr r1, _08033224 @ =gUnknown_02024BE0
- ldr r0, _08033228 @ =gUnknown_02024A60
- ldrb r0, [r0]
- adds r0, r1
- ldrb r1, [r0]
- ldr r2, _0803322C @ =gSprites
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r4, r0, r2
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- cmp r0, 0x20
- bne _08033234
- movs r3, 0
- movs r0, 0
- strh r0, [r4, 0x30]
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r1, [r2]
- subs r0, 0x5
- ands r0, r1
- strb r0, [r2]
- ldr r0, _08033230 @ =gUnknown_02024E6D
- strb r3, [r0]
- bl sub_80334EC
- b _0803325E
- .align 2, 0
-_08033224: .4byte gUnknown_02024BE0
-_08033228: .4byte gUnknown_02024A60
-_0803322C: .4byte gSprites
-_08033230: .4byte gUnknown_02024E6D
-_08033234:
- ldrh r0, [r4, 0x30]
- movs r1, 0x3
- ands r0, r1
- cmp r0, 0
- bne _08033258
- adds r3, r4, 0
- adds r3, 0x3E
- ldrb r2, [r3]
- lsls r0, r2, 29
- lsrs r0, 31
- movs r1, 0x1
- eors r1, r0
- lsls r1, 2
- movs r0, 0x5
- negs r0, r0
- ands r0, r2
- orrs r0, r1
- strb r0, [r3]
-_08033258:
- ldrh r0, [r4, 0x30]
- adds r0, 0x1
- strh r0, [r4, 0x30]
-_0803325E:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end bx_blink_t7
-
- thumb_func_start sub_8033264
-sub_8033264: @ 8033264
- push {r4,lr}
- ldr r2, _080332B4 @ =gSprites
- ldr r0, _080332B8 @ =gUnknown_03004340
- ldr r4, _080332BC @ =gUnknown_02024A60
- ldrb r3, [r4]
- adds r0, r3, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, [r0]
- ldr r0, _080332C0 @ =SpriteCallbackDummy
- cmp r1, r0
- bne _080332AC
- lsls r0, r3, 2
- ldr r1, _080332C4 @ =0x02017800
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x4
- ands r0, r1
- cmp r0, 0
- beq _080332A0
- adds r0, r3, 0
- adds r1, r3, 0
- adds r2, r3, 0
- movs r3, 0x6
- bl move_anim_start_t4
-_080332A0:
- ldr r0, _080332C8 @ =gUnknown_03004330
- ldrb r1, [r4]
- lsls r1, 2
- adds r1, r0
- ldr r0, _080332CC @ =sub_80332D0
- str r0, [r1]
-_080332AC:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080332B4: .4byte gSprites
-_080332B8: .4byte gUnknown_03004340
-_080332BC: .4byte gUnknown_02024A60
-_080332C0: .4byte SpriteCallbackDummy
-_080332C4: .4byte 0x02017800
-_080332C8: .4byte gUnknown_03004330
-_080332CC: .4byte sub_80332D0
- thumb_func_end sub_8033264
-
- thumb_func_start sub_80332D0
-sub_80332D0: @ 80332D0
- push {lr}
- ldr r0, _080332FC @ =gUnknown_02024A60
- ldrb r1, [r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r1, _08033300 @ =0x02017810
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- bne _080332F6
- ldr r0, _08033304 @ =c3_0802FDF4
- movs r1, 0xA
- bl CreateTask
- bl sub_80334EC
-_080332F6:
- pop {r0}
- bx r0
- .align 2, 0
-_080332FC: .4byte gUnknown_02024A60
-_08033300: .4byte 0x02017810
-_08033304: .4byte c3_0802FDF4
- thumb_func_end sub_80332D0
-
- thumb_func_start sub_8033308
-sub_8033308: @ 8033308
- push {r4,r5,lr}
- ldr r5, _080333AC @ =gUnknown_02024A60
- ldrb r1, [r5]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r3, _080333B0 @ =0x02017810
- adds r2, r0, r3
- ldrb r1, [r2, 0x1]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _080333A4
- ldrb r1, [r2]
- movs r0, 0x7F
- ands r0, r1
- strb r0, [r2]
- ldrb r0, [r5]
- lsls r1, r0, 1
- adds r1, r0
- lsls r1, 2
- adds r1, r3
- ldrb r2, [r1, 0x1]
- movs r0, 0x2
- negs r0, r0
- ands r0, r2
- strb r0, [r1, 0x1]
- ldr r4, _080333B4 @ =0x000027f9
- adds r0, r4, 0
- bl FreeSpriteTilesByTag
- adds r0, r4, 0
- bl FreeSpritePaletteByTag
- ldr r1, _080333B8 @ =gUnknown_02024BE0
- ldrb r0, [r5]
- adds r0, r1
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _080333BC @ =gSprites
- adds r0, r1
- movs r1, 0
- bl StartSpriteAnim
- ldr r4, _080333C0 @ =gUnknown_03004340
- ldrb r1, [r5]
- adds r0, r1, r4
- ldrb r0, [r0]
- ldr r2, _080333C4 @ =gUnknown_02024A6A
- lsls r1, 1
- adds r1, r2
- ldrh r2, [r1]
- movs r1, 0x64
- muls r1, r2
- ldr r2, _080333C8 @ =gEnemyParty
- adds r1, r2
- movs r2, 0
- bl sub_8045A5C
- ldrb r0, [r5]
- bl sub_804777C
- ldrb r0, [r5]
- adds r0, r4
- ldrb r0, [r0]
- bl sub_8043DFC
- ldrb r0, [r5]
- bl sub_8031F88
- ldr r1, _080333CC @ =gUnknown_03004330
- ldrb r0, [r5]
- lsls r0, 2
- adds r0, r1
- ldr r1, _080333D0 @ =sub_8033264
- str r1, [r0]
-_080333A4:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080333AC: .4byte gUnknown_02024A60
-_080333B0: .4byte 0x02017810
-_080333B4: .4byte 0x000027f9
-_080333B8: .4byte gUnknown_02024BE0
-_080333BC: .4byte gSprites
-_080333C0: .4byte gUnknown_03004340
-_080333C4: .4byte gUnknown_02024A6A
-_080333C8: .4byte gEnemyParty
-_080333CC: .4byte gUnknown_03004330
-_080333D0: .4byte sub_8033264
- thumb_func_end sub_8033308
-
- thumb_func_start sub_80333D4
-sub_80333D4: @ 80333D4
- push {r4-r6,lr}
- ldr r5, _08033470 @ =gUnknown_02024A60
- ldrb r2, [r5]
- lsls r3, r2, 1
- adds r0, r3, r2
- lsls r0, 2
- ldr r6, _08033474 @ =0x02017810
- adds r0, r6
- ldrb r1, [r0]
- movs r0, 0x88
- ands r0, r1
- cmp r0, 0
- bne _08033402
- ldr r0, _08033478 @ =gUnknown_02024A6A
- adds r0, r3, r0
- ldrh r1, [r0]
- movs r0, 0x64
- muls r1, r0
- ldr r0, _0803347C @ =gEnemyParty
- adds r1, r0
- adds r0, r2, 0
- bl sub_8141828
-_08033402:
- ldr r4, _08033480 @ =gSprites
- ldr r0, _08033484 @ =gUnknown_0300434C
- ldrb r2, [r5]
- adds r0, r2, r0
- ldrb r1, [r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r3, r0, 2
- adds r0, r4, 0
- adds r0, 0x1C
- adds r0, r3, r0
- ldr r1, [r0]
- ldr r0, _08033488 @ =SpriteCallbackDummy
- cmp r1, r0
- bne _08033468
- lsls r0, r2, 1
- adds r0, r2
- lsls r0, 2
- adds r0, r6
- ldrb r1, [r0]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- bne _08033468
- adds r0, r3, r4
- bl DestroySprite
- ldrb r4, [r5]
- ldr r1, _08033478 @ =gUnknown_02024A6A
- lsls r0, r4, 1
- adds r0, r1
- ldrh r1, [r0]
- movs r0, 0x64
- muls r0, r1
- ldr r1, _0803347C @ =gEnemyParty
- adds r0, r1
- movs r1, 0xB
- bl GetMonData
- adds r1, r0, 0
- lsls r1, 16
- lsrs r1, 16
- adds r0, r4, 0
- bl sub_8032984
- ldr r1, _0803348C @ =gUnknown_03004330
- ldrb r0, [r5]
- lsls r0, 2
- adds r0, r1
- ldr r1, _08033490 @ =sub_8033308
- str r1, [r0]
-_08033468:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08033470: .4byte gUnknown_02024A60
-_08033474: .4byte 0x02017810
-_08033478: .4byte gUnknown_02024A6A
-_0803347C: .4byte gEnemyParty
-_08033480: .4byte gSprites
-_08033484: .4byte gUnknown_0300434C
-_08033488: .4byte SpriteCallbackDummy
-_0803348C: .4byte gUnknown_03004330
-_08033490: .4byte sub_8033308
- thumb_func_end sub_80333D4
-
- thumb_func_start sub_8033494
-sub_8033494: @ 8033494
- push {lr}
- ldr r0, _080334B8 @ =gUnknown_02024A60
- ldrb r1, [r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r1, _080334BC @ =0x02017810
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- bne _080334B2
- bl sub_80334EC
-_080334B2:
- pop {r0}
- bx r0
- .align 2, 0
-_080334B8: .4byte gUnknown_02024A60
-_080334BC: .4byte 0x02017810
- thumb_func_end sub_8033494
-
- thumb_func_start sub_80334C0
-sub_80334C0: @ 80334C0
- push {lr}
- ldr r0, _080334E4 @ =gUnknown_02024A60
- ldrb r1, [r0]
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- ldr r1, _080334E8 @ =0x02017810
- adds r0, r1
- ldrb r1, [r0]
- movs r0, 0x20
- ands r0, r1
- cmp r0, 0
- bne _080334DE
- bl sub_80334EC
-_080334DE:
- pop {r0}
- bx r0
- .align 2, 0
-_080334E4: .4byte gUnknown_02024A60
-_080334E8: .4byte 0x02017810
- thumb_func_end sub_80334C0
-
- thumb_func_start sub_80334EC
-sub_80334EC: @ 80334EC
- ldr r1, _08033510 @ =gUnknown_03004330
- ldr r2, _08033514 @ =gUnknown_02024A60
- ldrb r0, [r2]
- lsls r0, 2
- adds r0, r1
- ldr r1, _08033518 @ =sub_8032AFC
- str r1, [r0]
- ldr r3, _0803351C @ =gUnknown_02024A64
- ldr r1, _08033520 @ =gBitTable
- ldrb r0, [r2]
- lsls r0, 2
- adds r0, r1
- ldr r1, [r0]
- ldr r0, [r3]
- bics r0, r1
- str r0, [r3]
- bx lr
- .align 2, 0
-_08033510: .4byte gUnknown_03004330
-_08033514: .4byte gUnknown_02024A60
-_08033518: .4byte sub_8032AFC
-_0803351C: .4byte gUnknown_02024A64
-_08033520: .4byte gBitTable
- thumb_func_end sub_80334EC
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/battle_anim_81258BC.s b/asm/battle_anim_81258BC.s
index 86abad6f3..be9b806d9 100644
--- a/asm/battle_anim_81258BC.s
+++ b/asm/battle_anim_81258BC.s
@@ -802,7 +802,7 @@ bx_battle_menu_t6_2: @ 812B4D4
beq _0812B546
movs r0, 0x5
bl PlaySE
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r1, _0812B50C @ =gUnknown_02024E60
ldr r0, _0812B510 @ =gUnknown_02024A60
ldrb r0, [r0]
diff --git a/asm/battle_anim_8137220.s b/asm/battle_anim_8137220.s
index 134e18e6f..13773361a 100644
--- a/asm/battle_anim_8137220.s
+++ b/asm/battle_anim_8137220.s
@@ -234,7 +234,7 @@ _081373E8:
bne _08137410
movs r0, 0x5
bl PlaySE
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x1
movs r1, 0x1
movs r2, 0
@@ -3871,7 +3871,7 @@ sub_8139208: @ 8139208
ldrh r0, [r4]
cmp r0, 0x2
bne _0813922A
- bl sub_814A7FC
+ bl DestroyMenuCursor
_0813922A:
ldrh r0, [r4]
bl sub_8120AA8
@@ -4061,7 +4061,7 @@ _081393B2:
lsls r0, 24
cmp r0, 0
bne _081393DE
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x5
bl PlaySE
movs r2, 0x80
diff --git a/asm/battle_tower.s b/asm/battle_tower.s
index 9dfce6c1c..c50903de5 100644
--- a/asm/battle_tower.s
+++ b/asm/battle_tower.s
@@ -1522,7 +1522,7 @@ _081350AE:
lsls r0, 16
lsrs r0, 16
movs r1, 0x1
- bl sub_8090D90
+ bl GetNationalPokedexFlag
lsls r0, 24
cmp r0, 0
beq _081350C6
@@ -1555,7 +1555,7 @@ AppendBattleTowerBannedSpeciesName: @ 81350E0
lsls r0, 16
lsrs r0, 16
movs r1, 0x1
- bl sub_8090D90
+ bl GetNationalPokedexFlag
lsls r0, 24
cmp r0, 0
beq _081351E6
diff --git a/asm/berry_blender.s b/asm/berry_blender.s
index 666882c04..b6ee5f9f3 100644
--- a/asm/berry_blender.s
+++ b/asm/berry_blender.s
@@ -5484,7 +5484,7 @@ _08050ED8:
adds r0, 0x6F
movs r1, 0x3
strb r1, [r0]
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x17
movs r1, 0x8
movs r2, 0x1C
@@ -5513,7 +5513,7 @@ _08050F18:
ldrb r0, [r1]
adds r0, 0x1
strb r0, [r1]
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x17
movs r1, 0x8
movs r2, 0x1C
@@ -5794,7 +5794,7 @@ _0805116E:
adds r0, 0x6F
movs r1, 0x3
strb r1, [r0]
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x17
movs r1, 0x8
movs r2, 0x1C
@@ -5810,7 +5810,7 @@ _08051190:
ldrb r1, [r0]
adds r1, 0x1
strb r1, [r0]
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x17
movs r1, 0x8
movs r2, 0x1C
diff --git a/asm/cable_car.s b/asm/cable_car.s
index 47afb097f..e4d989844 100644
--- a/asm/cable_car.s
+++ b/asm/cable_car.s
@@ -742,7 +742,7 @@ _081237E0:
str r3, [r2, 0x8]
ldr r0, [r2, 0x8]
bl warp_in
- ldr r0, _08123870 @ =gUnknown_0300485C
+ ldr r0, _08123870 @ =gFieldCallback
str r4, [r0]
ldr r0, _08123874 @ =CB2_LoadMap
bl SetMainCallback2
@@ -760,7 +760,7 @@ _08123860: .4byte 0x040000d4
_08123864: .4byte 0x85000400
_08123868: .4byte gUnknown_02039274
_0812386C: .4byte 0x81000800
-_08123870: .4byte gUnknown_0300485C
+_08123870: .4byte gFieldCallback
_08123874: .4byte CB2_LoadMap
thumb_func_end sub_8123740
diff --git a/asm/choose_party.s b/asm/choose_party.s
index 25122e4ef..f1a03cda3 100644
--- a/asm/choose_party.s
+++ b/asm/choose_party.s
@@ -1131,7 +1131,7 @@ _081226DC:
movs r2, 0x1D
movs r3, 0x13
bl MenuZeroFillWindowRect
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
bl sub_806D5A4
ldr r0, _0812271C @ =gOtherText_NoMoreThreePoke
movs r1, 0x1
@@ -1178,7 +1178,7 @@ _0812274A:
movs r2, 0x1D
movs r3, 0x13
bl MenuZeroFillWindowRect
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
adds r0, r4, 0
bl sub_8122838
_08122760:
@@ -1276,7 +1276,7 @@ sub_81227FC: @ 81227FC
movs r2, 0x1D
movs r3, 0x13
bl MenuZeroFillWindowRect
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
bl sub_806D538
@@ -2395,7 +2395,7 @@ sub_81230F4: @ 81230F4
movs r2, 0x1D
movs r3, 0x13
bl MenuZeroFillWindowRect
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0xF
movs r1, 0
bl sub_806D538
@@ -2455,7 +2455,7 @@ sub_8123170: @ 8123170
ands r0, r1
cmp r0, 0
bne _08123194
- ldr r0, _081231A0 @ =gUnknown_0300485C
+ ldr r0, _081231A0 @ =gFieldCallback
ldr r1, _081231A4 @ =sub_81231AC
str r1, [r0]
ldr r0, _081231A8 @ =c2_exit_to_overworld_2_switch
@@ -2468,7 +2468,7 @@ _08123194:
bx r0
.align 2, 0
_0812319C: .4byte gPaletteFade
-_081231A0: .4byte gUnknown_0300485C
+_081231A0: .4byte gFieldCallback
_081231A4: .4byte sub_81231AC
_081231A8: .4byte c2_exit_to_overworld_2_switch
thumb_func_end sub_8123170
diff --git a/asm/contest.s b/asm/contest.s
index 214935952..00c4013a3 100644
--- a/asm/contest.s
+++ b/asm/contest.s
@@ -1577,7 +1577,7 @@ _080ABEC6:
ands r5, r0
cmp r5, 0
beq _080ABF08
- bl sub_814A7FC
+ bl DestroyMenuCursor
movs r0, 0x5
bl PlaySE
ldr r0, _080ABF00 @ =gTasks
@@ -5585,7 +5585,7 @@ sub_80ADFD8: @ 80ADFD8
bne _080ADFFC
adds r0, r2, 0
bl DestroyTask
- ldr r0, _080AE004 @ =gUnknown_0300485C
+ ldr r0, _080AE004 @ =gFieldCallback
ldr r1, _080AE008 @ =sub_80AE010
str r1, [r0]
ldr r0, _080AE00C @ =c2_exit_to_overworld_2_switch
@@ -5595,7 +5595,7 @@ _080ADFFC:
bx r0
.align 2, 0
_080AE000: .4byte gPaletteFade
-_080AE004: .4byte gUnknown_0300485C
+_080AE004: .4byte gFieldCallback
_080AE008: .4byte sub_80AE010
_080AE00C: .4byte c2_exit_to_overworld_2_switch
thumb_func_end sub_80ADFD8
diff --git a/asm/contest_link_80C2020.s b/asm/contest_link_80C2020.s
index 672eb4c1a..7bd7de240 100644
--- a/asm/contest_link_80C2020.s
+++ b/asm/contest_link_80C2020.s
@@ -1601,7 +1601,7 @@ _080C2D42:
lsls r0, 16
lsrs r0, 16
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
adds r5, 0x40
subs r4, 0x1
cmp r4, 0
diff --git a/asm/daycare.s b/asm/daycare.s
index 2944f7565..a0ea9124a 100644
--- a/asm/daycare.s
+++ b/asm/daycare.s
@@ -2279,7 +2279,7 @@ _0804279C:
ands r0, r1
cmp r0, 0
beq _080427E8
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x5
bl PlaySE
ldr r3, _080427DC @ =gLastFieldPokeMenuOpened
@@ -2311,7 +2311,7 @@ _080427E8:
ands r0, r1
cmp r0, 0
beq _08042816
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r0, _0804281C @ =gLastFieldPokeMenuOpened
ldr r1, _08042820 @ =gScriptResult
strh r4, [r1]
diff --git a/asm/decoration_inventory.s b/asm/decoration_inventory.s
deleted file mode 100644
index 953d770ae..000000000
--- a/asm/decoration_inventory.s
+++ /dev/null
@@ -1,404 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start ClearDecorationInventory
-ClearDecorationInventory: @ 8133F4C
- push {r4,r5,lr}
- lsls r0, 24
- movs r3, 0
- ldr r1, _08133F7C @ =gDecorationInventories
- lsrs r2, r0, 21
- adds r0, r2, r1
- ldrb r0, [r0, 0x4]
- cmp r3, r0
- bcs _08133F76
- adds r5, r1, 0
- movs r4, 0
-_08133F62:
- adds r0, r2, r5
- ldr r1, [r0]
- adds r1, r3
- strb r4, [r1]
- adds r1, r3, 0x1
- lsls r1, 24
- lsrs r3, r1, 24
- ldrb r0, [r0, 0x4]
- cmp r3, r0
- bcc _08133F62
-_08133F76:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08133F7C: .4byte gDecorationInventories
- thumb_func_end ClearDecorationInventory
-
- thumb_func_start ClearDecorationInventories
-ClearDecorationInventories: @ 8133F80
- push {r4,lr}
- movs r4, 0
-_08133F84:
- adds r0, r4, 0
- bl ClearDecorationInventory
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x7
- bls _08133F84
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end ClearDecorationInventories
-
- thumb_func_start sub_8133F9C
-sub_8133F9C: @ 8133F9C
- push {r4,lr}
- lsls r0, 24
- movs r2, 0
- ldr r1, _08133FC8 @ =gDecorationInventories
- lsrs r0, 21
- adds r0, r1
- movs r1, 0x4
- ldrsb r1, [r0, r1]
- cmp r2, r1
- bge _08133FD8
- adds r4, r0, 0
- adds r3, r1, 0
-_08133FB4:
- lsls r0, r2, 24
- asrs r1, r0, 24
- ldr r0, [r4]
- adds r0, r1
- ldrb r0, [r0]
- cmp r0, 0
- bne _08133FCC
- adds r0, r1, 0
- b _08133FDC
- .align 2, 0
-_08133FC8: .4byte gDecorationInventories
-_08133FCC:
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r2, r0, 24
- asrs r0, 24
- cmp r0, r3
- blt _08133FB4
-_08133FD8:
- movs r0, 0x1
- negs r0, r0
-_08133FDC:
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8133F9C
-
- thumb_func_start sub_8133FE4
-sub_8133FE4: @ 8133FE4
- push {r4,lr}
- lsls r0, 24
- lsrs r3, r0, 24
- ldr r1, _08134010 @ =gDecorations
- lsls r0, r3, 5
- adds r0, r1
- ldrb r0, [r0, 0x13]
- movs r2, 0
- ldr r1, _08134014 @ =gDecorationInventories
- lsls r0, 3
- adds r0, r1
- ldrb r1, [r0, 0x4]
- cmp r2, r1
- bcs _08134022
- ldr r4, [r0]
-_08134002:
- adds r0, r4, r2
- ldrb r0, [r0]
- cmp r0, r3
- bne _08134018
- movs r0, 0x1
- b _08134024
- .align 2, 0
-_08134010: .4byte gDecorations
-_08134014: .4byte gDecorationInventories
-_08134018:
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r2, r0, 24
- cmp r2, r1
- bcc _08134002
-_08134022:
- movs r0, 0
-_08134024:
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8133FE4
-
- thumb_func_start IsThereStorageSpaceForDecoration
-IsThereStorageSpaceForDecoration: @ 813402C
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- adds r4, r0, 0
- cmp r4, 0
- beq _0813406C
- ldr r1, _08134064 @ =gDecorations
- lsls r0, r4, 5
- adds r0, r1
- ldrb r5, [r0, 0x13]
- adds r0, r5, 0
- bl sub_8133F9C
- lsls r0, 24
- asrs r2, r0, 24
- movs r0, 0x1
- negs r0, r0
- cmp r2, r0
- beq _0813406C
- ldr r0, _08134068 @ =gDecorationInventories
- lsls r1, r5, 3
- adds r1, r0
- ldr r0, [r1]
- adds r0, r2
- strb r4, [r0]
- movs r0, 0x1
- b _0813406E
- .align 2, 0
-_08134064: .4byte gDecorations
-_08134068: .4byte gDecorationInventories
-_0813406C:
- movs r0, 0
-_0813406E:
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end IsThereStorageSpaceForDecoration
-
- thumb_func_start sub_8134074
-sub_8134074: @ 8134074
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0
- beq _081340A0
- ldr r1, _0813409C @ =gDecorations
- lsls r0, 5
- adds r0, r1
- ldrb r0, [r0, 0x13]
- bl sub_8133F9C
- lsls r0, 24
- asrs r0, 24
- movs r1, 0x1
- negs r1, r1
- cmp r0, r1
- beq _081340A0
- movs r0, 0x1
- b _081340A2
- .align 2, 0
-_0813409C: .4byte gDecorations
-_081340A0:
- movs r0, 0
-_081340A2:
- pop {r1}
- bx r1
- thumb_func_end sub_8134074
-
- thumb_func_start sub_81340A8
-sub_81340A8: @ 81340A8
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- movs r3, 0
- cmp r5, 0
- bne _081340C4
- b _081340F2
-_081340B6:
- movs r0, 0
- strb r0, [r1]
- adds r0, r6, 0
- bl sub_8134104
- movs r0, 0x1
- b _081340F4
-_081340C4:
- ldr r2, _081340FC @ =gDecorationInventories
- ldr r1, _08134100 @ =gDecorations
- lsls r0, r5, 5
- adds r0, r1
- ldrb r4, [r0, 0x13]
- lsls r0, r4, 3
- adds r0, r2
- ldrb r1, [r0, 0x4]
- cmp r3, r1
- bcs _081340F2
- adds r6, r4, 0
- adds r4, r0, 0
- adds r2, r1, 0
-_081340DE:
- ldr r0, [r4]
- adds r1, r0, r3
- ldrb r0, [r1]
- cmp r0, r5
- beq _081340B6
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- cmp r3, r2
- bcc _081340DE
-_081340F2:
- movs r0, 0
-_081340F4:
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_081340FC: .4byte gDecorationInventories
-_08134100: .4byte gDecorations
- thumb_func_end sub_81340A8
-
- thumb_func_start sub_8134104
-sub_8134104: @ 8134104
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x4
- lsls r0, 24
- movs r6, 0
- ldr r2, _08134190 @ =gDecorationInventories
- lsrs r1, r0, 21
- adds r0, r1, r2
- ldrb r0, [r0, 0x4]
- cmp r6, r0
- bcs _08134180
- adds r7, r1, 0
- mov r8, r0
- str r0, [sp]
-_08134126:
- adds r1, r6, 0x1
- lsls r0, r1, 24
- lsrs r3, r0, 24
- adds r2, r7, 0
- mov r12, r1
- cmp r3, r8
- bcs _08134174
- ldr r1, _08134190 @ =gDecorationInventories
- mov r10, r1
- adds r0, r1, 0
- mov r9, r0
-_0813413C:
- mov r1, r10
- adds r5, r2, r1
- ldr r1, [r5]
- adds r0, r1, r3
- ldrb r4, [r0]
- adds r2, r4, 0
- cmp r2, 0
- beq _08134162
- adds r0, r1, r6
- ldrb r1, [r0]
- cmp r1, 0
- beq _08134158
- cmp r1, r2
- bls _08134162
-_08134158:
- ldrb r1, [r0]
- strb r4, [r0]
- ldr r0, [r5]
- adds r0, r3
- strb r1, [r0]
-_08134162:
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- adds r2, r7, 0
- mov r1, r9
- adds r0, r2, r1
- ldrb r0, [r0, 0x4]
- cmp r3, r0
- bcc _0813413C
-_08134174:
- mov r1, r12
- lsls r0, r1, 24
- lsrs r6, r0, 24
- ldr r0, [sp]
- cmp r6, r0
- bcc _08134126
-_08134180:
- add sp, 0x4
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08134190: .4byte gDecorationInventories
- thumb_func_end sub_8134104
-
- thumb_func_start sub_8134194
-sub_8134194: @ 8134194
- push {r4,r5,lr}
- lsls r0, 24
- movs r4, 0
- movs r3, 0
- ldr r2, _081341D0 @ =gDecorationInventories
- lsrs r1, r0, 21
- adds r0, r1, r2
- ldrb r0, [r0, 0x4]
- cmp r4, r0
- bcs _081341C8
- adds r5, r2, 0
-_081341AA:
- adds r2, r1, r5
- ldr r0, [r2]
- adds r0, r3
- ldrb r0, [r0]
- cmp r0, 0
- beq _081341BC
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
-_081341BC:
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- ldrb r2, [r2, 0x4]
- cmp r3, r2
- bcc _081341AA
-_081341C8:
- adds r0, r4, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_081341D0: .4byte gDecorationInventories
- thumb_func_end sub_8134194
-
- thumb_func_start sub_81341D4
-sub_81341D4: @ 81341D4
- push {r4,r5,lr}
- movs r5, 0
- movs r4, 0
-_081341DA:
- adds r0, r4, 0
- bl sub_8134194
- adds r0, r5, r0
- lsls r0, 24
- lsrs r5, r0, 24
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x7
- bls _081341DA
- adds r0, r5, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_81341D4
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/easy_chat.s b/asm/easy_chat.s
index 2983deea0..c34212a24 100644
--- a/asm/easy_chat.s
+++ b/asm/easy_chat.s
@@ -1595,7 +1595,7 @@ _080E6D58:
.align 2, 0
_080E6D60: .4byte 0x02001000
_080E6D64:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
bl sub_80E81FC
ldr r0, _080E6D78 @ =sub_80E6AC4
bl sub_80E682C
@@ -1781,7 +1781,7 @@ _080E6ED0: .4byte 0x00009c7c
_080E6ED4: .4byte 0x0000ffff
_080E6ED8: .4byte sub_80E752C
_080E6EDC:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
bl sub_80E81FC
ldr r4, _080E6EFC @ =0x02001000
ldrb r0, [r4, 0x8]
@@ -9975,7 +9975,7 @@ _080EAE50:
lsls r0, 16
lsrs r0, 16
movs r1, 0
- bl sub_8090D90
+ bl GetNationalPokedexFlag
b _080EAE7C
_080EAE62:
ldr r0, _080EAE74 @ =gUnknown_083DB694
diff --git a/asm/egg_hatch.s b/asm/egg_hatch.s
index 2f11d4111..7365f4da6 100644
--- a/asm/egg_hatch.s
+++ b/asm/egg_hatch.s
@@ -46,10 +46,10 @@ AddHatchedMonToParty: @ 80429EC
lsrs r4, 16
adds r0, r4, 0
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
adds r0, r4, 0
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
ldr r1, _08042AA4 @ =gStringVar1
adds r0, r5, 0
bl GetMonNick
@@ -351,7 +351,7 @@ Task_EggHatch: @ 8042CAC
bne _08042CD0
ldr r0, _08042CDC @ =CB2_EggHatch_0
bl SetMainCallback2
- ldr r1, _08042CE0 @ =gUnknown_0300485C
+ ldr r1, _08042CE0 @ =gFieldCallback
ldr r0, _08042CE4 @ =sub_8080990
str r0, [r1]
adds r0, r4, 0
@@ -363,7 +363,7 @@ _08042CD0:
.align 2, 0
_08042CD8: .4byte gPaletteFade
_08042CDC: .4byte CB2_EggHatch_0
-_08042CE0: .4byte gUnknown_0300485C
+_08042CE0: .4byte gFieldCallback
_08042CE4: .4byte sub_8080990
thumb_func_end Task_EggHatch
diff --git a/asm/evolution_scene.s b/asm/evolution_scene.s
index 404270195..159d96298 100644
--- a/asm/evolution_scene.s
+++ b/asm/evolution_scene.s
@@ -1233,13 +1233,13 @@ _08112354:
lsls r0, 16
lsrs r0, 16
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
ldrh r0, [r4, 0xC]
bl SpeciesToNationalPokedexNum
lsls r0, 16
lsrs r0, 16
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
adds r0, r5, 0
movs r1, 0xB
bl GetMonData
@@ -1739,13 +1739,13 @@ _081127BE:
lsls r0, 16
lsrs r0, 16
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
ldrh r0, [r4, 0x10]
bl SpeciesToNationalPokedexNum
lsls r0, 16
lsrs r0, 16
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
movs r0, 0xE
bl IncrementGameStat
b _08112FD0
@@ -3047,13 +3047,13 @@ _08113316:
lsls r0, 16
lsrs r0, 16
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
ldrh r0, [r4, 0x10]
bl SpeciesToNationalPokedexNum
lsls r0, 16
lsrs r0, 16
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
movs r0, 0xE
bl IncrementGameStat
b _08113B3A
@@ -3517,7 +3517,7 @@ _08113768:
movs r2, 0x8
movs r3, 0x1D
bl ZeroFillWindowRect
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r0, _081137D8 @ =gUnknown_08400F8C
movs r1, 0x92
lsls r1, 3
@@ -3591,7 +3591,7 @@ _08113818:
movs r2, 0x8
movs r3, 0x1D
bl ZeroFillWindowRect
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r0, _08113874 @ =gUnknown_08400F8C
movs r1, 0x92
lsls r1, 3
diff --git a/asm/field_effect.s b/asm/field_effect.s
deleted file mode 100644
index 2dfa491dc..000000000
--- a/asm/field_effect.s
+++ /dev/null
@@ -1,7738 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start CreateTrainerSprite_BirchSpeech
-CreateTrainerSprite_BirchSpeech: @ 80859BC
- push {r4-r7,lr}
- mov r7, r9
- mov r6, r8
- push {r6,r7}
- sub sp, 0x18
- adds r4, r0, 0
- adds r5, r1, 0
- adds r6, r2, 0
- mov r9, r3
- ldr r7, [sp, 0x34]
- lsls r4, 24
- lsls r5, 16
- lsrs r5, 16
- lsls r6, 16
- lsrs r6, 16
- mov r0, r9
- lsls r0, 24
- lsrs r0, 24
- mov r9, r0
- lsrs r4, 21
- ldr r3, _08085A44 @ =gTrainerFrontPicPaletteTable
- mov r8, r3
- add r8, r4
- mov r0, r8
- adds r1, r7, 0
- bl LoadCompressedObjectPaletteOverrideBuffer
- ldr r0, _08085A48 @ =gTrainerFrontPicTable
- adds r4, r0
- adds r0, r4, 0
- adds r1, r7, 0
- bl LoadCompressedObjectPicOverrideBuffer
- mov r1, sp
- ldrh r0, [r4, 0x6]
- movs r2, 0
- strh r0, [r1]
- mov r3, r8
- ldrh r0, [r3, 0x4]
- strh r0, [r1, 0x2]
- ldr r0, _08085A4C @ =gOamData_839F0F4
- str r0, [sp, 0x4]
- ldr r0, _08085A50 @ =gDummySpriteAnimTable
- str r0, [sp, 0x8]
- str r2, [sp, 0xC]
- ldr r0, _08085A54 @ =gDummySpriteAffineAnimTable
- str r0, [sp, 0x10]
- ldr r0, _08085A58 @ =SpriteCallbackDummy
- str r0, [sp, 0x14]
- lsls r5, 16
- asrs r5, 16
- lsls r6, 16
- asrs r6, 16
- mov r0, sp
- adds r1, r5, 0
- adds r2, r6, 0
- mov r3, r9
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- add sp, 0x18
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_08085A44: .4byte gTrainerFrontPicPaletteTable
-_08085A48: .4byte gTrainerFrontPicTable
-_08085A4C: .4byte gOamData_839F0F4
-_08085A50: .4byte gDummySpriteAnimTable
-_08085A54: .4byte gDummySpriteAffineAnimTable
-_08085A58: .4byte SpriteCallbackDummy
- thumb_func_end CreateTrainerSprite_BirchSpeech
-
- thumb_func_start LoadTrainerGfx_TrainerCard
-LoadTrainerGfx_TrainerCard: @ 8085A5C
- push {r4,r5,lr}
- adds r4, r0, 0
- adds r5, r1, 0
- adds r1, r2, 0
- lsls r4, 24
- lsls r5, 16
- lsrs r5, 16
- ldr r0, _08085A8C @ =gTrainerFrontPicTable
- lsrs r4, 21
- adds r0, r4, r0
- ldr r0, [r0]
- bl LZDecompressVram
- ldr r0, _08085A90 @ =gTrainerFrontPicPaletteTable
- adds r4, r0
- ldr r0, [r4]
- adds r1, r5, 0
- movs r2, 0x20
- bl LoadCompressedPalette
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08085A8C: .4byte gTrainerFrontPicTable
-_08085A90: .4byte gTrainerFrontPicPaletteTable
- thumb_func_end LoadTrainerGfx_TrainerCard
-
- thumb_func_start CreateBirchSprite
-CreateBirchSprite: @ 8085A94
- push {r4-r6,lr}
- adds r4, r0, 0
- adds r5, r1, 0
- adds r6, r2, 0
- lsls r4, 16
- lsrs r4, 16
- lsls r5, 16
- lsrs r5, 16
- lsls r6, 24
- lsrs r6, 24
- ldr r0, _08085ACC @ =gUnknown_0839F114
- bl LoadSpritePalette
- ldr r0, _08085AD0 @ =gSpriteTemplate_839F128
- lsls r4, 16
- asrs r4, 16
- lsls r5, 16
- asrs r5, 16
- adds r1, r4, 0
- adds r2, r5, 0
- adds r3, r6, 0
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08085ACC: .4byte gUnknown_0839F114
-_08085AD0: .4byte gSpriteTemplate_839F128
- thumb_func_end CreateBirchSprite
-
- thumb_func_start CreateMonSprite_PicBox
-CreateMonSprite_PicBox: @ 8085AD4
- push {r4-r6,lr}
- mov r6, r10
- mov r5, r9
- mov r4, r8
- push {r4-r6}
- sub sp, 0x8
- adds r4, r0, 0
- adds r6, r1, 0
- mov r8, r2
- mov r10, r3
- lsls r4, 16
- lsrs r4, 16
- lsls r6, 16
- lsrs r6, 16
- mov r0, r8
- lsls r0, 16
- lsrs r0, 16
- mov r8, r0
- mov r0, r10
- lsls r0, 24
- lsrs r0, 24
- mov r10, r0
- lsls r0, r4, 3
- mov r9, r0
- ldr r0, _08085B74 @ =gMonFrontPicTable
- add r0, r9
- ldr r1, _08085B78 @ =gMonFrontPicCoords
- lsls r2, r4, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- ldr r3, _08085B7C @ =gUnknown_081FAF4C
- ldr r3, [r3, 0xC]
- str r3, [sp]
- str r4, [sp, 0x4]
- bl DecompressPicFromTable_2
- ldr r5, _08085B80 @ =gMonPaletteTable
- add r9, r5
- mov r0, r9
- bl LoadCompressedObjectPalette
- adds r0, r4, 0
- movs r1, 0x3
- bl GetMonSpriteTemplate_803C56C
- ldr r4, _08085B84 @ =gUnknown_02024E8C
- ldrh r0, [r5, 0x4]
- strh r0, [r4, 0x2]
- ldrh r0, [r5, 0x4]
- bl IndexOfSpritePaletteTag
- adds r0, 0x10
- lsls r0, 24
- lsrs r0, 24
- bl sub_807DE38
- lsls r6, 16
- asrs r6, 16
- mov r0, r8
- lsls r0, 16
- asrs r0, 16
- mov r8, r0
- adds r0, r4, 0
- adds r1, r6, 0
- mov r2, r8
- mov r3, r10
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- add sp, 0x8
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08085B74: .4byte gMonFrontPicTable
-_08085B78: .4byte gMonFrontPicCoords
-_08085B7C: .4byte gUnknown_081FAF4C
-_08085B80: .4byte gMonPaletteTable
-_08085B84: .4byte gUnknown_02024E8C
- thumb_func_end CreateMonSprite_PicBox
-
- thumb_func_start CreateMonSprite_FieldMove
-CreateMonSprite_FieldMove: @ 8085B88
- push {r4-r6,lr}
- mov r6, r10
- mov r5, r9
- mov r4, r8
- push {r4-r6}
- sub sp, 0xC
- adds r5, r0, 0
- mov r10, r1
- adds r4, r2, 0
- adds r6, r3, 0
- ldr r0, [sp, 0x28]
- mov r8, r0
- ldr r0, [sp, 0x2C]
- mov r9, r0
- lsls r5, 16
- lsrs r5, 16
- lsls r6, 16
- lsrs r6, 16
- mov r0, r8
- lsls r0, 16
- lsrs r0, 16
- mov r8, r0
- mov r0, r9
- lsls r0, 24
- lsrs r0, 24
- mov r9, r0
- lsls r0, r5, 3
- ldr r1, _08085C34 @ =gMonFrontPicTable
- adds r0, r1
- ldr r1, _08085C38 @ =gMonFrontPicCoords
- lsls r2, r5, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- ldr r3, _08085C3C @ =gUnknown_081FAF4C
- ldr r3, [r3, 0xC]
- str r3, [sp]
- str r5, [sp, 0x4]
- str r4, [sp, 0x8]
- bl HandleLoadSpecialPokePic
- adds r0, r5, 0
- mov r1, r10
- adds r2, r4, 0
- bl sub_80409C8
- adds r4, r0, 0
- bl LoadCompressedObjectPalette
- adds r0, r5, 0
- movs r1, 0x3
- bl GetMonSpriteTemplate_803C56C
- ldr r5, _08085C40 @ =gUnknown_02024E8C
- ldrh r0, [r4, 0x4]
- strh r0, [r5, 0x2]
- ldrh r0, [r4, 0x4]
- bl IndexOfSpritePaletteTag
- adds r0, 0x10
- lsls r0, 24
- lsrs r0, 24
- bl sub_807DE38
- lsls r6, 16
- asrs r6, 16
- mov r0, r8
- lsls r0, 16
- asrs r0, 16
- mov r8, r0
- adds r0, r5, 0
- adds r1, r6, 0
- mov r2, r8
- mov r3, r9
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- add sp, 0xC
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08085C34: .4byte gMonFrontPicTable
-_08085C38: .4byte gMonFrontPicCoords
-_08085C3C: .4byte gUnknown_081FAF4C
-_08085C40: .4byte gUnknown_02024E8C
- thumb_func_end CreateMonSprite_FieldMove
-
- thumb_func_start FreeResourcesAndDestroySprite
-FreeResourcesAndDestroySprite: @ 8085C44
- push {r4,lr}
- adds r4, r0, 0
- bl sub_807DE68
- ldrb r0, [r4, 0x5]
- lsrs r0, 4
- bl GetSpritePaletteTagByPaletteNum
- lsls r0, 16
- lsrs r0, 16
- bl FreeSpritePaletteByTag
- ldrb r0, [r4, 0x1]
- lsls r0, 30
- cmp r0, 0
- beq _08085C6E
- ldrb r0, [r4, 0x3]
- lsls r0, 26
- lsrs r0, 27
- bl FreeOamMatrix
-_08085C6E:
- adds r0, r4, 0
- bl DestroySprite
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end FreeResourcesAndDestroySprite
-
- thumb_func_start MultiplyInvertedPaletteRGBComponents
-MultiplyInvertedPaletteRGBComponents: @ 8085C7C
- push {r4-r7,lr}
- mov r7, r9
- mov r6, r8
- push {r6,r7}
- lsls r0, 16
- lsls r1, 24
- lsrs r1, 24
- lsls r2, 24
- lsrs r2, 24
- lsls r3, 24
- lsrs r3, 24
- ldr r4, _08085D00 @ =gPlttBufferUnfaded
- lsrs r0, 15
- adds r4, r0, r4
- ldrh r4, [r4]
- movs r5, 0x1F
- mov r9, r5
- mov r8, r4
- mov r6, r8
- ands r6, r5
- mov r8, r6
- movs r6, 0xF8
- lsls r6, 2
- ands r6, r4
- lsrs r6, 5
- movs r5, 0xF8
- lsls r5, 7
- ands r4, r5
- lsrs r4, 10
- mov r7, r9
- mov r5, r8
- subs r7, r5
- mov r12, r7
- mov r7, r12
- muls r7, r1
- adds r1, r7, 0
- asrs r1, 4
- add r8, r1
- mov r5, r9
- subs r1, r5, r6
- muls r1, r2
- asrs r1, 4
- adds r6, r1
- subs r5, r4
- mov r9, r5
- mov r1, r9
- muls r1, r3
- asrs r1, 4
- adds r4, r1
- mov r7, r8
- lsls r7, 16
- lsls r6, 21
- orrs r6, r7
- lsls r4, 26
- orrs r4, r6
- lsrs r4, 16
- ldr r1, _08085D04 @ =gPlttBufferFaded
- adds r0, r1
- strh r4, [r0]
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08085D00: .4byte gPlttBufferUnfaded
-_08085D04: .4byte gPlttBufferFaded
- thumb_func_end MultiplyInvertedPaletteRGBComponents
-
- thumb_func_start MultiplyPaletteRGBComponents
-MultiplyPaletteRGBComponents: @ 8085D08
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- lsls r0, 16
- lsls r1, 24
- lsrs r1, 24
- lsls r2, 24
- lsrs r2, 24
- lsls r3, 24
- lsrs r3, 24
- ldr r4, _08085D78 @ =gPlttBufferUnfaded
- lsrs r0, 15
- adds r4, r0, r4
- ldrh r4, [r4]
- movs r5, 0x1F
- mov r8, r5
- mov r6, r8
- ands r6, r4
- mov r8, r6
- movs r5, 0xF8
- lsls r5, 2
- ands r5, r4
- lsrs r5, 5
- movs r6, 0xF8
- lsls r6, 7
- ands r4, r6
- lsrs r4, 10
- mov r6, r8
- muls r6, r1
- adds r1, r6, 0
- asrs r1, 4
- mov r6, r8
- subs r6, r1
- adds r1, r5, 0
- muls r1, r2
- asrs r1, 4
- subs r5, r1
- adds r1, r4, 0
- muls r1, r3
- asrs r1, 4
- subs r4, r1
- lsls r6, 16
- lsls r5, 21
- orrs r5, r6
- lsls r4, 26
- orrs r4, r5
- lsrs r4, 16
- ldr r1, _08085D7C @ =gPlttBufferFaded
- adds r0, r1
- strh r4, [r0]
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08085D78: .4byte gPlttBufferUnfaded
-_08085D7C: .4byte gPlttBufferFaded
- thumb_func_end MultiplyPaletteRGBComponents
-
- thumb_func_start FldEff_PokecenterHeal
-FldEff_PokecenterHeal: @ 8085D80
- push {r4,lr}
- bl CalculatePlayerPartyCount
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- ldr r0, _08085DBC @ =Task_PokecenterHeal
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08085DC0 @ =gTasks
- adds r1, r0
- strh r4, [r1, 0xA]
- movs r0, 0x5D
- strh r0, [r1, 0xC]
- movs r0, 0x24
- strh r0, [r1, 0xE]
- movs r0, 0x7C
- strh r0, [r1, 0x10]
- movs r0, 0x18
- strh r0, [r1, 0x12]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08085DBC: .4byte Task_PokecenterHeal
-_08085DC0: .4byte gTasks
- thumb_func_end FldEff_PokecenterHeal
-
- thumb_func_start Task_PokecenterHeal
-Task_PokecenterHeal: @ 8085DC4
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08085DEC @ =gTasks
- adds r1, r0
- ldr r2, _08085DF0 @ =gUnknown_0839F268
- movs r3, 0x8
- ldrsh r0, [r1, r3]
- lsls r0, 2
- adds r0, r2
- ldr r2, [r0]
- adds r0, r1, 0
- bl _call_via_r2
- pop {r0}
- bx r0
- .align 2, 0
-_08085DEC: .4byte gTasks
-_08085DF0: .4byte gUnknown_0839F268
- thumb_func_end Task_PokecenterHeal
-
- thumb_func_start PokecenterHealEffect_0
-PokecenterHealEffect_0: @ 8085DF4
- push {r4,lr}
- adds r4, r0, 0
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- movs r2, 0xC
- ldrsh r1, [r4, r2]
- movs r3, 0xE
- ldrsh r2, [r4, r3]
- movs r3, 0x1
- bl CreatePokeballGlowSprite
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x14]
- movs r1, 0x10
- ldrsh r0, [r4, r1]
- movs r2, 0x12
- ldrsh r1, [r4, r2]
- bl PokecenterHealEffectHelper
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x16]
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end PokecenterHealEffect_0
-
- thumb_func_start PokecenterHealEffect_1
-PokecenterHealEffect_1: @ 8085E30
- push {r4,lr}
- adds r2, r0, 0
- ldr r3, _08085E68 @ =gSprites
- movs r1, 0x14
- ldrsh r0, [r2, r1]
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r1, r3
- movs r4, 0x2E
- ldrsh r0, [r1, r4]
- cmp r0, 0x1
- ble _08085E62
- movs r0, 0x16
- ldrsh r1, [r2, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r3
- ldrh r1, [r0, 0x2E]
- adds r1, 0x1
- strh r1, [r0, 0x2E]
- ldrh r0, [r2, 0x8]
- adds r0, 0x1
- strh r0, [r2, 0x8]
-_08085E62:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08085E68: .4byte gSprites
- thumb_func_end PokecenterHealEffect_1
-
- thumb_func_start PokecenterHealEffect_2
-PokecenterHealEffect_2: @ 8085E6C
- push {lr}
- adds r3, r0, 0
- ldr r2, _08085E90 @ =gSprites
- movs r0, 0x14
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x2E
- ldrsh r0, [r0, r1]
- cmp r0, 0x4
- ble _08085E8C
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_08085E8C:
- pop {r0}
- bx r0
- .align 2, 0
-_08085E90: .4byte gSprites
- thumb_func_end PokecenterHealEffect_2
-
- thumb_func_start PokecenterHealEffect_3
-PokecenterHealEffect_3: @ 8085E94
- push {lr}
- ldr r2, _08085ECC @ =gSprites
- movs r3, 0x14
- ldrsh r1, [r0, r3]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r1, r0, r2
- movs r2, 0x2E
- ldrsh r0, [r1, r2]
- cmp r0, 0x6
- ble _08085EC6
- adds r0, r1, 0
- bl DestroySprite
- movs r0, 0x19
- bl FieldEffectActiveListRemove
- ldr r0, _08085ED0 @ =Task_PokecenterHeal
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08085EC6:
- pop {r0}
- bx r0
- .align 2, 0
-_08085ECC: .4byte gSprites
-_08085ED0: .4byte Task_PokecenterHeal
- thumb_func_end PokecenterHealEffect_3
-
- thumb_func_start FldEff_HallOfFameRecord
-FldEff_HallOfFameRecord: @ 8085ED4
- push {r4,lr}
- bl CalculatePlayerPartyCount
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- ldr r0, _08085F08 @ =Task_HallOfFameRecord
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08085F0C @ =gTasks
- adds r1, r0
- strh r4, [r1, 0xA]
- movs r0, 0x75
- strh r0, [r1, 0xC]
- movs r0, 0x34
- strh r0, [r1, 0xE]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08085F08: .4byte Task_HallOfFameRecord
-_08085F0C: .4byte gTasks
- thumb_func_end FldEff_HallOfFameRecord
-
- thumb_func_start Task_HallOfFameRecord
-Task_HallOfFameRecord: @ 8085F10
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08085F38 @ =gTasks
- adds r1, r0
- ldr r2, _08085F3C @ =gUnknown_0839F278
- movs r3, 0x8
- ldrsh r0, [r1, r3]
- lsls r0, 2
- adds r0, r2
- ldr r2, [r0]
- adds r0, r1, 0
- bl _call_via_r2
- pop {r0}
- bx r0
- .align 2, 0
-_08085F38: .4byte gTasks
-_08085F3C: .4byte gUnknown_0839F278
- thumb_func_end Task_HallOfFameRecord
-
- thumb_func_start HallOfFameRecordEffect_0
-HallOfFameRecordEffect_0: @ 8085F40
- push {r4,lr}
- adds r4, r0, 0
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- movs r2, 0xC
- ldrsh r1, [r4, r2]
- movs r3, 0xE
- ldrsh r2, [r4, r3]
- movs r3, 0
- bl CreatePokeballGlowSprite
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x14]
- ldr r0, _08085FB0 @ =Task_HallOfFameRecord
- bl FindTaskIdByFunc
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r4, 0
- movs r1, 0x78
- movs r2, 0x18
- movs r3, 0
- bl HallOfFameRecordEffectHelper
- adds r0, r4, 0
- movs r1, 0x28
- movs r2, 0x8
- movs r3, 0x1
- bl HallOfFameRecordEffectHelper
- adds r0, r4, 0
- movs r1, 0x48
- movs r2, 0x8
- movs r3, 0x1
- bl HallOfFameRecordEffectHelper
- adds r0, r4, 0
- movs r1, 0xA8
- movs r2, 0x8
- movs r3, 0x1
- bl HallOfFameRecordEffectHelper
- adds r0, r4, 0
- movs r1, 0xC8
- movs r2, 0x8
- movs r3, 0x1
- bl HallOfFameRecordEffectHelper
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08085FB0: .4byte Task_HallOfFameRecord
- thumb_func_end HallOfFameRecordEffect_0
-
- thumb_func_start HallOfFameRecordEffect_1
-HallOfFameRecordEffect_1: @ 8085FB4
- push {lr}
- adds r3, r0, 0
- ldr r2, _08085FE0 @ =gSprites
- movs r0, 0x14
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x2E
- ldrsh r0, [r0, r1]
- cmp r0, 0x1
- ble _08085FDA
- ldrh r0, [r3, 0x26]
- adds r0, 0x1
- strh r0, [r3, 0x26]
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_08085FDA:
- pop {r0}
- bx r0
- .align 2, 0
-_08085FE0: .4byte gSprites
- thumb_func_end HallOfFameRecordEffect_1
-
- thumb_func_start HallOfFameRecordEffect_2
-HallOfFameRecordEffect_2: @ 8085FE4
- push {lr}
- adds r3, r0, 0
- ldr r2, _08086008 @ =gSprites
- movs r0, 0x14
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x2E
- ldrsh r0, [r0, r1]
- cmp r0, 0x4
- ble _08086004
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_08086004:
- pop {r0}
- bx r0
- .align 2, 0
-_08086008: .4byte gSprites
- thumb_func_end HallOfFameRecordEffect_2
-
- thumb_func_start HallOfFameRecordEffect_3
-HallOfFameRecordEffect_3: @ 808600C
- push {lr}
- ldr r2, _08086044 @ =gSprites
- movs r3, 0x14
- ldrsh r1, [r0, r3]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r1, r0, r2
- movs r2, 0x2E
- ldrsh r0, [r1, r2]
- cmp r0, 0x6
- ble _0808603E
- adds r0, r1, 0
- bl DestroySprite
- movs r0, 0x3E
- bl FieldEffectActiveListRemove
- ldr r0, _08086048 @ =Task_HallOfFameRecord
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_0808603E:
- pop {r0}
- bx r0
- .align 2, 0
-_08086044: .4byte gSprites
-_08086048: .4byte Task_HallOfFameRecord
- thumb_func_end HallOfFameRecordEffect_3
-
- thumb_func_start CreatePokeballGlowSprite
-CreatePokeballGlowSprite: @ 808604C
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- mov r8, r0
- adds r4, r1, 0
- adds r5, r2, 0
- adds r6, r3, 0
- lsls r0, 16
- lsrs r0, 16
- mov r8, r0
- lsls r4, 16
- lsrs r4, 16
- lsls r5, 16
- lsrs r5, 16
- lsls r6, 16
- lsrs r6, 16
- ldr r0, _08086098 @ =SpriteCB_PokeballGlowEffect
- bl CreateInvisibleSprite
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- ldr r2, _0808609C @ =gSprites
- adds r1, r2
- strh r4, [r1, 0x24]
- strh r5, [r1, 0x26]
- strh r6, [r1, 0x38]
- mov r2, r8
- strh r2, [r1, 0x3A]
- strh r0, [r1, 0x3C]
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08086098: .4byte SpriteCB_PokeballGlowEffect
-_0808609C: .4byte gSprites
- thumb_func_end CreatePokeballGlowSprite
-
- thumb_func_start SpriteCB_PokeballGlowEffect
-SpriteCB_PokeballGlowEffect: @ 80860A0
- push {lr}
- ldr r2, _080860B8 @ =gUnknown_0839F288
- movs r3, 0x2E
- ldrsh r1, [r0, r3]
- lsls r1, 2
- adds r1, r2
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_080860B8: .4byte gUnknown_0839F288
- thumb_func_end SpriteCB_PokeballGlowEffect
-
- thumb_func_start PokeballGlowEffect_0
-PokeballGlowEffect_0: @ 80860BC
- push {r4,lr}
- adds r4, r0, 0
- ldrh r1, [r4, 0x30]
- movs r2, 0x30
- ldrsh r0, [r4, r2]
- cmp r0, 0
- beq _080860D4
- subs r0, r1, 0x1
- strh r0, [r4, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _08086130
-_080860D4:
- movs r0, 0x19
- strh r0, [r4, 0x30]
- ldr r0, _08086148 @ =gSpriteTemplate_839F208
- ldr r1, _0808614C @ =gUnknown_0839F2A8
- movs r2, 0x32
- ldrsh r3, [r4, r2]
- lsls r3, 2
- adds r3, r1
- ldrh r1, [r4, 0x24]
- ldrh r2, [r3]
- adds r1, r2
- lsls r1, 16
- asrs r1, 16
- ldrh r2, [r4, 0x26]
- ldrh r3, [r3, 0x2]
- adds r2, r3
- lsls r2, 16
- asrs r2, 16
- movs r3, 0
- bl CreateSpriteAtEnd
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08086150 @ =gSprites
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r1, r2
- ldrb r2, [r1, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r2
- movs r2, 0x8
- orrs r0, r2
- strb r0, [r1, 0x5]
- ldrh r0, [r4, 0x3C]
- strh r0, [r1, 0x2E]
- ldrh r0, [r4, 0x32]
- adds r0, 0x1
- strh r0, [r4, 0x32]
- ldrh r0, [r4, 0x3A]
- subs r0, 0x1
- strh r0, [r4, 0x3A]
- movs r0, 0x17
- bl PlaySE
-_08086130:
- movs r1, 0x3A
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _08086142
- movs r0, 0x20
- strh r0, [r4, 0x30]
- ldrh r0, [r4, 0x2E]
- adds r0, 0x1
- strh r0, [r4, 0x2E]
-_08086142:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08086148: .4byte gSpriteTemplate_839F208
-_0808614C: .4byte gUnknown_0839F2A8
-_08086150: .4byte gSprites
- thumb_func_end PokeballGlowEffect_0
-
- thumb_func_start PokeballGlowEffect_1
-PokeballGlowEffect_1: @ 8086154
- push {lr}
- adds r1, r0, 0
- ldrh r0, [r1, 0x30]
- subs r0, 0x1
- strh r0, [r1, 0x30]
- lsls r0, 16
- asrs r2, r0, 16
- cmp r2, 0
- bne _08086184
- ldrh r0, [r1, 0x2E]
- adds r0, 0x1
- strh r0, [r1, 0x2E]
- movs r0, 0x8
- strh r0, [r1, 0x30]
- strh r2, [r1, 0x32]
- strh r2, [r1, 0x34]
- movs r2, 0x38
- ldrsh r0, [r1, r2]
- cmp r0, 0
- beq _08086184
- movs r0, 0xB8
- lsls r0, 1
- bl PlayFanfare
-_08086184:
- pop {r0}
- bx r0
- thumb_func_end PokeballGlowEffect_1
-
- thumb_func_start PokeballGlowEffect_2
-PokeballGlowEffect_2: @ 8086188
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- adds r7, r0, 0
- ldrh r0, [r7, 0x30]
- subs r0, 0x1
- strh r0, [r7, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _080861B8
- movs r0, 0x8
- strh r0, [r7, 0x30]
- ldrh r0, [r7, 0x32]
- adds r0, 0x1
- movs r1, 0x3
- ands r0, r1
- strh r0, [r7, 0x32]
- cmp r0, 0
- bne _080861B8
- ldrh r0, [r7, 0x34]
- adds r0, 0x1
- strh r0, [r7, 0x34]
-_080861B8:
- ldrh r4, [r7, 0x32]
- adds r4, 0x3
- movs r0, 0x3
- mov r8, r0
- mov r1, r8
- ands r4, r1
- ldr r3, _080862B0 @ =0x00001007
- mov r10, r3
- mov r0, r10
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x84
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- ldr r6, _080862B4 @ =gUnknown_0839F2C0
- adds r1, r4, r6
- ldrb r1, [r1]
- ldr r5, _080862B8 @ =gUnknown_0839F2C4
- adds r2, r4, r5
- ldrb r2, [r2]
- ldr r3, _080862BC @ =gUnknown_0839F2C8
- mov r9, r3
- add r4, r9
- ldrb r3, [r4]
- bl MultiplyInvertedPaletteRGBComponents
- ldrh r4, [r7, 0x32]
- adds r4, 0x2
- mov r0, r8
- ands r4, r0
- mov r0, r10
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x83
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- adds r1, r4, r6
- ldrb r1, [r1]
- adds r2, r4, r5
- ldrb r2, [r2]
- add r4, r9
- ldrb r3, [r4]
- bl MultiplyInvertedPaletteRGBComponents
- ldrh r4, [r7, 0x32]
- adds r4, 0x1
- mov r3, r8
- ands r4, r3
- mov r0, r10
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x81
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- adds r1, r4, r6
- ldrb r1, [r1]
- adds r2, r4, r5
- ldrb r2, [r2]
- add r4, r9
- ldrb r3, [r4]
- bl MultiplyInvertedPaletteRGBComponents
- ldrh r4, [r7, 0x32]
- lsls r4, 24
- lsrs r4, 24
- mov r0, r10
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- ldr r3, _080862C0 @ =0x01050000
- adds r0, r3
- lsrs r0, 16
- adds r6, r4, r6
- ldrb r6, [r6]
- adds r5, r4, r5
- ldrb r5, [r5]
- add r4, r9
- ldrb r4, [r4]
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- mov r0, r10
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- ldr r1, _080862C4 @ =0x01030000
- adds r0, r1
- lsrs r0, 16
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- movs r3, 0x34
- ldrsh r0, [r7, r3]
- cmp r0, 0x2
- ble _080862A2
- ldrh r0, [r7, 0x2E]
- adds r0, 0x1
- movs r1, 0
- strh r0, [r7, 0x2E]
- movs r0, 0x8
- strh r0, [r7, 0x30]
- strh r1, [r7, 0x32]
-_080862A2:
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080862B0: .4byte 0x00001007
-_080862B4: .4byte gUnknown_0839F2C0
-_080862B8: .4byte gUnknown_0839F2C4
-_080862BC: .4byte gUnknown_0839F2C8
-_080862C0: .4byte 0x01050000
-_080862C4: .4byte 0x01030000
- thumb_func_end PokeballGlowEffect_2
-
- thumb_func_start PokeballGlowEffect_3
-PokeballGlowEffect_3: @ 80862C8
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- adds r2, r0, 0
- ldrh r0, [r2, 0x30]
- subs r0, 0x1
- strh r0, [r2, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _080862F8
- movs r0, 0x8
- strh r0, [r2, 0x30]
- ldrh r0, [r2, 0x32]
- adds r0, 0x1
- movs r1, 0x3
- ands r0, r1
- strh r0, [r2, 0x32]
- cmp r0, 0x3
- bne _080862F8
- ldrh r0, [r2, 0x2E]
- adds r0, 0x1
- strh r0, [r2, 0x2E]
- movs r0, 0x1E
- strh r0, [r2, 0x30]
-_080862F8:
- ldrh r4, [r2, 0x32]
- lsls r4, 24
- lsrs r4, 24
- ldr r0, _080863A4 @ =0x00001007
- mov r8, r0
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x84
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- ldr r1, _080863A8 @ =gUnknown_0839F2C0
- adds r1, r4, r1
- ldrb r6, [r1]
- ldr r1, _080863AC @ =gUnknown_0839F2C4
- adds r1, r4, r1
- ldrb r5, [r1]
- ldr r1, _080863B0 @ =gUnknown_0839F2C8
- adds r4, r1
- ldrb r4, [r4]
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- mov r0, r8
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x83
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- mov r0, r8
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- movs r1, 0x81
- lsls r1, 17
- adds r0, r1
- lsrs r0, 16
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- mov r0, r8
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- ldr r1, _080863B4 @ =0x01050000
- adds r0, r1
- lsrs r0, 16
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- mov r0, r8
- bl IndexOfSpritePaletteTag
- lsls r0, 24
- lsrs r0, 4
- ldr r1, _080863B8 @ =0x01030000
- adds r0, r1
- lsrs r0, 16
- adds r1, r6, 0
- adds r2, r5, 0
- adds r3, r4, 0
- bl MultiplyInvertedPaletteRGBComponents
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080863A4: .4byte 0x00001007
-_080863A8: .4byte gUnknown_0839F2C0
-_080863AC: .4byte gUnknown_0839F2C4
-_080863B0: .4byte gUnknown_0839F2C8
-_080863B4: .4byte 0x01050000
-_080863B8: .4byte 0x01030000
- thumb_func_end PokeballGlowEffect_3
-
- thumb_func_start PokeballGlowEffect_4
-PokeballGlowEffect_4: @ 80863BC
- push {lr}
- adds r1, r0, 0
- ldrh r0, [r1, 0x30]
- subs r0, 0x1
- strh r0, [r1, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _080863D2
- ldrh r0, [r1, 0x2E]
- adds r0, 0x1
- strh r0, [r1, 0x2E]
-_080863D2:
- pop {r0}
- bx r0
- thumb_func_end PokeballGlowEffect_4
-
- thumb_func_start PokeballGlowEffect_5
-PokeballGlowEffect_5: @ 80863D8
- ldrh r1, [r0, 0x2E]
- adds r1, 0x1
- strh r1, [r0, 0x2E]
- bx lr
- thumb_func_end PokeballGlowEffect_5
-
- thumb_func_start PokeballGlowEffect_6
-PokeballGlowEffect_6: @ 80863E0
- push {r4,lr}
- adds r4, r0, 0
- movs r1, 0x38
- ldrsh r0, [r4, r1]
- cmp r0, 0
- beq _080863F6
- bl IsFanfareTaskInactive
- lsls r0, 24
- cmp r0, 0
- beq _080863FC
-_080863F6:
- ldrh r0, [r4, 0x2E]
- adds r0, 0x1
- strh r0, [r4, 0x2E]
-_080863FC:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end PokeballGlowEffect_6
-
- thumb_func_start PokeballGlowEffect_7
-PokeballGlowEffect_7: @ 8086404
- bx lr
- thumb_func_end PokeballGlowEffect_7
-
- thumb_func_start SpriteCB_PokeballGlow
-SpriteCB_PokeballGlow: @ 8086408
- push {lr}
- adds r3, r0, 0
- ldr r2, _0808642C @ =gSprites
- movs r0, 0x2E
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x2E
- ldrsh r0, [r0, r1]
- cmp r0, 0x4
- ble _08086428
- adds r0, r3, 0
- bl FieldEffectFreeGraphicsResources
-_08086428:
- pop {r0}
- bx r0
- .align 2, 0
-_0808642C: .4byte gSprites
- thumb_func_end SpriteCB_PokeballGlow
-
- thumb_func_start PokecenterHealEffectHelper
-PokecenterHealEffectHelper: @ 8086430
- push {r4,lr}
- adds r3, r0, 0
- adds r2, r1, 0
- ldr r0, _08086480 @ =gSpriteTemplate_839F220
- lsls r3, 16
- asrs r3, 16
- lsls r2, 16
- asrs r2, 16
- adds r1, r3, 0
- movs r3, 0
- bl CreateSpriteAtEnd
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- lsls r0, r4, 4
- adds r0, r4
- lsls r0, 2
- ldr r1, _08086484 @ =gSprites
- adds r0, r1
- ldrb r2, [r0, 0x5]
- movs r1, 0xD
- negs r1, r1
- ands r1, r2
- movs r2, 0x8
- orrs r1, r2
- strb r1, [r0, 0x5]
- adds r3, r0, 0
- adds r3, 0x3E
- ldrb r1, [r3]
- movs r2, 0x4
- orrs r1, r2
- strb r1, [r3]
- ldr r1, _08086488 @ =gUnknown_0839F1A0
- bl SetSubspriteTables
- adds r0, r4, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08086480: .4byte gSpriteTemplate_839F220
-_08086484: .4byte gSprites
-_08086488: .4byte gUnknown_0839F1A0
- thumb_func_end PokecenterHealEffectHelper
-
- thumb_func_start SpriteCB_PokecenterMonitor
-SpriteCB_PokecenterMonitor: @ 808648C
- push {r4,lr}
- adds r4, r0, 0
- movs r1, 0x2E
- ldrsh r0, [r4, r1]
- cmp r0, 0
- beq _080864B0
- movs r0, 0
- strh r0, [r4, 0x2E]
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r1, [r2]
- subs r0, 0x5
- ands r0, r1
- strb r0, [r2]
- adds r0, r4, 0
- movs r1, 0x1
- bl StartSpriteAnim
-_080864B0:
- adds r0, r4, 0
- adds r0, 0x3F
- ldrb r1, [r0]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- beq _080864C4
- adds r0, r4, 0
- bl FieldEffectFreeGraphicsResources
-_080864C4:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end SpriteCB_PokecenterMonitor
-
- thumb_func_start HallOfFameRecordEffectHelper
-HallOfFameRecordEffectHelper: @ 80864CC
- push {r4,r5,lr}
- lsls r0, 16
- lsrs r5, r0, 16
- lsls r1, 16
- lsrs r1, 16
- lsls r2, 16
- lsrs r2, 16
- lsls r3, 24
- cmp r3, 0
- bne _08086514
- ldr r0, _08086508 @ =gSpriteTemplate_839F238
- lsls r1, 16
- asrs r1, 16
- lsls r2, 16
- asrs r2, 16
- movs r3, 0
- bl CreateSpriteAtEnd
- lsls r0, 24
- lsrs r4, r0, 24
- lsls r0, r4, 4
- adds r0, r4
- lsls r0, 2
- ldr r1, _0808650C @ =gSprites
- adds r0, r1
- ldr r1, _08086510 @ =gUnknown_0839F1C8
- bl SetSubspriteTables
- b _08086528
- .align 2, 0
-_08086508: .4byte gSpriteTemplate_839F238
-_0808650C: .4byte gSprites
-_08086510: .4byte gUnknown_0839F1C8
-_08086514:
- ldr r0, _08086548 @ =gSpriteTemplate_839F250
- lsls r1, 16
- asrs r1, 16
- lsls r2, 16
- asrs r2, 16
- movs r3, 0
- bl CreateSpriteAtEnd
- lsls r0, 24
- lsrs r4, r0, 24
-_08086528:
- ldr r1, _0808654C @ =gSprites
- lsls r0, r4, 4
- adds r0, r4
- lsls r0, 2
- adds r0, r1
- adds r3, r0, 0
- adds r3, 0x3E
- ldrb r1, [r3]
- movs r2, 0x4
- orrs r1, r2
- strb r1, [r3]
- strh r5, [r0, 0x2E]
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086548: .4byte gSpriteTemplate_839F250
-_0808654C: .4byte gSprites
- thumb_func_end HallOfFameRecordEffectHelper
-
- thumb_func_start SpriteCB_HallOfFameMonitor
-SpriteCB_HallOfFameMonitor: @ 8086550
- push {lr}
- adds r3, r0, 0
- ldr r2, _080865B8 @ =gTasks
- movs r0, 0x2E
- ldrsh r1, [r3, r0]
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r1, 0x26
- ldrsh r0, [r0, r1]
- cmp r0, 0
- beq _080865A6
- ldrh r1, [r3, 0x30]
- movs r2, 0x30
- ldrsh r0, [r3, r2]
- cmp r0, 0
- beq _0808657E
- subs r0, r1, 0x1
- strh r0, [r3, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _080865A0
-_0808657E:
- movs r0, 0x10
- strh r0, [r3, 0x30]
- movs r0, 0x3E
- adds r0, r3
- mov r12, r0
- ldrb r2, [r0]
- lsls r0, r2, 29
- lsrs r0, 31
- movs r1, 0x1
- eors r1, r0
- lsls r1, 2
- movs r0, 0x5
- negs r0, r0
- ands r0, r2
- orrs r0, r1
- mov r1, r12
- strb r0, [r1]
-_080865A0:
- ldrh r0, [r3, 0x32]
- adds r0, 0x1
- strh r0, [r3, 0x32]
-_080865A6:
- movs r2, 0x32
- ldrsh r0, [r3, r2]
- cmp r0, 0x7F
- ble _080865B4
- adds r0, r3, 0
- bl FieldEffectFreeGraphicsResources
-_080865B4:
- pop {r0}
- bx r0
- .align 2, 0
-_080865B8: .4byte gTasks
- thumb_func_end SpriteCB_HallOfFameMonitor
-
- thumb_func_start sub_80865BC
-sub_80865BC: @ 80865BC
- push {lr}
- ldr r0, _080865D0 @ =c2_exit_to_overworld_2_switch
- bl SetMainCallback2
- ldr r1, _080865D4 @ =gUnknown_0300485C
- ldr r0, _080865D8 @ =mapldr_080842E8
- str r0, [r1]
- pop {r0}
- bx r0
- .align 2, 0
-_080865D0: .4byte c2_exit_to_overworld_2_switch
-_080865D4: .4byte gUnknown_0300485C
-_080865D8: .4byte mapldr_080842E8
- thumb_func_end sub_80865BC
-
- thumb_func_start mapldr_080842E8
-mapldr_080842E8: @ 80865DC
- push {lr}
- bl pal_fill_black
- ldr r0, _080865FC @ =task00_8084310
- movs r1, 0
- bl CreateTask
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r1, _08086600 @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- pop {r0}
- bx r0
- .align 2, 0
-_080865FC: .4byte task00_8084310
-_08086600: .4byte gUnknown_0300485C
- thumb_func_end mapldr_080842E8
-
- thumb_func_start task00_8084310
-task00_8084310: @ 8086604
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r6, r0, 24
- lsls r0, r6, 2
- adds r0, r6
- lsls r0, 3
- ldr r1, _0808666C @ =gTasks
- adds r4, r0, r1
- movs r0, 0x8
- ldrsh r5, [r4, r0]
- cmp r5, 0
- bne _08086640
- bl sub_807D770
- lsls r0, 24
- cmp r0, 0
- beq _08086666
- ldr r1, _08086670 @ =gUnknown_0202FF84
- ldr r0, _08086674 @ =gLastFieldPokeMenuOpened
- ldrb r0, [r0]
- str r0, [r1]
- cmp r0, 0x5
- ble _08086634
- str r5, [r1]
-_08086634:
- movs r0, 0x1F
- bl FieldEffectStart
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086640:
- movs r0, 0x1F
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _08086666
- bl flag_var_implications_of_teleport_
- bl warp_in
- ldr r0, _08086678 @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r1, _0808667C @ =gUnknown_0300485C
- ldr r0, _08086680 @ =mapldr_08084390
- str r0, [r1]
- adds r0, r6, 0
- bl DestroyTask
-_08086666:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_0808666C: .4byte gTasks
-_08086670: .4byte gUnknown_0202FF84
-_08086674: .4byte gLastFieldPokeMenuOpened
-_08086678: .4byte CB2_LoadMap
-_0808667C: .4byte gUnknown_0300485C
-_08086680: .4byte mapldr_08084390
- thumb_func_end task00_8084310
-
- thumb_func_start mapldr_08084390
-mapldr_08084390: @ 8086684
- push {r4,lr}
- bl sub_8053E90
- bl pal_fill_black
- ldr r0, _080866DC @ =c3_080843F8
- movs r1, 0
- bl CreateTask
- ldr r4, _080866E0 @ =gMapObjects
- ldr r3, _080866E4 @ =gPlayerAvatar
- ldrb r1, [r3, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- ldrb r1, [r0, 0x1]
- movs r2, 0x20
- orrs r1, r2
- strb r1, [r0, 0x1]
- ldrb r1, [r3]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- beq _080866C6
- ldrb r1, [r3, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- movs r1, 0x3
- bl FieldObjectTurn
-_080866C6:
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r1, _080866E8 @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080866DC: .4byte c3_080843F8
-_080866E0: .4byte gMapObjects
-_080866E4: .4byte gPlayerAvatar
-_080866E8: .4byte gUnknown_0300485C
- thumb_func_end mapldr_08084390
-
- thumb_func_start c3_080843F8
-c3_080843F8: @ 80866EC
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- adds r5, r0, 0
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- ldr r1, _08086740 @ =gTasks
- adds r4, r0, r1
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _0808671E
- ldr r0, _08086744 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08086738
- movs r0, 0x20
- bl FieldEffectStart
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_0808671E:
- movs r0, 0x20
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _08086738
- bl ScriptContext2_Disable
- bl UnfreezeMapObjects
- adds r0, r5, 0
- bl DestroyTask
-_08086738:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086740: .4byte gTasks
-_08086744: .4byte gPaletteFade
- thumb_func_end c3_080843F8
-
- thumb_func_start sub_8086748
-sub_8086748: @ 8086748
- push {lr}
- bl sub_8053E90
- bl pal_fill_for_map_transition
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r0, _0808676C @ =sub_8086774
- movs r1, 0
- bl CreateTask
- ldr r1, _08086770 @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- pop {r0}
- bx r0
- .align 2, 0
-_0808676C: .4byte sub_8086774
-_08086770: .4byte gUnknown_0300485C
- thumb_func_end sub_8086748
-
- thumb_func_start sub_8086774
-sub_8086774: @ 8086774
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _080867A4 @ =gTasks
- adds r4, r1, r0
- ldr r5, _080867A8 @ =gUnknown_0839F2CC
-_08086786:
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r5
- ldr r1, [r0]
- adds r0, r4, 0
- bl _call_via_r1
- lsls r0, 24
- cmp r0, 0
- bne _08086786
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080867A4: .4byte gTasks
-_080867A8: .4byte gUnknown_0839F2CC
- thumb_func_end sub_8086774
-
- thumb_func_start sub_80867AC
-sub_80867AC: @ 80867AC
- push {r4-r6,lr}
- mov r6, r9
- mov r5, r8
- push {r5,r6}
- mov r9, r0
- ldr r6, _08086848 @ =gPlayerAvatar
- ldrb r0, [r6, 0x5]
- lsls r5, r0, 3
- adds r5, r0
- lsls r5, 2
- ldr r0, _0808684C @ =gMapObjects
- mov r8, r0
- add r5, r8
- ldrb r0, [r6, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086850 @ =gSprites
- adds r4, r0
- bl CameraObjectReset2
- ldrb r1, [r6, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- add r0, r8
- ldrb r1, [r0, 0x1]
- movs r2, 0x20
- orrs r1, r2
- strb r1, [r0, 0x1]
- movs r0, 0x1
- strb r0, [r6, 0x6]
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r5, 0
- bl FieldObjectSetSpecialAnim
- adds r3, r4, 0
- adds r3, 0x42
- ldrb r0, [r3]
- lsrs r0, 6
- mov r1, r9
- strh r0, [r1, 0x10]
- ldrb r0, [r5, 0x3]
- movs r2, 0x4
- orrs r0, r2
- strb r0, [r5, 0x3]
- ldrb r1, [r4, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r1
- orrs r0, r2
- strb r0, [r4, 0x5]
- ldrb r1, [r3]
- movs r0, 0x3F
- ands r0, r1
- movs r1, 0x80
- orrs r0, r1
- strb r0, [r3]
- mov r1, r9
- ldrh r0, [r1, 0x8]
- adds r0, 0x1
- strh r0, [r1, 0x8]
- movs r0, 0x1
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08086848: .4byte gPlayerAvatar
-_0808684C: .4byte gMapObjects
-_08086850: .4byte gSprites
- thumb_func_end sub_80867AC
-
- thumb_func_start sub_8086854
-sub_8086854: @ 8086854
- push {r4,lr}
- adds r4, r0, 0
- bl sub_807D770
- lsls r0, 24
- cmp r0, 0
- beq _08086868
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086868:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8086854
-
- thumb_func_start sub_8086870
-sub_8086870: @ 8086870
- push {r4-r6,lr}
- adds r5, r0, 0
- ldr r6, _080868D4 @ =gPlayerAvatar
- ldrb r0, [r6, 0x4]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r0, _080868D8 @ =gSprites
- adds r2, r0
- adds r0, r2, 0
- adds r0, 0x29
- movs r4, 0
- ldrsb r4, [r0, r4]
- lsls r0, r4, 17
- negs r0, r0
- ldrh r1, [r2, 0x22]
- ldr r3, _080868DC @ =gSpriteCoordOffsetY
- adds r1, r4
- ldrh r3, [r3]
- adds r1, r3
- asrs r0, 16
- adds r0, r1
- negs r0, r0
- movs r1, 0
- strh r0, [r2, 0x26]
- movs r0, 0x1
- strh r0, [r5, 0xA]
- strh r1, [r5, 0xC]
- ldr r2, _080868E0 @ =gMapObjects
- ldrb r0, [r6, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- adds r1, r2
- ldrb r2, [r1, 0x1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r2
- strb r0, [r1, 0x1]
- movs r0, 0x2B
- bl PlaySE
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_080868D4: .4byte gPlayerAvatar
-_080868D8: .4byte gSprites
-_080868DC: .4byte gSpriteCoordOffsetY
-_080868E0: .4byte gMapObjects
- thumb_func_end sub_8086870
-
- thumb_func_start sub_80868E4
-sub_80868E4: @ 80868E4
- push {r4-r6,lr}
- adds r4, r0, 0
- ldr r2, _08086990 @ =gPlayerAvatar
- ldrb r1, [r2, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086994 @ =gMapObjects
- adds r6, r0, r1
- ldrb r1, [r2, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086998 @ =gSprites
- adds r5, r0, r1
- ldrh r0, [r4, 0xA]
- ldrh r1, [r5, 0x26]
- adds r0, r1
- strh r0, [r5, 0x26]
- ldrh r2, [r4, 0xA]
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- cmp r0, 0x7
- bgt _08086926
- ldrh r1, [r4, 0xC]
- adds r0, r2, r1
- strh r0, [r4, 0xC]
- movs r1, 0xF
- ands r0, r1
- cmp r0, 0
- beq _08086926
- lsls r0, r2, 1
- strh r0, [r4, 0xA]
-_08086926:
- ldrh r2, [r4, 0xE]
- movs r1, 0xE
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _08086964
- movs r0, 0x26
- ldrsh r1, [r5, r0]
- movs r0, 0x10
- negs r0, r0
- cmp r1, r0
- blt _08086964
- adds r0, r2, 0x1
- strh r0, [r4, 0xE]
- ldrb r1, [r6, 0x3]
- movs r0, 0x5
- negs r0, r0
- ands r0, r1
- strb r0, [r6, 0x3]
- ldrb r1, [r4, 0x10]
- adds r3, r5, 0
- adds r3, 0x42
- lsls r1, 6
- ldrb r2, [r3]
- movs r0, 0x3F
- ands r0, r2
- orrs r0, r1
- strb r0, [r3]
- ldrb r0, [r6]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r6]
-_08086964:
- movs r1, 0x26
- ldrsh r0, [r5, r1]
- cmp r0, 0
- blt _08086988
- movs r0, 0xD6
- bl PlaySE
- ldrb r0, [r6]
- movs r1, 0x8
- orrs r0, r1
- movs r1, 0x20
- orrs r0, r1
- strb r0, [r6]
- movs r0, 0
- strh r0, [r5, 0x26]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086988:
- movs r0, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08086990: .4byte gPlayerAvatar
-_08086994: .4byte gMapObjects
-_08086998: .4byte gSprites
- thumb_func_end sub_80868E4
-
- thumb_func_start sub_808699C
-sub_808699C: @ 808699C
- push {lr}
- ldrh r1, [r0, 0x8]
- adds r1, 0x1
- movs r2, 0
- strh r1, [r0, 0x8]
- movs r1, 0x4
- strh r1, [r0, 0xA]
- strh r2, [r0, 0xC]
- movs r0, 0
- bl SetCameraPanningCallback
- movs r0, 0x1
- pop {r1}
- bx r1
- thumb_func_end sub_808699C
-
- thumb_func_start sub_80869B8
-sub_80869B8: @ 80869B8
- push {r4,lr}
- adds r4, r0, 0
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0
- bl SetCameraPanning
- ldrh r0, [r4, 0xA]
- negs r2, r0
- strh r2, [r4, 0xA]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- movs r1, 0x3
- ands r0, r1
- cmp r0, 0
- bne _080869E0
- lsls r0, r2, 16
- asrs r0, 17
- strh r0, [r4, 0xA]
-_080869E0:
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _080869EE
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_080869EE:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_80869B8
-
- thumb_func_start sub_80869F8
-sub_80869F8: @ 80869F8
- push {lr}
- ldr r1, _08086A24 @ =gPlayerAvatar
- movs r0, 0
- strb r0, [r1, 0x6]
- bl ScriptContext2_Disable
- bl CameraObjectReset1
- bl UnfreezeMapObjects
- bl InstallCameraPanAheadCallback
- ldr r0, _08086A28 @ =sub_8086774
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08086A24: .4byte gPlayerAvatar
-_08086A28: .4byte sub_8086774
- thumb_func_end sub_80869F8
-
- thumb_func_start sub_8086A2C
-sub_8086A2C: @ 8086A2C
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- lsls r1, 24
- lsrs r1, 24
- ldr r0, _08086A60 @ =sub_8086A68
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08086A64 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- movs r0, 0
- strh r0, [r1, 0xA]
- cmp r4, 0x6A
- bne _08086A58
- movs r0, 0x1
- strh r0, [r1, 0xA]
-_08086A58:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08086A60: .4byte sub_8086A68
-_08086A64: .4byte gTasks
- thumb_func_end sub_8086A2C
-
- thumb_func_start sub_8086A68
-sub_8086A68: @ 8086A68
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08086A98 @ =gTasks
- adds r4, r1, r0
- ldr r5, _08086A9C @ =gUnknown_0839F2E8
-_08086A7A:
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r5
- ldr r1, [r0]
- adds r0, r4, 0
- bl _call_via_r1
- lsls r0, 24
- cmp r0, 0
- bne _08086A7A
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086A98: .4byte gTasks
-_08086A9C: .4byte gUnknown_0839F2E8
- thumb_func_end sub_8086A68
-
- thumb_func_start sub_8086AA0
-sub_8086AA0: @ 8086AA0
- push {r4,lr}
- adds r4, r0, 0
- bl FreezeMapObjects
- bl CameraObjectReset2
- ldrb r0, [r4, 0xA]
- bl sub_80B4824
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8086AA0
-
- thumb_func_start sub_8086AC0
-sub_8086AC0: @ 8086AC0
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08086B28 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086B2C @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _08086AEA
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08086B1E
-_08086AEA:
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- movs r1, 0
- strh r0, [r5, 0x8]
- strh r1, [r5, 0xC]
- strh r1, [r5, 0xE]
- ldrb r0, [r5, 0xA]
- cmp r0, 0
- bne _08086B18
- movs r0, 0x4
- strh r0, [r5, 0x8]
-_08086B18:
- movs r0, 0x50
- bl PlaySE
-_08086B1E:
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08086B28: .4byte gPlayerAvatar
-_08086B2C: .4byte gMapObjects
- thumb_func_end sub_8086AC0
-
- thumb_func_start sub_8086B30
-sub_8086B30: @ 8086B30
- push {r4,lr}
- adds r4, r0, 0
- bl sub_8086B98
- movs r1, 0xC
- ldrsh r0, [r4, r1]
- cmp r0, 0x3
- ble _08086B4A
- bl sub_8086C30
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086B4A:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8086B30
-
- thumb_func_start sub_8086B54
-sub_8086B54: @ 8086B54
- push {lr}
- bl sub_8086B98
- bl sub_8086C40
- movs r0, 0
- pop {r1}
- bx r1
- thumb_func_end sub_8086B54
-
- thumb_func_start sub_8086B64
-sub_8086B64: @ 8086B64
- push {r4,lr}
- adds r4, r0, 0
- bl sub_8086BE4
- movs r1, 0xC
- ldrsh r0, [r4, r1]
- cmp r0, 0x3
- ble _08086B7E
- bl sub_8086C30
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086B7E:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8086B64
-
- thumb_func_start sub_8086B88
-sub_8086B88: @ 8086B88
- push {lr}
- bl sub_8086BE4
- bl sub_8086C40
- movs r0, 0
- pop {r1}
- bx r1
- thumb_func_end sub_8086B88
-
- thumb_func_start sub_8086B98
-sub_8086B98: @ 8086B98
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08086BDC @ =gPlayerAvatar
- ldrb r0, [r0, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086BE0 @ =gSprites
- adds r4, r0
- movs r0, 0xC
- ldrsh r1, [r5, r0]
- movs r0, 0x84
- bl Cos
- strh r0, [r4, 0x24]
- movs r0, 0xC
- ldrsh r1, [r5, r0]
- movs r0, 0x94
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r5, 0xE]
- adds r0, 0x1
- strh r0, [r5, 0xE]
- movs r1, 0x1
- ands r0, r1
- cmp r0, 0
- beq _08086BD6
- ldrh r0, [r5, 0xC]
- adds r0, 0x1
- strh r0, [r5, 0xC]
-_08086BD6:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086BDC: .4byte gPlayerAvatar
-_08086BE0: .4byte gSprites
- thumb_func_end sub_8086B98
-
- thumb_func_start sub_8086BE4
-sub_8086BE4: @ 8086BE4
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08086C28 @ =gPlayerAvatar
- ldrb r0, [r0, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086C2C @ =gSprites
- adds r4, r0
- movs r0, 0xC
- ldrsh r1, [r5, r0]
- movs r0, 0x7C
- bl Cos
- strh r0, [r4, 0x24]
- movs r0, 0xC
- ldrsh r1, [r5, r0]
- movs r0, 0x76
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r5, 0xE]
- adds r0, 0x1
- strh r0, [r5, 0xE]
- movs r1, 0x1
- ands r0, r1
- cmp r0, 0
- beq _08086C22
- ldrh r0, [r5, 0xC]
- adds r0, 0x1
- strh r0, [r5, 0xC]
-_08086C22:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086C28: .4byte gPlayerAvatar
-_08086C2C: .4byte gSprites
- thumb_func_end sub_8086BE4
-
- thumb_func_start sub_8086C30
-sub_8086C30: @ 8086C30
- push {lr}
- bl sub_8053FF8
- bl fade_8080918
- pop {r0}
- bx r0
- thumb_func_end sub_8086C30
-
- thumb_func_start sub_8086C40
-sub_8086C40: @ 8086C40
- push {lr}
- ldr r0, _08086C80 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08086C7C
- bl sub_8054034
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _08086C7C
- bl sub_80B483C
- bl warp_in
- ldr r1, _08086C84 @ =gUnknown_0300485C
- ldr r0, _08086C88 @ =sub_8086C94
- str r0, [r1]
- ldr r0, _08086C8C @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r0, _08086C90 @ =sub_8086A68
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08086C7C:
- pop {r0}
- bx r0
- .align 2, 0
-_08086C80: .4byte gPaletteFade
-_08086C84: .4byte gUnknown_0300485C
-_08086C88: .4byte sub_8086C94
-_08086C8C: .4byte CB2_LoadMap
-_08086C90: .4byte sub_8086A68
- thumb_func_end sub_8086C40
-
- thumb_func_start sub_8086C94
-sub_8086C94: @ 8086C94
- push {lr}
- bl sub_8053E90
- bl pal_fill_for_map_transition
- bl ScriptContext2_Enable
- ldr r0, _08086CB4 @ =sub_8086CBC
- movs r1, 0
- bl CreateTask
- ldr r1, _08086CB8 @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- pop {r0}
- bx r0
- .align 2, 0
-_08086CB4: .4byte sub_8086CBC
-_08086CB8: .4byte gUnknown_0300485C
- thumb_func_end sub_8086C94
-
- thumb_func_start sub_8086CBC
-sub_8086CBC: @ 8086CBC
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08086CEC @ =gTasks
- adds r4, r1, r0
- ldr r5, _08086CF0 @ =gUnknown_0839F300
-_08086CCE:
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r5
- ldr r1, [r0]
- adds r0, r4, 0
- bl _call_via_r1
- lsls r0, 24
- cmp r0, 0
- bne _08086CCE
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086CEC: .4byte gTasks
-_08086CF0: .4byte gUnknown_0839F300
- thumb_func_end sub_8086CBC
-
- thumb_func_start sub_8086CF4
-sub_8086CF4: @ 8086CF4
- push {r4,r5,lr}
- sub sp, 0x4
- adds r5, r0, 0
- bl CameraObjectReset2
- ldr r0, _08086D54 @ =gPlayerAvatar
- ldrb r0, [r0, 0x5]
- lsls r4, r0, 3
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086D58 @ =gMapObjects
- adds r4, r0
- movs r0, 0x4
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- mov r4, sp
- adds r4, 0x2
- mov r0, sp
- adds r1, r4, 0
- bl PlayerGetDestCoords
- mov r0, sp
- movs r1, 0
- ldrsh r0, [r0, r1]
- movs r2, 0
- ldrsh r1, [r4, r2]
- bl MapGridGetMetatileBehaviorAt
- lsls r0, 24
- lsrs r1, r0, 24
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0x10
- strh r0, [r5, 0xA]
- cmp r1, 0x6B
- bne _08086D5C
- movs r1, 0x1
- movs r0, 0x3
- strh r0, [r5, 0x8]
- b _08086D5E
- .align 2, 0
-_08086D54: .4byte gPlayerAvatar
-_08086D58: .4byte gMapObjects
-_08086D5C:
- movs r1, 0
-_08086D5E:
- adds r0, r1, 0
- bl sub_80B4824
- movs r0, 0x1
- add sp, 0x4
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_8086CF4
-
- thumb_func_start sub_8086D70
-sub_8086D70: @ 8086D70
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08086DA8 @ =gPlayerAvatar
- ldrb r0, [r0, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086DAC @ =gSprites
- adds r4, r0
- movs r0, 0xA
- ldrsh r1, [r5, r0]
- movs r0, 0x84
- bl Cos
- strh r0, [r4, 0x24]
- movs r0, 0xA
- ldrsh r1, [r5, r0]
- movs r0, 0x94
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08086DA8: .4byte gPlayerAvatar
-_08086DAC: .4byte gSprites
- thumb_func_end sub_8086D70
-
- thumb_func_start sub_8086DB0
-sub_8086DB0: @ 8086DB0
- push {r4,r5,lr}
- adds r4, r0, 0
- ldr r0, _08086E08 @ =gPlayerAvatar
- ldrb r1, [r0, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086E0C @ =gSprites
- adds r5, r0, r1
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0x84
- bl Cos
- strh r0, [r5, 0x24]
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0x94
- bl Sin
- strh r0, [r5, 0x26]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- movs r1, 0x1
- ands r0, r1
- cmp r0, 0
- beq _08086DEE
- ldrh r0, [r4, 0xA]
- subs r0, 0x1
- strh r0, [r4, 0xA]
-_08086DEE:
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _08086DFE
- strh r0, [r5, 0x24]
- strh r0, [r5, 0x26]
- movs r0, 0x5
- strh r0, [r4, 0x8]
-_08086DFE:
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08086E08: .4byte gPlayerAvatar
-_08086E0C: .4byte gSprites
- thumb_func_end sub_8086DB0
-
- thumb_func_start sub_8086E10
-sub_8086E10: @ 8086E10
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08086E48 @ =gPlayerAvatar
- ldrb r0, [r0, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08086E4C @ =gSprites
- adds r4, r0
- movs r0, 0xA
- ldrsh r1, [r5, r0]
- movs r0, 0x7C
- bl Cos
- strh r0, [r4, 0x24]
- movs r0, 0xA
- ldrsh r1, [r5, r0]
- movs r0, 0x76
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08086E48: .4byte gPlayerAvatar
-_08086E4C: .4byte gSprites
- thumb_func_end sub_8086E10
-
- thumb_func_start sub_8086E50
-sub_8086E50: @ 8086E50
- push {r4,r5,lr}
- adds r4, r0, 0
- ldr r0, _08086EA8 @ =gPlayerAvatar
- ldrb r1, [r0, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086EAC @ =gSprites
- adds r5, r0, r1
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0x7C
- bl Cos
- strh r0, [r5, 0x24]
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0x76
- bl Sin
- strh r0, [r5, 0x26]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- movs r1, 0x1
- ands r0, r1
- cmp r0, 0
- beq _08086E8E
- ldrh r0, [r4, 0xA]
- subs r0, 0x1
- strh r0, [r4, 0xA]
-_08086E8E:
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _08086EA0
- strh r0, [r5, 0x24]
- strh r0, [r5, 0x26]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08086EA0:
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08086EA8: .4byte gPlayerAvatar
-_08086EAC: .4byte gSprites
- thumb_func_end sub_8086E50
-
- thumb_func_start sub_8086EB0
-sub_8086EB0: @ 8086EB0
- push {r4,lr}
- adds r4, r0, 0
- bl sub_80B4850
- lsls r0, 24
- cmp r0, 0
- bne _08086ECC
- bl sub_80B483C
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x1
- b _08086ECE
-_08086ECC:
- movs r0, 0
-_08086ECE:
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8086EB0
-
- thumb_func_start sub_8086ED4
-sub_8086ED4: @ 8086ED4
- push {r4,lr}
- ldr r0, _08086F20 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08086F24 @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08086F18
- bl CameraObjectReset1
- bl ScriptContext2_Disable
- movs r0, 0x4
- bl GetGoSpeed0AnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- ldr r0, _08086F28 @ =sub_8086CBC
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08086F18:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08086F20: .4byte gPlayerAvatar
-_08086F24: .4byte gMapObjects
-_08086F28: .4byte sub_8086CBC
- thumb_func_end sub_8086ED4
-
- thumb_func_start FldEff_UseWaterfall
-FldEff_UseWaterfall: @ 8086F2C
- push {r4,lr}
- ldr r4, _08086F58 @ =sub_8086F64
- adds r0, r4, 0
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08086F5C @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- ldr r2, _08086F60 @ =gUnknown_0202FF84
- ldr r2, [r2]
- strh r2, [r1, 0xA]
- bl _call_via_r4
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08086F58: .4byte sub_8086F64
-_08086F5C: .4byte gTasks
-_08086F60: .4byte gUnknown_0202FF84
- thumb_func_end FldEff_UseWaterfall
-
- thumb_func_start sub_8086F64
-sub_8086F64: @ 8086F64
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r5, _08086FA0 @ =gUnknown_0839F31C
- ldr r2, _08086FA4 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r4, r1, r2
-_08086F76:
- movs r0, 0x8
- ldrsh r2, [r4, r0]
- lsls r2, 2
- adds r2, r5
- ldr r0, _08086FA8 @ =gPlayerAvatar
- ldrb r0, [r0, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _08086FAC @ =gMapObjects
- adds r1, r0
- ldr r2, [r2]
- adds r0, r4, 0
- bl _call_via_r2
- lsls r0, 24
- cmp r0, 0
- bne _08086F76
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08086FA0: .4byte gUnknown_0839F31C
-_08086FA4: .4byte gTasks
-_08086FA8: .4byte gPlayerAvatar
-_08086FAC: .4byte gMapObjects
- thumb_func_end sub_8086F64
-
- thumb_func_start sub_8086FB0
-sub_8086FB0: @ 8086FB0
- push {r4,lr}
- adds r4, r0, 0
- bl ScriptContext2_Enable
- ldr r1, _08086FCC @ =gPlayerAvatar
- movs r0, 0x1
- strb r0, [r1, 0x6]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08086FCC: .4byte gPlayerAvatar
- thumb_func_end sub_8086FB0
-
- thumb_func_start waterfall_1_do_anim_probably
-waterfall_1_do_anim_probably: @ 8086FD0
- push {r4,r5,lr}
- adds r4, r0, 0
- adds r5, r1, 0
- bl ScriptContext2_Enable
- adds r0, r5, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- bne _08087000
- adds r0, r5, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- ldr r1, _08087008 @ =gUnknown_0202FF84
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- str r0, [r1]
- movs r0, 0x3B
- bl FieldEffectStart
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08087000:
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08087008: .4byte gUnknown_0202FF84
- thumb_func_end waterfall_1_do_anim_probably
-
- thumb_func_start waterfall_2_wait_anim_finish_probably
-waterfall_2_wait_anim_finish_probably: @ 808700C
- push {r4,lr}
- adds r4, r0, 0
- movs r0, 0x6
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _08087026
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x1
- b _08087028
-_08087026:
- movs r0, 0
-_08087028:
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end waterfall_2_wait_anim_finish_probably
-
- thumb_func_start sub_8087030
-sub_8087030: @ 8087030
- push {r4,r5,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- movs r0, 0x2
- bl GetSimpleGoAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_8087030
-
- thumb_func_start sub_8087058
-sub_8087058: @ 8087058
- push {r4,r5,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- bne _0808706E
- movs r0, 0
- b _080870AA
-_0808706E:
- ldrb r0, [r4, 0x1E]
- bl MetatileBehavior_IsWaterfall
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0
- bne _080870A4
- bl ScriptContext2_Disable
- ldr r0, _0808709C @ =gPlayerAvatar
- strb r4, [r0, 0x6]
- ldr r0, _080870A0 @ =sub_8086F64
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- movs r0, 0x2B
- bl FieldEffectActiveListRemove
- movs r0, 0
- b _080870AA
- .align 2, 0
-_0808709C: .4byte gPlayerAvatar
-_080870A0: .4byte sub_8086F64
-_080870A4:
- movs r0, 0x3
- strh r0, [r5, 0x8]
- movs r0, 0x1
-_080870AA:
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_8087058
-
- thumb_func_start FldEff_UseDive
-FldEff_UseDive: @ 80870B0
- push {r4,lr}
- ldr r4, _080870E0 @ =Task_Dive
- adds r0, r4, 0
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _080870E4 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- ldr r3, _080870E8 @ =gUnknown_0202FF84
- ldr r2, [r3]
- strh r2, [r1, 0x26]
- ldr r2, [r3, 0x4]
- strh r2, [r1, 0x24]
- bl _call_via_r4
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_080870E0: .4byte Task_Dive
-_080870E4: .4byte gTasks
-_080870E8: .4byte gUnknown_0202FF84
- thumb_func_end FldEff_UseDive
-
- thumb_func_start Task_Dive
-Task_Dive: @ 80870EC
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r5, _0808711C @ =gUnknown_0839F330
- ldr r2, _08087120 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r4, r1, r2
-_080870FE:
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r5
- ldr r1, [r0]
- adds r0, r4, 0
- bl _call_via_r1
- lsls r0, 24
- cmp r0, 0
- bne _080870FE
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_0808711C: .4byte gUnknown_0839F330
-_08087120: .4byte gTasks
- thumb_func_end Task_Dive
-
- thumb_func_start sub_8087124
-sub_8087124: @ 8087124
- ldr r2, _08087134 @ =gPlayerAvatar
- movs r1, 0x1
- strb r1, [r2, 0x6]
- ldrh r1, [r0, 0x8]
- adds r1, 0x1
- strh r1, [r0, 0x8]
- movs r0, 0
- bx lr
- .align 2, 0
-_08087134: .4byte gPlayerAvatar
- thumb_func_end sub_8087124
-
- thumb_func_start dive_2_unknown
-dive_2_unknown: @ 8087138
- push {r4,lr}
- adds r4, r0, 0
- bl ScriptContext2_Enable
- ldr r1, _0808715C @ =gUnknown_0202FF84
- movs r2, 0x26
- ldrsh r0, [r4, r2]
- str r0, [r1]
- movs r0, 0x3B
- bl FieldEffectStart
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_0808715C: .4byte gUnknown_0202FF84
- thumb_func_end dive_2_unknown
-
- thumb_func_start dive_3_unknown
-dive_3_unknown: @ 8087160
- push {lr}
- sub sp, 0x8
- mov r1, sp
- adds r1, 0x2
- mov r0, sp
- bl PlayerGetDestCoords
- movs r0, 0x6
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _080871A4
- ldr r2, _080871AC @ =gMapObjects
- ldr r0, _080871B0 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x1E]
- mov r0, sp
- bl dive_warp
- ldr r0, _080871B4 @ =Task_Dive
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- movs r0, 0x2C
- bl FieldEffectActiveListRemove
-_080871A4:
- movs r0, 0
- add sp, 0x8
- pop {r1}
- bx r1
- .align 2, 0
-_080871AC: .4byte gMapObjects
-_080871B0: .4byte gPlayerAvatar
-_080871B4: .4byte Task_Dive
- thumb_func_end dive_3_unknown
-
- thumb_func_start sub_80871B8
-sub_80871B8: @ 80871B8
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r0, _080871CC @ =sub_80871D0
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_080871CC: .4byte sub_80871D0
- thumb_func_end sub_80871B8
-
- thumb_func_start sub_80871D0
-sub_80871D0: @ 80871D0
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r6, _08087218 @ =gUnknown_0839F33C
- ldr r2, _0808721C @ =gTasks
- ldr r5, _08087220 @ =gPlayerAvatar
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r4, r1, r2
-_080871E4:
- movs r0, 0x8
- ldrsh r3, [r4, r0]
- lsls r3, 2
- adds r3, r6
- ldrb r0, [r5, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _08087224 @ =gMapObjects
- adds r1, r0
- ldrb r0, [r5, 0x4]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r0, _08087228 @ =gSprites
- adds r2, r0
- ldr r3, [r3]
- adds r0, r4, 0
- bl _call_via_r3
- lsls r0, 24
- cmp r0, 0
- bne _080871E4
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08087218: .4byte gUnknown_0839F33C
-_0808721C: .4byte gTasks
-_08087220: .4byte gPlayerAvatar
-_08087224: .4byte gMapObjects
-_08087228: .4byte gSprites
- thumb_func_end sub_80871D0
-
- thumb_func_start sub_808722C
-sub_808722C: @ 808722C
- push {r4,r5,lr}
- adds r4, r0, 0
- adds r5, r1, 0
- bl FreezeMapObjects
- bl CameraObjectReset2
- movs r0, 0
- bl SetCameraPanningCallback
- ldr r0, _08087260 @ =gPlayerAvatar
- movs r2, 0x1
- strb r2, [r0, 0x6]
- ldrb r0, [r5, 0x3]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r5, 0x3]
- strh r2, [r4, 0xA]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x1
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_08087260: .4byte gPlayerAvatar
- thumb_func_end sub_808722C
-
- thumb_func_start sub_8087264
-sub_8087264: @ 8087264
- push {r4,lr}
- adds r4, r0, 0
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0
- bl SetCameraPanning
- ldrh r0, [r4, 0xA]
- negs r0, r0
- strh r0, [r4, 0xA]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x7
- ble _08087290
- movs r0, 0
- strh r0, [r4, 0xC]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08087290:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8087264
-
- thumb_func_start sub_8087298
-sub_8087298: @ 8087298
- push {r4,r5,lr}
- adds r4, r0, 0
- movs r0, 0
- strh r0, [r2, 0x26]
- movs r0, 0x1
- strh r0, [r4, 0xE]
- ldr r3, _080872E0 @ =gUnknown_0202FF84
- movs r5, 0x10
- ldrsh r0, [r1, r5]
- str r0, [r3]
- movs r5, 0x12
- ldrsh r0, [r1, r5]
- str r0, [r3, 0x4]
- adds r0, r2, 0
- adds r0, 0x43
- ldrb r0, [r0]
- subs r0, 0x1
- str r0, [r3, 0x8]
- ldrb r0, [r2, 0x5]
- lsls r0, 28
- lsrs r0, 30
- str r0, [r3, 0xC]
- movs r0, 0x32
- bl FieldEffectStart
- movs r0, 0xB2
- bl PlaySE
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x1
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_080872E0: .4byte gUnknown_0202FF84
- thumb_func_end sub_8087298
-
- thumb_func_start sub_80872E4
-sub_80872E4: @ 80872E4
- push {r4-r7,lr}
- adds r4, r0, 0
- adds r6, r1, 0
- adds r5, r2, 0
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- movs r0, 0
- bl SetCameraPanning
- ldrh r0, [r4, 0xA]
- negs r2, r0
- strh r2, [r4, 0xA]
- ldrh r0, [r4, 0xC]
- adds r1, r0, 0x1
- strh r1, [r4, 0xC]
- lsls r0, r1, 16
- asrs r0, 16
- cmp r0, 0x11
- bgt _0808731E
- movs r0, 0x1
- ands r1, r0
- cmp r1, 0
- bne _08087330
- lsls r0, r2, 16
- asrs r0, 16
- cmp r0, 0x3
- bgt _08087330
- lsls r0, r2, 1
- b _0808732E
-_0808731E:
- movs r0, 0x4
- ands r1, r0
- cmp r1, 0
- bne _08087330
- lsls r0, r2, 16
- cmp r0, 0
- ble _08087330
- asrs r0, 17
-_0808732E:
- strh r0, [r4, 0xA]
-_08087330:
- movs r1, 0xC
- ldrsh r0, [r4, r1]
- cmp r0, 0x6
- ble _0808737C
- adds r0, r5, 0
- adds r0, 0x29
- movs r1, 0
- ldrsb r1, [r0, r1]
- lsls r2, r1, 17
- negs r2, r2
- movs r7, 0x26
- ldrsh r3, [r5, r7]
- movs r7, 0x22
- ldrsh r0, [r5, r7]
- adds r0, r1
- ldr r1, _08087374 @ =gSpriteCoordOffsetY
- movs r7, 0
- ldrsh r1, [r1, r7]
- adds r0, r1
- asrs r2, 16
- adds r0, r2
- cmn r3, r0
- ble _08087378
- ldrh r0, [r5, 0x26]
- ldrh r1, [r4, 0xE]
- subs r0, r1
- strh r0, [r5, 0x26]
- lsls r0, r1, 16
- asrs r0, 16
- cmp r0, 0x7
- bgt _0808737C
- adds r0, r1, 0x1
- strh r0, [r4, 0xE]
- b _0808737C
- .align 2, 0
-_08087374: .4byte gSpriteCoordOffsetY
-_08087378:
- movs r0, 0x1
- strh r0, [r4, 0x10]
-_0808737C:
- ldrh r2, [r4, 0x12]
- movs r1, 0x12
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _080873BA
- movs r7, 0x26
- ldrsh r1, [r5, r7]
- movs r0, 0x10
- negs r0, r0
- cmp r1, r0
- bge _080873BA
- adds r0, r2, 0x1
- strh r0, [r4, 0x12]
- ldrb r0, [r6, 0x3]
- movs r2, 0x4
- orrs r0, r2
- strb r0, [r6, 0x3]
- ldrb r1, [r5, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r1
- orrs r0, r2
- strb r0, [r5, 0x5]
- adds r2, r5, 0
- adds r2, 0x42
- ldrb r1, [r2]
- movs r0, 0x3F
- ands r0, r1
- movs r1, 0x80
- orrs r0, r1
- strb r0, [r2]
-_080873BA:
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _080873D0
- movs r7, 0x10
- ldrsh r0, [r4, r7]
- cmp r0, 0
- beq _080873D0
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_080873D0:
- movs r0, 0
- pop {r4-r7}
- pop {r1}
- bx r1
- thumb_func_end sub_80872E4
-
- thumb_func_start sub_80873D8
-sub_80873D8: @ 80873D8
- push {r4,lr}
- adds r4, r0, 0
- bl sub_8053FF8
- bl fade_8080918
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_80873D8
-
- thumb_func_start sub_80873F4
-sub_80873F4: @ 80873F4
- push {lr}
- ldr r0, _08087434 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _0808742C
- bl sub_8054034
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _0808742C
- bl warp_in
- ldr r1, _08087438 @ =gUnknown_0300485C
- ldr r0, _0808743C @ =mapldr_080851BC
- str r0, [r1]
- ldr r0, _08087440 @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r0, _08087444 @ =sub_80871D0
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_0808742C:
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08087434: .4byte gPaletteFade
-_08087438: .4byte gUnknown_0300485C
-_0808743C: .4byte mapldr_080851BC
-_08087440: .4byte CB2_LoadMap
-_08087444: .4byte sub_80871D0
- thumb_func_end sub_80873F4
-
- thumb_func_start mapldr_080851BC
-mapldr_080851BC: @ 8087448
- push {lr}
- bl sub_8053E90
- bl pal_fill_for_map_transition
- bl ScriptContext2_Enable
- ldr r0, _08087468 @ =gUnknown_0300485C
- movs r1, 0
- str r1, [r0]
- ldr r0, _0808746C @ =sub_8087470
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_08087468: .4byte gUnknown_0300485C
-_0808746C: .4byte sub_8087470
- thumb_func_end mapldr_080851BC
-
- thumb_func_start sub_8087470
-sub_8087470: @ 8087470
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r6, _080874B8 @ =gUnknown_0839F354
- ldr r2, _080874BC @ =gTasks
- ldr r5, _080874C0 @ =gPlayerAvatar
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r4, r1, r2
-_08087484:
- movs r0, 0x8
- ldrsh r3, [r4, r0]
- lsls r3, 2
- adds r3, r6
- ldrb r0, [r5, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _080874C4 @ =gMapObjects
- adds r1, r0
- ldrb r0, [r5, 0x4]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r0, _080874C8 @ =gSprites
- adds r2, r0
- ldr r3, [r3]
- adds r0, r4, 0
- bl _call_via_r3
- lsls r0, 24
- cmp r0, 0
- bne _08087484
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080874B8: .4byte gUnknown_0839F354
-_080874BC: .4byte gTasks
-_080874C0: .4byte gPlayerAvatar
-_080874C4: .4byte gMapObjects
-_080874C8: .4byte gSprites
- thumb_func_end sub_8087470
-
- thumb_func_start sub_80874CC
-sub_80874CC: @ 80874CC
- push {r4,r5,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- bl CameraObjectReset2
- bl FreezeMapObjects
- ldr r1, _080874F8 @ =gPlayerAvatar
- movs r0, 0x1
- strb r0, [r1, 0x6]
- ldrb r0, [r4, 0x1]
- movs r1, 0x20
- orrs r0, r1
- strb r0, [r4, 0x1]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_080874F8: .4byte gPlayerAvatar
- thumb_func_end sub_80874CC
-
- thumb_func_start sub_80874FC
-sub_80874FC: @ 80874FC
- push {r4-r6,lr}
- adds r4, r0, 0
- adds r5, r1, 0
- adds r6, r2, 0
- bl sub_807D770
- lsls r0, 24
- cmp r0, 0
- beq _0808753C
- ldr r1, _08087544 @ =gUnknown_0202FF84
- movs r2, 0x10
- ldrsh r0, [r5, r2]
- str r0, [r1]
- movs r2, 0x12
- ldrsh r0, [r5, r2]
- str r0, [r1, 0x4]
- adds r0, r6, 0
- adds r0, 0x43
- ldrb r0, [r0]
- subs r0, 0x1
- str r0, [r1, 0x8]
- ldrb r0, [r6, 0x5]
- lsls r0, 28
- lsrs r0, 30
- str r0, [r1, 0xC]
- movs r0, 0x31
- bl FieldEffectStart
- strh r0, [r4, 0xA]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_0808753C:
- movs r0, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08087544: .4byte gUnknown_0202FF84
- thumb_func_end sub_80874FC
-
- thumb_func_start sub_8087548
-sub_8087548: @ 8087548
- push {r4,lr}
- adds r2, r0, 0
- adds r4, r1, 0
- movs r0, 0xA
- ldrsh r1, [r2, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087598 @ =gSprites
- adds r0, r1
- adds r0, 0x2B
- ldrb r0, [r0]
- cmp r0, 0x1
- bls _08087590
- ldrh r0, [r2, 0x8]
- adds r0, 0x1
- strh r0, [r2, 0x8]
- ldrb r1, [r4, 0x1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x1]
- bl CameraObjectReset1
- movs r0, 0xAF
- bl PlaySE
- movs r0, 0x4
- bl sub_80608A4
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
-_08087590:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08087598: .4byte gSprites
- thumb_func_end sub_8087548
-
- thumb_func_start sub_808759C
-sub_808759C: @ 808759C
- push {lr}
- adds r0, r1, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _080875C6
- ldr r1, _080875CC @ =gPlayerAvatar
- movs r0, 0
- strb r0, [r1, 0x6]
- bl ScriptContext2_Disable
- bl UnfreezeMapObjects
- ldr r0, _080875D0 @ =sub_8087470
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_080875C6:
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_080875CC: .4byte gPlayerAvatar
-_080875D0: .4byte sub_8087470
- thumb_func_end sub_808759C
-
- thumb_func_start FldEff_LavaridgeGymWarp
-FldEff_LavaridgeGymWarp: @ 80875D4
- push {r4,lr}
- ldr r4, _0808762C @ =gUnknown_0202FF84
- adds r1, r4, 0x4
- adds r0, r4, 0
- movs r2, 0x8
- movs r3, 0x8
- bl sub_8060470
- ldr r0, _08087630 @ =gFieldEffectObjectTemplatePointers
- adds r0, 0x84
- ldr r0, [r0]
- movs r2, 0
- ldrsh r1, [r4, r2]
- movs r3, 0x4
- ldrsh r2, [r4, r3]
- ldrb r3, [r4, 0x8]
- bl CreateSpriteAtEnd
- lsls r0, 24
- lsrs r0, 24
- ldr r1, _08087634 @ =gSprites
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r1
- movs r1, 0x3
- ldrb r3, [r4, 0xC]
- ands r3, r1
- lsls r3, 2
- ldrb r4, [r2, 0x5]
- movs r1, 0xD
- negs r1, r1
- ands r1, r4
- orrs r1, r3
- strb r1, [r2, 0x5]
- adds r2, 0x3E
- ldrb r1, [r2]
- movs r3, 0x2
- orrs r1, r3
- strb r1, [r2]
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_0808762C: .4byte gUnknown_0202FF84
-_08087630: .4byte gFieldEffectObjectTemplatePointers
-_08087634: .4byte gSprites
- thumb_func_end FldEff_LavaridgeGymWarp
-
- thumb_func_start sub_8087638
-sub_8087638: @ 8087638
- push {lr}
- adds r2, r0, 0
- adds r0, 0x3F
- ldrb r1, [r0]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- beq _08087650
- adds r0, r2, 0
- movs r1, 0x32
- bl FieldEffectStop
-_08087650:
- pop {r0}
- bx r0
- thumb_func_end sub_8087638
-
- thumb_func_start sub_8087654
-sub_8087654: @ 8087654
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r0, _08087668 @ =sub_808766C
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_08087668: .4byte sub_808766C
- thumb_func_end sub_8087654
-
- thumb_func_start sub_808766C
-sub_808766C: @ 808766C
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r6, _080876B4 @ =gUnknown_0839F364
- ldr r2, _080876B8 @ =gTasks
- ldr r5, _080876BC @ =gPlayerAvatar
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r4, r1, r2
-_08087680:
- movs r0, 0x8
- ldrsh r3, [r4, r0]
- lsls r3, 2
- adds r3, r6
- ldrb r0, [r5, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _080876C0 @ =gMapObjects
- adds r1, r0
- ldrb r0, [r5, 0x4]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r0, _080876C4 @ =gSprites
- adds r2, r0
- ldr r3, [r3]
- adds r0, r4, 0
- bl _call_via_r3
- lsls r0, 24
- cmp r0, 0
- bne _08087680
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080876B4: .4byte gUnknown_0839F364
-_080876B8: .4byte gTasks
-_080876BC: .4byte gPlayerAvatar
-_080876C0: .4byte gMapObjects
-_080876C4: .4byte gSprites
- thumb_func_end sub_808766C
-
- thumb_func_start sub_80876C8
-sub_80876C8: @ 80876C8
- push {r4,r5,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- bl FreezeMapObjects
- bl CameraObjectReset2
- ldr r1, _080876F4 @ =gPlayerAvatar
- movs r0, 0x1
- strb r0, [r1, 0x6]
- ldrb r0, [r4, 0x3]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r4, 0x3]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- pop {r4,r5}
- pop {r1}
- bx r1
- .align 2, 0
-_080876F4: .4byte gPlayerAvatar
- thumb_func_end sub_80876C8
-
- thumb_func_start sub_80876F8
-sub_80876F8: @ 80876F8
- push {r4-r6,lr}
- adds r5, r0, 0
- adds r4, r1, 0
- adds r6, r2, 0
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _0808776C
- ldrh r1, [r5, 0xA]
- movs r2, 0xA
- ldrsh r0, [r5, r2]
- cmp r0, 0x3
- ble _0808774C
- ldr r1, _08087748 @ =gUnknown_0202FF84
- movs r2, 0x10
- ldrsh r0, [r4, r2]
- str r0, [r1]
- movs r2, 0x12
- ldrsh r0, [r4, r2]
- str r0, [r1, 0x4]
- adds r0, r6, 0
- adds r0, 0x43
- ldrb r0, [r0]
- subs r0, 0x1
- str r0, [r1, 0x8]
- ldrb r0, [r6, 0x5]
- lsls r0, 28
- lsrs r0, 30
- str r0, [r1, 0xC]
- movs r0, 0x31
- bl FieldEffectStart
- strh r0, [r5, 0xA]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- b _0808776C
- .align 2, 0
-_08087748: .4byte gUnknown_0202FF84
-_0808774C:
- adds r0, r1, 0x1
- strh r0, [r5, 0xA]
- ldrb r0, [r4, 0x18]
- lsls r0, 28
- lsrs r0, 28
- bl GetStepInPlaceDelay4AnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- movs r0, 0x27
- bl PlaySE
-_0808776C:
- movs r0, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- thumb_func_end sub_80876F8
-
- thumb_func_start sub_8087774
-sub_8087774: @ 8087774
- push {r4,lr}
- adds r3, r0, 0
- adds r4, r1, 0
- ldr r2, _080877A8 @ =gSprites
- movs r0, 0xA
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- adds r0, 0x2B
- ldrb r0, [r0]
- cmp r0, 0x2
- bne _0808779E
- ldrb r0, [r4, 0x1]
- movs r1, 0x20
- orrs r0, r1
- strb r0, [r4, 0x1]
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_0808779E:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_080877A8: .4byte gSprites
- thumb_func_end sub_8087774
-
- thumb_func_start sub_80877AC
-sub_80877AC: @ 80877AC
- push {r4,lr}
- adds r4, r0, 0
- movs r0, 0x31
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _080877CA
- bl sub_8053FF8
- bl fade_8080918
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_080877CA:
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_80877AC
-
- thumb_func_start sub_80877D4
-sub_80877D4: @ 80877D4
- push {lr}
- ldr r0, _08087814 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _0808780C
- bl sub_8054034
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _0808780C
- bl warp_in
- ldr r1, _08087818 @ =gUnknown_0300485C
- ldr r0, _0808781C @ =sub_8086748
- str r0, [r1]
- ldr r0, _08087820 @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r0, _08087824 @ =sub_808766C
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_0808780C:
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08087814: .4byte gPaletteFade
-_08087818: .4byte gUnknown_0300485C
-_0808781C: .4byte sub_8086748
-_08087820: .4byte CB2_LoadMap
-_08087824: .4byte sub_808766C
- thumb_func_end sub_80877D4
-
- thumb_func_start FldEff_PopOutOfAsh
-FldEff_PopOutOfAsh: @ 8087828
- push {r4,lr}
- ldr r4, _08087880 @ =gUnknown_0202FF84
- adds r1, r4, 0x4
- adds r0, r4, 0
- movs r2, 0x8
- movs r3, 0x8
- bl sub_8060470
- ldr r0, _08087884 @ =gFieldEffectObjectTemplatePointers
- adds r0, 0x80
- ldr r0, [r0]
- movs r2, 0
- ldrsh r1, [r4, r2]
- movs r3, 0x4
- ldrsh r2, [r4, r3]
- ldrb r3, [r4, 0x8]
- bl CreateSpriteAtEnd
- lsls r0, 24
- lsrs r0, 24
- ldr r1, _08087888 @ =gSprites
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r1
- movs r1, 0x3
- ldrb r3, [r4, 0xC]
- ands r3, r1
- lsls r3, 2
- ldrb r4, [r2, 0x5]
- movs r1, 0xD
- negs r1, r1
- ands r1, r4
- orrs r1, r3
- strb r1, [r2, 0x5]
- adds r2, 0x3E
- ldrb r1, [r2]
- movs r3, 0x2
- orrs r1, r3
- strb r1, [r2]
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08087880: .4byte gUnknown_0202FF84
-_08087884: .4byte gFieldEffectObjectTemplatePointers
-_08087888: .4byte gSprites
- thumb_func_end FldEff_PopOutOfAsh
-
- thumb_func_start sub_808788C
-sub_808788C: @ 808788C
- push {lr}
- adds r2, r0, 0
- adds r0, 0x3F
- ldrb r1, [r0]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- beq _080878A4
- adds r0, r2, 0
- movs r1, 0x31
- bl FieldEffectStop
-_080878A4:
- pop {r0}
- bx r0
- thumb_func_end sub_808788C
-
- thumb_func_start sub_80878A8
-sub_80878A8: @ 80878A8
- push {lr}
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r0, _080878C0 @ =sub_80878C4
- movs r1, 0x50
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_080878C0: .4byte sub_80878C4
- thumb_func_end sub_80878A8
-
- thumb_func_start sub_80878C4
-sub_80878C4: @ 80878C4
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _080878EC @ =gUnknown_0839F378
- ldr r2, _080878F0 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_080878EC: .4byte gUnknown_0839F378
-_080878F0: .4byte gTasks
- thumb_func_end sub_80878C4
-
- thumb_func_start sub_80878F4
-sub_80878F4: @ 80878F4
- push {r4,lr}
- adds r4, r0, 0
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x40
- strh r0, [r4, 0x24]
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x26]
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_80878F4
-
- thumb_func_start sub_8087914
-sub_8087914: @ 8087914
- push {r4,r5,lr}
- sub sp, 0x8
- adds r4, r0, 0
- ldr r1, _080879B8 @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldrh r1, [r4, 0x24]
- movs r2, 0x24
- ldrsh r0, [r4, r2]
- cmp r0, 0
- beq _08087940
- subs r0, r1, 0x1
- strh r0, [r4, 0x24]
- lsls r0, 16
- cmp r0, 0
- bne _08087940
- bl sub_8053FF8
- bl fade_8080918
-_08087940:
- ldr r0, _080879BC @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _080879C0 @ =gMapObjects
- adds r5, r0, r1
- adds r0, r5, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _08087966
- adds r0, r5, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08087A20
-_08087966:
- movs r1, 0x24
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _080879D8
- ldr r0, _080879C4 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _080879D8
- bl sub_8054034
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _080879D8
- ldrh r1, [r4, 0x26]
- lsls r1, 24
- lsrs r1, 24
- adds r0, r5, 0
- bl FieldObjectSetDirection
- bl sub_8053678
- bl warp_in
- ldr r1, _080879C8 @ =gUnknown_0300485C
- ldr r0, _080879CC @ =mapldr_080859D4
- str r0, [r1]
- ldr r0, _080879D0 @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r0, _080879D4 @ =sub_80878C4
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- b _08087A20
- .align 2, 0
-_080879B8: .4byte gUnknown_0839F380
-_080879BC: .4byte gPlayerAvatar
-_080879C0: .4byte gMapObjects
-_080879C4: .4byte gPaletteFade
-_080879C8: .4byte gUnknown_0300485C
-_080879CC: .4byte mapldr_080859D4
-_080879D0: .4byte CB2_LoadMap
-_080879D4: .4byte sub_80878C4
-_080879D8:
- ldrh r1, [r4, 0xA]
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- cmp r0, 0
- beq _080879EC
- subs r0, r1, 0x1
- strh r0, [r4, 0xA]
- lsls r0, 16
- cmp r0, 0
- bne _08087A20
-_080879EC:
- ldrb r0, [r5, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r0, [r0]
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r5, 0
- bl FieldObjectSetSpecialAnim
- ldrh r1, [r4, 0xC]
- movs r2, 0xC
- ldrsh r0, [r4, r2]
- cmp r0, 0xB
- bgt _08087A14
- adds r0, r1, 0x1
- strh r0, [r4, 0xC]
-_08087A14:
- ldrh r1, [r4, 0xC]
- lsls r1, 16
- asrs r1, 18
- movs r0, 0x8
- asrs r0, r1
- strh r0, [r4, 0xA]
-_08087A20:
- add sp, 0x8
- pop {r4,r5}
- pop {r0}
- bx r0
- thumb_func_end sub_8087914
-
- thumb_func_start mapldr_080859D4
-mapldr_080859D4: @ 8087A28
- push {lr}
- bl sub_8053E90
- bl pal_fill_for_map_transition
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r1, _08087A64 @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- ldr r2, _08087A68 @ =gMapObjects
- ldr r0, _08087A6C @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x1]
- movs r2, 0x20
- orrs r1, r2
- strb r1, [r0, 0x1]
- ldr r0, _08087A70 @ =sub_8087A74
- movs r1, 0
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_08087A64: .4byte gUnknown_0300485C
-_08087A68: .4byte gMapObjects
-_08087A6C: .4byte gPlayerAvatar
-_08087A70: .4byte sub_8087A74
- thumb_func_end mapldr_080859D4
-
- thumb_func_start sub_8087A74
-sub_8087A74: @ 8087A74
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08087A9C @ =gUnknown_0839F388
- ldr r2, _08087AA0 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08087A9C: .4byte gUnknown_0839F388
-_08087AA0: .4byte gTasks
- thumb_func_end sub_8087A74
-
- thumb_func_start sub_8087AA4
-sub_8087AA4: @ 8087AA4
- push {r4,lr}
- adds r4, r0, 0
- bl sub_807D770
- lsls r0, 24
- cmp r0, 0
- beq _08087AC2
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x26]
-_08087AC2:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_8087AA4
-
- thumb_func_start sub_8087AC8
-sub_8087AC8: @ 8087AC8
- push {r4-r6,lr}
- sub sp, 0x8
- adds r5, r0, 0
- ldr r1, _08087B4C @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldr r0, _08087B50 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087B54 @ =gMapObjects
- adds r6, r0, r1
- ldrh r1, [r5, 0xA]
- movs r2, 0xA
- ldrsh r0, [r5, r2]
- cmp r0, 0
- beq _08087AFA
- subs r0, r1, 0x1
- strh r0, [r5, 0xA]
- lsls r0, 16
- cmp r0, 0
- bne _08087B8C
-_08087AFA:
- adds r0, r6, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _08087B12
- adds r0, r6, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08087BA0
-_08087B12:
- movs r1, 0xC
- ldrsh r0, [r5, r1]
- cmp r0, 0x1F
- ble _08087B5C
- movs r2, 0x26
- ldrsh r4, [r5, r2]
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- cmp r4, r0
- bne _08087B5C
- ldrb r1, [r6, 0x1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r1
- strb r0, [r6, 0x1]
- bl ScriptContext2_Disable
- bl UnfreezeMapObjects
- ldr r0, _08087B58 @ =sub_8087A74
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- b _08087BA0
- .align 2, 0
-_08087B4C: .4byte gUnknown_0839F380
-_08087B50: .4byte gPlayerAvatar
-_08087B54: .4byte gMapObjects
-_08087B58: .4byte sub_8087A74
-_08087B5C:
- ldrb r0, [r6, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r0, [r0]
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r6, 0
- bl FieldObjectSetSpecialAnim
- ldrh r1, [r5, 0xC]
- movs r2, 0xC
- ldrsh r0, [r5, r2]
- cmp r0, 0x1F
- bgt _08087B84
- adds r0, r1, 0x1
- strh r0, [r5, 0xC]
-_08087B84:
- ldrh r0, [r5, 0xC]
- lsls r0, 16
- asrs r0, 18
- strh r0, [r5, 0xA]
-_08087B8C:
- ldrb r2, [r6, 0x1]
- lsls r1, r2, 26
- lsrs r1, 31
- movs r0, 0x1
- eors r1, r0
- lsls r1, 5
- subs r0, 0x22
- ands r0, r2
- orrs r0, r1
- strb r0, [r6, 0x1]
-_08087BA0:
- add sp, 0x8
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end sub_8087AC8
-
- thumb_func_start sub_8087BA8
-sub_8087BA8: @ 8087BA8
- push {lr}
- ldr r0, _08087BB8 @ =sub_8087BBC
- movs r1, 0
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_08087BB8: .4byte sub_8087BBC
- thumb_func_end sub_8087BA8
-
- thumb_func_start sub_8087BBC
-sub_8087BBC: @ 8087BBC
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08087BE4 @ =gUnknown_0839F390
- ldr r2, _08087BE8 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08087BE4: .4byte gUnknown_0839F390
-_08087BE8: .4byte gTasks
- thumb_func_end sub_8087BBC
-
- thumb_func_start sub_8087BEC
-sub_8087BEC: @ 8087BEC
- push {r4,lr}
- adds r4, r0, 0
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- bl CameraObjectReset2
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0x26]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_8087BEC
-
- thumb_func_start sub_8087C14
-sub_8087C14: @ 8087C14
- push {r4,r5,lr}
- sub sp, 0x8
- adds r4, r0, 0
- ldr r1, _08087C98 @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldr r0, _08087C9C @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087CA0 @ =gMapObjects
- adds r5, r0, r1
- ldrh r1, [r4, 0xA]
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- cmp r0, 0
- beq _08087C46
- subs r0, r1, 0x1
- strh r0, [r4, 0xA]
- lsls r0, 16
- cmp r0, 0
- bne _08087C60
-_08087C46:
- ldrb r0, [r5, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r1, [r0]
- adds r0, r5, 0
- bl FieldObjectTurn
- movs r0, 0x8
- strh r0, [r4, 0xA]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
-_08087C60:
- movs r1, 0xC
- ldrsh r0, [r4, r1]
- cmp r0, 0x7
- ble _08087C8E
- movs r2, 0x26
- ldrsh r1, [r4, r2]
- ldrb r0, [r5, 0x18]
- lsls r0, 28
- lsrs r0, 28
- cmp r1, r0
- bne _08087C8E
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x4
- strh r0, [r4, 0xA]
- movs r0, 0x8
- strh r0, [r4, 0xC]
- movs r0, 0x1
- strh r0, [r4, 0xE]
- movs r0, 0x2D
- bl PlaySE
-_08087C8E:
- add sp, 0x8
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08087C98: .4byte gUnknown_0839F380
-_08087C9C: .4byte gPlayerAvatar
-_08087CA0: .4byte gMapObjects
- thumb_func_end sub_8087C14
-
- thumb_func_start sub_8087CA4
-sub_8087CA4: @ 8087CA4
- push {r4,r5,lr}
- sub sp, 0x8
- adds r4, r0, 0
- ldr r1, _08087D68 @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldr r2, _08087D6C @ =gPlayerAvatar
- ldrb r1, [r2, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087D70 @ =gMapObjects
- adds r3, r0, r1
- ldrb r1, [r2, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087D74 @ =gSprites
- adds r5, r0, r1
- ldrh r0, [r4, 0xA]
- subs r0, 0x1
- strh r0, [r4, 0xA]
- lsls r0, 16
- cmp r0, 0
- bgt _08087CEE
- movs r0, 0x4
- strh r0, [r4, 0xA]
- ldrb r0, [r3, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r1, [r0]
- adds r0, r3, 0
- bl FieldObjectTurn
-_08087CEE:
- ldrh r0, [r5, 0x22]
- ldrh r1, [r4, 0xE]
- subs r0, r1
- strh r0, [r5, 0x22]
- ldrh r1, [r4, 0xE]
- ldrh r2, [r4, 0x10]
- adds r0, r1, r2
- strh r0, [r4, 0x10]
- ldrh r0, [r4, 0xC]
- subs r0, 0x1
- strh r0, [r4, 0xC]
- lsls r0, 16
- cmp r0, 0
- bgt _08087D1A
- movs r0, 0x4
- strh r0, [r4, 0xC]
- lsls r0, r1, 16
- asrs r0, 16
- cmp r0, 0x7
- bgt _08087D1A
- lsls r0, r1, 1
- strh r0, [r4, 0xE]
-_08087D1A:
- movs r1, 0x10
- ldrsh r0, [r4, r1]
- cmp r0, 0x8
- ble _08087D48
- ldrb r1, [r5, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r1
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r5, 0x5]
- adds r2, r5, 0
- adds r2, 0x42
- ldrb r1, [r2]
- movs r0, 0xC0
- ands r0, r1
- cmp r0, 0
- beq _08087D48
- movs r0, 0x3F
- ands r0, r1
- movs r1, 0x80
- orrs r0, r1
- strb r0, [r2]
-_08087D48:
- movs r2, 0x10
- ldrsh r0, [r4, r2]
- cmp r0, 0xA7
- ble _08087D5E
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- bl sub_8053FF8
- bl fade_8080918
-_08087D5E:
- add sp, 0x8
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08087D68: .4byte gUnknown_0839F380
-_08087D6C: .4byte gPlayerAvatar
-_08087D70: .4byte gMapObjects
-_08087D74: .4byte gSprites
- thumb_func_end sub_8087CA4
-
- thumb_func_start sub_8087D78
-sub_8087D78: @ 8087D78
- push {lr}
- ldr r0, _08087DB8 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08087DB4
- bl sub_8054034
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _08087DB4
- bl sub_8053570
- bl warp_in
- ldr r0, _08087DBC @ =CB2_LoadMap
- bl SetMainCallback2
- ldr r1, _08087DC0 @ =gUnknown_0300485C
- ldr r0, _08087DC4 @ =mapldr_08085D88
- str r0, [r1]
- ldr r0, _08087DC8 @ =sub_8087BBC
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08087DB4:
- pop {r0}
- bx r0
- .align 2, 0
-_08087DB8: .4byte gPaletteFade
-_08087DBC: .4byte CB2_LoadMap
-_08087DC0: .4byte gUnknown_0300485C
-_08087DC4: .4byte mapldr_08085D88
-_08087DC8: .4byte sub_8087BBC
- thumb_func_end sub_8087D78
-
- thumb_func_start mapldr_08085D88
-mapldr_08085D88: @ 8087DCC
- push {lr}
- bl sub_8053E90
- bl pal_fill_for_map_transition
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r1, _08087E0C @ =gUnknown_0300485C
- movs r0, 0
- str r0, [r1]
- ldr r2, _08087E10 @ =gMapObjects
- ldr r0, _08087E14 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x1]
- movs r2, 0x20
- orrs r1, r2
- strb r1, [r0, 0x1]
- bl CameraObjectReset2
- ldr r0, _08087E18 @ =sub_8087E1C
- movs r1, 0
- bl CreateTask
- pop {r0}
- bx r0
- .align 2, 0
-_08087E0C: .4byte gUnknown_0300485C
-_08087E10: .4byte gMapObjects
-_08087E14: .4byte gPlayerAvatar
-_08087E18: .4byte sub_8087E1C
- thumb_func_end mapldr_08085D88
-
- thumb_func_start sub_8087E1C
-sub_8087E1C: @ 8087E1C
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08087E44 @ =gUnknown_0839F3A0
- ldr r2, _08087E48 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08087E44: .4byte gUnknown_0839F3A0
-_08087E48: .4byte gTasks
- thumb_func_end sub_8087E1C
-
- thumb_func_start sub_8087E4C
-sub_8087E4C: @ 8087E4C
- push {r4-r6,lr}
- adds r6, r0, 0
- bl sub_807D770
- lsls r0, 24
- cmp r0, 0
- beq _08087EC2
- ldr r5, _08087EC8 @ =gPlayerAvatar
- ldrb r0, [r5, 0x4]
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r0, _08087ECC @ =gSprites
- adds r2, r0
- adds r0, r2, 0
- adds r0, 0x29
- movs r4, 0
- ldrsb r4, [r0, r4]
- lsls r0, r4, 17
- negs r0, r0
- ldrh r1, [r2, 0x22]
- ldr r3, _08087ED0 @ =gSpriteCoordOffsetY
- adds r1, r4
- ldrh r3, [r3]
- adds r1, r3
- asrs r0, 16
- adds r0, r1
- negs r0, r0
- strh r0, [r2, 0x26]
- ldr r3, _08087ED4 @ =gMapObjects
- ldrb r0, [r5, 0x5]
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- adds r1, r3
- ldrb r3, [r1, 0x1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r3
- strb r0, [r1, 0x1]
- ldrh r0, [r6, 0x8]
- adds r0, 0x1
- strh r0, [r6, 0x8]
- movs r0, 0x8
- strh r0, [r6, 0xA]
- movs r0, 0x1
- strh r0, [r6, 0xC]
- adds r2, 0x42
- ldrb r0, [r2]
- lsrs r0, 6
- strh r0, [r6, 0x24]
- bl player_get_direction_lower_nybble
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r6, 0x26]
- movs r0, 0x2D
- bl PlaySE
-_08087EC2:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08087EC8: .4byte gPlayerAvatar
-_08087ECC: .4byte gSprites
-_08087ED0: .4byte gSpriteCoordOffsetY
-_08087ED4: .4byte gMapObjects
- thumb_func_end sub_8087E4C
-
- thumb_func_start sub_8087ED8
-sub_8087ED8: @ 8087ED8
- push {r4-r7,lr}
- sub sp, 0x8
- adds r4, r0, 0
- ldr r1, _08087F40 @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldr r2, _08087F44 @ =gPlayerAvatar
- ldrb r1, [r2, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087F48 @ =gMapObjects
- adds r6, r0, r1
- ldrb r1, [r2, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08087F4C @ =gSprites
- adds r5, r0, r1
- ldrh r0, [r4, 0xA]
- ldrh r1, [r5, 0x26]
- adds r0, r1
- strh r0, [r5, 0x26]
- lsls r0, 16
- asrs r0, 16
- movs r1, 0x8
- negs r1, r1
- cmp r0, r1
- blt _08087F50
- ldrh r1, [r4, 0x22]
- movs r2, 0x22
- ldrsh r0, [r4, r2]
- cmp r0, 0
- bne _08087F76
- adds r0, r1, 0x1
- strh r0, [r4, 0x22]
- ldrb r0, [r6]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r6]
- ldrh r1, [r4, 0x24]
- adds r3, r5, 0
- adds r3, 0x42
- lsls r1, 6
- ldrb r2, [r3]
- movs r0, 0x3F
- ands r0, r2
- orrs r0, r1
- strb r0, [r3]
- b _08087F76
- .align 2, 0
-_08087F40: .4byte gUnknown_0839F380
-_08087F44: .4byte gPlayerAvatar
-_08087F48: .4byte gMapObjects
-_08087F4C: .4byte gSprites
-_08087F50:
- ldrb r1, [r5, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r1
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r5, 0x5]
- adds r2, r5, 0
- adds r2, 0x42
- ldrb r1, [r2]
- movs r0, 0xC0
- ands r0, r1
- cmp r0, 0
- beq _08087F76
- movs r0, 0x3F
- ands r0, r1
- movs r1, 0x80
- orrs r0, r1
- strb r0, [r2]
-_08087F76:
- ldrh r2, [r5, 0x26]
- movs r3, 0x26
- ldrsh r1, [r5, r3]
- movs r0, 0x30
- negs r0, r0
- cmp r1, r0
- blt _08087F9A
- ldrh r1, [r4, 0xA]
- movs r3, 0xA
- ldrsh r0, [r4, r3]
- cmp r0, 0x1
- ble _08087F9A
- movs r0, 0x1
- ands r0, r2
- cmp r0, 0
- bne _08087F9A
- subs r0, r1, 0x1
- strh r0, [r4, 0xA]
-_08087F9A:
- ldrh r0, [r4, 0xC]
- subs r0, 0x1
- movs r7, 0
- strh r0, [r4, 0xC]
- lsls r0, 16
- cmp r0, 0
- bne _08087FBC
- movs r0, 0x4
- strh r0, [r4, 0xC]
- ldrb r0, [r6, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r1, [r0]
- adds r0, r6, 0
- bl FieldObjectTurn
-_08087FBC:
- movs r1, 0x26
- ldrsh r0, [r5, r1]
- cmp r0, 0
- blt _08087FD2
- strh r7, [r5, 0x26]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x1
- strh r0, [r4, 0xA]
- strh r7, [r4, 0xC]
-_08087FD2:
- add sp, 0x8
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8087ED8
-
- thumb_func_start sub_8087FDC
-sub_8087FDC: @ 8087FDC
- push {r4,r5,lr}
- sub sp, 0x8
- adds r4, r0, 0
- ldr r1, _08088058 @ =gUnknown_0839F380
- mov r0, sp
- movs r2, 0x5
- bl memcpy
- ldr r0, _0808805C @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088060 @ =gMapObjects
- adds r5, r0, r1
- ldrh r0, [r4, 0xA]
- subs r0, 0x1
- strh r0, [r4, 0xA]
- lsls r0, 16
- cmp r0, 0
- bne _08088050
- ldrb r0, [r5, 0x18]
- lsls r0, 28
- lsrs r0, 28
- add r0, sp
- ldrb r1, [r0]
- adds r0, r5, 0
- bl FieldObjectTurn
- movs r0, 0x8
- strh r0, [r4, 0xA]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x4
- ble _08088050
- movs r0, 0x24
- ldrsh r1, [r4, r0]
- ldrb r0, [r5, 0x18]
- lsls r0, 28
- lsrs r0, 28
- cmp r1, r0
- bne _08088050
- bl ScriptContext2_Disable
- bl CameraObjectReset1
- bl UnfreezeMapObjects
- ldr r0, _08088064 @ =sub_8087E1C
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08088050:
- add sp, 0x8
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088058: .4byte gUnknown_0839F380
-_0808805C: .4byte gPlayerAvatar
-_08088060: .4byte gMapObjects
-_08088064: .4byte sub_8087E1C
- thumb_func_end sub_8087FDC
-
- thumb_func_start FldEff_FieldMoveShowMon
-FldEff_FieldMoveShowMon: @ 8088068
- push {r4,lr}
- bl sav1_map_get_light_level
- lsls r0, 24
- lsrs r0, 24
- bl is_light_level_1_2_3_5_or_6
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _08088088
- ldr r0, _08088084 @ =sub_8088120
- b _0808808A
- .align 2, 0
-_08088084: .4byte sub_8088120
-_08088088:
- ldr r0, _080880B8 @ =sub_808847C
-_0808808A:
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r2, _080880BC @ =gUnknown_0202FF84
- ldr r0, [r2]
- ldr r1, [r2, 0x4]
- ldr r2, [r2, 0x8]
- bl sub_8088830
- ldr r2, _080880C0 @ =gTasks
- lsls r1, r4, 2
- adds r1, r4
- lsls r1, 3
- adds r1, r2
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r1, 0x26]
- movs r0, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_080880B8: .4byte sub_808847C
-_080880BC: .4byte gUnknown_0202FF84
-_080880C0: .4byte gTasks
- thumb_func_end FldEff_FieldMoveShowMon
-
- thumb_func_start FldEff_FieldMoveShowMonInit
-FldEff_FieldMoveShowMonInit: @ 80880C4
- push {r4-r6,lr}
- ldr r5, _08088118 @ =gUnknown_0202FF84
- ldr r0, [r5]
- movs r6, 0x80
- lsls r6, 24
- ands r6, r0
- lsls r0, 24
- lsrs r0, 24
- movs r1, 0x64
- adds r4, r0, 0
- muls r4, r1
- ldr r0, _0808811C @ =gPlayerParty
- adds r4, r0
- adds r0, r4, 0
- movs r1, 0xB
- bl GetMonData
- str r0, [r5]
- adds r0, r4, 0
- movs r1, 0x1
- bl GetMonData
- str r0, [r5, 0x4]
- adds r0, r4, 0
- movs r1, 0
- bl GetMonData
- str r0, [r5, 0x8]
- ldr r0, [r5]
- orrs r0, r6
- str r0, [r5]
- movs r0, 0x6
- bl FieldEffectStart
- movs r0, 0x3B
- bl FieldEffectActiveListRemove
- movs r0, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08088118: .4byte gUnknown_0202FF84
-_0808811C: .4byte gPlayerParty
- thumb_func_end FldEff_FieldMoveShowMonInit
-
- thumb_func_start sub_8088120
-sub_8088120: @ 8088120
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08088148 @ =gUnknown_0839F3AC
- ldr r2, _0808814C @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08088148: .4byte gUnknown_0839F3AC
-_0808814C: .4byte gTasks
- thumb_func_end sub_8088120
-
- thumb_func_start sub_8088150
-sub_8088150: @ 8088150
- push {r4-r6,lr}
- adds r4, r0, 0
- ldr r6, _080881A0 @ =REG_WININ
- ldrh r0, [r6]
- strh r0, [r4, 0x1E]
- ldr r5, _080881A4 @ =REG_WINOUT
- ldrh r0, [r5]
- strh r0, [r4, 0x20]
- adds r0, r4, 0
- adds r0, 0x22
- ldr r1, _080881A8 @ =gMain
- ldr r1, [r1, 0xC]
- bl StoreWordInTwoHalfwords
- ldr r1, _080881AC @ =0x0000f0f1
- strh r1, [r4, 0xA]
- ldr r0, _080881B0 @ =0x00005051
- strh r0, [r4, 0xC]
- movs r0, 0x3F
- strh r0, [r4, 0xE]
- movs r0, 0x3E
- strh r0, [r4, 0x10]
- ldr r0, _080881B4 @ =REG_WIN0H
- strh r1, [r0]
- ldr r1, _080881B8 @ =REG_WIN0V
- ldrh r0, [r4, 0xC]
- strh r0, [r1]
- ldrh r0, [r4, 0xE]
- strh r0, [r6]
- ldrh r0, [r4, 0x10]
- strh r0, [r5]
- ldr r0, _080881BC @ =sub_80883DC
- bl SetVBlankCallback
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080881A0: .4byte REG_WININ
-_080881A4: .4byte REG_WINOUT
-_080881A8: .4byte gMain
-_080881AC: .4byte 0x0000f0f1
-_080881B0: .4byte 0x00005051
-_080881B4: .4byte REG_WIN0H
-_080881B8: .4byte REG_WIN0V
-_080881BC: .4byte sub_80883DC
- thumb_func_end sub_8088150
-
- thumb_func_start sub_80881C0
-sub_80881C0: @ 80881C0
- push {r4-r6,lr}
- sub sp, 0x4
- adds r6, r0, 0
- ldr r0, _08088218 @ =REG_BG0CNT
- ldrh r1, [r0]
- lsrs r1, 2
- lsls r1, 30
- lsrs r1, 16
- ldrh r4, [r0]
- lsrs r4, 8
- lsls r4, 27
- lsrs r4, 16
- ldr r0, _0808821C @ =gFieldMoveStreaksTiles
- movs r5, 0xC0
- lsls r5, 19
- adds r1, r5
- movs r2, 0x80
- lsls r2, 1
- bl CpuSet
- movs r0, 0
- str r0, [sp]
- adds r5, r4, r5
- ldr r2, _08088220 @ =0x05000200
- mov r0, sp
- adds r1, r5, 0
- bl CpuSet
- ldr r0, _08088224 @ =gFieldMoveStreaksPalette
- movs r1, 0xF0
- movs r2, 0x20
- bl LoadPalette
- adds r0, r4, 0
- bl sub_808843C
- ldrh r0, [r6, 0x8]
- adds r0, 0x1
- strh r0, [r6, 0x8]
- add sp, 0x4
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08088218: .4byte REG_BG0CNT
-_0808821C: .4byte gFieldMoveStreaksTiles
-_08088220: .4byte 0x05000200
-_08088224: .4byte gFieldMoveStreaksPalette
- thumb_func_end sub_80881C0
-
- thumb_func_start sub_8088228
-sub_8088228: @ 8088228
- push {r4-r7,lr}
- adds r3, r0, 0
- ldrh r0, [r3, 0x12]
- subs r0, 0x10
- strh r0, [r3, 0x12]
- ldrh r6, [r3, 0xA]
- ldrh r2, [r3, 0xC]
- movs r7, 0xFF
- lsrs r1, r6, 8
- subs r1, 0x10
- lsls r1, 16
- lsrs r0, r2, 8
- subs r0, 0x2
- lsls r0, 16
- lsrs r4, r0, 16
- adds r0, r7, 0
- ands r0, r2
- adds r5, r0, 0x2
- lsrs r2, r1, 16
- cmp r1, 0
- bge _08088254
- movs r2, 0
-_08088254:
- lsls r0, r4, 16
- asrs r0, 16
- cmp r0, 0x27
- bgt _0808825E
- movs r4, 0x28
-_0808825E:
- cmp r5, 0x78
- ble _08088264
- movs r5, 0x78
-_08088264:
- lsls r2, 16
- asrs r2, 16
- lsls r1, r2, 8
- adds r0, r7, 0
- ands r0, r6
- orrs r1, r0
- strh r1, [r3, 0xA]
- lsls r0, r4, 16
- asrs r4, r0, 16
- lsls r0, r4, 8
- adds r1, r5, 0
- orrs r0, r1
- strh r0, [r3, 0xC]
- cmp r2, 0
- bne _080882A4
- cmp r4, 0x28
- bne _080882A4
- cmp r1, 0x78
- bne _080882A4
- ldr r2, _080882AC @ =gSprites
- movs r0, 0x26
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _080882B0 @ =sub_8088890
- str r1, [r0]
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_080882A4:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080882AC: .4byte gSprites
-_080882B0: .4byte sub_8088890
- thumb_func_end sub_8088228
-
- thumb_func_start sub_80882B4
-sub_80882B4: @ 80882B4
- push {lr}
- adds r3, r0, 0
- ldrh r0, [r3, 0x12]
- subs r0, 0x10
- strh r0, [r3, 0x12]
- ldr r2, _080882E0 @ =gSprites
- movs r0, 0x26
- ldrsh r1, [r3, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x3C
- ldrsh r0, [r0, r1]
- cmp r0, 0
- beq _080882DA
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_080882DA:
- pop {r0}
- bx r0
- .align 2, 0
-_080882E0: .4byte gSprites
- thumb_func_end sub_80882B4
-
- thumb_func_start sub_80882E4
-sub_80882E4: @ 80882E4
- push {r4,lr}
- adds r3, r0, 0
- ldrh r0, [r3, 0x12]
- subs r0, 0x10
- strh r0, [r3, 0x12]
- ldrh r2, [r3, 0xC]
- lsls r1, r2, 16
- movs r0, 0xFF
- asrs r1, 24
- adds r1, 0x6
- lsls r1, 16
- ands r0, r2
- subs r0, 0x6
- lsls r0, 16
- lsrs r2, r0, 16
- lsrs r4, r1, 16
- asrs r1, 16
- cmp r1, 0x50
- ble _0808830C
- movs r4, 0x50
-_0808830C:
- lsls r0, r2, 16
- asrs r0, 16
- cmp r0, 0x50
- bgt _08088316
- movs r2, 0x51
-_08088316:
- lsls r0, r4, 16
- asrs r0, 16
- lsls r1, r0, 8
- lsls r2, 16
- asrs r2, 16
- orrs r1, r2
- strh r1, [r3, 0xC]
- cmp r0, 0x50
- bne _08088332
- cmp r2, 0x51
- bne _08088332
- ldrh r0, [r3, 0x8]
- adds r0, 0x1
- strh r0, [r3, 0x8]
-_08088332:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_80882E4
-
- thumb_func_start sub_8088338
-sub_8088338: @ 8088338
- push {r4,lr}
- sub sp, 0x4
- adds r4, r0, 0
- ldr r0, _08088378 @ =REG_BG0CNT
- ldrh r1, [r0]
- lsrs r1, 8
- lsls r1, 27
- lsrs r1, 16
- movs r0, 0
- str r0, [sp]
- movs r0, 0xC0
- lsls r0, 19
- adds r1, r0
- ldr r2, _0808837C @ =0x05000200
- mov r0, sp
- bl CpuSet
- movs r0, 0xF1
- strh r0, [r4, 0xA]
- movs r0, 0xA1
- strh r0, [r4, 0xC]
- ldrh r0, [r4, 0x1E]
- strh r0, [r4, 0xE]
- ldrh r0, [r4, 0x20]
- strh r0, [r4, 0x10]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- add sp, 0x4
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088378: .4byte REG_BG0CNT
-_0808837C: .4byte 0x05000200
- thumb_func_end sub_8088338
-
- thumb_func_start sub_8088380
-sub_8088380: @ 8088380
- push {r4,r5,lr}
- sub sp, 0x4
- adds r5, r0, 0
- adds r0, 0x22
- mov r1, sp
- bl LoadWordFromTwoHalfwords
- ldr r0, [sp]
- bl SetVBlankCallback
- ldr r4, _080883D0 @ =gWindowConfig_81E6CE4
- adds r0, r4, 0
- bl SetUpWindowConfig
- adds r0, r4, 0
- bl InitMenuWindow
- movs r0, 0x26
- ldrsh r1, [r5, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _080883D4 @ =gSprites
- adds r0, r1
- bl FreeResourcesAndDestroySprite
- movs r0, 0x6
- bl FieldEffectActiveListRemove
- ldr r0, _080883D8 @ =sub_8088120
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- add sp, 0x4
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080883D0: .4byte gWindowConfig_81E6CE4
-_080883D4: .4byte gSprites
-_080883D8: .4byte sub_8088120
- thumb_func_end sub_8088380
-
- thumb_func_start sub_80883DC
-sub_80883DC: @ 80883DC
- push {r4,lr}
- sub sp, 0x4
- ldr r0, _08088430 @ =sub_8088120
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- lsls r4, r0, 2
- adds r4, r0
- lsls r4, 3
- ldr r0, _08088434 @ =gTasks
- adds r4, r0
- adds r0, r4, 0
- adds r0, 0x22
- mov r1, sp
- bl LoadWordFromTwoHalfwords
- ldr r0, [sp]
- bl _call_via_r0
- ldr r1, _08088438 @ =REG_WIN0H
- ldrh r0, [r4, 0xA]
- strh r0, [r1]
- adds r1, 0x4
- ldrh r0, [r4, 0xC]
- strh r0, [r1]
- adds r1, 0x4
- ldrh r0, [r4, 0xE]
- strh r0, [r1]
- adds r1, 0x2
- ldrh r0, [r4, 0x10]
- strh r0, [r1]
- subs r1, 0x3A
- ldrh r0, [r4, 0x12]
- strh r0, [r1]
- adds r1, 0x2
- ldrh r0, [r4, 0x14]
- strh r0, [r1]
- add sp, 0x4
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088430: .4byte sub_8088120
-_08088434: .4byte gTasks
-_08088438: .4byte REG_WIN0H
- thumb_func_end sub_80883DC
-
- thumb_func_start sub_808843C
-sub_808843C: @ 808843C
- push {r4,r5,lr}
- lsls r0, 16
- lsrs r0, 16
- ldr r1, _08088470 @ =0x06000140
- adds r2, r0, r1
- movs r1, 0
- ldr r5, _08088474 @ =gFieldMoveStreaksTilemap
- movs r0, 0xF0
- lsls r0, 8
- adds r4, r0, 0
- ldr r3, _08088478 @ =0x0000013f
-_08088452:
- lsls r0, r1, 1
- adds r0, r5
- ldrh r0, [r0]
- orrs r0, r4
- strh r0, [r2]
- adds r0, r1, 0x1
- lsls r0, 16
- lsrs r1, r0, 16
- adds r2, 0x2
- cmp r1, r3
- bls _08088452
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088470: .4byte 0x06000140
-_08088474: .4byte gFieldMoveStreaksTilemap
-_08088478: .4byte 0x0000013f
- thumb_func_end sub_808843C
-
- thumb_func_start sub_808847C
-sub_808847C: @ 808847C
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _080884A4 @ =gUnknown_0839F3C8
- ldr r2, _080884A8 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_080884A4: .4byte gUnknown_0839F3C8
-_080884A8: .4byte gTasks
- thumb_func_end sub_808847C
-
- thumb_func_start sub_80884AC
-sub_80884AC: @ 80884AC
- push {r4,lr}
- adds r4, r0, 0
- ldr r1, _080884DC @ =REG_BG0HOFS
- ldrh r0, [r4, 0xA]
- strh r0, [r1]
- adds r1, 0x2
- ldrh r0, [r4, 0xC]
- strh r0, [r1]
- adds r0, r4, 0
- adds r0, 0x22
- ldr r1, _080884E0 @ =gMain
- ldr r1, [r1, 0xC]
- bl StoreWordInTwoHalfwords
- ldr r0, _080884E4 @ =sub_80886B0
- bl SetVBlankCallback
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080884DC: .4byte REG_BG0HOFS
-_080884E0: .4byte gMain
-_080884E4: .4byte sub_80886B0
- thumb_func_end sub_80884AC
-
- thumb_func_start sub_80884E8
-sub_80884E8: @ 80884E8
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- sub sp, 0x4
- adds r6, r0, 0
- ldr r0, _08088544 @ =REG_BG0CNT
- ldrh r1, [r0]
- lsrs r1, 2
- lsls r1, 30
- lsrs r1, 16
- ldrh r4, [r0]
- lsrs r4, 8
- lsls r4, 27
- lsrs r4, 16
- movs r0, 0
- mov r8, r0
- strh r4, [r6, 0x20]
- ldr r0, _08088548 @ =gDarknessFieldMoveStreaksTiles
- movs r5, 0xC0
- lsls r5, 19
- adds r1, r5
- movs r2, 0x40
- bl CpuSet
- mov r0, r8
- str r0, [sp]
- adds r4, r5
- ldr r2, _0808854C @ =0x05000200
- mov r0, sp
- adds r1, r4, 0
- bl CpuSet
- ldr r0, _08088550 @ =gDarknessFieldMoveStreaksPalette
- movs r1, 0xF0
- movs r2, 0x20
- bl LoadPalette
- ldrh r0, [r6, 0x8]
- adds r0, 0x1
- strh r0, [r6, 0x8]
- add sp, 0x4
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08088544: .4byte REG_BG0CNT
-_08088548: .4byte gDarknessFieldMoveStreaksTiles
-_0808854C: .4byte 0x05000200
-_08088550: .4byte gDarknessFieldMoveStreaksPalette
- thumb_func_end sub_80884E8
-
- thumb_func_start sub_8088554
-sub_8088554: @ 8088554
- push {r4,lr}
- adds r4, r0, 0
- bl sub_8088708
- lsls r0, 24
- cmp r0, 0
- beq _0808858A
- ldr r1, _08088598 @ =REG_WIN1H
- movs r0, 0xF0
- strh r0, [r1]
- adds r1, 0x4
- ldr r2, _0808859C @ =0x00002878
- adds r0, r2, 0
- strh r0, [r1]
- ldr r2, _080885A0 @ =gSprites
- movs r0, 0x26
- ldrsh r1, [r4, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _080885A4 @ =sub_8088890
- str r1, [r0]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_0808858A:
- adds r0, r4, 0
- bl sub_80886F8
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088598: .4byte REG_WIN1H
-_0808859C: .4byte 0x00002878
-_080885A0: .4byte gSprites
-_080885A4: .4byte sub_8088890
- thumb_func_end sub_8088554
-
- thumb_func_start sub_80885A8
-sub_80885A8: @ 80885A8
- push {r4,lr}
- adds r4, r0, 0
- bl sub_80886F8
- ldr r2, _080885D4 @ =gSprites
- movs r0, 0x26
- ldrsh r1, [r4, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- movs r1, 0x3C
- ldrsh r0, [r0, r1]
- cmp r0, 0
- beq _080885CC
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_080885CC:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080885D4: .4byte gSprites
- thumb_func_end sub_80885A8
-
- thumb_func_start sub_80885D8
-sub_80885D8: @ 80885D8
- push {r4,lr}
- adds r4, r0, 0
- bl sub_80886F8
- ldrh r1, [r4, 0xA]
- movs r0, 0x7
- ands r0, r1
- movs r1, 0
- strh r0, [r4, 0xE]
- strh r1, [r4, 0x10]
- ldr r0, _08088604 @ =REG_WIN1H
- ldr r2, _08088608 @ =0x0000ffff
- adds r1, r2, 0
- strh r1, [r0]
- adds r0, 0x4
- strh r1, [r0]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088604: .4byte REG_WIN1H
-_08088608: .4byte 0x0000ffff
- thumb_func_end sub_80885D8
-
- thumb_func_start sub_808860C
-sub_808860C: @ 808860C
- push {r4,lr}
- adds r4, r0, 0
- bl sub_80886F8
- adds r0, r4, 0
- bl sub_80887C0
- lsls r0, 24
- cmp r0, 0
- beq _08088626
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08088626:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_808860C
-
- thumb_func_start sub_808862C
-sub_808862C: @ 808862C
- push {r4,r5,lr}
- sub sp, 0x8
- adds r5, r0, 0
- ldr r0, _0808869C @ =REG_BG0CNT
- ldrh r1, [r0]
- lsrs r1, 8
- lsls r1, 27
- lsrs r1, 16
- movs r0, 0
- str r0, [sp]
- movs r0, 0xC0
- lsls r0, 19
- adds r1, r0
- ldr r2, _080886A0 @ =0x05000200
- mov r0, sp
- bl CpuSet
- adds r0, r5, 0
- adds r0, 0x22
- add r1, sp, 0x4
- bl LoadWordFromTwoHalfwords
- ldr r0, [sp, 0x4]
- bl SetVBlankCallback
- ldr r4, _080886A4 @ =gWindowConfig_81E6CE4
- adds r0, r4, 0
- bl SetUpWindowConfig
- adds r0, r4, 0
- bl InitMenuWindow
- movs r0, 0x26
- ldrsh r1, [r5, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _080886A8 @ =gSprites
- adds r0, r1
- bl FreeResourcesAndDestroySprite
- movs r0, 0x6
- bl FieldEffectActiveListRemove
- ldr r0, _080886AC @ =sub_808847C
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
- add sp, 0x8
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_0808869C: .4byte REG_BG0CNT
-_080886A0: .4byte 0x05000200
-_080886A4: .4byte gWindowConfig_81E6CE4
-_080886A8: .4byte gSprites
-_080886AC: .4byte sub_808847C
- thumb_func_end sub_808862C
-
- thumb_func_start sub_80886B0
-sub_80886B0: @ 80886B0
- push {r4,lr}
- sub sp, 0x4
- ldr r0, _080886EC @ =sub_808847C
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- lsls r4, r0, 2
- adds r4, r0
- lsls r4, 3
- ldr r0, _080886F0 @ =gTasks
- adds r4, r0
- adds r0, r4, 0
- adds r0, 0x22
- mov r1, sp
- bl LoadWordFromTwoHalfwords
- ldr r0, [sp]
- bl _call_via_r0
- ldr r1, _080886F4 @ =REG_BG0HOFS
- ldrh r0, [r4, 0xA]
- strh r0, [r1]
- adds r1, 0x2
- ldrh r0, [r4, 0xC]
- strh r0, [r1]
- add sp, 0x4
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080886EC: .4byte sub_808847C
-_080886F0: .4byte gTasks
-_080886F4: .4byte REG_BG0HOFS
- thumb_func_end sub_80886B0
-
- thumb_func_start sub_80886F8
-sub_80886F8: @ 80886F8
- ldrh r1, [r0, 0xA]
- subs r1, 0x10
- strh r1, [r0, 0xA]
- ldrh r1, [r0, 0xE]
- adds r1, 0x10
- strh r1, [r0, 0xE]
- bx lr
- thumb_func_end sub_80886F8
-
- thumb_func_start sub_8088708
-sub_8088708: @ 8088708
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x4
- adds r5, r0, 0
- ldrh r2, [r5, 0x10]
- movs r1, 0x10
- ldrsh r0, [r5, r1]
- cmp r0, 0x1F
- ble _08088724
- movs r0, 0x1
- b _080887A8
-_08088724:
- ldrh r0, [r5, 0xE]
- lsls r0, 16
- asrs r3, r0, 19
- movs r1, 0x1F
- ands r3, r1
- movs r4, 0x10
- ldrsh r0, [r5, r4]
- cmp r3, r0
- blt _080887A6
- movs r0, 0x20
- subs r3, r0, r3
- ands r3, r1
- subs r0, r2
- mov r12, r0
- mov r7, r12
- ands r7, r1
- mov r12, r7
- ldrh r0, [r5, 0x20]
- ldr r1, _080887B8 @ =0x06000140
- adds r1, r0
- mov r8, r1
- movs r4, 0
- ldr r7, _080887BC @ =gDarknessFieldMoveStreaksTilemap
- mov r10, r7
- movs r0, 0xF0
- lsls r0, 8
- mov r9, r0
- adds r1, r3, 0x1
- movs r0, 0x1F
- ands r1, r0
- str r1, [sp]
- mov r6, r12
- adds r6, 0x1
- ands r6, r0
-_08088768:
- lsls r1, r4, 5
- adds r2, r1, r3
- lsls r2, 1
- add r2, r8
- mov r7, r12
- adds r0, r7, r1
- lsls r0, 1
- add r0, r10
- ldrh r0, [r0]
- mov r7, r9
- orrs r0, r7
- strh r0, [r2]
- ldr r0, [sp]
- adds r2, r1, r0
- lsls r2, 1
- add r2, r8
- adds r1, r6, r1
- lsls r1, 1
- add r1, r10
- ldrh r0, [r1]
- mov r1, r9
- orrs r0, r1
- strh r0, [r2]
- adds r0, r4, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- cmp r4, 0x9
- bls _08088768
- ldrh r0, [r5, 0x10]
- adds r0, 0x2
- strh r0, [r5, 0x10]
-_080887A6:
- movs r0, 0
-_080887A8:
- add sp, 0x4
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_080887B8: .4byte 0x06000140
-_080887BC: .4byte gDarknessFieldMoveStreaksTilemap
- thumb_func_end sub_8088708
-
- thumb_func_start sub_80887C0
-sub_80887C0: @ 80887C0
- push {r4-r7,lr}
- adds r5, r0, 0
- movs r1, 0x10
- ldrsh r0, [r5, r1]
- cmp r0, 0x1F
- ble _080887D0
- movs r0, 0x1
- b _08088824
-_080887D0:
- ldrh r0, [r5, 0xE]
- lsls r0, 16
- asrs r0, 19
- lsls r0, 16
- lsrs r2, r0, 16
- movs r1, 0x10
- ldrsh r0, [r5, r1]
- cmp r2, r0
- blt _08088822
- ldrh r0, [r5, 0xA]
- lsls r0, 16
- asrs r2, r0, 19
- movs r0, 0x1F
- ands r2, r0
- ldrh r0, [r5, 0x20]
- ldr r1, _0808882C @ =0x06000140
- adds r6, r0, r1
- movs r3, 0
- movs r0, 0xF0
- lsls r0, 8
- adds r7, r0, 0
- adds r4, r2, 0x1
- movs r0, 0x1F
- ands r4, r0
-_08088800:
- lsls r0, r3, 5
- adds r1, r0, r2
- lsls r1, 1
- adds r1, r6
- strh r7, [r1]
- adds r0, r4
- lsls r0, 1
- adds r0, r6
- strh r7, [r0]
- adds r0, r3, 0x1
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0x9
- bls _08088800
- ldrh r0, [r5, 0x10]
- adds r0, 0x2
- strh r0, [r5, 0x10]
-_08088822:
- movs r0, 0
-_08088824:
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_0808882C: .4byte 0x06000140
- thumb_func_end sub_80887C0
-
- thumb_func_start sub_8088830
-sub_8088830: @ 8088830
- push {r4-r6,lr}
- sub sp, 0x8
- adds r6, r0, 0
- movs r5, 0x80
- lsls r5, 24
- ands r5, r6
- lsrs r5, 16
- lsls r5, 16
- lsrs r5, 16
- ldr r0, _08088884 @ =0x7fffffff
- ands r6, r0
- lsls r0, r6, 16
- lsrs r0, 16
- movs r3, 0xA0
- lsls r3, 1
- movs r4, 0x50
- str r4, [sp]
- movs r4, 0
- str r4, [sp, 0x4]
- bl CreateMonSprite_FieldMove
- lsls r0, 24
- lsrs r0, 24
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r1, _08088888 @ =gSprites
- adds r2, r1
- ldr r1, _0808888C @ =SpriteCallbackDummy
- str r1, [r2, 0x1C]
- ldrb r3, [r2, 0x5]
- movs r1, 0xD
- negs r1, r1
- ands r1, r3
- strb r1, [r2, 0x5]
- strh r6, [r2, 0x2E]
- strh r5, [r2, 0x3A]
- add sp, 0x8
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08088884: .4byte 0x7fffffff
-_08088888: .4byte gSprites
-_0808888C: .4byte SpriteCallbackDummy
- thumb_func_end sub_8088830
-
- thumb_func_start sub_8088890
-sub_8088890: @ 8088890
- push {lr}
- adds r1, r0, 0
- ldrh r0, [r1, 0x20]
- subs r0, 0x14
- strh r0, [r1, 0x20]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x78
- bgt _080888D0
- movs r0, 0x78
- strh r0, [r1, 0x20]
- movs r0, 0x1E
- strh r0, [r1, 0x30]
- ldr r0, _080888C4 @ =sub_80888D4
- str r0, [r1, 0x1C]
- movs r2, 0x3A
- ldrsh r0, [r1, r2]
- cmp r0, 0
- beq _080888C8
- ldrh r0, [r1, 0x2E]
- movs r1, 0
- movs r2, 0x7D
- movs r3, 0xA
- bl PlayCry2
- b _080888D0
- .align 2, 0
-_080888C4: .4byte sub_80888D4
-_080888C8:
- ldrh r0, [r1, 0x2E]
- movs r1, 0
- bl PlayCry1
-_080888D0:
- pop {r0}
- bx r0
- thumb_func_end sub_8088890
-
- thumb_func_start sub_80888D4
-sub_80888D4: @ 80888D4
- push {lr}
- adds r1, r0, 0
- ldrh r0, [r1, 0x30]
- subs r0, 0x1
- strh r0, [r1, 0x30]
- lsls r0, 16
- cmp r0, 0
- bne _080888E8
- ldr r0, _080888EC @ =sub_80888F0
- str r0, [r1, 0x1C]
-_080888E8:
- pop {r0}
- bx r0
- .align 2, 0
-_080888EC: .4byte sub_80888F0
- thumb_func_end sub_80888D4
-
- thumb_func_start sub_80888F0
-sub_80888F0: @ 80888F0
- push {lr}
- adds r2, r0, 0
- ldrh r3, [r2, 0x20]
- movs r0, 0x20
- ldrsh r1, [r2, r0]
- movs r0, 0x40
- negs r0, r0
- cmp r1, r0
- bge _08088908
- movs r0, 0x1
- strh r0, [r2, 0x3C]
- b _0808890E
-_08088908:
- adds r0, r3, 0
- subs r0, 0x14
- strh r0, [r2, 0x20]
-_0808890E:
- pop {r0}
- bx r0
- thumb_func_end sub_80888F0
-
- thumb_func_start FldEff_UseSurf
-FldEff_UseSurf: @ 8088914
- push {lr}
- ldr r0, _08088944 @ =sub_8088954
- movs r1, 0xFF
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08088948 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- ldr r0, _0808894C @ =gUnknown_0202FF84
- ldr r0, [r0]
- strh r0, [r1, 0x26]
- bl sav1_reset_battle_music_maybe
- ldr r0, _08088950 @ =0x0000016d
- bl sub_8053FB0
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08088944: .4byte sub_8088954
-_08088948: .4byte gTasks
-_0808894C: .4byte gUnknown_0202FF84
-_08088950: .4byte 0x0000016d
- thumb_func_end FldEff_UseSurf
-
- thumb_func_start sub_8088954
-sub_8088954: @ 8088954
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _0808897C @ =gUnknown_0839F3E4
- ldr r2, _08088980 @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_0808897C: .4byte gUnknown_0839F3E4
-_08088980: .4byte gTasks
- thumb_func_end sub_8088954
-
- thumb_func_start sub_8088984
-sub_8088984: @ 8088984
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- adds r4, r0, 0
- bl ScriptContext2_Enable
- bl FreezeMapObjects
- ldr r5, _080889DC @ =gPlayerAvatar
- movs r0, 0x1
- strb r0, [r5, 0x6]
- movs r0, 0x8
- bl SetPlayerAvatarStateMask
- adds r6, r4, 0
- adds r6, 0xA
- movs r0, 0xC
- adds r0, r4
- mov r8, r0
- adds r0, r6, 0
- mov r1, r8
- bl PlayerGetDestCoords
- ldr r2, _080889E0 @ =gMapObjects
- ldrb r1, [r5, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r0, [r0, 0x18]
- lsrs r0, 4
- adds r1, r6, 0
- mov r2, r8
- bl MoveCoords
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_080889DC: .4byte gPlayerAvatar
-_080889E0: .4byte gMapObjects
- thumb_func_end sub_8088984
-
- thumb_func_start sub_80889E4
-sub_80889E4: @ 80889E4
- push {r4,r5,lr}
- adds r5, r0, 0
- ldr r0, _08088A28 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088A2C @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _08088A0E
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08088A20
-_08088A0E:
- bl sub_8059BF4
- adds r0, r4, 0
- movs r1, 0x39
- bl FieldObjectSetSpecialAnim
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
-_08088A20:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088A28: .4byte gPlayerAvatar
-_08088A2C: .4byte gMapObjects
- thumb_func_end sub_80889E4
-
- thumb_func_start sub_8088A30
-sub_8088A30: @ 8088A30
- push {r4,lr}
- adds r4, r0, 0
- ldr r0, _08088A6C @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088A70 @ =gMapObjects
- adds r0, r1
- bl FieldObjectCheckIfSpecialAnimFinishedOrInactive
- lsls r0, 24
- cmp r0, 0
- beq _08088A66
- ldr r2, _08088A74 @ =gUnknown_0202FF84
- movs r1, 0x26
- ldrsh r0, [r4, r1]
- movs r1, 0x80
- lsls r1, 24
- orrs r0, r1
- str r0, [r2]
- movs r0, 0x3B
- bl FieldEffectStart
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08088A66:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088A6C: .4byte gPlayerAvatar
-_08088A70: .4byte gMapObjects
-_08088A74: .4byte gUnknown_0202FF84
- thumb_func_end sub_8088A30
-
- thumb_func_start sub_8088A78
-sub_8088A78: @ 8088A78
- push {r4-r6,lr}
- adds r6, r0, 0
- movs r0, 0x6
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _08088AE2
- ldr r5, _08088AE8 @ =gPlayerAvatar
- ldrb r0, [r5, 0x5]
- lsls r4, r0, 3
- adds r4, r0
- lsls r4, 2
- ldr r0, _08088AEC @ =gMapObjects
- adds r4, r0
- movs r0, 0x3
- bl GetPlayerAvatarGraphicsIdByStateId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl sub_805B980
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- ldrb r0, [r4, 0x18]
- lsrs r0, 4
- bl sub_80608D0
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- ldr r1, _08088AF0 @ =gUnknown_0202FF84
- movs r2, 0xA
- ldrsh r0, [r6, r2]
- str r0, [r1]
- movs r2, 0xC
- ldrsh r0, [r6, r2]
- str r0, [r1, 0x4]
- ldrb r0, [r5, 0x5]
- str r0, [r1, 0x8]
- movs r0, 0x8
- bl FieldEffectStart
- strb r0, [r4, 0x1A]
- ldrh r0, [r6, 0x8]
- adds r0, 0x1
- strh r0, [r6, 0x8]
-_08088AE2:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08088AE8: .4byte gPlayerAvatar
-_08088AEC: .4byte gMapObjects
-_08088AF0: .4byte gUnknown_0202FF84
- thumb_func_end sub_8088A78
-
- thumb_func_start sub_8088AF4
-sub_8088AF4: @ 8088AF4
- push {r4,r5,lr}
- ldr r5, _08088B5C @ =gPlayerAvatar
- ldrb r1, [r5, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088B60 @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08088B54
- movs r0, 0
- strb r0, [r5, 0x6]
- ldrb r1, [r5]
- movs r0, 0xDF
- ands r0, r1
- strb r0, [r5]
- ldrb r0, [r4, 0x18]
- lsrs r0, 4
- bl GetFaceDirectionAnimId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl FieldObjectSetSpecialAnim
- ldrb r0, [r4, 0x1A]
- movs r1, 0x1
- bl sub_8127ED0
- bl UnfreezeMapObjects
- bl ScriptContext2_Disable
- movs r0, 0x9
- bl FieldEffectActiveListRemove
- ldr r0, _08088B64 @ =sub_8088954
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08088B54:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088B5C: .4byte gPlayerAvatar
-_08088B60: .4byte gMapObjects
-_08088B64: .4byte sub_8088954
- thumb_func_end sub_8088AF4
-
- thumb_func_start FldEff_NPCFlyOut
-FldEff_NPCFlyOut: @ 8088B68
- push {r4,lr}
- ldr r0, _08088BB4 @ =gFieldEffectObjectTemplatePointers
- ldr r0, [r0, 0x68]
- movs r1, 0x78
- movs r2, 0
- movs r3, 0x1
- bl CreateSprite
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- lsls r2, r4, 4
- adds r2, r4
- lsls r2, 2
- ldr r0, _08088BB8 @ =gSprites
- adds r2, r0
- ldrb r1, [r2, 0x5]
- movs r0, 0xF
- ands r0, r1
- movs r1, 0xD
- negs r1, r1
- ands r0, r1
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r2, 0x5]
- ldr r0, _08088BBC @ =sub_8088BC4
- str r0, [r2, 0x1C]
- ldr r0, _08088BC0 @ =gUnknown_0202FF84
- ldr r0, [r0]
- strh r0, [r2, 0x30]
- movs r0, 0x9E
- bl PlaySE
- adds r0, r4, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_08088BB4: .4byte gFieldEffectObjectTemplatePointers
-_08088BB8: .4byte gSprites
-_08088BBC: .4byte sub_8088BC4
-_08088BC0: .4byte gUnknown_0202FF84
- thumb_func_end FldEff_NPCFlyOut
-
- thumb_func_start sub_8088BC4
-sub_8088BC4: @ 8088BC4
- push {r4,r5,lr}
- adds r4, r0, 0
- movs r1, 0x32
- ldrsh r0, [r4, r1]
- movs r1, 0x8C
- bl Cos
- movs r5, 0
- strh r0, [r4, 0x24]
- movs r2, 0x32
- ldrsh r0, [r4, r2]
- movs r1, 0x48
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r4, 0x32]
- adds r0, 0x4
- movs r1, 0xFF
- ands r0, r1
- strh r0, [r4, 0x32]
- movs r1, 0x2E
- ldrsh r0, [r4, r1]
- cmp r0, 0
- beq _08088C26
- movs r2, 0x30
- ldrsh r0, [r4, r2]
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- ldr r0, _08088C3C @ =gSprites
- adds r1, r0
- adds r3, r1, 0
- adds r3, 0x3E
- ldrb r2, [r3]
- movs r0, 0x3
- negs r0, r0
- ands r0, r2
- strb r0, [r3]
- ldrh r0, [r4, 0x24]
- ldrh r2, [r4, 0x20]
- adds r0, r2
- strh r0, [r1, 0x20]
- ldrh r0, [r4, 0x26]
- ldrh r2, [r4, 0x22]
- adds r0, r2
- subs r0, 0x8
- strh r0, [r1, 0x22]
- strh r5, [r1, 0x24]
- strh r5, [r1, 0x26]
-_08088C26:
- movs r1, 0x32
- ldrsh r0, [r4, r1]
- cmp r0, 0x7F
- ble _08088C36
- adds r0, r4, 0
- movs r1, 0x1E
- bl FieldEffectStop
-_08088C36:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088C3C: .4byte gSprites
- thumb_func_end sub_8088BC4
-
- thumb_func_start FldEff_UseFly
-FldEff_UseFly: @ 8088C40
- push {lr}
- ldr r0, _08088C64 @ =sub_8088C70
- movs r1, 0xFE
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08088C68 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r1, r2
- ldr r0, _08088C6C @ =gUnknown_0202FF84
- ldr r0, [r0]
- strh r0, [r1, 0xA]
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08088C64: .4byte sub_8088C70
-_08088C68: .4byte gTasks
-_08088C6C: .4byte gUnknown_0202FF84
- thumb_func_end FldEff_UseFly
-
- thumb_func_start sub_8088C70
-sub_8088C70: @ 8088C70
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08088C98 @ =gUnknown_0839F3F8
- ldr r2, _08088C9C @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08088C98: .4byte gUnknown_0839F3F8
-_08088C9C: .4byte gTasks
- thumb_func_end sub_8088C70
-
- thumb_func_start sub_8088CA0
-sub_8088CA0: @ 8088CA0
- push {r4-r6,lr}
- adds r5, r0, 0
- ldr r6, _08088CF0 @ =gPlayerAvatar
- ldrb r1, [r6, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088CF4 @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _08088CCA
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08088CE8
-_08088CCA:
- ldrb r0, [r6]
- strh r0, [r5, 0x26]
- movs r0, 0x1
- strb r0, [r6, 0x6]
- bl SetPlayerAvatarStateMask
- bl sub_8059BF4
- adds r0, r4, 0
- movs r1, 0x39
- bl FieldObjectSetSpecialAnim
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
-_08088CE8:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08088CF0: .4byte gPlayerAvatar
-_08088CF4: .4byte gMapObjects
- thumb_func_end sub_8088CA0
-
- thumb_func_start sub_8088CF8
-sub_8088CF8: @ 8088CF8
- push {r4,lr}
- adds r4, r0, 0
- ldr r0, _08088D30 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088D34 @ =gMapObjects
- adds r0, r1
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08088D28
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- ldr r1, _08088D38 @ =gUnknown_0202FF84
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- str r0, [r1]
- movs r0, 0x3B
- bl FieldEffectStart
-_08088D28:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088D30: .4byte gPlayerAvatar
-_08088D34: .4byte gMapObjects
-_08088D38: .4byte gUnknown_0202FF84
- thumb_func_end sub_8088CF8
-
- thumb_func_start sub_8088D3C
-sub_8088D3C: @ 8088D3C
- push {r4,r5,lr}
- adds r4, r0, 0
- movs r0, 0x6
- bl FieldEffectActiveListContains
- lsls r0, 24
- cmp r0, 0
- bne _08088D84
- ldr r0, _08088D8C @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088D90 @ =gMapObjects
- adds r5, r0, r1
- ldrh r1, [r4, 0x26]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- beq _08088D74
- ldrb r0, [r5, 0x1A]
- movs r1, 0x2
- bl sub_8127ED0
- ldrb r0, [r5, 0x1A]
- movs r1, 0
- bl sub_8127EFC
-_08088D74:
- bl sub_8088F60
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r4, 0xA]
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08088D84:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088D8C: .4byte gPlayerAvatar
-_08088D90: .4byte gMapObjects
- thumb_func_end sub_8088D3C
-
- thumb_func_start sub_8088D94
-sub_8088D94: @ 8088D94
- push {r4,lr}
- adds r4, r0, 0
- ldrb r0, [r4, 0xA]
- bl sub_8088FA4
- lsls r0, 24
- cmp r0, 0
- beq _08088DC8
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x10
- strh r0, [r4, 0xC]
- movs r0, 0x1
- bl SetPlayerAvatarTransitionFlags
- ldr r0, _08088DD0 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088DD4 @ =gMapObjects
- adds r0, r1
- movs r1, 0x2
- bl FieldObjectSetSpecialAnim
-_08088DC8:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088DD0: .4byte gPlayerAvatar
-_08088DD4: .4byte gMapObjects
- thumb_func_end sub_8088D94
-
- thumb_func_start sub_8088DD8
-sub_8088DD8: @ 8088DD8
- push {r4,lr}
- adds r4, r0, 0
- ldr r0, _08088E24 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088E28 @ =gMapObjects
- adds r2, r0, r1
- ldrh r1, [r4, 0xC]
- movs r3, 0xC
- ldrsh r0, [r4, r3]
- cmp r0, 0
- beq _08088DFE
- subs r0, r1, 0x1
- strh r0, [r4, 0xC]
- lsls r0, 16
- cmp r0, 0
- bne _08088E1C
-_08088DFE:
- adds r0, r2, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08088E1C
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x9E
- bl PlaySE
- ldrb r0, [r4, 0xA]
- bl sub_8088FC0
-_08088E1C:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088E24: .4byte gPlayerAvatar
-_08088E28: .4byte gMapObjects
- thumb_func_end sub_8088DD8
-
- thumb_func_start sub_8088E2C
-sub_8088E2C: @ 8088E2C
- push {r4-r6,lr}
- adds r5, r0, 0
- ldrh r0, [r5, 0xC]
- adds r0, 0x1
- strh r0, [r5, 0xC]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x7
- ble _08088EA2
- ldr r0, _08088EA8 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08088EAC @ =gMapObjects
- adds r4, r0, r1
- movs r0, 0x3
- bl GetPlayerAvatarGraphicsIdByStateId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl sub_805B980
- ldrb r1, [r4, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r6, _08088EB0 @ =gSprites
- adds r0, r6
- movs r1, 0x16
- bl StartSpriteAnim
- ldrb r0, [r4, 0x1]
- movs r1, 0x10
- orrs r0, r1
- strb r0, [r4, 0x1]
- adds r0, r4, 0
- movs r1, 0x48
- bl FieldObjectSetSpecialAnim
- ldrh r1, [r5, 0x26]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- beq _08088E98
- ldrb r1, [r4, 0x1A]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r0, r6
- bl DestroySprite
-_08088E98:
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0
- strh r0, [r5, 0xC]
-_08088EA2:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08088EA8: .4byte gPlayerAvatar
-_08088EAC: .4byte gMapObjects
-_08088EB0: .4byte gSprites
- thumb_func_end sub_8088E2C
-
- thumb_func_start sub_8088EB4
-sub_8088EB4: @ 8088EB4
- push {r4,r5,lr}
- adds r5, r0, 0
- ldrh r0, [r5, 0xC]
- adds r0, 0x1
- strh r0, [r5, 0xC]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x9
- ble _08088F00
- ldr r0, _08088F08 @ =gPlayerAvatar
- ldrb r0, [r0, 0x5]
- lsls r4, r0, 3
- adds r4, r0
- lsls r4, 2
- ldr r0, _08088F0C @ =gMapObjects
- adds r4, r0
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimActive
- ldrb r1, [r4, 0x1]
- movs r0, 0x11
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x1]
- ldrb r1, [r4, 0x2]
- movs r0, 0x41
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x2]
- ldrb r0, [r5, 0xA]
- ldrb r1, [r4, 0x4]
- bl sub_8088FFC
- bl CameraObjectReset2
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
-_08088F00:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08088F08: .4byte gPlayerAvatar
-_08088F0C: .4byte gMapObjects
- thumb_func_end sub_8088EB4
-
- thumb_func_start sub_8088F10
-sub_8088F10: @ 8088F10
- push {r4,lr}
- adds r4, r0, 0
- ldrb r0, [r4, 0xA]
- bl sub_8088FA4
- lsls r0, 24
- cmp r0, 0
- beq _08088F2A
- bl fade_8080918
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_08088F2A:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_8088F10
-
- thumb_func_start sub_8088F30
-sub_8088F30: @ 8088F30
- push {lr}
- ldr r0, _08088F58 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08088F52
- movs r0, 0x1F
- bl FieldEffectActiveListRemove
- ldr r0, _08088F5C @ =sub_8088C70
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08088F52:
- pop {r0}
- bx r0
- .align 2, 0
-_08088F58: .4byte gPaletteFade
-_08088F5C: .4byte sub_8088C70
- thumb_func_end sub_8088F30
-
- thumb_func_start sub_8088F60
-sub_8088F60: @ 8088F60
- push {lr}
- ldr r0, _08088F98 @ =gFieldEffectObjectTemplatePointers
- ldr r0, [r0, 0x68]
- movs r1, 0xFF
- movs r2, 0xB4
- movs r3, 0x1
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- ldr r1, _08088F9C @ =gSprites
- adds r2, r1
- ldrb r3, [r2, 0x5]
- movs r1, 0xF
- ands r1, r3
- movs r3, 0xD
- negs r3, r3
- ands r1, r3
- movs r3, 0x4
- orrs r1, r3
- strb r1, [r2, 0x5]
- ldr r1, _08088FA0 @ =sub_8089018
- str r1, [r2, 0x1C]
- pop {r1}
- bx r1
- .align 2, 0
-_08088F98: .4byte gFieldEffectObjectTemplatePointers
-_08088F9C: .4byte gSprites
-_08088FA0: .4byte sub_8089018
- thumb_func_end sub_8088F60
-
- thumb_func_start sub_8088FA4
-sub_8088FA4: @ 8088FA4
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08088FBC @ =gSprites
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r1, r2
- ldrh r0, [r1, 0x3C]
- lsls r0, 24
- lsrs r0, 24
- bx lr
- .align 2, 0
-_08088FBC: .4byte gSprites
- thumb_func_end sub_8088FA4
-
- thumb_func_start sub_8088FC0
-sub_8088FC0: @ 8088FC0
- push {r4,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08088FF4 @ =gSprites
- adds r4, r0
- ldr r0, _08088FF8 @ =sub_80890D8
- str r0, [r4, 0x1C]
- movs r1, 0
- movs r0, 0x78
- strh r0, [r4, 0x20]
- strh r1, [r4, 0x22]
- strh r1, [r4, 0x24]
- strh r1, [r4, 0x26]
- adds r0, r4, 0
- adds r0, 0x2E
- movs r2, 0x10
- bl memset
- movs r0, 0x40
- strh r0, [r4, 0x3A]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08088FF4: .4byte gSprites
-_08088FF8: .4byte sub_80890D8
- thumb_func_end sub_8088FC0
-
- thumb_func_start sub_8088FFC
-sub_8088FFC: @ 8088FFC
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08089014 @ =gSprites
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r3
- strh r1, [r2, 0x3A]
- bx lr
- .align 2, 0
-_08089014: .4byte gSprites
- thumb_func_end sub_8088FFC
-
- thumb_func_start sub_8089018
-sub_8089018: @ 8089018
- push {r4,lr}
- adds r4, r0, 0
- movs r1, 0x3C
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _080890C4
- movs r1, 0x2E
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _0808905C
- ldrb r0, [r4, 0x1]
- movs r1, 0x3
- orrs r0, r1
- strb r0, [r4, 0x1]
- ldr r0, _080890CC @ =gSpriteAffineAnimTable_0839F44C
- str r0, [r4, 0x10]
- adds r0, r4, 0
- bl InitSpriteAffineAnim
- adds r0, r4, 0
- movs r1, 0
- bl StartSpriteAffineAnim
- movs r0, 0x76
- strh r0, [r4, 0x20]
- ldr r0, _080890D0 @ =0x0000ffd0
- strh r0, [r4, 0x22]
- ldrh r0, [r4, 0x2E]
- adds r0, 0x1
- strh r0, [r4, 0x2E]
- movs r0, 0x40
- strh r0, [r4, 0x30]
- adds r0, 0xC0
- strh r0, [r4, 0x32]
-_0808905C:
- ldrh r0, [r4, 0x32]
- lsls r0, 16
- asrs r0, 24
- ldrh r1, [r4, 0x30]
- adds r0, r1
- strh r0, [r4, 0x30]
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- movs r1, 0x78
- bl Cos
- strh r0, [r4, 0x24]
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- movs r1, 0x78
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r2, [r4, 0x32]
- movs r0, 0x32
- ldrsh r1, [r4, r0]
- ldr r0, _080890D4 @ =0x000007ff
- cmp r1, r0
- bgt _08089092
- adds r0, r2, 0
- adds r0, 0x60
- strh r0, [r4, 0x32]
-_08089092:
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- cmp r0, 0x81
- ble _080890C4
- ldrh r0, [r4, 0x3C]
- adds r0, 0x1
- strh r0, [r4, 0x3C]
- ldrb r1, [r4, 0x1]
- movs r0, 0x4
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x1]
- ldrb r0, [r4, 0x3]
- lsls r0, 26
- lsrs r0, 27
- bl FreeOamMatrix
- ldrb r1, [r4, 0x1]
- lsrs r1, 6
- ldrb r2, [r4, 0x3]
- lsrs r2, 6
- adds r0, r4, 0
- movs r3, 0
- bl CalcCenterToCornerVec
-_080890C4:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080890CC: .4byte gSpriteAffineAnimTable_0839F44C
-_080890D0: .4byte 0x0000ffd0
-_080890D4: .4byte 0x000007ff
- thumb_func_end sub_8089018
-
- thumb_func_start sub_80890D8
-sub_80890D8: @ 80890D8
- push {r4,r5,lr}
- adds r4, r0, 0
- movs r1, 0x32
- ldrsh r0, [r4, r1]
- movs r1, 0x8C
- bl Cos
- movs r5, 0
- strh r0, [r4, 0x24]
- movs r2, 0x32
- ldrsh r0, [r4, r2]
- movs r1, 0x48
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r0, [r4, 0x32]
- adds r0, 0x4
- movs r1, 0xFF
- ands r0, r1
- strh r0, [r4, 0x32]
- movs r1, 0x3A
- ldrsh r0, [r4, r1]
- cmp r0, 0x40
- beq _08089136
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- ldr r0, _08089148 @ =gSprites
- adds r1, r0
- adds r3, r1, 0
- adds r3, 0x3E
- ldrb r2, [r3]
- movs r0, 0x3
- negs r0, r0
- ands r0, r2
- strb r0, [r3]
- ldrh r0, [r4, 0x24]
- ldrh r2, [r4, 0x20]
- adds r0, r2
- strh r0, [r1, 0x20]
- ldrh r0, [r4, 0x26]
- ldrh r2, [r4, 0x22]
- adds r0, r2
- subs r0, 0x8
- strh r0, [r1, 0x22]
- strh r5, [r1, 0x24]
- strh r5, [r1, 0x26]
-_08089136:
- movs r1, 0x32
- ldrsh r0, [r4, r1]
- cmp r0, 0x7F
- ble _08089142
- movs r0, 0x1
- strh r0, [r4, 0x3C]
-_08089142:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08089148: .4byte gSprites
- thumb_func_end sub_80890D8
-
- thumb_func_start sub_808914C
-sub_808914C: @ 808914C
- push {r4,lr}
- adds r4, r0, 0
- movs r1, 0x3C
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _08089220
- movs r2, 0x2E
- ldrsh r0, [r4, r2]
- cmp r0, 0
- bne _08089196
- ldrb r0, [r4, 0x1]
- movs r1, 0x3
- orrs r0, r1
- strb r0, [r4, 0x1]
- ldr r0, _08089228 @ =gSpriteAffineAnimTable_0839F44C
- str r0, [r4, 0x10]
- adds r0, r4, 0
- bl InitSpriteAffineAnim
- adds r0, r4, 0
- movs r1, 0x1
- bl StartSpriteAffineAnim
- movs r0, 0x5E
- strh r0, [r4, 0x20]
- ldr r0, _0808922C @ =0x0000ffe0
- strh r0, [r4, 0x22]
- ldrh r0, [r4, 0x2E]
- adds r0, 0x1
- strh r0, [r4, 0x2E]
- movs r0, 0xF0
- strh r0, [r4, 0x30]
- movs r0, 0x80
- lsls r0, 4
- strh r0, [r4, 0x32]
- movs r0, 0x80
- strh r0, [r4, 0x36]
-_08089196:
- ldrh r1, [r4, 0x32]
- lsls r1, 16
- asrs r1, 24
- ldrh r2, [r4, 0x30]
- adds r2, r1
- ldrh r0, [r4, 0x34]
- adds r0, r1
- strh r0, [r4, 0x34]
- movs r0, 0xFF
- ands r2, r0
- strh r2, [r4, 0x30]
- movs r3, 0x30
- ldrsh r0, [r4, r3]
- movs r1, 0x20
- bl Cos
- strh r0, [r4, 0x24]
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- movs r1, 0x78
- bl Sin
- strh r0, [r4, 0x26]
- ldrh r1, [r4, 0x32]
- movs r2, 0x32
- ldrsh r0, [r4, r2]
- movs r2, 0x80
- lsls r2, 1
- cmp r0, r2
- ble _080891D8
- ldrh r0, [r4, 0x36]
- subs r0, r1, r0
- strh r0, [r4, 0x32]
-_080891D8:
- ldrh r1, [r4, 0x36]
- movs r3, 0x36
- ldrsh r0, [r4, r3]
- cmp r0, 0xFF
- bgt _080891E8
- adds r0, r1, 0
- adds r0, 0x18
- strh r0, [r4, 0x36]
-_080891E8:
- movs r1, 0x32
- ldrsh r0, [r4, r1]
- cmp r0, 0xFF
- bgt _080891F2
- strh r2, [r4, 0x32]
-_080891F2:
- movs r2, 0x34
- ldrsh r0, [r4, r2]
- cmp r0, 0x3B
- ble _08089220
- ldrh r0, [r4, 0x3C]
- adds r0, 0x1
- strh r0, [r4, 0x3C]
- ldrb r1, [r4, 0x1]
- movs r0, 0x4
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x1]
- ldrb r0, [r4, 0x3]
- lsls r0, 26
- lsrs r0, 27
- bl FreeOamMatrix
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r0, [r2]
- movs r1, 0x4
- orrs r0, r1
- strb r0, [r2]
-_08089220:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08089228: .4byte gSpriteAffineAnimTable_0839F44C
-_0808922C: .4byte 0x0000ffe0
- thumb_func_end sub_808914C
-
- thumb_func_start sub_8089230
-sub_8089230: @ 8089230
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r4, 0
- bl sub_8088FC0
- ldr r1, _08089254 @ =gSprites
- lsls r0, r4, 4
- adds r0, r4
- lsls r0, 2
- adds r1, 0x1C
- adds r0, r1
- ldr r1, _08089258 @ =sub_808914C
- str r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08089254: .4byte gSprites
-_08089258: .4byte sub_808914C
- thumb_func_end sub_8089230
-
- thumb_func_start FldEff_FlyIn
-FldEff_FlyIn: @ 808925C
- push {lr}
- ldr r0, _0808926C @ =sub_8089270
- movs r1, 0xFE
- bl CreateTask
- movs r0, 0
- pop {r1}
- bx r1
- .align 2, 0
-_0808926C: .4byte sub_8089270
- thumb_func_end FldEff_FlyIn
-
- thumb_func_start sub_8089270
-sub_8089270: @ 8089270
- push {lr}
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- ldr r3, _08089298 @ =gUnknown_0839F454
- ldr r2, _0808929C @ =gTasks
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- movs r2, 0x8
- ldrsh r1, [r0, r2]
- lsls r1, 2
- adds r1, r3
- ldr r1, [r1]
- bl _call_via_r1
- pop {r0}
- bx r0
- .align 2, 0
-_08089298: .4byte gUnknown_0839F454
-_0808929C: .4byte gTasks
- thumb_func_end sub_8089270
-
- thumb_func_start sub_80892A0
-sub_80892A0: @ 80892A0
- push {r4-r6,lr}
- adds r5, r0, 0
- ldr r6, _08089348 @ =gPlayerAvatar
- ldrb r1, [r6, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _0808934C @ =gMapObjects
- adds r4, r0, r1
- adds r0, r4, 0
- bl FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive
- lsls r0, 24
- cmp r0, 0
- beq _080892CA
- adds r0, r4, 0
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _08089342
-_080892CA:
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- movs r0, 0x11
- strh r0, [r5, 0xC]
- ldrb r0, [r6]
- strh r0, [r5, 0x26]
- movs r0, 0x1
- strb r0, [r6, 0x6]
- bl SetPlayerAvatarStateMask
- ldrh r1, [r5, 0x26]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- beq _080892F2
- ldrb r0, [r4, 0x1A]
- movs r1, 0
- bl sub_8127ED0
-_080892F2:
- movs r0, 0x3
- bl GetPlayerAvatarGraphicsIdByStateId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl sub_805B980
- bl CameraObjectReset2
- adds r0, r4, 0
- movs r1, 0x3
- bl FieldObjectTurn
- ldrb r1, [r4, 0x4]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _08089350 @ =gSprites
- adds r0, r1
- movs r1, 0x16
- bl StartSpriteAnim
- ldrb r1, [r4, 0x1]
- movs r0, 0x21
- negs r0, r0
- ands r0, r1
- strb r0, [r4, 0x1]
- bl sub_8088F60
- lsls r0, 24
- lsrs r0, 24
- strh r0, [r5, 0xA]
- bl sub_8088FC0
- ldrb r0, [r5, 0xA]
- ldrb r1, [r4, 0x4]
- bl sub_8088FFC
-_08089342:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08089348: .4byte gPlayerAvatar
-_0808934C: .4byte gMapObjects
-_08089350: .4byte gSprites
- thumb_func_end sub_80892A0
-
- thumb_func_start sub_8089354
-sub_8089354: @ 8089354
- push {r4,r5,lr}
- adds r5, r0, 0
- ldrh r1, [r5, 0xC]
- movs r2, 0xC
- ldrsh r0, [r5, r2]
- cmp r0, 0
- beq _0808936C
- subs r0, r1, 0x1
- strh r0, [r5, 0xC]
- lsls r0, 16
- cmp r0, 0
- bne _080893AC
-_0808936C:
- ldr r0, _080893B4 @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _080893B8 @ =gMapObjects
- adds r0, r1
- ldrb r0, [r0, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _080893BC @ =gSprites
- adds r4, r0
- ldrb r0, [r5, 0xA]
- movs r1, 0x40
- bl sub_8088FFC
- ldrh r0, [r4, 0x24]
- ldrh r1, [r4, 0x20]
- adds r0, r1
- movs r1, 0
- strh r0, [r4, 0x20]
- ldrh r0, [r4, 0x26]
- ldrh r2, [r4, 0x22]
- adds r0, r2
- strh r0, [r4, 0x22]
- strh r1, [r4, 0x24]
- strh r1, [r4, 0x26]
- ldrh r0, [r5, 0x8]
- adds r0, 0x1
- strh r0, [r5, 0x8]
- strh r1, [r5, 0xC]
-_080893AC:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080893B4: .4byte gPlayerAvatar
-_080893B8: .4byte gMapObjects
-_080893BC: .4byte gSprites
- thumb_func_end sub_8089354
-
- thumb_func_start sub_80893C0
-sub_80893C0: @ 80893C0
- push {r4,lr}
- sub sp, 0x24
- adds r4, r0, 0
- ldr r1, _08089408 @ =gUnknown_0839F470
- mov r0, sp
- movs r2, 0x24
- bl memcpy
- ldr r0, _0808940C @ =gPlayerAvatar
- ldrb r0, [r0, 0x4]
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- ldr r0, _08089410 @ =gSprites
- adds r1, r0
- movs r2, 0xC
- ldrsh r0, [r4, r2]
- lsls r0, 1
- add r0, sp
- ldrh r0, [r0]
- strh r0, [r1, 0x26]
- ldrh r0, [r4, 0xC]
- adds r0, 0x1
- strh r0, [r4, 0xC]
- lsls r0, 16
- asrs r0, 16
- cmp r0, 0x11
- ble _080893FE
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
-_080893FE:
- add sp, 0x24
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08089408: .4byte gUnknown_0839F470
-_0808940C: .4byte gPlayerAvatar
-_08089410: .4byte gSprites
- thumb_func_end sub_80893C0
-
- thumb_func_start sub_8089414
-sub_8089414: @ 8089414
- push {r4-r6,lr}
- adds r6, r0, 0
- ldrb r0, [r6, 0xA]
- bl sub_8088FA4
- lsls r0, 24
- cmp r0, 0
- beq _08089478
- ldr r0, _08089480 @ =gPlayerAvatar
- ldrb r0, [r0, 0x5]
- lsls r5, r0, 3
- adds r5, r0
- lsls r5, 2
- ldr r0, _08089484 @ =gMapObjects
- adds r5, r0
- ldrb r0, [r5, 0x4]
- lsls r4, r0, 4
- adds r4, r0
- lsls r4, 2
- ldr r0, _08089488 @ =gSprites
- adds r4, r0
- ldrb r1, [r5, 0x1]
- movs r0, 0x11
- negs r0, r0
- ands r0, r1
- strb r0, [r5, 0x1]
- movs r0, 0x10
- ldrsh r1, [r5, r0]
- movs r0, 0x12
- ldrsh r2, [r5, r0]
- adds r0, r5, 0
- bl sub_805C058
- movs r0, 0
- strh r0, [r4, 0x24]
- strh r0, [r4, 0x26]
- adds r4, 0x3E
- ldrb r0, [r4]
- movs r1, 0x2
- orrs r0, r1
- strb r0, [r4]
- bl sub_8059BF4
- adds r0, r5, 0
- movs r1, 0x39
- bl FieldObjectSetSpecialAnim
- ldrh r0, [r6, 0x8]
- adds r0, 0x1
- strh r0, [r6, 0x8]
-_08089478:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08089480: .4byte gPlayerAvatar
-_08089484: .4byte gMapObjects
-_08089488: .4byte gSprites
- thumb_func_end sub_8089414
-
- thumb_func_start sub_808948C
-sub_808948C: @ 808948C
- push {r4,lr}
- adds r4, r0, 0
- ldr r0, _080894BC @ =gPlayerAvatar
- ldrb r1, [r0, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _080894C0 @ =gMapObjects
- adds r0, r1
- bl FieldObjectClearAnimIfSpecialAnimFinished
- lsls r0, 24
- cmp r0, 0
- beq _080894B4
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- ldrb r0, [r4, 0xA]
- bl sub_8089230
-_080894B4:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080894BC: .4byte gPlayerAvatar
-_080894C0: .4byte gMapObjects
- thumb_func_end sub_808948C
-
- thumb_func_start sub_80894C4
-sub_80894C4: @ 80894C4
- push {r4,lr}
- adds r4, r0, 0
- ldrb r0, [r4, 0xA]
- bl sub_8088FA4
- lsls r0, 24
- cmp r0, 0
- beq _080894F0
- movs r0, 0xA
- ldrsh r1, [r4, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- ldr r1, _080894F8 @ =gSprites
- adds r0, r1
- bl DestroySprite
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- movs r0, 0x10
- strh r0, [r4, 0xA]
-_080894F0:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080894F8: .4byte gSprites
- thumb_func_end sub_80894C4
-
- thumb_func_start fishE
-fishE: @ 80894FC
- push {r4-r7,lr}
- adds r5, r0, 0
- ldrh r0, [r5, 0xA]
- subs r0, 0x1
- strh r0, [r5, 0xA]
- lsls r0, 16
- cmp r0, 0
- bne _08089566
- ldr r6, _0808956C @ =gPlayerAvatar
- ldrb r1, [r6, 0x5]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08089570 @ =gMapObjects
- adds r4, r0, r1
- movs r7, 0
- ldrh r1, [r5, 0x26]
- movs r0, 0x8
- ands r0, r1
- cmp r0, 0
- beq _08089530
- movs r7, 0x3
- ldrb r0, [r4, 0x1A]
- movs r1, 0x1
- bl sub_8127ED0
-_08089530:
- adds r0, r7, 0
- bl GetPlayerAvatarGraphicsIdByStateId
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r4, 0
- bl sub_805B980
- adds r0, r4, 0
- movs r1, 0x1
- bl FieldObjectTurn
- ldrh r0, [r5, 0x26]
- strb r0, [r6]
- movs r0, 0
- strb r0, [r6, 0x6]
- movs r0, 0x20
- bl FieldEffectActiveListRemove
- ldr r0, _08089574 @ =sub_8089270
- bl FindTaskIdByFunc
- lsls r0, 24
- lsrs r0, 24
- bl DestroyTask
-_08089566:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_0808956C: .4byte gPlayerAvatar
-_08089570: .4byte gMapObjects
-_08089574: .4byte sub_8089270
- thumb_func_end fishE
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/field_fadetransition.s b/asm/field_fadetransition.s
index 798285a45..e882e7030 100644
--- a/asm/field_fadetransition.s
+++ b/asm/field_fadetransition.s
@@ -617,7 +617,7 @@ sub_8080E88: @ 8080E88
bl PlayRainSoundEffect
movs r0, 0x9
bl PlaySE
- ldr r0, _08080EB4 @ =gUnknown_0300485C
+ ldr r0, _08080EB4 @ =gFieldCallback
ldr r1, _08080EB8 @ =mapldr_default
str r1, [r0]
ldr r0, _08080EBC @ =task0A_fade_n_map_maybe
@@ -626,7 +626,7 @@ sub_8080E88: @ 8080E88
pop {r0}
bx r0
.align 2, 0
-_08080EB4: .4byte gUnknown_0300485C
+_08080EB4: .4byte gFieldCallback
_08080EB8: .4byte mapldr_default
_08080EBC: .4byte task0A_fade_n_map_maybe
thumb_func_end sub_8080E88
@@ -638,7 +638,7 @@ sp13E_warp_to_last_warp: @ 8080EC0
bl sub_8053FF8
bl fade_8080918
bl PlayRainSoundEffect
- ldr r0, _08080EE4 @ =gUnknown_0300485C
+ ldr r0, _08080EE4 @ =gFieldCallback
ldr r1, _08080EE8 @ =mapldr_default
str r1, [r0]
ldr r0, _08080EEC @ =task0A_fade_n_map_maybe
@@ -647,7 +647,7 @@ sp13E_warp_to_last_warp: @ 8080EC0
pop {r0}
bx r0
.align 2, 0
-_08080EE4: .4byte gUnknown_0300485C
+_08080EE4: .4byte gFieldCallback
_08080EE8: .4byte mapldr_default
_08080EEC: .4byte task0A_fade_n_map_maybe
thumb_func_end sp13E_warp_to_last_warp
@@ -656,7 +656,7 @@ _08080EEC: .4byte task0A_fade_n_map_maybe
sub_8080EF0: @ 8080EF0
push {lr}
bl ScriptContext2_Enable
- ldr r0, _08080F08 @ =gUnknown_0300485C
+ ldr r0, _08080F08 @ =gFieldCallback
ldr r1, _08080F0C @ =mapldr_default
str r1, [r0]
ldr r0, _08080F10 @ =sub_808115C
@@ -665,7 +665,7 @@ sub_8080EF0: @ 8080EF0
pop {r0}
bx r0
.align 2, 0
-_08080F08: .4byte gUnknown_0300485C
+_08080F08: .4byte gFieldCallback
_08080F0C: .4byte mapldr_default
_08080F10: .4byte sub_808115C
thumb_func_end sub_8080EF0
@@ -674,13 +674,13 @@ _08080F10: .4byte sub_808115C
sp13F_fall_to_last_warp: @ 8080F14
push {lr}
bl sp13E_warp_to_last_warp
- ldr r1, _08080F24 @ =gUnknown_0300485C
+ ldr r1, _08080F24 @ =gFieldCallback
ldr r0, _08080F28 @ =sub_8086748
str r0, [r1]
pop {r0}
bx r0
.align 2, 0
-_08080F24: .4byte gUnknown_0300485C
+_08080F24: .4byte gFieldCallback
_08080F28: .4byte sub_8086748
thumb_func_end sp13F_fall_to_last_warp
@@ -730,14 +730,14 @@ sub_8080F68: @ 8080F68
ldr r0, _08080F90 @ =task0A_fade_n_map_maybe
movs r1, 0xA
bl CreateTask
- ldr r1, _08080F94 @ =gUnknown_0300485C
+ ldr r1, _08080F94 @ =gFieldCallback
ldr r0, _08080F98 @ =sub_8080B78
str r0, [r1]
pop {r0}
bx r0
.align 2, 0
_08080F90: .4byte task0A_fade_n_map_maybe
-_08080F94: .4byte gUnknown_0300485C
+_08080F94: .4byte gFieldCallback
_08080F98: .4byte sub_8080B78
thumb_func_end sub_8080F68
@@ -749,14 +749,14 @@ sub_8080F9C: @ 8080F9C
ldr r0, _08080FB8 @ =task0A_fade_n_map_maybe
movs r1, 0xA
bl CreateTask
- ldr r1, _08080FBC @ =gUnknown_0300485C
+ ldr r1, _08080FBC @ =gFieldCallback
ldr r0, _08080FC0 @ =sub_80C791C
str r0, [r1]
pop {r0}
bx r0
.align 2, 0
_08080FB8: .4byte task0A_fade_n_map_maybe
-_08080FBC: .4byte gUnknown_0300485C
+_08080FBC: .4byte gFieldCallback
_08080FC0: .4byte sub_80C791C
thumb_func_end sub_8080F9C
@@ -1204,7 +1204,7 @@ sub_8081334: @ 8081334
bl PlayRainSoundEffect
movs r0, 0x9
bl PlaySE
- ldr r0, _08081360 @ =gUnknown_0300485C
+ ldr r0, _08081360 @ =gFieldCallback
ldr r1, _08081364 @ =sub_8080B60
str r1, [r0]
ldr r0, _08081368 @ =sub_80812C8
@@ -1213,7 +1213,7 @@ sub_8081334: @ 8081334
pop {r0}
bx r0
.align 2, 0
-_08081360: .4byte gUnknown_0300485C
+_08081360: .4byte gFieldCallback
_08081364: .4byte sub_8080B60
_08081368: .4byte sub_80812C8
thumb_func_end sub_8081334
diff --git a/asm/field_specials.s b/asm/field_specials.s
index 63677b6a0..136489b80 100644
--- a/asm/field_specials.s
+++ b/asm/field_specials.s
@@ -3086,7 +3086,7 @@ _0810F17A:
ands r0, r1
cmp r0, 0
beq _0810F1AE
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r0, _0810F1F0 @ =gScriptResult
ldr r1, _0810F1E8 @ =gUnknown_0203925B
ldrb r1, [r1]
@@ -3107,7 +3107,7 @@ _0810F1AE:
ands r0, r1
cmp r0, 0
beq _0810F1DE
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r1, _0810F1F0 @ =gScriptResult
movs r0, 0x7F
strh r0, [r1]
diff --git a/asm/fldeff_80C5CD4.s b/asm/fldeff_80C5CD4.s
index 25ede5738..33182fc6a 100644
--- a/asm/fldeff_80C5CD4.s
+++ b/asm/fldeff_80C5CD4.s
@@ -814,7 +814,7 @@ SetUpFieldMove_SecretPower: @ 80C62C4
cmp r0, 0x1
bne _080C6330
bl sub_80C6264
- ldr r1, _080C6320 @ =gUnknown_0300485C
+ ldr r1, _080C6320 @ =gFieldCallback
ldr r0, _080C6324 @ =sub_808AB90
str r0, [r1]
ldr r1, _080C6328 @ =gUnknown_03005CE4
@@ -823,7 +823,7 @@ SetUpFieldMove_SecretPower: @ 80C62C4
.align 2, 0
_080C6318: .4byte gScriptResult
_080C631C: .4byte gUnknown_0203923C
-_080C6320: .4byte gUnknown_0300485C
+_080C6320: .4byte gFieldCallback
_080C6324: .4byte sub_808AB90
_080C6328: .4byte gUnknown_03005CE4
_080C632C: .4byte sub_80C639C
@@ -835,14 +835,14 @@ _080C6330:
cmp r0, 0x1
bne _080C6360
bl sub_80C6264
- ldr r1, _080C6350 @ =gUnknown_0300485C
+ ldr r1, _080C6350 @ =gFieldCallback
ldr r0, _080C6354 @ =sub_808AB90
str r0, [r1]
ldr r1, _080C6358 @ =gUnknown_03005CE4
ldr r0, _080C635C @ =sub_80C64A8
b _080C6380
.align 2, 0
-_080C6350: .4byte gUnknown_0300485C
+_080C6350: .4byte gFieldCallback
_080C6354: .4byte sub_808AB90
_080C6358: .4byte gUnknown_03005CE4
_080C635C: .4byte sub_80C64A8
@@ -858,7 +858,7 @@ _080C636E:
b _080C6384
_080C6372:
bl sub_80C6264
- ldr r1, _080C638C @ =gUnknown_0300485C
+ ldr r1, _080C638C @ =gFieldCallback
ldr r0, _080C6390 @ =sub_808AB90
str r0, [r1]
ldr r1, _080C6394 @ =gUnknown_03005CE4
@@ -871,7 +871,7 @@ _080C6384:
pop {r1}
bx r1
.align 2, 0
-_080C638C: .4byte gUnknown_0300485C
+_080C638C: .4byte gFieldCallback
_080C6390: .4byte sub_808AB90
_080C6394: .4byte gUnknown_03005CE4
_080C6398: .4byte sub_80C660C
diff --git a/asm/fldeff_flash.s b/asm/fldeff_flash.s
index c14e9057d..dcd485d9f 100644
--- a/asm/fldeff_flash.s
+++ b/asm/fldeff_flash.s
@@ -18,7 +18,7 @@ SetUpFieldMove_Flash: @ 810CBB4
lsls r0, 24
cmp r0, 0
bne _0810CBF4
- ldr r1, _0810CBE4 @ =gUnknown_0300485C
+ ldr r1, _0810CBE4 @ =gFieldCallback
ldr r0, _0810CBE8 @ =sub_808AB90
str r0, [r1]
ldr r1, _0810CBEC @ =gUnknown_03005CE4
@@ -29,7 +29,7 @@ SetUpFieldMove_Flash: @ 810CBB4
.align 2, 0
_0810CBDC: .4byte gMapHeader
_0810CBE0: .4byte 0x00000828
-_0810CBE4: .4byte gUnknown_0300485C
+_0810CBE4: .4byte gFieldCallback
_0810CBE8: .4byte sub_808AB90
_0810CBEC: .4byte gUnknown_03005CE4
_0810CBF0: .4byte sub_810CBFC
diff --git a/asm/item_menu.s b/asm/item_menu.s
index 7463663d8..b76f24ccf 100644
--- a/asm/item_menu.s
+++ b/asm/item_menu.s
@@ -812,13 +812,13 @@ sub_80A37C0: @ 80A37C0
ldr r0, _080A37F4 @ =sub_80A50C8
str r0, [r1]
movs r0, 0
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x1
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x2
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x3
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
pop {r0}
bx r0
.align 2, 0
@@ -3784,13 +3784,13 @@ sub_80A4E8C: @ 80A4E8C
movs r1, 0x1
bl sub_80F979C
movs r0, 0
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x1
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x2
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x3
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
ldr r5, _080A4F04 @ =gBGTilemapBuffers + 0x1000
lsls r4, 24
asrs r4, 24
@@ -5786,7 +5786,7 @@ sub_80A5EA0: @ 80A5EA0
bl sub_80A5DA0
ldr r1, _080A5EF4 @ =gUnknown_083C16F4
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
b _080A5F0C
.align 2, 0
_080A5EE8: .4byte gMain
@@ -6302,7 +6302,7 @@ sub_80A631C: @ 80A631C
push {lr}
lsls r0, 24
lsrs r0, 24
- ldr r2, _080A6344 @ =gUnknown_0300485C
+ ldr r2, _080A6344 @ =gFieldCallback
ldr r1, _080A6348 @ =sub_80B3050
str r1, [r2]
ldr r2, _080A634C @ =gTasks
@@ -6318,7 +6318,7 @@ sub_80A631C: @ 80A631C
pop {r0}
bx r0
.align 2, 0
-_080A6344: .4byte gUnknown_0300485C
+_080A6344: .4byte gFieldCallback
_080A6348: .4byte sub_80B3050
_080A634C: .4byte gTasks
_080A6350: .4byte c2_exit_to_overworld_2_switch
@@ -6695,7 +6695,7 @@ sub_80A6650: @ 80A6650
bl sub_80A5D78
ldr r1, _080A666C @ =gUnknown_083C16FC
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
pop {r4}
pop {r0}
bx r0
@@ -7202,8 +7202,8 @@ sub_80A6A4C: @ 80A6A4C
push {lr}
lsls r0, 24
lsrs r0, 24
- ldr r2, _080A6A74 @ =gUnknown_0300485C
- ldr r1, _080A6A78 @ =sub_813A0F8
+ ldr r2, _080A6A74 @ =gFieldCallback
+ ldr r1, _080A6A78 @ =ItemStorage_ReturnToMenuAfterDeposit
str r1, [r2]
ldr r2, _080A6A7C @ =gTasks
lsls r1, r0, 2
@@ -7218,8 +7218,8 @@ sub_80A6A4C: @ 80A6A4C
pop {r0}
bx r0
.align 2, 0
-_080A6A74: .4byte gUnknown_0300485C
-_080A6A78: .4byte sub_813A0F8
+_080A6A74: .4byte gFieldCallback
+_080A6A78: .4byte ItemStorage_ReturnToMenuAfterDeposit
_080A6A7C: .4byte gTasks
_080A6A80: .4byte c2_exit_to_overworld_2_switch
thumb_func_end sub_80A6A4C
@@ -8369,7 +8369,7 @@ sub_80A73F0: @ 80A73F0
thumb_func_start sub_80A73FC
sub_80A73FC: @ 80A73FC
push {lr}
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
bl sub_814AD44
pop {r0}
bx r0
diff --git a/asm/learn_move.s b/asm/learn_move.s
index 84d244fe8..fdf650a08 100644
--- a/asm/learn_move.s
+++ b/asm/learn_move.s
@@ -51,7 +51,7 @@ sub_813269C: @ 813269C
bne _081326C0
ldr r0, _081326CC @ =sub_81326D8
bl SetMainCallback2
- ldr r1, _081326D0 @ =gUnknown_0300485C
+ ldr r1, _081326D0 @ =gFieldCallback
ldr r0, _081326D4 @ =sub_8080990
str r0, [r1]
adds r0, r4, 0
@@ -63,7 +63,7 @@ _081326C0:
.align 2, 0
_081326C8: .4byte gPaletteFade
_081326CC: .4byte sub_81326D8
-_081326D0: .4byte gUnknown_0300485C
+_081326D0: .4byte gFieldCallback
_081326D4: .4byte sub_8080990
thumb_func_end sub_813269C
diff --git a/asm/mauville_old_man.s b/asm/mauville_old_man.s
index 90d97e9a4..726de6fc1 100644
--- a/asm/mauville_old_man.s
+++ b/asm/mauville_old_man.s
@@ -1410,7 +1410,7 @@ _080F8840:
ldr r0, _080F8870 @ =gUnknown_03000748
strb r4, [r0]
_080F8848:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x19
diff --git a/asm/menu_helpers.s b/asm/menu_helpers.s
index f10070110..0f5caf3da 100644
--- a/asm/menu_helpers.s
+++ b/asm/menu_helpers.s
@@ -161,8 +161,8 @@ _080F9140:
_080F9148: .4byte gUnknown_020388C4
thumb_func_end Task_CallYesOrNoCallback
- thumb_func_start sub_80F914C
-sub_80F914C: @ 80F914C
+ thumb_func_start DoYesNoFuncWithChoice
+DoYesNoFuncWithChoice: @ 80F914C
lsls r0, 24
lsrs r0, 24
ldr r3, _080F916C @ =gUnknown_020388C4
@@ -182,7 +182,7 @@ sub_80F914C: @ 80F914C
_080F916C: .4byte gUnknown_020388C4
_080F9170: .4byte gTasks
_080F9174: .4byte Task_CallYesOrNoCallback
- thumb_func_end sub_80F914C
+ thumb_func_end DoYesNoFuncWithChoice
thumb_func_start brm_trade_1
brm_trade_1: @ 80F9178
@@ -1207,8 +1207,8 @@ _080F98D4: .4byte gSprites
_080F98D8: .4byte SpriteCallbackDummy
thumb_func_end sub_80F98A4
- thumb_func_start sub_80F98DC
-sub_80F98DC: @ 80F98DC
+ thumb_func_start StartVerticalScrollIndicators
+StartVerticalScrollIndicators: @ 80F98DC
push {lr}
lsls r0, 24
lsrs r1, r0, 24
@@ -1235,7 +1235,7 @@ _080F9902:
_080F9908: .4byte gUnknown_020388C0
_080F990C: .4byte gSprites
_080F9910: .4byte sub_80F9834
- thumb_func_end sub_80F98DC
+ thumb_func_end StartVerticalScrollIndicators
thumb_func_start sub_80F9914
sub_80F9914: @ 80F9914
@@ -1284,8 +1284,8 @@ _080F9964: .4byte gUnknown_020388C0
_080F9968: .4byte gSprites
thumb_func_end sub_80F9914
- thumb_func_start sub_80F996C
-sub_80F996C: @ 80F996C
+ thumb_func_start PauseVerticalScrollIndicator
+PauseVerticalScrollIndicator: @ 80F996C
push {r4,lr}
adds r4, r0, 0
lsls r4, 24
@@ -1297,7 +1297,7 @@ sub_80F996C: @ 80F996C
pop {r4}
pop {r0}
bx r0
- thumb_func_end sub_80F996C
+ thumb_func_end PauseVerticalScrollIndicator
thumb_func_start sub_80F9988
sub_80F9988: @ 80F9988
diff --git a/asm/mon_markings.s b/asm/mon_markings.s
index 28bc116a9..caab4e299 100644
--- a/asm/mon_markings.s
+++ b/asm/mon_markings.s
@@ -246,7 +246,7 @@ _080F7434:
lsrs r3, r0, 16
cmp r3, 0x3
bls _080F7434
- bl sub_814A7FC
+ bl DestroyMenuCursor
lsls r0, r5, 16
asrs r0, 16
lsls r1, r6, 16
@@ -322,7 +322,7 @@ _080F74C8:
lsrs r4, r0, 16
cmp r4, 0x3
bls _080F74C8
- bl sub_814A7FC
+ bl DestroyMenuCursor
ldr r0, [r5]
ldr r0, [r0, 0x24]
cmp r0, 0
diff --git a/asm/mystery_event_script.s b/asm/mystery_event_script.s
index 93abd97bc..02b6a0a48 100644
--- a/asm/mystery_event_script.s
+++ b/asm/mystery_event_script.s
@@ -667,10 +667,10 @@ _0812668C:
lsrs r4, 16
adds r0, r4, 0
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
adds r0, r4, 0
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
_081266C6:
adds r0, r7, 0
movs r1, 0xC
diff --git a/asm/party_menu.s b/asm/party_menu.s
index 053d8b8b0..8a7c153b9 100644
--- a/asm/party_menu.s
+++ b/asm/party_menu.s
@@ -7423,7 +7423,7 @@ sub_806E7D0: @ 806E7D0
lsls r3, 24
lsrs r3, 24
bl MenuZeroFillWindowRect
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
add sp, 0x4
pop {r4-r6}
pop {r0}
diff --git a/asm/player_pc.s b/asm/player_pc.s
deleted file mode 100644
index 5e2adb775..000000000
--- a/asm/player_pc.s
+++ /dev/null
@@ -1,1298 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start sub_813AD58
-sub_813AD58: @ 813AD58
- push {lr}
- sub sp, 0x8
- lsls r0, 16
- lsrs r1, r0, 16
- ldr r2, _0813AD74 @ =0xffff0009
- adds r0, r1, r2
- cmp r0, 0x8
- bhi _0813ADE8
- lsls r0, 2
- ldr r1, _0813AD78 @ =_0813AD7C
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_0813AD74: .4byte 0xffff0009
-_0813AD78: .4byte _0813AD7C
- .align 2, 0
-_0813AD7C:
- .4byte _0813ADE0
- .4byte _0813ADD8
- .4byte _0813ADD0
- .4byte _0813ADC8
- .4byte _0813ADC0
- .4byte _0813ADB8
- .4byte _0813ADB0
- .4byte _0813ADA8
- .4byte _0813ADA0
-_0813ADA0:
- ldr r1, _0813ADA4 @ =gMenuText_GoBackToPrev
- b _0813ADF0
- .align 2, 0
-_0813ADA4: .4byte gMenuText_GoBackToPrev
-_0813ADA8:
- ldr r1, _0813ADAC @ =gOtherText_HowManyToWithdraw
- b _0813ADF0
- .align 2, 0
-_0813ADAC: .4byte gOtherText_HowManyToWithdraw
-_0813ADB0:
- ldr r1, _0813ADB4 @ =gOtherText_WithdrewThing
- b _0813ADF0
- .align 2, 0
-_0813ADB4: .4byte gOtherText_WithdrewThing
-_0813ADB8:
- ldr r1, _0813ADBC @ =gOtherText_HowManyToToss
- b _0813ADF0
- .align 2, 0
-_0813ADBC: .4byte gOtherText_HowManyToToss
-_0813ADC0:
- ldr r1, _0813ADC4 @ =gOtherText_ThrewAwayItem
- b _0813ADF0
- .align 2, 0
-_0813ADC4: .4byte gOtherText_ThrewAwayItem
-_0813ADC8:
- ldr r1, _0813ADCC @ =gOtherText_NoMoreRoom
- b _0813ADF0
- .align 2, 0
-_0813ADCC: .4byte gOtherText_NoMoreRoom
-_0813ADD0:
- ldr r1, _0813ADD4 @ =gOtherText_TooImportant
- b _0813ADF0
- .align 2, 0
-_0813ADD4: .4byte gOtherText_TooImportant
-_0813ADD8:
- ldr r1, _0813ADDC @ =gOtherText_OkayToThrowAwayPrompt
- b _0813ADF0
- .align 2, 0
-_0813ADDC: .4byte gOtherText_OkayToThrowAwayPrompt
-_0813ADE0:
- ldr r1, _0813ADE4 @ =gOtherText_SwitchWhichItem
- b _0813ADF0
- .align 2, 0
-_0813ADE4: .4byte gOtherText_SwitchWhichItem
-_0813ADE8:
- adds r0, r1, 0
- bl ItemId_GetDescription
- adds r1, r0, 0
-_0813ADF0:
- movs r0, 0x30
- str r0, [sp]
- movs r0, 0x1
- str r0, [sp, 0x4]
- adds r0, r1, 0
- movs r1, 0x8
- movs r2, 0x68
- movs r3, 0x68
- bl sub_8072AB0
- add sp, 0x8
- pop {r0}
- bx r0
- thumb_func_end sub_813AD58
-
- thumb_func_start sub_813AE0C
-sub_813AE0C: @ 813AE0C
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r2, _0813AE48 @ =gTasks + 0x8
- adds r4, r1, r2
- ldrh r1, [r4]
- ldrh r2, [r4, 0x2]
- adds r1, r2
- lsls r1, 16
- lsrs r5, r1, 16
- bl sub_813ABE8
- movs r1, 0x12
- ldrsh r0, [r4, r1]
- cmp r0, 0
- bne _0813AE62
- lsls r0, r5, 16
- asrs r1, r0, 16
- movs r2, 0x4
- ldrsh r0, [r4, r2]
- cmp r1, r0
- bne _0813AE50
- ldr r0, _0813AE4C @ =0x0000ffff
- bl sub_813AD58
- b _0813AE62
- .align 2, 0
-_0813AE48: .4byte gTasks + 0x8
-_0813AE4C: .4byte 0x0000ffff
-_0813AE50:
- ldr r0, _0813AE68 @ =gSaveBlock1
- lsls r1, 2
- adds r1, r0
- movs r0, 0x93
- lsls r0, 3
- adds r1, r0
- ldrh r0, [r1]
- bl sub_813AD58
-_0813AE62:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_0813AE68: .4byte gSaveBlock1
- thumb_func_end sub_813AE0C
-
- thumb_func_start sub_813AE6C
-sub_813AE6C: @ 813AE6C
- push {r4-r6,lr}
- sub sp, 0x8
- adds r6, r0, 0
- adds r4, r1, 0
- lsls r6, 24
- lsrs r6, 24
- lsls r4, 24
- lsrs r4, 24
- lsls r5, r6, 2
- adds r5, r6
- lsls r5, 3
- ldr r0, _0813AEF8 @ =gTasks + 0x8
- adds r5, r0
- bl sub_80F944C
- bl LoadScrollIndicatorPalette
- bl sub_813AF04
- movs r0, 0xF
- movs r1, 0
- movs r2, 0x1D
- movs r3, 0x13
- bl MenuDrawTextWindow
- movs r0, 0
- movs r1, 0xC
- movs r2, 0xE
- movs r3, 0x13
- bl MenuDrawTextWindow
- movs r0, 0
- movs r1, 0
- movs r2, 0xB
- movs r3, 0x3
- bl MenuDrawTextWindow
- ldr r0, _0813AEFC @ =gSaveBlock1
- movs r1, 0x93
- lsls r1, 3
- adds r0, r1
- ldrh r0, [r0]
- bl sub_813AD58
- ldr r0, _0813AF00 @ =gUnknown_084062C0
- lsls r4, 3
- adds r4, r0
- ldr r0, [r4]
- movs r1, 0x1
- movs r2, 0x1
- bl MenuPrint
- adds r0, r6, 0
- bl sub_813ABE8
- ldrb r3, [r5, 0x8]
- ldrb r0, [r5]
- str r0, [sp]
- movs r0, 0xD
- str r0, [sp, 0x4]
- movs r0, 0
- movs r1, 0x10
- movs r2, 0x2
- bl InitMenu
- add sp, 0x8
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_0813AEF8: .4byte gTasks + 0x8
-_0813AEFC: .4byte gSaveBlock1
-_0813AF00: .4byte gUnknown_084062C0
- thumb_func_end sub_813AE6C
-
- thumb_func_start sub_813AF04
-sub_813AF04: @ 813AF04
- push {lr}
- sub sp, 0x8
- ldr r1, _0813AF38 @ =gUnknown_08406334
- mov r0, sp
- movs r2, 0x6
- bl memcpy
- add r0, sp, 0x4
- movs r1, 0xDF
- movs r2, 0x2
- bl LoadPalette
- mov r0, sp
- adds r0, 0x2
- movs r1, 0xD1
- movs r2, 0x2
- bl LoadPalette
- mov r0, sp
- movs r1, 0xD8
- movs r2, 0x2
- bl LoadPalette
- add sp, 0x8
- pop {r0}
- bx r0
- .align 2, 0
-_0813AF38: .4byte gUnknown_08406334
- thumb_func_end sub_813AF04
-
- thumb_func_start sub_813AF3C
-sub_813AF3C: @ 813AF3C
- push {r4,lr}
- movs r2, 0
- movs r1, 0x6
- ldr r4, _0813AF70 @ =gSaveBlock1
- ldr r3, _0813AF74 @ =0x00002b6c
-_0813AF46:
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r0, r4
- adds r0, r3
- ldrh r0, [r0]
- cmp r0, 0
- beq _0813AF5C
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r2, r0, 24
-_0813AF5C:
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r1, r0, 24
- cmp r1, 0xF
- bls _0813AF46
- adds r0, r2, 0
- pop {r4}
- pop {r1}
- bx r1
- .align 2, 0
-_0813AF70: .4byte gSaveBlock1
-_0813AF74: .4byte 0x00002b6c
- thumb_func_end sub_813AF3C
-
- thumb_func_start sub_813AF78
-sub_813AF78: @ 813AF78
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x24
- movs r2, 0x6
-_0813AF86:
- adds r1, r2, 0x1
- lsls r0, r1, 24
- lsrs r3, r0, 24
- mov r10, r1
- cmp r3, 0xF
- bhi _0813AFF4
- ldr r0, _0813B010 @ =gSaveBlock1
- mov r12, r0
- lsls r0, r2, 3
- adds r0, r2
- lsls r0, 2
- add r0, r12
- ldr r1, _0813B014 @ =0x00002b6c
- adds r1, r0
- mov r8, r1
- ldr r2, _0813B018 @ =0x00002b4c
- mov r9, r2
- adds r4, r0, r2
-_0813AFAA:
- mov r5, r8
- ldrh r0, [r5]
- cmp r0, 0
- bne _0813AFEA
- mov r1, sp
- adds r0, r4, 0
- ldm r0!, {r2,r6,r7}
- stm r1!, {r2,r6,r7}
- ldm r0!, {r5-r7}
- stm r1!, {r5-r7}
- ldm r0!, {r2,r5,r6}
- stm r1!, {r2,r5,r6}
- lsls r2, r3, 3
- adds r2, r3
- lsls r2, 2
- add r2, r12
- add r2, r9
- adds r1, r4, 0
- adds r0, r2, 0
- ldm r0!, {r5-r7}
- stm r1!, {r5-r7}
- ldm r0!, {r5-r7}
- stm r1!, {r5-r7}
- ldm r0!, {r5-r7}
- stm r1!, {r5-r7}
- mov r0, sp
- ldm r0!, {r1,r5,r7}
- stm r2!, {r1,r5,r7}
- ldm r0!, {r1,r6,r7}
- stm r2!, {r1,r6,r7}
- ldm r0!, {r5-r7}
- stm r2!, {r5-r7}
-_0813AFEA:
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- cmp r3, 0xF
- bls _0813AFAA
-_0813AFF4:
- mov r1, r10
- lsls r0, r1, 24
- lsrs r2, r0, 24
- cmp r2, 0xE
- bls _0813AF86
- add sp, 0x24
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B010: .4byte gSaveBlock1
-_0813B014: .4byte 0x00002b6c
-_0813B018: .4byte 0x00002b4c
- thumb_func_end sub_813AF78
-
- thumb_func_start sub_813B01C
-sub_813B01C: @ 813B01C
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- movs r7, 0
- ldr r1, _0813B0B8 @ =0x0201fe00
- ldrb r4, [r1, 0x2]
- ldrb r0, [r1, 0x1]
- adds r0, r4, r0
- cmp r4, r0
- bge _0813B08A
- adds r6, r1, 0
- ldr r0, _0813B0BC @ =gStringVar1
- mov r8, r0
-_0813B036:
- ldrb r0, [r6, 0x2]
- subs r0, r4, r0
- lsls r0, 17
- lsrs r7, r0, 16
- adds r0, r7, 0x2
- lsls r0, 24
- lsrs r5, r0, 24
- adds r3, r7, 0x3
- lsls r3, 24
- lsrs r3, 24
- movs r0, 0x15
- adds r1, r5, 0
- movs r2, 0x1C
- bl MenuFillWindowRectWithBlankTile
- ldrb r0, [r6, 0x3]
- cmp r4, r0
- beq _0813B0C4
- lsls r1, r4, 3
- adds r1, r4
- lsls r1, 2
- ldr r0, _0813B0C0 @ =gSaveBlock1 + 0x2C36
- adds r1, r0
- mov r0, r8
- bl StringCopy
- mov r0, r8
- bl SanitizeNameString
- mov r0, r8
- movs r1, 0x15
- adds r2, r5, 0
- bl MenuPrint
- adds r0, r4, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- ldrb r0, [r6, 0x2]
- ldrb r1, [r6, 0x1]
- adds r0, r1
- cmp r4, r0
- blt _0813B036
-_0813B08A:
- ldr r5, _0813B0B8 @ =0x0201fe00
- ldrb r0, [r5, 0x2]
- subs r0, r4, r0
- cmp r0, 0x8
- beq _0813B0A4
- adds r1, r7, 0x4
- lsls r1, 24
- lsrs r1, 24
- movs r0, 0x15
- movs r2, 0x1C
- movs r3, 0x12
- bl MenuFillWindowRectWithBlankTile
-_0813B0A4:
- ldrb r0, [r5, 0x2]
- cmp r0, 0
- beq _0813B0D4
- movs r0, 0
- movs r1, 0xC8
- movs r2, 0x8
- bl CreateVerticalScrollIndicators
- b _0813B0DA
- .align 2, 0
-_0813B0B8: .4byte 0x0201fe00
-_0813B0BC: .4byte gStringVar1
-_0813B0C0: .4byte gSaveBlock1 + 0x2C36
-_0813B0C4:
- ldr r0, _0813B0D0 @ =gOtherText_CancelNoTerminator
- movs r1, 0x15
- adds r2, r5, 0
- bl MenuPrint
- b _0813B08A
- .align 2, 0
-_0813B0D0: .4byte gOtherText_CancelNoTerminator
-_0813B0D4:
- movs r0, 0
- bl DestroyVerticalScrollIndicator
-_0813B0DA:
- ldr r0, _0813B0F4 @ =0x0201fe00
- ldrb r1, [r0, 0x2]
- ldrb r2, [r0, 0x1]
- adds r1, r2
- ldrb r0, [r0, 0x3]
- cmp r1, r0
- bgt _0813B0F8
- movs r0, 0x1
- movs r1, 0xC8
- movs r2, 0x98
- bl CreateVerticalScrollIndicators
- b _0813B0FE
- .align 2, 0
-_0813B0F4: .4byte 0x0201fe00
-_0813B0F8:
- movs r0, 0x1
- bl DestroyVerticalScrollIndicator
-_0813B0FE:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_813B01C
-
- thumb_func_start sub_813B108
-sub_813B108: @ 813B108
- push {r4,lr}
- sub sp, 0x8
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- bl sub_80F944C
- bl LoadScrollIndicatorPalette
- movs r0, 0
- movs r1, 0
- movs r2, 0x1D
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- movs r0, 0
- movs r1, 0
- movs r2, 0x8
- movs r3, 0x3
- bl MenuDrawTextWindow
- ldr r0, _0813B16C @ =gPCText_Mailbox
- movs r1, 0x1
- movs r2, 0x1
- bl MenuPrint
- movs r0, 0x14
- movs r1, 0
- movs r2, 0x1D
- movs r3, 0x13
- bl MenuDrawTextWindow
- adds r0, r4, 0
- bl sub_813B01C
- ldr r0, _0813B170 @ =0x0201fe00
- ldrb r3, [r0, 0x1]
- ldrb r0, [r0]
- str r0, [sp]
- movs r0, 0x8
- str r0, [sp, 0x4]
- movs r0, 0
- movs r1, 0x15
- movs r2, 0x2
- bl InitMenu
- add sp, 0x8
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B16C: .4byte gPCText_Mailbox
-_0813B170: .4byte 0x0201fe00
- thumb_func_end sub_813B108
-
- thumb_func_start sub_813B174
-sub_813B174: @ 813B174
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- adds r4, r5, 0
- ldr r0, _0813B1AC @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r3, 0x80
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- bne _0813B274
- ldr r2, _0813B1B0 @ =gMain
- ldrh r1, [r2, 0x30]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _0813B1CA
- ldr r4, _0813B1B4 @ =0x0201fe00
- ldrb r0, [r4]
- cmp r0, 0
- beq _0813B1B8
- movs r0, 0x5
- bl PlaySE
- movs r0, 0x1
- negs r0, r0
- b _0813B1E6
- .align 2, 0
-_0813B1AC: .4byte gPaletteFade
-_0813B1B0: .4byte gMain
-_0813B1B4: .4byte 0x0201fe00
-_0813B1B8:
- ldrb r0, [r4, 0x2]
- cmp r0, 0
- beq _0813B274
- movs r0, 0x5
- bl PlaySE
- ldrb r0, [r4, 0x2]
- subs r0, 0x1
- b _0813B208
-_0813B1CA:
- adds r0, r3, 0
- ands r0, r1
- cmp r0, 0
- beq _0813B212
- ldr r4, _0813B1F0 @ =0x0201fe00
- ldrb r1, [r4]
- ldrb r0, [r4, 0x1]
- subs r0, 0x1
- cmp r1, r0
- beq _0813B1F4
- movs r0, 0x5
- bl PlaySE
- movs r0, 0x1
-_0813B1E6:
- bl MoveMenuCursor
- strb r0, [r4]
- b _0813B274
- .align 2, 0
-_0813B1F0: .4byte 0x0201fe00
-_0813B1F4:
- ldrb r0, [r4, 0x2]
- adds r0, r1
- ldrb r1, [r4, 0x3]
- cmp r0, r1
- beq _0813B274
- movs r0, 0x5
- bl PlaySE
- ldrb r0, [r4, 0x2]
- adds r0, 0x1
-_0813B208:
- strb r0, [r4, 0x2]
- adds r0, r5, 0
- bl sub_813B01C
- b _0813B274
-_0813B212:
- ldrh r1, [r2, 0x2E]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _0813B25C
- bl sub_8072DEC
- movs r0, 0x5
- bl PlaySE
- ldr r0, _0813B23C @ =0x0201fe00
- ldrb r1, [r0, 0x2]
- ldrb r2, [r0]
- adds r1, r2
- ldrb r0, [r0, 0x3]
- cmp r1, r0
- bne _0813B240
- adds r0, r5, 0
- bl sub_813B320
- b _0813B274
- .align 2, 0
-_0813B23C: .4byte 0x0201fe00
-_0813B240:
- bl sub_813B27C
- ldr r0, _0813B254 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r1, r0
- ldr r0, _0813B258 @ =sub_813B294
- str r0, [r1]
- b _0813B274
- .align 2, 0
-_0813B254: .4byte gTasks
-_0813B258: .4byte sub_813B294
-_0813B25C:
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _0813B274
- bl sub_8072DEC
- movs r0, 0x5
- bl PlaySE
- adds r0, r4, 0
- bl sub_813B320
-_0813B274:
- pop {r4,r5}
- pop {r0}
- bx r0
- thumb_func_end sub_813B174
-
- thumb_func_start sub_813B27C
-sub_813B27C: @ 813B27C
- push {lr}
- bl BuyMenuFreeMemory
- movs r0, 0
- bl DestroyVerticalScrollIndicator
- movs r0, 0x1
- bl DestroyVerticalScrollIndicator
- pop {r0}
- bx r0
- thumb_func_end sub_813B27C
-
- thumb_func_start sub_813B294
-sub_813B294: @ 813B294
- push {r4,r5,lr}
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- movs r0, 0
- movs r1, 0
- movs r2, 0x1D
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- ldr r4, _0813B2E8 @ =gStringVar1
- ldr r1, _0813B2EC @ =0x0201fe00
- ldrb r0, [r1]
- adds r0, 0x6
- ldrb r1, [r1, 0x2]
- adds r0, r1
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _0813B2F0 @ =gSaveBlock1 + 0x2B5E
- adds r1, r0
- adds r0, r4, 0
- bl StringCopy
- adds r0, r4, 0
- bl SanitizeNameString
- ldr r4, _0813B2F4 @ =gStringVar4
- ldr r1, _0813B2F8 @ =gOtherText_WhatWillYouDoMail
- adds r0, r4, 0
- bl StringExpandPlaceholders
- ldr r2, _0813B2FC @ =sub_813B348
- adds r0, r5, 0
- adds r1, r4, 0
- movs r3, 0
- bl DisplayItemMessageOnField
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B2E8: .4byte gStringVar1
-_0813B2EC: .4byte 0x0201fe00
-_0813B2F0: .4byte gSaveBlock1 + 0x2B5E
-_0813B2F4: .4byte gStringVar4
-_0813B2F8: .4byte gOtherText_WhatWillYouDoMail
-_0813B2FC: .4byte sub_813B348
- thumb_func_end sub_813B294
-
- thumb_func_start sub_813B300
-sub_813B300: @ 813B300
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0
- movs r1, 0
- movs r2, 0x1D
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- adds r0, r4, 0
- bl ReshowPlayerPC
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_813B300
-
- thumb_func_start sub_813B320
-sub_813B320: @ 813B320
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- bl sub_813B27C
- ldr r1, _0813B340 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _0813B344 @ =sub_813B300
- str r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B340: .4byte gTasks
-_0813B344: .4byte sub_813B300
- thumb_func_end sub_813B320
-
- thumb_func_start sub_813B348
-sub_813B348: @ 813B348
- push {r4,lr}
- sub sp, 0x8
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0
- movs r1, 0
- movs r2, 0xC
- movs r3, 0x9
- bl MenuDrawTextWindow
- ldr r3, _0813B394 @ =gUnknown_084062F8
- movs r0, 0x1
- movs r1, 0x1
- movs r2, 0x4
- bl PrintMenuItems
- movs r0, 0
- str r0, [sp]
- movs r0, 0xB
- str r0, [sp, 0x4]
- movs r0, 0
- movs r1, 0x1
- movs r2, 0x1
- movs r3, 0x4
- bl InitMenu
- ldr r1, _0813B398 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _0813B39C @ =sub_813B3A0
- str r1, [r0]
- add sp, 0x8
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B394: .4byte gUnknown_084062F8
-_0813B398: .4byte gTasks
-_0813B39C: .4byte sub_813B3A0
- thumb_func_end sub_813B348
-
- thumb_func_start sub_813B3A0
-sub_813B3A0: @ 813B3A0
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- adds r4, r5, 0
- ldr r2, _0813B3C4 @ =gMain
- ldrh r1, [r2, 0x30]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _0813B3C8
- movs r0, 0x5
- bl PlaySE
- movs r0, 0x1
- negs r0, r0
- bl MoveMenuCursor
- b _0813B420
- .align 2, 0
-_0813B3C4: .4byte gMain
-_0813B3C8:
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _0813B3DE
- movs r0, 0x5
- bl PlaySE
- movs r0, 0x1
- bl MoveMenuCursor
- b _0813B420
-_0813B3DE:
- ldrh r1, [r2, 0x2E]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _0813B40C
- movs r0, 0x5
- bl PlaySE
- ldr r4, _0813B408 @ =gUnknown_084062F8
- bl GetMenuCursorPos
- lsls r0, 24
- lsrs r0, 21
- adds r4, 0x4
- adds r0, r4
- ldr r1, [r0]
- adds r0, r5, 0
- bl _call_via_r1
- b _0813B420
- .align 2, 0
-_0813B408: .4byte gUnknown_084062F8
-_0813B40C:
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _0813B420
- movs r0, 0x5
- bl PlaySE
- adds r0, r4, 0
- bl Mailbox_Cancel
-_0813B420:
- pop {r4,r5}
- pop {r0}
- bx r0
- thumb_func_end sub_813B3A0
-
- thumb_func_start Mailbox_Read
-Mailbox_Read: @ 813B428
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0x1
- movs r1, 0
- bl fade_screen
- ldr r1, _0813B44C @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _0813B450 @ =sub_813B454
- str r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B44C: .4byte gTasks
-_0813B450: .4byte sub_813B454
- thumb_func_end Mailbox_Read
-
- thumb_func_start sub_813B454
-sub_813B454: @ 813B454
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r0, _0813B490 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _0813B488
- ldr r0, _0813B494 @ =0x0201fe00
- ldrb r1, [r0]
- adds r1, 0x6
- ldrb r0, [r0, 0x2]
- adds r1, r0
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _0813B498 @ =gSaveBlock1 + 0x2B4C
- adds r0, r1
- ldr r1, _0813B49C @ =sub_813B4F0
- movs r2, 0x1
- bl HandleReadMail
- adds r0, r4, 0
- bl DestroyTask
-_0813B488:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B490: .4byte gPaletteFade
-_0813B494: .4byte 0x0201fe00
-_0813B498: .4byte gSaveBlock1 + 0x2B4C
-_0813B49C: .4byte sub_813B4F0
- thumb_func_end sub_813B454
-
- thumb_func_start sub_813B4A0
-sub_813B4A0: @ 813B4A0
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- bl sub_807D770
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0x1
- bne _0813B4C0
- ldr r0, _0813B4C8 @ =gTasks
- lsls r1, r4, 2
- adds r1, r4
- lsls r1, 3
- adds r1, r0
- ldr r0, _0813B4CC @ =sub_813B174
- str r0, [r1]
-_0813B4C0:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B4C8: .4byte gTasks
-_0813B4CC: .4byte sub_813B174
- thumb_func_end sub_813B4A0
-
- thumb_func_start sub_813B4D0
-sub_813B4D0: @ 813B4D0
- push {lr}
- ldr r0, _0813B4EC @ =sub_813B4A0
- movs r1, 0
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- bl sub_813B108
- bl pal_fill_black
- pop {r0}
- bx r0
- .align 2, 0
-_0813B4EC: .4byte sub_813B4A0
- thumb_func_end sub_813B4D0
-
- thumb_func_start sub_813B4F0
-sub_813B4F0: @ 813B4F0
- push {lr}
- ldr r0, _0813B504 @ =gUnknown_0300485C
- ldr r1, _0813B508 @ =sub_813B4D0
- str r1, [r0]
- ldr r0, _0813B50C @ =c2_exit_to_overworld_2_switch
- bl SetMainCallback2
- pop {r0}
- bx r0
- .align 2, 0
-_0813B504: .4byte gUnknown_0300485C
-_0813B508: .4byte sub_813B4D0
-_0813B50C: .4byte c2_exit_to_overworld_2_switch
- thumb_func_end sub_813B4F0
-
- thumb_func_start Mailbox_MoveToBag
-Mailbox_MoveToBag: @ 813B510
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- bl sub_8072DEC
- ldr r0, _0813B540 @ =gStringVar1
- ldr r1, _0813B544 @ =gOtherText_MoveToBag
- bl StringCopy
- ldr r0, _0813B548 @ =gUnknown_0840633A
- movs r1, 0x1
- movs r2, 0x3
- bl MenuPrint
- ldr r1, _0813B54C @ =gOtherText_MessageWillBeLost
- ldr r2, _0813B550 @ =sub_813B554
- adds r0, r4, 0
- movs r3, 0
- bl DisplayItemMessageOnField
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B540: .4byte gStringVar1
-_0813B544: .4byte gOtherText_MoveToBag
-_0813B548: .4byte gUnknown_0840633A
-_0813B54C: .4byte gOtherText_MessageWillBeLost
-_0813B550: .4byte sub_813B554
- thumb_func_end Mailbox_MoveToBag
-
- thumb_func_start sub_813B554
-sub_813B554: @ 813B554
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0x14
- movs r1, 0x8
- movs r2, 0x1
- bl DisplayYesNoMenu
- ldr r1, _0813B574 @ =gUnknown_084062E8
- adds r0, r4, 0
- bl sub_80F914C
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B574: .4byte gUnknown_084062E8
- thumb_func_end sub_813B554
-
- thumb_func_start sub_813B578
-sub_813B578: @ 813B578
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- ldr r4, _0813B5BC @ =0x0201fe00
- ldrb r0, [r4]
- adds r0, 0x6
- ldrb r1, [r4, 0x2]
- adds r0, r1
- lsls r1, r0, 3
- adds r1, r0
- lsls r1, 2
- ldr r0, _0813B5C0 @ =gSaveBlock1 + 0x2B4C
- adds r6, r1, r0
- movs r0, 0x14
- movs r1, 0x8
- movs r2, 0x1A
- movs r3, 0xD
- bl MenuZeroFillWindowRect
- ldrh r0, [r6, 0x20]
- movs r1, 0x1
- bl AddBagItem
- lsls r0, 24
- cmp r0, 0
- bne _0813B5CC
- ldr r1, _0813B5C4 @ =gOtherText_BagIsFull
- ldr r2, _0813B5C8 @ =sub_813B758
- adds r0, r5, 0
- movs r3, 0
- bl DisplayItemMessageOnField
- b _0813B602
- .align 2, 0
-_0813B5BC: .4byte 0x0201fe00
-_0813B5C0: .4byte gSaveBlock1 + 0x2B4C
-_0813B5C4: .4byte gOtherText_BagIsFull
-_0813B5C8: .4byte sub_813B758
-_0813B5CC:
- ldr r1, _0813B608 @ =gOtherText_MailWasReturned
- ldr r2, _0813B60C @ =sub_813B758
- adds r0, r5, 0
- movs r3, 0
- bl DisplayItemMessageOnField
- adds r0, r6, 0
- bl ClearMailStruct
- bl sub_813AF78
- ldrb r0, [r4, 0x3]
- subs r0, 0x1
- strb r0, [r4, 0x3]
- ldrb r1, [r4, 0x3]
- ldrb r0, [r4, 0x1]
- ldrb r2, [r4, 0x2]
- adds r0, r2
- cmp r1, r0
- bge _0813B5FC
- cmp r2, 0
- beq _0813B5FC
- subs r0, r2, 0x1
- strb r0, [r4, 0x2]
-_0813B5FC:
- adds r0, r5, 0
- bl sub_813A240
-_0813B602:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B608: .4byte gOtherText_MailWasReturned
-_0813B60C: .4byte sub_813B758
- thumb_func_end sub_813B578
-
- thumb_func_start sub_813B610
-sub_813B610: @ 813B610
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0x14
- movs r1, 0x8
- movs r2, 0x1A
- movs r3, 0xD
- bl MenuZeroFillWindowRect
- adds r0, r4, 0
- bl sub_813B758
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_813B610
-
- thumb_func_start Mailbox_Give
-Mailbox_Give: @ 813B630
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- bl CalculatePlayerPartyCount
- lsls r0, 24
- cmp r0, 0
- bne _0813B648
- adds r0, r4, 0
- bl sub_813B718
- b _0813B65E
-_0813B648:
- movs r0, 0x1
- movs r1, 0
- bl fade_screen
- ldr r0, _0813B664 @ =gTasks
- lsls r1, r4, 2
- adds r1, r4
- lsls r1, 3
- adds r1, r0
- ldr r0, _0813B668 @ =sub_813B66C
- str r0, [r1]
-_0813B65E:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B664: .4byte gTasks
-_0813B668: .4byte sub_813B66C
- thumb_func_end Mailbox_Give
-
- thumb_func_start sub_813B66C
-sub_813B66C: @ 813B66C
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r0, _0813B698 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _0813B690
- ldr r0, _0813B69C @ =sub_808B020
- bl SetMainCallback2
- ldr r1, _0813B6A0 @ =gUnknown_02038561
- movs r0, 0x3
- strb r0, [r1]
- adds r0, r4, 0
- bl DestroyTask
-_0813B690:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B698: .4byte gPaletteFade
-_0813B69C: .4byte sub_808B020
-_0813B6A0: .4byte gUnknown_02038561
- thumb_func_end sub_813B66C
-
- thumb_func_start sub_813B6A4
-sub_813B6A4: @ 813B6A4
- push {r4-r6,lr}
- ldr r0, _0813B6F0 @ =sub_813B4A0
- movs r1, 0
- bl CreateTask
- lsls r0, 24
- lsrs r6, r0, 24
- ldr r5, _0813B6F4 @ =0x0201fe00
- ldrb r4, [r5, 0x3]
- bl sub_813AF3C
- strb r0, [r5, 0x3]
- bl sub_813AF78
- ldrb r0, [r5, 0x3]
- cmp r4, r0
- beq _0813B6DA
- ldrb r1, [r5, 0x3]
- ldrb r0, [r5, 0x1]
- ldrb r2, [r5, 0x2]
- adds r0, r2
- cmp r1, r0
- bge _0813B6DA
- cmp r2, 0
- beq _0813B6DA
- subs r0, r2, 0x1
- strb r0, [r5, 0x2]
-_0813B6DA:
- adds r0, r6, 0
- bl sub_813A240
- adds r0, r6, 0
- bl sub_813B108
- bl pal_fill_black
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B6F0: .4byte sub_813B4A0
-_0813B6F4: .4byte 0x0201fe00
- thumb_func_end sub_813B6A4
-
- thumb_func_start sub_813B6F8
-sub_813B6F8: @ 813B6F8
- push {lr}
- ldr r0, _0813B70C @ =gUnknown_0300485C
- ldr r1, _0813B710 @ =sub_813B6A4
- str r1, [r0]
- ldr r0, _0813B714 @ =c2_exit_to_overworld_2_switch
- bl SetMainCallback2
- pop {r0}
- bx r0
- .align 2, 0
-_0813B70C: .4byte gUnknown_0300485C
-_0813B710: .4byte sub_813B6A4
-_0813B714: .4byte c2_exit_to_overworld_2_switch
- thumb_func_end sub_813B6F8
-
- thumb_func_start sub_813B718
-sub_813B718: @ 813B718
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r1, _0813B72C @ =gOtherText_NoPokemon
- ldr r2, _0813B730 @ =sub_813B758
- movs r3, 0
- bl DisplayItemMessageOnField
- pop {r0}
- bx r0
- .align 2, 0
-_0813B72C: .4byte gOtherText_NoPokemon
-_0813B730: .4byte sub_813B758
- thumb_func_end sub_813B718
-
- thumb_func_start Mailbox_Cancel
-Mailbox_Cancel: @ 813B734
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- bl sub_8072DEC
- movs r0, 0
- movs r1, 0
- movs r2, 0xC
- movs r3, 0x9
- bl MenuZeroFillWindowRect
- adds r0, r4, 0
- bl sub_813B758
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end Mailbox_Cancel
-
- thumb_func_start sub_813B758
-sub_813B758: @ 813B758
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r4, 0
- bl sub_813B108
- ldr r1, _0813B77C @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _0813B780 @ =sub_813B174
- str r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_0813B77C: .4byte gTasks
-_0813B780: .4byte sub_813B174
- thumb_func_end sub_813B758
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/pokeblock.s b/asm/pokeblock.s
index 44ac16b7e..74da210b0 100644
--- a/asm/pokeblock.s
+++ b/asm/pokeblock.s
@@ -1539,7 +1539,7 @@ sub_810C2C8: @ 810C2C8
ldrb r0, [r4]
cmp r0, 0x3
bne _0810C2E8
- ldr r1, _0810C310 @ =gUnknown_0300485C
+ ldr r1, _0810C310 @ =gFieldCallback
ldr r0, _0810C314 @ =sub_8080990
str r0, [r1]
_0810C2E8:
@@ -1559,7 +1559,7 @@ _0810C300:
.align 2, 0
_0810C308: .4byte gPaletteFade
_0810C30C: .4byte gUnknown_02039244
-_0810C310: .4byte gUnknown_0300485C
+_0810C310: .4byte gFieldCallback
_0810C314: .4byte sub_8080990
_0810C318: .4byte gUnknown_083F7EA8
thumb_func_end sub_810C2C8
@@ -1830,7 +1830,7 @@ sub_810C540: @ 810C540
lsrs r5, 24
ldr r0, _0810C5A0 @ =gWindowConfig_81E6E50
bl BasicInitMenuWindow
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x7
movs r1, 0x4
movs r2, 0xD
@@ -1912,7 +1912,7 @@ sub_810C5EC: @ 810C5EC
bl DisplayYesNoMenu
ldr r1, _0810C60C @ =gUnknown_083F7F24
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
pop {r4}
pop {r0}
bx r0
@@ -1965,9 +1965,9 @@ sub_810C668: @ 810C668
lsls r0, 24
lsrs r4, r0, 24
movs r0, 0
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x1
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
ldr r2, _0810C6CC @ =gUnknown_02039248
ldrb r0, [r2, 0x2]
ldrb r1, [r2, 0x3]
@@ -2075,10 +2075,10 @@ sub_810C748: @ 810C748
lsls r4, 24
lsrs r4, 24
movs r0, 0
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x1
- bl sub_80F98DC
- bl sub_8072DEC
+ bl StartVerticalScrollIndicators
+ bl HandleDestroyMenuCursors
movs r0, 0x7
movs r1, 0x4
movs r2, 0xD
diff --git a/asm/pokedex.s b/asm/pokedex.s
deleted file mode 100644
index 8fd971840..000000000
--- a/asm/pokedex.s
+++ /dev/null
@@ -1,5294 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start sub_8090750
-sub_8090750: @ 8090750
- push {r4-r7,lr}
- sub sp, 0x8
- lsls r0, 24
- lsrs r7, r0, 24
- ldr r1, _08090778 @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- ldrh r6, [r0, 0xA]
- movs r2, 0x8
- ldrsh r0, [r0, r2]
- adds r4, r1, 0
- cmp r0, 0x6
- bhi _0809079C
- lsls r0, 2
- ldr r1, _0809077C @ =_08090780
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08090778: .4byte gTasks
-_0809077C: .4byte _08090780
- .align 2, 0
-_08090780:
- .4byte _0809079C
- .4byte _080907E0
- .4byte _0809085C
- .4byte _080908A0
- .4byte _08090960
- .4byte _080909B8
- .4byte _080909F4
-_0809079C:
- ldr r0, _080907D0 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _080907AA
- b _08090A26
-_080907AA:
- ldr r1, _080907D4 @ =gUnknown_03005CEC
- ldr r0, _080907D8 @ =gMain
- ldr r0, [r0, 0xC]
- str r0, [r1]
- movs r0, 0
- bl SetVBlankCallback
- movs r0, 0x80
- lsls r0, 1
- bl sub_8091060
- ldr r1, _080907DC @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- movs r1, 0x1
- strh r1, [r0, 0x8]
- b _08090A26
- .align 2, 0
-_080907D0: .4byte gPaletteFade
-_080907D4: .4byte gUnknown_03005CEC
-_080907D8: .4byte gMain
-_080907DC: .4byte gTasks
-_080907E0:
- ldr r0, _08090840 @ =gPokedexMenu_Gfx
- ldr r1, _08090844 @ =0x06004000
- bl LZ77UnCompVram
- ldr r0, _08090848 @ =gUnknown_08E96BD4
- ldr r4, _0809084C @ =0x06007800
- adds r1, r4, 0
- bl LZ77UnCompVram
- movs r2, 0
- lsls r5, r7, 2
- mov r12, r5
- movs r0, 0x80
- lsls r0, 6
- adds r6, r0, 0
- ldr r3, _08090850 @ =0x0000027f
-_08090800:
- lsls r0, r2, 1
- adds r0, r4
- ldrh r5, [r0]
- adds r1, r6, r5
- strh r1, [r0]
- adds r0, r2, 0x1
- lsls r0, 16
- lsrs r2, r0, 16
- cmp r2, r3
- bls _08090800
- ldr r0, _08090854 @ =gTasks
- mov r1, r12
- adds r4, r1, r7
- lsls r4, 3
- adds r4, r0
- ldrh r0, [r4, 0xA]
- movs r2, 0xFF
- lsls r2, 2
- movs r1, 0x2
- bl sub_8091738
- bl ResetPaletteFade
- ldr r0, _08090858 @ =gPokedexMenu_Pal + 0x2
- movs r1, 0x21
- movs r2, 0x9E
- bl LoadPalette
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- b _08090A26
- .align 2, 0
-_08090840: .4byte gPokedexMenu_Gfx
-_08090844: .4byte 0x06004000
-_08090848: .4byte gUnknown_08E96BD4
-_0809084C: .4byte 0x06007800
-_08090850: .4byte 0x0000027f
-_08090854: .4byte gTasks
-_08090858: .4byte gPokedexMenu_Pal + 0x2
-_0809085C:
- ldr r4, _0809088C @ =gWindowConfig_81E7064
- adds r0, r4, 0
- bl SetUpWindowConfig
- adds r0, r4, 0
- bl InitMenuWindow
- ldr r2, _08090890 @ =0x0600c000
- add r1, sp, 0x4
- movs r0, 0
- strh r0, [r1]
- ldr r0, _08090894 @ =0x040000d4
- str r1, [r0]
- str r2, [r0, 0x4]
- ldr r1, _08090898 @ =0x81000100
- str r1, [r0, 0x8]
- ldr r0, [r0, 0x8]
- ldr r1, _0809089C @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- b _080909E0
- .align 2, 0
-_0809088C: .4byte gWindowConfig_81E7064
-_08090890: .4byte 0x0600c000
-_08090894: .4byte 0x040000d4
-_08090898: .4byte 0x81000100
-_0809089C: .4byte gTasks
-_080908A0:
- ldr r0, _080908C8 @ =gDexText_RegisterComplete
- movs r1, 0x2
- movs r2, 0
- movs r3, 0xD0
- bl sub_8072BD8
- bl IsNationalPokedexEnabled
- cmp r0, 0
- bne _080908CC
- adds r0, r6, 0
- bl NationalToHoennOrder
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0xD
- movs r2, 0x3
- bl sub_8091154
- b _080908D6
- .align 2, 0
-_080908C8: .4byte gDexText_RegisterComplete
-_080908CC:
- adds r0, r6, 0
- movs r1, 0xD
- movs r2, 0x3
- bl sub_8091154
-_080908D6:
- adds r0, r6, 0
- movs r1, 0x10
- movs r2, 0x3
- bl sub_80911C8
- ldr r0, _0809094C @ =gDexText_UnknownPoke
- movs r1, 0xB
- movs r2, 0x5
- bl MenuPrint
- ldr r0, _08090950 @ =gDexText_UnknownHeight
- movs r1, 0x10
- movs r2, 0x7
- bl MenuPrint
- ldr r0, _08090954 @ =gDexText_UnknownWeight
- movs r1, 0x10
- movs r2, 0x9
- bl MenuPrint
- lsls r4, r6, 3
- adds r4, r6
- lsls r4, 2
- ldr r6, _08090958 @ =gPokedexEntries
- adds r5, r4, r6
- adds r0, r5, 0
- movs r1, 0xB
- movs r2, 0x5
- bl sub_8091304
- ldrh r0, [r5, 0xC]
- movs r1, 0x10
- movs r2, 0x7
- bl sub_8091458
- ldrh r0, [r5, 0xE]
- movs r1, 0x10
- movs r2, 0x9
- bl sub_8091564
- adds r6, 0x10
- adds r4, r6
- ldr r0, [r4]
- movs r1, 0x2
- movs r2, 0xD
- bl MenuPrint
- movs r1, 0xFF
- lsls r1, 2
- movs r0, 0xE
- bl sub_80917CC
- ldr r1, _0809095C @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- b _080909E0
- .align 2, 0
-_0809094C: .4byte gDexText_UnknownPoke
-_08090950: .4byte gDexText_UnknownHeight
-_08090954: .4byte gDexText_UnknownWeight
-_08090958: .4byte gPokedexEntries
-_0809095C: .4byte gTasks
-_08090960:
- adds r0, r6, 0
- movs r1, 0x30
- movs r2, 0x38
- movs r3, 0
- bl sub_80918EC
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- ldr r0, _080909AC @ =gSprites
- lsls r1, r4, 4
- adds r1, r4
- lsls r1, 2
- adds r1, r0
- ldrb r2, [r1, 0x5]
- movs r0, 0xD
- negs r0, r0
- ands r0, r2
- strb r0, [r1, 0x5]
- movs r0, 0x1
- negs r0, r0
- movs r1, 0
- str r1, [sp]
- movs r2, 0x10
- movs r3, 0
- bl BeginNormalPaletteFade
- ldr r0, _080909B0 @ =gUnknown_03005CEC
- ldr r0, [r0]
- bl SetVBlankCallback
- ldr r1, _080909B4 @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- strh r4, [r0, 0xE]
- b _080909E0
- .align 2, 0
-_080909AC: .4byte gSprites
-_080909B0: .4byte gUnknown_03005CEC
-_080909B4: .4byte gTasks
-_080909B8:
- ldr r0, _080909E8 @ =REG_BLDCNT
- movs r1, 0
- strh r1, [r0]
- adds r0, 0x2
- strh r1, [r0]
- adds r0, 0x2
- strh r1, [r0]
- ldr r1, _080909EC @ =REG_BG3CNT
- ldr r2, _080909F0 @ =0x00000f07
- adds r0, r2, 0
- strh r0, [r1]
- subs r1, 0xE
- movs r5, 0xE2
- lsls r5, 5
- adds r0, r5, 0
- strh r0, [r1]
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r4
-_080909E0:
- ldrh r1, [r0, 0x8]
- adds r1, 0x1
- strh r1, [r0, 0x8]
- b _08090A26
- .align 2, 0
-_080909E8: .4byte REG_BLDCNT
-_080909EC: .4byte REG_BG3CNT
-_080909F0: .4byte 0x00000f07
-_080909F4:
- ldr r0, _08090A30 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- lsls r0, 24
- lsrs r5, r0, 24
- cmp r5, 0
- bne _08090A26
- adds r0, r6, 0
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0
- bl PlayCry1
- ldr r1, _08090A34 @ =gTasks
- lsls r0, r7, 2
- adds r0, r7
- lsls r0, 3
- adds r0, r1
- strh r5, [r0, 0xC]
- strh r5, [r0, 0x10]
- ldr r1, _08090A38 @ =sub_8090A3C
- str r1, [r0]
-_08090A26:
- add sp, 0x8
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08090A30: .4byte gPaletteFade
-_08090A34: .4byte gTasks
-_08090A38: .4byte sub_8090A3C
- thumb_func_end sub_8090750
-
- thumb_func_start sub_8090A3C
-sub_8090A3C: @ 8090A3C
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- sub sp, 0x4
- lsls r0, 24
- lsrs r6, r0, 24
- ldr r0, _08090A8C @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x2
- ands r0, r1
- lsls r0, 16
- lsrs r2, r0, 16
- cmp r2, 0
- beq _08090AA4
- ldr r0, _08090A90 @ =0x0000fffc
- movs r1, 0
- str r1, [sp]
- movs r2, 0
- movs r3, 0x10
- bl BeginNormalPaletteFade
- ldr r3, _08090A94 @ =gSprites
- ldr r0, _08090A98 @ =gTasks
- lsls r1, r6, 2
- adds r1, r6
- lsls r1, 3
- adds r1, r0
- movs r0, 0xE
- ldrsh r2, [r1, r0]
- lsls r0, r2, 4
- adds r0, r2
- lsls r0, 2
- adds r3, 0x1C
- adds r0, r3
- ldr r2, _08090A9C @ =sub_8090C28
- str r2, [r0]
- ldr r0, _08090AA0 @ =sub_8090B8C
- str r0, [r1]
- b _08090B7A
- .align 2, 0
-_08090A8C: .4byte gMain
-_08090A90: .4byte 0x0000fffc
-_08090A94: .4byte gSprites
-_08090A98: .4byte gTasks
-_08090A9C: .4byte sub_8090C28
-_08090AA0: .4byte sub_8090B8C
-_08090AA4:
- movs r0, 0x1
- mov r8, r0
- ands r0, r1
- lsls r7, r6, 2
- cmp r0, 0
- beq _08090B44
- ldr r0, _08090B00 @ =gTasks
- adds r1, r7, r6
- lsls r1, 3
- adds r5, r1, r0
- movs r1, 0x10
- ldrsh r0, [r5, r1]
- cmp r0, 0
- bne _08090B0C
- ldrh r4, [r5, 0xA]
- movs r0, 0x2
- movs r1, 0xD
- movs r2, 0x1B
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- ldr r1, _08090B04 @ =gPokedexEntries
- lsls r0, r4, 3
- adds r0, r4
- lsls r0, 2
- adds r1, 0x14
- adds r0, r1
- ldr r0, [r0]
- movs r1, 0x2
- movs r2, 0xD
- bl MenuPrint
- ldr r1, _08090B08 @ =0x06007aca
- ldrh r0, [r1]
- adds r0, 0x1
- strh r0, [r1]
- adds r1, 0x40
- ldrh r0, [r1]
- adds r0, 0x1
- strh r0, [r1]
- mov r0, r8
- strh r0, [r5, 0x10]
- movs r0, 0x15
- bl PlaySE
- b _08090B44
- .align 2, 0
-_08090B00: .4byte gTasks
-_08090B04: .4byte gPokedexEntries
-_08090B08: .4byte 0x06007aca
-_08090B0C:
- ldr r0, _08090B34 @ =0x0000fffc
- str r2, [sp]
- movs r1, 0
- movs r2, 0
- movs r3, 0x10
- bl BeginNormalPaletteFade
- ldr r2, _08090B38 @ =gSprites
- movs r0, 0xE
- ldrsh r1, [r5, r0]
- lsls r0, r1, 4
- adds r0, r1
- lsls r0, 2
- adds r2, 0x1C
- adds r0, r2
- ldr r1, _08090B3C @ =sub_8090C28
- str r1, [r0]
- ldr r0, _08090B40 @ =sub_8090B8C
- str r0, [r5]
- b _08090B7A
- .align 2, 0
-_08090B34: .4byte 0x0000fffc
-_08090B38: .4byte gSprites
-_08090B3C: .4byte sub_8090C28
-_08090B40: .4byte sub_8090B8C
-_08090B44:
- ldr r1, _08090B68 @ =gTasks
- adds r0, r7, r6
- lsls r0, 3
- adds r0, r1
- ldrh r1, [r0, 0xC]
- adds r1, 0x1
- strh r1, [r0, 0xC]
- movs r0, 0x10
- ands r1, r0
- cmp r1, 0
- beq _08090B70
- ldr r0, _08090B6C @ =gPokedexMenu_Pal + 0x2
- movs r1, 0x51
- movs r2, 0xE
- bl LoadPalette
- b _08090B7A
- .align 2, 0
-_08090B68: .4byte gTasks
-_08090B6C: .4byte gPokedexMenu_Pal + 0x2
-_08090B70:
- ldr r0, _08090B88 @ =gPokedexMenu2_Pal + 0x2
- movs r1, 0x51
- movs r2, 0xE
- bl LoadPalette
-_08090B7A:
- add sp, 0x4
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08090B88: .4byte gPokedexMenu2_Pal + 0x2
- thumb_func_end sub_8090A3C
-
- thumb_func_start sub_8090B8C
-sub_8090B8C: @ 8090B8C
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r6, r0, 24
- ldr r0, _08090C14 @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08090C0C
- movs r1, 0x80
- lsls r1, 19
- movs r2, 0xCA
- lsls r2, 5
- adds r0, r2, 0
- strh r0, [r1]
- ldr r0, _08090C18 @ =gUnknown_08D00524
- ldr r1, _08090C1C @ =0x0600c000
- movs r2, 0x80
- lsls r2, 4
- bl CpuSet
- bl sub_800D74C
- ldr r0, _08090C20 @ =gTasks
- lsls r4, r6, 2
- adds r4, r6
- lsls r4, 3
- adds r4, r0
- ldrh r0, [r4, 0xA]
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r0, 16
- ldrh r1, [r4, 0x22]
- lsls r1, 16
- ldrh r2, [r4, 0x20]
- orrs r1, r2
- ldrh r2, [r4, 0x26]
- lsls r2, 16
- ldrh r3, [r4, 0x24]
- orrs r2, r3
- ldr r5, _08090C24 @ =gSprites
- movs r3, 0xE
- ldrsh r4, [r4, r3]
- lsls r3, r4, 4
- adds r3, r4
- lsls r3, 2
- adds r3, r5
- ldrb r4, [r3, 0x5]
- lsrs r4, 4
- bl species_and_otid_get_pal
- lsls r4, 4
- movs r2, 0x80
- lsls r2, 1
- adds r1, r2, 0
- orrs r4, r1
- adds r1, r4, 0
- movs r2, 0x20
- bl LoadCompressedPalette
- adds r0, r6, 0
- bl DestroyTask
-_08090C0C:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08090C14: .4byte gPaletteFade
-_08090C18: .4byte gUnknown_08D00524
-_08090C1C: .4byte 0x0600c000
-_08090C20: .4byte gTasks
-_08090C24: .4byte gSprites
- thumb_func_end sub_8090B8C
-
- thumb_func_start sub_8090C28
-sub_8090C28: @ 8090C28
- push {lr}
- adds r1, r0, 0
- ldrh r2, [r1, 0x20]
- movs r3, 0x20
- ldrsh r0, [r1, r3]
- cmp r0, 0x77
- bgt _08090C3A
- adds r0, r2, 0x2
- strh r0, [r1, 0x20]
-_08090C3A:
- ldrh r2, [r1, 0x20]
- movs r3, 0x20
- ldrsh r0, [r1, r3]
- cmp r0, 0x78
- ble _08090C48
- subs r0, r2, 0x2
- strh r0, [r1, 0x20]
-_08090C48:
- ldrh r2, [r1, 0x22]
- movs r3, 0x22
- ldrsh r0, [r1, r3]
- cmp r0, 0x4F
- bgt _08090C56
- adds r0, r2, 0x1
- strh r0, [r1, 0x22]
-_08090C56:
- ldrh r2, [r1, 0x22]
- movs r3, 0x22
- ldrsh r0, [r1, r3]
- cmp r0, 0x50
- ble _08090C64
- subs r0, r2, 0x1
- strh r0, [r1, 0x22]
-_08090C64:
- pop {r0}
- bx r0
- thumb_func_end sub_8090C28
-
- thumb_func_start sub_8090C68
-sub_8090C68: @ 8090C68
- push {r4,r5,lr}
- ldr r4, _08090CD0 @ =gUnknown_0202FFBC
- ldr r0, [r4]
- ldrb r1, [r0, 0x2]
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _08090D2A
- ldr r5, _08090CD4 @ =gPokedexView
- ldr r0, [r5]
- ldr r1, _08090CD8 @ =0x0000064e
- adds r0, r1
- ldrb r0, [r0]
- cmp r0, 0
- bne _08090CE4
- movs r0, 0x2
- movs r1, 0xD
- movs r2, 0x1B
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- ldr r2, _08090CDC @ =gPokedexEntries
- ldr r0, [r4]
- ldrh r1, [r0]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r2, 0x14
- adds r0, r2
- ldr r0, [r0]
- movs r1, 0x2
- movs r2, 0xD
- bl MenuPrint
- ldr r0, [r5]
- ldr r1, _08090CD8 @ =0x0000064e
- adds r0, r1
- movs r1, 0x1
- strb r1, [r0]
- ldr r1, _08090CE0 @ =0x06007aca
- ldrh r0, [r1]
- adds r0, 0x1
- strh r0, [r1]
- adds r1, 0x40
- ldrh r0, [r1]
- adds r0, 0x1
- strh r0, [r1]
- movs r0, 0x15
- bl PlaySE
- b _08090D2A
- .align 2, 0
-_08090CD0: .4byte gUnknown_0202FFBC
-_08090CD4: .4byte gPokedexView
-_08090CD8: .4byte 0x0000064e
-_08090CDC: .4byte gPokedexEntries
-_08090CE0: .4byte 0x06007aca
-_08090CE4:
- movs r0, 0x2
- movs r1, 0xD
- movs r2, 0x1B
- movs r3, 0x13
- bl MenuZeroFillWindowRect
- ldr r2, _08090D30 @ =gPokedexEntries
- ldr r0, [r4]
- ldrh r1, [r0]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- adds r2, 0x10
- adds r0, r2
- ldr r0, [r0]
- movs r1, 0x2
- movs r2, 0xD
- bl MenuPrint
- ldr r0, [r5]
- ldr r1, _08090D34 @ =0x0000064e
- adds r0, r1
- movs r1, 0
- strb r1, [r0]
- ldr r1, _08090D38 @ =0x06007aca
- ldrh r0, [r1]
- subs r0, 0x1
- strh r0, [r1]
- adds r1, 0x40
- ldrh r0, [r1]
- subs r0, 0x1
- strh r0, [r1]
- movs r0, 0x15
- bl PlaySE
-_08090D2A:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08090D30: .4byte gPokedexEntries
-_08090D34: .4byte 0x0000064e
-_08090D38: .4byte 0x06007aca
- thumb_func_end sub_8090C68
-
- thumb_func_start GetPokemonCategory
-GetPokemonCategory: @ 8090D3C
- adds r1, r0, 0
- lsls r1, 16
- lsrs r1, 16
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _08090D50 @ =gPokedexEntries
- adds r0, r1
- bx lr
- .align 2, 0
-_08090D50: .4byte gPokedexEntries
- thumb_func_end GetPokemonCategory
-
- thumb_func_start GetPokedexHeightWeight
-GetPokedexHeightWeight: @ 8090D54
- push {lr}
- lsls r0, 16
- lsrs r2, r0, 16
- lsls r1, 24
- lsrs r1, 24
- cmp r1, 0
- beq _08090D6A
- cmp r1, 0x1
- beq _08090D7C
- movs r0, 0x1
- b _08090D88
-_08090D6A:
- ldr r0, _08090D78 @ =gPokedexEntries
- lsls r1, r2, 3
- adds r1, r2
- lsls r1, 2
- adds r1, r0
- ldrh r0, [r1, 0xC]
- b _08090D88
- .align 2, 0
-_08090D78: .4byte gPokedexEntries
-_08090D7C:
- ldr r0, _08090D8C @ =gPokedexEntries
- lsls r1, r2, 3
- adds r1, r2
- lsls r1, 2
- adds r1, r0
- ldrh r0, [r1, 0xE]
-_08090D88:
- pop {r1}
- bx r1
- .align 2, 0
-_08090D8C: .4byte gPokedexEntries
- thumb_func_end GetPokedexHeightWeight
-
- thumb_func_start sub_8090D90
-sub_8090D90: @ 8090D90
- push {r4-r7,lr}
- lsls r0, 16
- lsls r1, 24
- lsrs r2, r1, 24
- adds r3, r2, 0
- ldr r1, _08090DC4 @ =0xffff0000
- adds r0, r1
- lsrs r1, r0, 16
- lsrs r0, 19
- lsls r0, 24
- lsrs r4, r0, 24
- movs r0, 0x7
- ands r1, r0
- movs r0, 0x80
- lsls r0, 17
- lsls r0, r1
- lsrs r5, r0, 24
- movs r6, 0
- cmp r2, 0x1
- beq _08090E24
- cmp r2, 0x1
- bgt _08090DC8
- cmp r2, 0
- beq _08090DD4
- b _08090F0A
- .align 2, 0
-_08090DC4: .4byte 0xffff0000
-_08090DC8:
- cmp r3, 0x2
- beq _08090EBC
- cmp r3, 0x3
- bne _08090DD2
- b _08090EFC
-_08090DD2:
- b _08090F0A
-_08090DD4:
- ldr r1, _08090E14 @ =gSaveBlock2
- adds r0, r1, 0
- adds r0, 0x5C
- adds r0, r4, r0
- ldrb r2, [r0]
- ands r2, r5
- adds r7, r1, 0
- cmp r2, 0
- bne _08090DE8
- b _08090F0A
-_08090DE8:
- ldr r0, _08090E18 @ =gSaveBlock1
- ldr r3, _08090E1C @ =0x00000938
- adds r1, r0, r3
- adds r1, r4, r1
- ldrb r1, [r1]
- ands r1, r5
- adds r6, r0, 0
- cmp r2, r1
- bne _08090E08
- ldr r1, _08090E20 @ =0x00003a8c
- adds r0, r6, r1
- adds r0, r4, r0
- ldrb r0, [r0]
- ands r0, r5
- cmp r2, r0
- beq _08090E62
-_08090E08:
- adds r1, r7, 0
- adds r1, 0x5C
- adds r1, r4, r1
- mvns r3, r5
- b _08090E8E
- .align 2, 0
-_08090E14: .4byte gSaveBlock2
-_08090E18: .4byte gSaveBlock1
-_08090E1C: .4byte 0x00000938
-_08090E20: .4byte 0x00003a8c
-_08090E24:
- ldr r1, _08090E68 @ =gSaveBlock2
- adds r0, r1, 0
- adds r0, 0x28
- adds r0, r4, r0
- ldrb r2, [r0]
- ands r2, r5
- adds r7, r1, 0
- cmp r2, 0
- beq _08090F0A
- adds r0, r7, 0
- adds r0, 0x5C
- adds r0, r4, r0
- ldrb r0, [r0]
- ands r0, r5
- ldr r6, _08090E6C @ =gSaveBlock1
- cmp r2, r0
- bne _08090E78
- ldr r3, _08090E70 @ =0x00000938
- adds r0, r6, r3
- adds r0, r4, r0
- ldrb r0, [r0]
- ands r0, r5
- cmp r2, r0
- bne _08090E78
- ldr r1, _08090E74 @ =0x00003a8c
- adds r0, r6, r1
- adds r0, r4, r0
- ldrb r0, [r0]
- ands r0, r5
- cmp r2, r0
- bne _08090E78
-_08090E62:
- movs r6, 0x1
- b _08090F0A
- .align 2, 0
-_08090E68: .4byte gSaveBlock2
-_08090E6C: .4byte gSaveBlock1
-_08090E70: .4byte 0x00000938
-_08090E74: .4byte 0x00003a8c
-_08090E78:
- adds r1, r7, 0
- adds r1, 0x28
- adds r1, r4, r1
- mvns r3, r5
- ldrb r2, [r1]
- adds r0, r3, 0
- ands r0, r2
- strb r0, [r1]
- adds r1, r7, 0
- adds r1, 0x5C
- adds r1, r4, r1
-_08090E8E:
- ldrb r2, [r1]
- adds r0, r3, 0
- ands r0, r2
- strb r0, [r1]
- ldr r0, _08090EB4 @ =0x00000938
- adds r1, r6, r0
- adds r1, r4, r1
- ldrb r2, [r1]
- adds r0, r3, 0
- ands r0, r2
- strb r0, [r1]
- ldr r1, _08090EB8 @ =0x00003a8c
- adds r0, r6, r1
- adds r0, r4, r0
- ldrb r1, [r0]
- ands r3, r1
- strb r3, [r0]
- movs r6, 0
- b _08090F0A
- .align 2, 0
-_08090EB4: .4byte 0x00000938
-_08090EB8: .4byte 0x00003a8c
-_08090EBC:
- ldr r1, _08090EEC @ =gSaveBlock2
- adds r1, 0x5C
- adds r1, r4, r1
- ldrb r2, [r1]
- adds r0, r5, 0
- orrs r0, r2
- strb r0, [r1]
- ldr r1, _08090EF0 @ =gSaveBlock1
- ldr r3, _08090EF4 @ =0x00000938
- adds r2, r1, r3
- adds r2, r4, r2
- ldrb r3, [r2]
- adds r0, r5, 0
- orrs r0, r3
- strb r0, [r2]
- ldr r0, _08090EF8 @ =0x00003a8c
- adds r1, r0
- adds r1, r4, r1
- ldrb r2, [r1]
- adds r0, r5, 0
- orrs r0, r2
- strb r0, [r1]
- b _08090F0A
- .align 2, 0
-_08090EEC: .4byte gSaveBlock2
-_08090EF0: .4byte gSaveBlock1
-_08090EF4: .4byte 0x00000938
-_08090EF8: .4byte 0x00003a8c
-_08090EFC:
- ldr r0, _08090F14 @ =gSaveBlock2
- adds r0, 0x28
- adds r0, r4, r0
- ldrb r2, [r0]
- adds r1, r5, 0
- orrs r1, r2
- strb r1, [r0]
-_08090F0A:
- adds r0, r6, 0
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_08090F14: .4byte gSaveBlock2
- thumb_func_end sub_8090D90
-
- thumb_func_start GetNationalPokedexCount
-GetNationalPokedexCount: @ 8090F18
- push {r4-r7,lr}
- lsls r0, 24
- lsrs r6, r0, 24
- movs r5, 0
- movs r0, 0
- ldr r7, _08090F30 @ =0x00000181
-_08090F24:
- cmp r6, 0
- beq _08090F34
- cmp r6, 0x1
- beq _08090F3E
- adds r4, r0, 0x1
- b _08090F56
- .align 2, 0
-_08090F30: .4byte 0x00000181
-_08090F34:
- adds r4, r0, 0x1
- lsls r0, r4, 16
- lsrs r0, 16
- movs r1, 0
- b _08090F46
-_08090F3E:
- adds r4, r0, 0x1
- lsls r0, r4, 16
- lsrs r0, 16
- movs r1, 0x1
-_08090F46:
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- beq _08090F56
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
-_08090F56:
- lsls r0, r4, 16
- lsrs r0, 16
- cmp r0, r7
- bls _08090F24
- adds r0, r5, 0
- pop {r4-r7}
- pop {r1}
- bx r1
- thumb_func_end GetNationalPokedexCount
-
- thumb_func_start GetHoennPokedexCount
-GetHoennPokedexCount: @ 8090F68
- push {r4-r6,lr}
- lsls r0, 24
- lsrs r6, r0, 24
- movs r5, 0
- movs r0, 0
-_08090F72:
- cmp r6, 0
- beq _08090F7E
- cmp r6, 0x1
- beq _08090F90
- adds r4, r0, 0x1
- b _08090FB0
-_08090F7E:
- adds r4, r0, 0x1
- lsls r0, r4, 16
- lsrs r0, 16
- bl HoennToNationalOrder
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0
- b _08090FA0
-_08090F90:
- adds r4, r0, 0x1
- lsls r0, r4, 16
- lsrs r0, 16
- bl HoennToNationalOrder
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0x1
-_08090FA0:
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- beq _08090FB0
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
-_08090FB0:
- lsls r0, r4, 16
- lsrs r0, 16
- cmp r0, 0xC9
- bls _08090F72
- adds r0, r5, 0
- pop {r4-r6}
- pop {r1}
- bx r1
- thumb_func_end GetHoennPokedexCount
-
- thumb_func_start sub_8090FC0
-sub_8090FC0: @ 8090FC0
- push {r4,lr}
- movs r0, 0
-_08090FC4:
- adds r0, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- adds r0, r4, 0
- bl HoennToNationalOrder
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0x1
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- bne _08090FE4
- movs r0, 0
- b _08090FEC
-_08090FE4:
- adds r0, r4, 0
- cmp r0, 0xC7
- bls _08090FC4
- movs r0, 0x1
-_08090FEC:
- pop {r4}
- pop {r1}
- bx r1
- thumb_func_end sub_8090FC0
-
- thumb_func_start sub_8090FF4
-sub_8090FF4: @ 8090FF4
- push {r4,r5,lr}
- movs r0, 0
-_08090FF8:
- adds r0, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- adds r0, r4, 0
- movs r1, 0x1
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- beq _08091046
- adds r0, r4, 0
- cmp r0, 0x95
- bls _08090FF8
- movs r0, 0x98
-_08091014:
- adds r0, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- adds r0, r4, 0
- movs r1, 0x1
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- beq _08091046
- adds r0, r4, 0
- cmp r0, 0xF9
- bls _08091014
- movs r0, 0xFC
- ldr r5, _0809104C @ =0x0000017f
-_08091032:
- adds r0, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- adds r0, r4, 0
- movs r1, 0x1
- bl sub_8090D90
- lsls r0, 24
- cmp r0, 0
- bne _08091050
-_08091046:
- movs r0, 0
- b _08091058
- .align 2, 0
-_0809104C: .4byte 0x0000017f
-_08091050:
- adds r0, r4, 0
- cmp r0, r5
- bls _08091032
- movs r0, 0x1
-_08091058:
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_8090FF4
-
- thumb_func_start sub_8091060
-sub_8091060: @ 8091060
- push {r4,r5,lr}
- lsls r0, 16
- lsrs r4, r0, 16
- adds r5, r4, 0
- movs r0, 0x80
- lsls r0, 1
- ands r0, r4
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0
- bne _0809108E
- movs r2, 0x80
- lsls r2, 19
- ldrh r1, [r2]
- ldr r0, _0809112C @ =0x0000feff
- ands r0, r1
- strh r0, [r2]
- ldr r0, _08091130 @ =REG_BG0CNT
- strh r3, [r0]
- adds r0, 0x8
- strh r3, [r0]
- adds r0, 0x2
- strh r3, [r0]
-_0809108E:
- movs r0, 0x80
- lsls r0, 2
- ands r0, r4
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0
- bne _080910B4
- movs r2, 0x80
- lsls r2, 19
- ldrh r1, [r2]
- ldr r0, _08091134 @ =0x0000fdff
- ands r0, r1
- strh r0, [r2]
- ldr r0, _08091138 @ =REG_BG1CNT
- strh r3, [r0]
- adds r0, 0xA
- strh r3, [r0]
- adds r0, 0x2
- strh r3, [r0]
-_080910B4:
- movs r0, 0x80
- lsls r0, 3
- ands r0, r4
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0
- bne _080910DA
- movs r2, 0x80
- lsls r2, 19
- ldrh r1, [r2]
- ldr r0, _0809113C @ =0x0000fbff
- ands r0, r1
- strh r0, [r2]
- ldr r0, _08091140 @ =REG_BG2CNT
- strh r3, [r0]
- adds r0, 0xC
- strh r3, [r0]
- adds r0, 0x2
- strh r3, [r0]
-_080910DA:
- movs r0, 0x80
- lsls r0, 4
- ands r0, r4
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0
- bne _08091100
- movs r2, 0x80
- lsls r2, 19
- ldrh r1, [r2]
- ldr r0, _08091144 @ =0x0000f7ff
- ands r0, r1
- strh r0, [r2]
- ldr r0, _08091148 @ =REG_BG3CNT
- strh r3, [r0]
- adds r0, 0xE
- strh r3, [r0]
- adds r0, 0x2
- strh r3, [r0]
-_08091100:
- movs r0, 0x80
- lsls r0, 5
- ands r5, r0
- cmp r5, 0
- bne _08091124
- movs r2, 0x80
- lsls r2, 19
- ldrh r1, [r2]
- ldr r0, _0809114C @ =0x0000efff
- ands r0, r1
- strh r0, [r2]
- bl ResetSpriteData
- bl FreeAllSpritePalettes
- ldr r1, _08091150 @ =gReservedSpritePaletteCount
- movs r0, 0x8
- strb r0, [r1]
-_08091124:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_0809112C: .4byte 0x0000feff
-_08091130: .4byte REG_BG0CNT
-_08091134: .4byte 0x0000fdff
-_08091138: .4byte REG_BG1CNT
-_0809113C: .4byte 0x0000fbff
-_08091140: .4byte REG_BG2CNT
-_08091144: .4byte 0x0000f7ff
-_08091148: .4byte REG_BG3CNT
-_0809114C: .4byte 0x0000efff
-_08091150: .4byte gReservedSpritePaletteCount
- thumb_func_end sub_8091060
-
- thumb_func_start sub_8091154
-sub_8091154: @ 8091154
- push {r4-r6,lr}
- mov r6, r8
- push {r6}
- sub sp, 0x4
- adds r4, r0, 0
- adds r6, r1, 0
- mov r8, r2
- lsls r4, 16
- lsrs r4, 16
- lsls r6, 24
- lsrs r6, 24
- mov r0, r8
- lsls r0, 24
- lsrs r0, 24
- mov r8, r0
- mov r5, sp
- adds r0, r4, 0
- movs r1, 0x64
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r5]
- mov r5, sp
- adds r0, r4, 0
- movs r1, 0x64
- bl __umodsi3
- adds r4, r0, 0
- lsls r4, 16
- lsrs r4, 16
- adds r0, r4, 0
- movs r1, 0xA
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r5, 0x1]
- mov r5, sp
- adds r0, r4, 0
- movs r1, 0xA
- bl __umodsi3
- adds r0, 0xA1
- strb r0, [r5, 0x2]
- mov r1, sp
- movs r0, 0xFF
- strb r0, [r1, 0x3]
- mov r0, sp
- adds r1, r6, 0
- mov r2, r8
- bl MenuPrint
- add sp, 0x4
- pop {r3}
- mov r8, r3
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end sub_8091154
-
- thumb_func_start sub_80911C8
-sub_80911C8: @ 80911C8
- push {r4-r6,lr}
- sub sp, 0xC
- lsls r0, 16
- lsrs r3, r0, 16
- lsls r1, 24
- lsrs r6, r1, 24
- lsls r2, 24
- lsrs r5, r2, 24
- movs r4, 0
- movs r2, 0xFF
-_080911DC:
- mov r1, sp
- adds r0, r1, r4
- ldrb r1, [r0]
- orrs r1, r2
- strb r1, [r0]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0xA
- bls _080911DC
- adds r0, r3, 0
- bl NationalPokedexNumToSpecies
- adds r3, r0, 0
- cmp r3, 0
- beq _08091238
- movs r4, 0
- ldr r2, _08091234 @ =gSpeciesNames
- movs r0, 0xB
- adds r1, r3, 0
- muls r1, r0
- adds r0, r1, r2
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _0809124C
- adds r3, r2, 0
- adds r2, r1, 0
-_08091212:
- mov r0, sp
- adds r1, r0, r4
- adds r0, r4, r2
- adds r0, r3
- ldrb r0, [r0]
- strb r0, [r1]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- adds r0, r4, r2
- adds r0, r3
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _0809124C
- cmp r4, 0x9
- bls _08091212
- b _0809124C
- .align 2, 0
-_08091234: .4byte gSpeciesNames
-_08091238:
- movs r4, 0
- movs r1, 0xAE
-_0809123C:
- mov r2, sp
- adds r0, r2, r4
- strb r1, [r0]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x9
- bls _0809123C
-_0809124C:
- mov r0, sp
- adds r1, r6, 0
- adds r2, r5, 0
- bl MenuPrint
- adds r0, r4, 0
- add sp, 0xC
- pop {r4-r6}
- pop {r1}
- bx r1
- thumb_func_end sub_80911C8
-
- thumb_func_start sub_8091260
-sub_8091260: @ 8091260
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- sub sp, 0x28
- adds r4, r3, 0
- lsls r0, 16
- lsrs r5, r0, 16
- lsls r1, 24
- lsrs r1, 24
- mov r8, r1
- lsls r2, 24
- lsrs r7, r2, 24
- lsls r4, 24
- lsrs r4, 24
- ldr r1, _080912CC @ =gUnknown_083B5558
- mov r0, sp
- bl StringCopy
- adds r6, r0, 0
- mov r0, sp
- strb r4, [r0, 0x2]
- adds r0, r5, 0
- bl NationalPokedexNumToSpecies
- adds r5, r0, 0
- cmp r5, 0
- beq _080912D4
- movs r4, 0
- ldr r2, _080912D0 @ =gSpeciesNames
- movs r0, 0xB
- adds r1, r5, 0
- muls r1, r0
- adds r0, r1, r2
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _080912E6
- adds r3, r2, 0
- adds r2, r1, 0
-_080912AC:
- adds r1, r6, r4
- adds r0, r4, r2
- adds r0, r3
- ldrb r0, [r0]
- strb r0, [r1]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- adds r0, r4, r2
- adds r0, r3
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _080912E6
- cmp r4, 0x9
- bls _080912AC
- b _080912E6
- .align 2, 0
-_080912CC: .4byte gUnknown_083B5558
-_080912D0: .4byte gSpeciesNames
-_080912D4:
- movs r4, 0
- movs r1, 0xAE
-_080912D8:
- adds r0, r6, r4
- strb r1, [r0]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x9
- bls _080912D8
-_080912E6:
- adds r1, r6, r4
- movs r0, 0xFF
- strb r0, [r1]
- mov r0, sp
- mov r1, r8
- adds r2, r7, 0
- bl MenuPrint
- adds r0, r4, 0
- add sp, 0x28
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r1}
- bx r1
- thumb_func_end sub_8091260
-
- thumb_func_start sub_8091304
-sub_8091304: @ 8091304
- push {r4-r7,lr}
- sub sp, 0x20
- adds r3, r0, 0
- lsls r1, 24
- lsrs r1, 24
- mov r12, r1
- lsls r2, 24
- lsrs r7, r2, 24
- movs r4, 0
- ldrb r0, [r3]
- ldr r6, _08091340 @ =gDexText_UnknownPoke
- cmp r0, 0xFF
- beq _0809133A
-_0809131E:
- mov r0, sp
- adds r1, r0, r4
- adds r0, r3, r4
- ldrb r0, [r0]
- strb r0, [r1]
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- adds r0, r3, r4
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _0809133A
- cmp r4, 0xA
- bls _0809131E
-_0809133A:
- movs r3, 0
- ldrb r0, [r6]
- b _0809134E
- .align 2, 0
-_08091340: .4byte gDexText_UnknownPoke
-_08091344:
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- adds r0, r3, r6
- ldrb r0, [r0]
-_0809134E:
- cmp r0, 0xAC
- beq _08091344
- cmp r0, 0
- beq _08091344
- subs r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- adds r0, r3, r6
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _08091388
- adds r5, r6, 0
-_08091366:
- adds r1, r4, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- mov r0, sp
- adds r2, r0, r1
- adds r1, r3, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- adds r1, r5
- ldrb r0, [r1]
- strb r0, [r2]
- adds r0, r3, r5
- ldrb r0, [r0]
- cmp r0, 0xFF
- bne _08091366
-_08091388:
- mov r0, sp
- adds r1, r0, r4
- movs r0, 0xFF
- strb r0, [r1]
- mov r0, sp
- mov r1, r12
- adds r2, r7, 0
- adds r3, r6, 0
- bl sub_8072B80
- add sp, 0x20
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8091304
-
- thumb_func_start unref_sub_80913A4
-unref_sub_80913A4: @ 80913A4
- push {r4-r7,lr}
- sub sp, 0x8
- lsls r0, 16
- lsrs r4, r0, 16
- lsls r1, 24
- lsrs r7, r1, 24
- lsls r2, 24
- lsrs r6, r2, 24
- movs r5, 0
- movs r1, 0xFA
- lsls r1, 2
- adds r0, r4, 0
- bl __udivsi3
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0
- bne _080913CE
- mov r0, sp
- strb r5, [r0]
- b _080913D6
-_080913CE:
- mov r1, sp
- adds r0, 0xA1
- strb r0, [r1]
- movs r5, 0x1
-_080913D6:
- movs r1, 0xFA
- lsls r1, 2
- adds r0, r4, 0
- bl __umodsi3
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0x64
- bl __udivsi3
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0
- bne _080913FC
- cmp r5, 0
- bne _080913FC
- mov r0, sp
- strb r5, [r0, 0x1]
- b _08091402
-_080913FC:
- mov r1, sp
- adds r0, 0xA1
- strb r0, [r1, 0x1]
-_08091402:
- mov r5, sp
- movs r1, 0xFA
- lsls r1, 2
- adds r0, r4, 0
- bl __umodsi3
- lsls r0, 16
- lsrs r0, 16
- movs r1, 0x64
- bl __umodsi3
- adds r4, r0, 0
- lsls r4, 16
- lsrs r4, 16
- adds r0, r4, 0
- movs r1, 0xA
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r5, 0x2]
- mov r1, sp
- movs r0, 0xAD
- strb r0, [r1, 0x3]
- mov r5, sp
- adds r0, r4, 0
- movs r1, 0xA
- bl __umodsi3
- adds r0, 0xA1
- strb r0, [r5, 0x4]
- mov r1, sp
- movs r0, 0xFF
- strb r0, [r1, 0x5]
- mov r0, sp
- adds r1, r7, 0
- adds r2, r6, 0
- bl MenuPrint
- add sp, 0x8
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end unref_sub_80913A4
-
- thumb_func_start sub_8091458
-sub_8091458: @ 8091458
- push {r4-r7,lr}
- mov r7, r9
- mov r6, r8
- push {r6,r7}
- sub sp, 0x10
- lsls r0, 16
- lsrs r0, 16
- lsls r1, 24
- lsrs r1, 24
- mov r9, r1
- lsls r2, 24
- lsrs r2, 24
- mov r8, r2
- ldr r1, _080914D4 @ =0x00002710
- muls r0, r1
- movs r1, 0xFE
- bl __divsi3
- adds r7, r0, 0
- movs r1, 0xA
- bl __umodsi3
- cmp r0, 0x4
- bls _0809148A
- adds r7, 0xA
-_0809148A:
- adds r0, r7, 0
- movs r1, 0x78
- bl __udivsi3
- adds r6, r0, 0
- lsls r0, r6, 4
- subs r0, r6
- lsls r0, 3
- subs r0, r7, r0
- movs r1, 0xA
- bl __udivsi3
- adds r7, r0, 0
- mov r1, sp
- movs r0, 0xFC
- strb r0, [r1]
- adds r1, 0x1
- movs r0, 0x13
- strb r0, [r1]
- adds r0, r6, 0
- movs r1, 0xA
- bl __udivsi3
- adds r2, r0, 0
- cmp r2, 0
- bne _080914D8
- mov r1, sp
- adds r1, 0x2
- movs r0, 0x12
- strb r0, [r1]
- movs r5, 0x4
- adds r1, 0x1
- adds r0, r6, 0
- adds r0, 0xA1
- strb r0, [r1]
- b _080914F8
- .align 2, 0
-_080914D4: .4byte 0x00002710
-_080914D8:
- mov r1, sp
- adds r1, 0x2
- movs r0, 0xC
- strb r0, [r1]
- adds r1, 0x1
- adds r0, r2, 0
- adds r0, 0xA1
- strb r0, [r1]
- movs r5, 0x5
- add r4, sp, 0x4
- adds r0, r6, 0
- movs r1, 0xA
- bl __umodsi3
- adds r0, 0xA1
- strb r0, [r4]
-_080914F8:
- adds r1, r5, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r5, r0, 24
- adds r2, r5, 0
- add r1, sp
- movs r0, 0xB4
- strb r0, [r1]
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r5, r0, 24
- adds r6, r5, 0
- mov r0, sp
- adds r4, r0, r2
- adds r0, r7, 0
- movs r1, 0xA
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r4]
- adds r0, r6, 0x1
- lsls r0, 24
- lsrs r5, r0, 24
- mov r1, sp
- adds r4, r1, r6
- adds r0, r7, 0
- movs r1, 0xA
- bl __umodsi3
- adds r0, 0xA1
- strb r0, [r4]
- adds r0, r5, 0x1
- lsls r0, 24
- lsrs r0, 24
- mov r1, sp
- adds r2, r1, r5
- movs r1, 0xB2
- strb r1, [r2]
- mov r2, sp
- adds r1, r2, r0
- movs r0, 0xFF
- strb r0, [r1]
- mov r0, sp
- mov r1, r9
- mov r2, r8
- bl MenuPrint
- add sp, 0x10
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8091458
-
- thumb_func_start sub_8091564
-sub_8091564: @ 8091564
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x14
- lsls r0, 16
- lsrs r0, 16
- lsls r1, 24
- lsrs r1, 24
- mov r10, r1
- lsls r2, 24
- lsrs r2, 24
- str r2, [sp, 0x10]
- ldr r7, _080915BC @ =0x000186a0
- muls r0, r7
- ldr r1, _080915C0 @ =0x000011b8
- bl __divsi3
- adds r6, r0, 0
- movs r1, 0xA
- bl __umodsi3
- cmp r0, 0x4
- bls _08091598
- adds r6, 0xA
-_08091598:
- movs r5, 0
- mov r4, sp
- adds r0, r6, 0
- adds r1, r7, 0
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r4]
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0xA1
- bne _080915C4
- mov r0, sp
- strb r5, [r0]
- movs r7, 0x2
- adds r0, 0x1
- strb r5, [r0]
- b _080915C8
- .align 2, 0
-_080915BC: .4byte 0x000186a0
-_080915C0: .4byte 0x000011b8
-_080915C4:
- movs r5, 0x1
- movs r7, 0x1
-_080915C8:
- ldr r1, _0809160C @ =0x000186a0
- adds r0, r6, 0
- bl __umodsi3
- adds r6, r0, 0
- mov r0, sp
- adds r4, r0, r7
- ldr r1, _08091610 @ =0x00002710
- adds r0, r6, 0
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r4]
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0xA1
- bne _08091614
- cmp r5, 0
- bne _08091614
- adds r1, r7, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r2, r7, 0
- mov r3, sp
- adds r0, r3, r1
- strb r5, [r0]
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r0, r3, r2
- strb r5, [r0]
- b _0809161C
- .align 2, 0
-_0809160C: .4byte 0x000186a0
-_08091610: .4byte 0x00002710
-_08091614:
- movs r5, 0x1
- adds r0, r7, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
-_0809161C:
- ldr r1, _08091660 @ =0x00002710
- adds r0, r6, 0
- bl __umodsi3
- adds r6, r0, 0
- mov r0, sp
- adds r4, r0, r7
- movs r1, 0xFA
- lsls r1, 2
- adds r0, r6, 0
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r4]
- lsls r0, 24
- lsrs r0, 24
- cmp r0, 0xA1
- bne _08091664
- cmp r5, 0
- bne _08091664
- adds r1, r7, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r2, r7, 0
- mov r3, sp
- adds r0, r3, r1
- strb r5, [r0]
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r0, r3, r2
- strb r5, [r0]
- b _0809166A
- .align 2, 0
-_08091660: .4byte 0x00002710
-_08091664:
- adds r0, r7, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
-_0809166A:
- movs r1, 0xFA
- lsls r1, 2
- adds r0, r6, 0
- bl __umodsi3
- adds r6, r0, 0
- adds r1, r7, 0
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r5, r7, 0
- mov r0, sp
- adds r4, r0, r1
- adds r0, r6, 0
- movs r1, 0x64
- bl __udivsi3
- adds r0, 0xA1
- movs r1, 0
- mov r9, r1
- strb r0, [r4]
- adds r0, r6, 0
- movs r1, 0x64
- bl __umodsi3
- adds r6, r0, 0
- adds r0, r5, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r1, r7, 0
- mov r2, sp
- adds r0, r2, r5
- movs r3, 0xAD
- mov r8, r3
- mov r2, r8
- strb r2, [r0]
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r5, r7, 0
- mov r3, sp
- adds r4, r3, r1
- adds r0, r6, 0
- movs r1, 0xA
- bl __udivsi3
- adds r0, 0xA1
- strb r0, [r4]
- adds r0, r5, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r1, r7, 0
- mov r2, sp
- adds r0, r2, r5
- mov r3, r9
- strb r3, [r0]
- adds r0, r1, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r2, r7, 0
- add r1, sp
- movs r0, 0xE0
- strb r0, [r1]
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r3, r7, 0
- mov r0, sp
- adds r1, r0, r2
- movs r0, 0xD6
- strb r0, [r1]
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r7, r0, 24
- adds r2, r7, 0
- mov r0, sp
- adds r1, r0, r3
- movs r0, 0xE7
- strb r0, [r1]
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r0, 24
- mov r3, sp
- adds r1, r3, r2
- mov r2, r8
- strb r2, [r1]
- adds r1, r3, r0
- movs r0, 0xFF
- strb r0, [r1]
- mov r0, sp
- mov r1, r10
- ldr r2, [sp, 0x10]
- bl MenuPrint
- add sp, 0x14
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8091564
-
- thumb_func_start sub_8091738
-sub_8091738: @ 8091738
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- sub sp, 0x80
- adds r4, r1, 0
- adds r5, r2, 0
- lsls r0, 16
- lsrs r0, 16
- lsls r4, 16
- lsrs r4, 16
- lsls r5, 16
- lsrs r5, 16
- ldr r6, _080917C8 @ =gMonFootprintTable
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r0, 14
- adds r0, r6
- ldr r0, [r0]
- mov r12, r0
- movs r7, 0
- movs r1, 0
- lsls r4, 14
- mov r8, r4
- lsls r5, 5
-_0809176A:
- mov r2, r12
- adds r0, r2, r1
- ldrb r3, [r0]
- movs r6, 0
- adds r4, r1, 0x1
-_08091774:
- lsls r1, r6, 1
- adds r2, r3, 0
- asrs r2, r1
- movs r0, 0x1
- ands r2, r0
- movs r0, 0x2
- lsls r0, r1
- ands r0, r3
- cmp r0, 0
- beq _0809178C
- movs r0, 0x10
- orrs r2, r0
-_0809178C:
- mov r1, sp
- adds r0, r1, r7
- strb r2, [r0]
- adds r0, r7, 0x1
- lsls r0, 16
- lsrs r7, r0, 16
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
- cmp r6, 0x3
- bls _08091774
- lsls r0, r4, 16
- lsrs r1, r0, 16
- cmp r1, 0x1F
- bls _0809176A
- movs r1, 0xC0
- lsls r1, 19
- adds r1, r5, r1
- add r1, r8
- mov r0, sp
- movs r2, 0x40
- bl CpuSet
- add sp, 0x80
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080917C8: .4byte gMonFootprintTable
- thumb_func_end sub_8091738
-
- thumb_func_start sub_80917CC
-sub_80917CC: @ 80917CC
- push {r4,lr}
- lsls r0, 16
- lsls r1, 16
- lsrs r1, 16
- lsrs r0, 5
- ldr r2, _08091808 @ =0x06000232
- adds r3, r0, r2
- movs r4, 0xF0
- lsls r4, 8
- adds r2, r1, r4
- strh r2, [r3]
- ldr r2, _0809180C @ =0x06000234
- adds r3, r0, r2
- adds r4, 0x1
- adds r2, r1, r4
- strh r2, [r3]
- ldr r2, _08091810 @ =0x06000272
- adds r3, r0, r2
- adds r4, 0x1
- adds r2, r1, r4
- strh r2, [r3]
- ldr r2, _08091814 @ =0x06000274
- adds r0, r2
- adds r4, 0x1
- adds r1, r4
- strh r1, [r0]
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08091808: .4byte 0x06000232
-_0809180C: .4byte 0x06000234
-_08091810: .4byte 0x06000272
-_08091814: .4byte 0x06000274
- thumb_func_end sub_80917CC
-
- thumb_func_start sub_8091818
-sub_8091818: @ 8091818
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- adds r5, r4, 0
- lsls r1, 16
- lsrs r0, r1, 16
- lsls r2, 16
- lsrs r2, 16
- lsls r3, 16
- lsrs r3, 16
- cmp r4, 0x1
- beq _08091844
- cmp r4, 0x1
- bgt _0809183A
- cmp r4, 0
- beq _0809184C
- b _0809186C
-_0809183A:
- cmp r5, 0x2
- beq _0809185E
- cmp r5, 0x3
- beq _08091852
- b _0809186C
-_08091844:
- cmp r0, r2
- bls _0809186C
- subs r0, 0x1
- b _08091864
-_0809184C:
- cmp r0, r3
- bcs _0809186C
- b _08091862
-_08091852:
- cmp r0, r2
- bls _0809185A
- subs r0, 0x1
- b _08091864
-_0809185A:
- adds r0, r3, 0
- b _0809186C
-_0809185E:
- cmp r0, r3
- bcs _0809186A
-_08091862:
- adds r0, 0x1
-_08091864:
- lsls r0, 16
- lsrs r0, 16
- b _0809186C
-_0809186A:
- adds r0, r2, 0
-_0809186C:
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end sub_8091818
-
- thumb_func_start nullsub_59
-nullsub_59: @ 8091874
- bx lr
- thumb_func_end nullsub_59
-
- thumb_func_start sub_8091878
-sub_8091878: @ 8091878
- push {r4-r7,lr}
- lsls r1, 24
- ldr r4, _080918A0 @ =gUnknown_02024E8C
- adds r3, r4, 0
- ldr r2, _080918A4 @ =gUnknown_083B57A4
- ldm r2!, {r5-r7}
- stm r3!, {r5-r7}
- ldm r2!, {r5-r7}
- stm r3!, {r5-r7}
- strh r0, [r4, 0x2]
- ldr r0, _080918A8 @ =gUnknown_083B5794
- lsrs r1, 22
- adds r1, r0
- ldr r0, [r1]
- str r0, [r4, 0xC]
- ldr r0, _080918AC @ =gSpriteAnimTable_81E7C64
- str r0, [r4, 0x8]
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080918A0: .4byte gUnknown_02024E8C
-_080918A4: .4byte gUnknown_083B57A4
-_080918A8: .4byte gUnknown_083B5794
-_080918AC: .4byte gSpriteAnimTable_81E7C64
- thumb_func_end sub_8091878
-
- thumb_func_start sub_80918B0
-sub_80918B0: @ 80918B0
- push {r4-r7,lr}
- lsls r1, 24
- ldr r4, _080918DC @ =gUnknown_02024E8C
- adds r3, r4, 0
- ldr r2, _080918E0 @ =gUnknown_083B57A4
- ldm r2!, {r5-r7}
- stm r3!, {r5-r7}
- ldm r2!, {r5-r7}
- stm r3!, {r5-r7}
- strh r0, [r4, 0x2]
- ldr r0, _080918E4 @ =gUnknown_083B5794
- lsrs r1, 22
- adds r1, r0
- ldr r0, [r1]
- str r0, [r4, 0xC]
- ldr r0, _080918E8 @ =gUnknown_081EC2A4
- ldr r0, [r0]
- str r0, [r4, 0x8]
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080918DC: .4byte gUnknown_02024E8C
-_080918E0: .4byte gUnknown_083B57A4
-_080918E4: .4byte gUnknown_083B5794
-_080918E8: .4byte gUnknown_081EC2A4
- thumb_func_end sub_80918B0
-
- thumb_func_start sub_80918EC
-sub_80918EC: @ 80918EC
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x10
- lsls r0, 16
- lsrs r7, r0, 16
- lsls r1, 16
- lsrs r1, 16
- mov r9, r1
- lsls r2, 16
- lsrs r2, 16
- mov r10, r2
- lsls r3, 16
- lsrs r3, 16
- mov r8, r3
- adds r0, r7, 0
- bl NationalPokedexNumToSpecies
- adds r7, r0, 0
- cmp r7, SPECIES_UNOWN
- beq _0809199C
- movs r0, 0x9A
- lsls r0, 1
- cmp r7, r0
- beq _08091958
- lsls r6, r7, 3
- ldr r0, _0809194C @ =gMonFrontPicTable
- adds r0, r6, r0
- ldr r1, _08091950 @ =gMonFrontPicCoords
- lsls r2, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08091954 @ =gUnknown_083B5584
- mov r12, r4
- mov r5, r8
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- bl DecompressPicFromTable_2
- b _080919CE
- .align 2, 0
-_0809194C: .4byte gMonFrontPicTable
-_08091950: .4byte gMonFrontPicCoords
-_08091954: .4byte gUnknown_083B5584
-_08091958:
- lsls r6, r7, 3
- ldr r0, _0809198C @ =gMonFrontPicTable
- adds r0, r6
- ldr r2, _08091990 @ =gMonFrontPicCoords
- lsls r1, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08091994 @ =gUnknown_083B5584
- mov r12, r4
- mov r5, r8
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- ldr r4, _08091998 @ =gSaveBlock2
- ldr r4, [r4, 0x20]
- str r4, [sp, 0x8]
- movs r4, 0x1
- str r4, [sp, 0xC]
- bl LoadSpecialPokePic
- b _080919CE
- .align 2, 0
-_0809198C: .4byte gMonFrontPicTable
-_08091990: .4byte gMonFrontPicCoords
-_08091994: .4byte gUnknown_083B5584
-_08091998: .4byte gSaveBlock2
-_0809199C:
- lsls r6, r7, 3
- ldr r0, _08091A30 @ =gMonFrontPicTable
- adds r0, r6
- ldr r2, _08091A34 @ =gMonFrontPicCoords
- lsls r1, r7, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08091A38 @ =gUnknown_083B5584
- mov r12, r4
- mov r5, r8
- lsls r4, r5, 2
- add r4, r12
- ldr r4, [r4]
- str r4, [sp]
- str r7, [sp, 0x4]
- ldr r4, _08091A3C @ =gSaveBlock2
- ldr r4, [r4, 0x1C]
- str r4, [sp, 0x8]
- movs r4, 0x1
- str r4, [sp, 0xC]
- bl LoadSpecialPokePic
-_080919CE:
- ldr r0, _08091A40 @ =gMonPaletteTable
- adds r0, r6, r0
- ldr r0, [r0]
- mov r1, r8
- lsls r4, r1, 4
- movs r2, 0x80
- lsls r2, 1
- adds r1, r4, r2
- lsls r1, 16
- lsrs r1, 16
- movs r2, 0x20
- bl LoadCompressedPalette
- mov r3, r8
- lsls r1, r3, 24
- lsrs r1, 24
- mov r0, r8
- bl sub_8091878
- ldr r0, _08091A44 @ =gUnknown_02024E8C
- mov r5, r9
- lsls r1, r5, 16
- asrs r1, 16
- mov r3, r10
- lsls r2, r3, 16
- asrs r2, 16
- movs r3, 0
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- ldr r1, _08091A48 @ =gSprites
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r1
- ldrb r3, [r2, 0x5]
- movs r1, 0xF
- ands r1, r3
- orrs r1, r4
- strb r1, [r2, 0x5]
- add sp, 0x10
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_08091A30: .4byte gMonFrontPicTable
-_08091A34: .4byte gMonFrontPicCoords
-_08091A38: .4byte gUnknown_083B5584
-_08091A3C: .4byte gSaveBlock2
-_08091A40: .4byte gMonPaletteTable
-_08091A44: .4byte gUnknown_02024E8C
-_08091A48: .4byte gSprites
- thumb_func_end sub_80918EC
-
- thumb_func_start sub_8091A4C
-sub_8091A4C: @ 8091A4C
- push {r4-r6,lr}
- mov r6, r9
- mov r5, r8
- push {r5,r6}
- sub sp, 0x8
- adds r5, r0, 0
- adds r6, r1, 0
- mov r8, r2
- mov r9, r3
- lsls r5, 16
- lsrs r5, 16
- lsls r6, 16
- lsrs r6, 16
- mov r0, r8
- lsls r0, 16
- lsrs r0, 16
- mov r8, r0
- mov r1, r9
- lsls r1, 16
- lsrs r1, 16
- mov r9, r1
- lsls r0, r5, 3
- ldr r1, _08091AE4 @ =gTrainerFrontPicTable
- adds r0, r1
- ldr r1, _08091AE8 @ =gTrainerFrontPicCoords
- lsls r2, r5, 2
- adds r2, r1
- ldrb r1, [r2]
- ldrb r2, [r2, 0x1]
- movs r3, 0x80
- lsls r3, 18
- ldr r4, _08091AEC @ =gUnknown_083B5584
- ldr r4, [r4]
- str r4, [sp]
- str r5, [sp, 0x4]
- bl DecompressPicFromTable_2
- adds r0, r5, 0
- movs r1, 0
- bl sub_80918B0
- ldr r0, _08091AF0 @ =gUnknown_02024E8C
- lsls r6, 16
- asrs r6, 16
- mov r3, r8
- lsls r3, 16
- asrs r3, 16
- mov r8, r3
- adds r1, r6, 0
- mov r2, r8
- movs r3, 0
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- ldr r1, _08091AF4 @ =gSprites
- lsls r2, r0, 4
- adds r2, r0
- lsls r2, 2
- adds r2, r1
- mov r1, r9
- lsls r1, 4
- mov r9, r1
- ldrb r3, [r2, 0x5]
- movs r1, 0xF
- ands r1, r3
- mov r3, r9
- orrs r1, r3
- strb r1, [r2, 0x5]
- add sp, 0x8
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r6}
- pop {r1}
- bx r1
- .align 2, 0
-_08091AE4: .4byte gTrainerFrontPicTable
-_08091AE8: .4byte gTrainerFrontPicCoords
-_08091AEC: .4byte gUnknown_083B5584
-_08091AF0: .4byte gUnknown_02024E8C
-_08091AF4: .4byte gSprites
- thumb_func_end sub_8091A4C
-
- thumb_func_start sub_8091AF8
-sub_8091AF8: @ 8091AF8
- push {r4-r7,lr}
- mov r7, r10
- mov r6, r9
- mov r5, r8
- push {r5-r7}
- sub sp, 0x14
- ldr r4, [sp, 0x34]
- ldr r5, [sp, 0x38]
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 24
- lsrs r1, 24
- lsls r2, 24
- lsrs r7, r2, 24
- lsls r3, 24
- lsrs r3, 24
- str r3, [sp, 0x4]
- lsls r4, 24
- lsrs r4, 24
- str r4, [sp, 0x8]
- lsls r5, 24
- lsrs r5, 24
- mov r10, r5
- bl SortPokedex
- movs r5, 0
- movs r6, 0
- ldr r4, _08091D08 @ =0x00000181
- ldr r3, _08091D0C @ =gPokedexView
-_08091B32:
- ldr r2, [r3]
- lsls r0, r5, 2
- adds r1, r2, r0
- ldrb r0, [r1, 0x2]
- lsls r0, 31
- cmp r0, 0
- beq _08091B4E
- lsls r0, r6, 2
- adds r0, r2, r0
- ldr r1, [r1]
- str r1, [r0]
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
-_08091B4E:
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- cmp r5, r4
- bls _08091B32
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- adds r1, r6, 0
- strh r6, [r0]
- cmp r7, 0xFF
- beq _08091C04
- movs r5, 0
- lsls r0, r1, 16
- movs r6, 0
- cmp r0, 0
- beq _08091BFA
- lsls r7, 2
- ldr r0, _08091D14 @ =gUnknown_083B57BC
- adds r0, 0x3
- adds r0, r7, r0
- str r0, [sp, 0xC]
- ldr r0, _08091D14 @ =gUnknown_083B57BC
- adds r0, r7
- mov r9, r0
-_08091B82:
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- lsls r4, r5, 2
- adds r0, r4
- ldrh r0, [r0]
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r2, r0, 16
- ldr r1, _08091D18 @ =gSpeciesNames
- movs r0, 0xB
- muls r0, r2
- adds r0, r1
- ldrb r2, [r0]
- adds r3, r2, 0
- mov r0, r9
- ldrb r0, [r0]
- cmp r2, r0
- bcc _08091BBA
- mov r1, r9
- ldrb r0, [r1]
- ldr r1, _08091D14 @ =gUnknown_083B57BC
- adds r1, 0x1
- adds r1, r7, r1
- ldrb r1, [r1]
- adds r0, r1
- cmp r2, r0
- blt _08091BD2
-_08091BBA:
- ldr r0, _08091D14 @ =gUnknown_083B57BC
- adds r0, 0x2
- adds r0, r7, r0
- ldrb r2, [r0]
- cmp r3, r2
- bcc _08091BE6
- ldrb r1, [r0]
- ldr r2, [sp, 0xC]
- ldrb r0, [r2]
- adds r1, r0
- cmp r3, r1
- bge _08091BE6
-_08091BD2:
- ldr r2, _08091D0C @ =gPokedexView
- ldr r0, [r2]
- lsls r1, r6, 2
- adds r1, r0, r1
- adds r0, r4
- ldr r0, [r0]
- str r0, [r1]
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
-_08091BE6:
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r5, r0
- bcc _08091B82
-_08091BFA:
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- strh r6, [r0]
-_08091C04:
- ldr r0, [sp, 0x4]
- cmp r0, 0xFF
- beq _08091C74
- movs r5, 0
- movs r6, 0
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r6, r0
- bcs _08091C6A
- adds r7, r1, 0
- ldr r0, _08091D1C @ =gBaseStats
- mov r8, r0
-_08091C22:
- ldr r0, [r7]
- lsls r4, r5, 2
- adds r0, r4
- ldrh r0, [r0]
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r2, r0, 16
- lsls r0, r2, 3
- subs r0, r2
- lsls r0, 2
- add r0, r8
- ldrb r0, [r0, 0x19]
- lsls r0, 25
- lsrs r0, 25
- ldr r1, [sp, 0x4]
- cmp r1, r0
- bne _08091C58
- ldr r0, [r7]
- lsls r1, r6, 2
- adds r1, r0, r1
- adds r0, r4
- ldr r0, [r0]
- str r0, [r1]
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
-_08091C58:
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- ldr r0, [r7]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r5, r0
- bcc _08091C22
-_08091C6A:
- ldr r1, _08091D0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- strh r6, [r0]
-_08091C74:
- ldr r0, [sp, 0x8]
- cmp r0, 0xFF
- bne _08091C8A
- mov r1, r10
- cmp r1, 0xFF
- bne _08091C82
- b _08091DA6
-_08091C82:
- mov r2, r10
- str r2, [sp, 0x8]
- movs r0, 0xFF
- mov r10, r0
-_08091C8A:
- mov r1, r10
- cmp r1, 0xFF
- bne _08091D20
- movs r5, 0
- movs r6, 0
- ldr r2, _08091D0C @ =gPokedexView
- ldr r0, [r2]
- ldr r1, _08091D10 @ =0x0000060c
- adds r0, r1
- ldrh r0, [r0]
- cmp r6, r0
- bcs _08091D9C
- adds r3, r2, 0
- mov r7, sp
- mov r8, r2
-_08091CA8:
- ldr r0, [r3]
- lsls r4, r5, 2
- adds r1, r0, r4
- ldrb r0, [r1, 0x2]
- lsls r0, 30
- cmp r0, 0
- bge _08091CF2
- ldrh r0, [r1]
- str r3, [sp, 0x10]
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r2, r0, 16
- ldr r1, _08091D1C @ =gBaseStats
- lsls r0, r2, 3
- subs r0, r2
- lsls r0, 2
- adds r0, r1
- ldrb r1, [r0, 0x6]
- strb r1, [r7]
- ldrb r0, [r0, 0x7]
- strb r0, [r7, 0x1]
- ldr r3, [sp, 0x10]
- ldr r2, [sp, 0x8]
- cmp r1, r2
- beq _08091CE0
- cmp r0, r2
- bne _08091CF2
-_08091CE0:
- ldr r0, [r3]
- lsls r1, r6, 2
- adds r1, r0, r1
- adds r0, r4
- ldr r0, [r0]
- str r0, [r1]
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
-_08091CF2:
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- mov r1, r8
- ldr r0, [r1]
- ldr r2, _08091D10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r5, r0
- bcc _08091CA8
- b _08091D9C
- .align 2, 0
-_08091D08: .4byte 0x00000181
-_08091D0C: .4byte gPokedexView
-_08091D10: .4byte 0x0000060c
-_08091D14: .4byte gUnknown_083B57BC
-_08091D18: .4byte gSpeciesNames
-_08091D1C: .4byte gBaseStats
-_08091D20:
- movs r5, 0
- movs r6, 0
- ldr r1, _08091E0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091E10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r6, r0
- bcs _08091D9C
- mov r7, sp
-_08091D34:
- ldr r0, [r1]
- lsls r1, r5, 2
- adds r2, r0, r1
- ldrb r0, [r2, 0x2]
- lsls r0, 30
- adds r4, r1, 0
- cmp r0, 0
- bge _08091D88
- ldrh r0, [r2]
- bl NationalPokedexNumToSpecies
- lsls r0, 16
- lsrs r2, r0, 16
- ldr r1, _08091E14 @ =gBaseStats
- lsls r0, r2, 3
- subs r0, r2
- lsls r0, 2
- adds r0, r1
- ldrb r1, [r0, 0x6]
- strb r1, [r7]
- ldrb r0, [r0, 0x7]
- strb r0, [r7, 0x1]
- ldr r2, [sp, 0x8]
- cmp r1, r2
- bne _08091D6A
- cmp r0, r10
- beq _08091D74
-_08091D6A:
- cmp r1, r10
- bne _08091D88
- ldr r1, [sp, 0x8]
- cmp r0, r1
- bne _08091D88
-_08091D74:
- ldr r2, _08091E0C @ =gPokedexView
- ldr r0, [r2]
- lsls r1, r6, 2
- adds r1, r0, r1
- adds r0, r4
- ldr r0, [r0]
- str r0, [r1]
- adds r0, r6, 0x1
- lsls r0, 16
- lsrs r6, r0, 16
-_08091D88:
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- ldr r1, _08091E0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091E10 @ =0x0000060c
- adds r0, r2
- ldrh r0, [r0]
- cmp r5, r0
- bcc _08091D34
-_08091D9C:
- ldr r1, _08091E0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091E10 @ =0x0000060c
- adds r0, r2
- strh r6, [r0]
-_08091DA6:
- ldr r1, _08091E0C @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08091E10 @ =0x0000060c
- adds r1, r0, r2
- ldrh r0, [r1]
- cmp r0, 0
- beq _08091DFA
- adds r5, r0, 0
- ldr r0, _08091E18 @ =0x00000181
- cmp r5, r0
- bhi _08091DFA
- ldr r4, _08091E0C @ =gPokedexView
- movs r1, 0x2
- negs r1, r1
- mov r10, r1
- movs r2, 0x3
- negs r2, r2
- mov r9, r2
- mov r8, r0
- ldr r0, _08091E1C @ =0x0000ffff
- adds r7, r0, 0
-_08091DD0:
- ldr r1, [r4]
- lsls r3, r5, 2
- adds r1, r3
- ldrh r0, [r1]
- orrs r0, r7
- strh r0, [r1]
- ldrb r2, [r1, 0x2]
- mov r0, r10
- ands r0, r2
- strb r0, [r1, 0x2]
- ldr r1, [r4]
- adds r1, r3
- ldrb r2, [r1, 0x2]
- mov r0, r9
- ands r0, r2
- strb r0, [r1, 0x2]
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- cmp r5, r8
- bls _08091DD0
-_08091DFA:
- adds r0, r6, 0
- add sp, 0x14
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r7}
- pop {r1}
- bx r1
- .align 2, 0
-_08091E0C: .4byte gPokedexView
-_08091E10: .4byte 0x0000060c
-_08091E14: .4byte gBaseStats
-_08091E18: .4byte 0x00000181
-_08091E1C: .4byte 0x0000ffff
- thumb_func_end sub_8091AF8
-
- thumb_func_start sub_8091E20
-sub_8091E20: @ 8091E20
- push {lr}
- sub sp, 0x8
- movs r1, 0x20
- str r1, [sp]
- movs r1, 0x1
- str r1, [sp, 0x4]
- movs r1, 0x9
- movs r2, 0x78
- movs r3, 0xD0
- bl sub_8072AB0
- add sp, 0x8
- pop {r0}
- bx r0
- thumb_func_end sub_8091E20
-
- thumb_func_start sub_8091E3C
-sub_8091E3C: @ 8091E3C
- push {lr}
- ldr r0, _08091E50 @ =sub_8091E54
- movs r1, 0
- bl CreateTask
- lsls r0, 24
- lsrs r0, 24
- pop {r1}
- bx r1
- .align 2, 0
-_08091E50: .4byte sub_8091E54
- thumb_func_end sub_8091E3C
-
- thumb_func_start sub_8091E54
-sub_8091E54: @ 8091E54
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- sub sp, 0x4
- lsls r0, 24
- lsrs r5, r0, 24
- ldr r1, _08091E78 @ =gMain
- ldr r2, _08091E7C @ =0x0000043c
- adds r0, r1, r2
- ldrb r0, [r0]
- adds r3, r1, 0
- cmp r0, 0x4
- bhi _08091E98
- lsls r0, 2
- ldr r1, _08091E80 @ =_08091E84
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08091E78: .4byte gMain
-_08091E7C: .4byte 0x0000043c
-_08091E80: .4byte _08091E84
- .align 2, 0
-_08091E84:
- .4byte _08091E98
- .4byte _08091F50
- .4byte _08091FC0
- .4byte _08091FE0
- .4byte _0809200C
-_08091E98:
- ldr r0, _08091F1C @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _08091EA6
- b _08092030
-_08091EA6:
- ldr r0, _08091F20 @ =gPokedexView
- ldr r0, [r0]
- ldr r1, _08091F24 @ =0x0000064a
- adds r0, r1
- movs r1, 0x2
- strb r1, [r0]
- movs r0, 0
- bl sub_8091060
- ldr r0, _08091F28 @ =gPokedexMenuSearch_Gfx
- movs r1, 0xC0
- lsls r1, 19
- bl LZ77UnCompVram
- ldr r0, _08091F2C @ =gUnknown_08E96D2C
- ldr r1, _08091F30 @ =0x06007800
- bl LZ77UnCompVram
- ldr r0, _08091F34 @ =gPokedexMenuSearch_Pal + 0x2
- movs r1, 0x1
- movs r2, 0x7E
- bl LoadPalette
- bl IsNationalPokedexEnabled
- cmp r0, 0
- bne _08091F10
- movs r4, 0
- ldr r2, _08091F38 @ =0x06007a80
- mov r8, r2
- ldr r0, _08091F3C @ =0x06007b00
- mov r12, r0
- movs r5, 0x1
- ldr r7, _08091F40 @ =0x06007ac0
- ldr r6, _08091F44 @ =0x06007b40
-_08091EEC:
- lsls r1, r4, 1
- mov r0, r8
- adds r2, r1, r0
- mov r0, r12
- adds r3, r1, r0
- ldrh r0, [r3]
- strh r0, [r2]
- adds r2, r1, r7
- adds r1, r6
- ldrh r0, [r1]
- strh r0, [r2]
- strh r5, [r3]
- strh r5, [r1]
- adds r0, r4, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- cmp r4, 0x10
- bls _08091EEC
-_08091F10:
- ldr r0, _08091F48 @ =gMain
- ldr r1, _08091F4C @ =0x0000043c
- adds r0, r1
- movs r1, 0x1
- strb r1, [r0]
- b _08092030
- .align 2, 0
-_08091F1C: .4byte gPaletteFade
-_08091F20: .4byte gPokedexView
-_08091F24: .4byte 0x0000064a
-_08091F28: .4byte gPokedexMenuSearch_Gfx
-_08091F2C: .4byte gUnknown_08E96D2C
-_08091F30: .4byte 0x06007800
-_08091F34: .4byte gPokedexMenuSearch_Pal + 0x2
-_08091F38: .4byte 0x06007a80
-_08091F3C: .4byte 0x06007b00
-_08091F40: .4byte 0x06007ac0
-_08091F44: .4byte 0x06007b40
-_08091F48: .4byte gMain
-_08091F4C: .4byte 0x0000043c
-_08091F50:
- ldr r4, _08091FA8 @ =gWindowConfig_81E7064
- adds r0, r4, 0
- bl SetUpWindowConfig
- adds r0, r4, 0
- bl InitMenuWindow
- ldr r0, _08091FAC @ =gUnknown_083A05CC
- bl LoadCompressedObjectPic
- ldr r0, _08091FB0 @ =gUnknown_083A05DC
- bl LoadSpritePalettes
- adds r0, r5, 0
- bl sub_809308C
- movs r4, 0
- lsls r0, r5, 2
- adds r0, r5
- lsls r1, r0, 3
- ldr r3, _08091FB4 @ =gTasks + 0x8
- movs r2, 0
-_08091F7C:
- lsls r0, r4, 1
- adds r0, r1
- adds r0, r3
- strh r2, [r0]
- adds r0, r4, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- cmp r4, 0xF
- bls _08091F7C
- adds r0, r5, 0
- bl sub_8092EB0
- movs r0, 0
- bl sub_8092AB0
- adds r0, r5, 0
- bl sub_8092B68
- ldr r1, _08091FB8 @ =gMain
- ldr r2, _08091FBC @ =0x0000043c
- adds r1, r2
- b _08091FF6
- .align 2, 0
-_08091FA8: .4byte gWindowConfig_81E7064
-_08091FAC: .4byte gUnknown_083A05CC
-_08091FB0: .4byte gUnknown_083A05DC
-_08091FB4: .4byte gTasks + 0x8
-_08091FB8: .4byte gMain
-_08091FBC: .4byte 0x0000043c
-_08091FC0:
- movs r0, 0x1
- negs r0, r0
- movs r1, 0
- str r1, [sp]
- movs r2, 0x10
- movs r3, 0
- bl BeginNormalPaletteFade
- ldr r1, _08091FD8 @ =gMain
- ldr r0, _08091FDC @ =0x0000043c
- adds r1, r0
- b _08091FF6
- .align 2, 0
-_08091FD8: .4byte gMain
-_08091FDC: .4byte 0x0000043c
-_08091FE0:
- ldr r1, _08092000 @ =REG_BG3CNT
- ldr r2, _08092004 @ =0x00000f03
- adds r0, r2, 0
- strh r0, [r1]
- subs r1, 0xE
- movs r2, 0xE2
- lsls r2, 5
- adds r0, r2, 0
- strh r0, [r1]
- ldr r0, _08092008 @ =0x0000043c
- adds r1, r3, r0
-_08091FF6:
- ldrb r0, [r1]
- adds r0, 0x1
- strb r0, [r1]
- b _08092030
- .align 2, 0
-_08092000: .4byte REG_BG3CNT
-_08092004: .4byte 0x00000f03
-_08092008: .4byte 0x0000043c
-_0809200C:
- ldr r0, _0809203C @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- lsls r0, 24
- lsrs r2, r0, 24
- cmp r2, 0
- bne _08092030
- ldr r1, _08092040 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r0, r1
- ldr r1, _08092044 @ =sub_809204C
- str r1, [r0]
- ldr r1, _08092048 @ =0x0000043c
- adds r0, r3, r1
- strb r2, [r0]
-_08092030:
- add sp, 0x4
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_0809203C: .4byte gPaletteFade
-_08092040: .4byte gTasks
-_08092044: .4byte sub_809204C
-_08092048: .4byte 0x0000043c
- thumb_func_end sub_8091E54
-
- thumb_func_start sub_809204C
-sub_809204C: @ 809204C
- push {r4,r5,lr}
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- ldr r0, _08092074 @ =gTasks
- lsls r4, r5, 2
- adds r4, r5
- lsls r4, 3
- adds r4, r0
- ldrb r0, [r4, 0x8]
- bl sub_8092AB0
- adds r0, r5, 0
- bl sub_8092B68
- ldr r0, _08092078 @ =sub_809207C
- str r0, [r4]
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08092074: .4byte gTasks
-_08092078: .4byte sub_809207C
- thumb_func_end sub_809204C
-
- thumb_func_start sub_809207C
-sub_809207C: @ 809207C
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- ldr r0, _080920A4 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _080920B0
- movs r0, 0x3
- bl PlaySE
- ldr r0, _080920A8 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r1, r0
- ldr r0, _080920AC @ =sub_80927B8
- str r0, [r1]
- b _0809216C
- .align 2, 0
-_080920A4: .4byte gMain
-_080920A8: .4byte gTasks
-_080920AC: .4byte sub_80927B8
-_080920B0:
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _0809210C
- ldr r1, _080920D4 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r5, r0, r1
- movs r0, 0x8
- ldrsh r4, [r5, r0]
- cmp r4, 0x1
- beq _080920E8
- cmp r4, 0x1
- bgt _080920D8
- cmp r4, 0
- beq _080920DE
- b _0809216C
- .align 2, 0
-_080920D4: .4byte gTasks
-_080920D8:
- cmp r4, 0x2
- beq _080920FC
- b _0809216C
-_080920DE:
- movs r0, 0x15
- bl PlaySE
- strh r4, [r5, 0xA]
- b _080920F2
-_080920E8:
- movs r0, 0x15
- bl PlaySE
- movs r0, 0x4
- strh r0, [r5, 0xA]
-_080920F2:
- ldr r0, _080920F8 @ =sub_809217C
- str r0, [r5]
- b _0809216C
- .align 2, 0
-_080920F8: .4byte sub_809217C
-_080920FC:
- movs r0, 0x3
- bl PlaySE
- ldr r0, _08092108 @ =sub_80927B8
- str r0, [r5]
- b _0809216C
- .align 2, 0
-_08092108: .4byte sub_80927B8
-_0809210C:
- movs r0, 0x20
- ands r0, r1
- cmp r0, 0
- beq _0809213A
- ldr r0, _08092174 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r4, r1, r0
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- cmp r0, 0
- ble _0809213A
- movs r0, 0x6D
- bl PlaySE
- ldrh r0, [r4, 0x8]
- subs r0, 0x1
- strh r0, [r4, 0x8]
- lsls r0, 24
- lsrs r0, 24
- bl sub_8092AB0
-_0809213A:
- ldr r0, _08092178 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- beq _0809216C
- ldr r0, _08092174 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r4, r1, r0
- movs r1, 0x8
- ldrsh r0, [r4, r1]
- cmp r0, 0x1
- bgt _0809216C
- movs r0, 0x6D
- bl PlaySE
- ldrh r0, [r4, 0x8]
- adds r0, 0x1
- strh r0, [r4, 0x8]
- lsls r0, 24
- lsrs r0, 24
- bl sub_8092AB0
-_0809216C:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08092174: .4byte gTasks
-_08092178: .4byte gMain
- thumb_func_end sub_809207C
-
- thumb_func_start sub_809217C
-sub_809217C: @ 809217C
- push {r4,r5,lr}
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- ldr r0, _080921A8 @ =gTasks
- lsls r4, r5, 2
- adds r4, r5
- lsls r4, 3
- adds r4, r0
- ldrb r0, [r4, 0x8]
- ldrb r1, [r4, 0xA]
- bl sub_8092AD4
- adds r0, r5, 0
- bl sub_8092B68
- ldr r0, _080921AC @ =sub_80921B0
- str r0, [r4]
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080921A8: .4byte gTasks
-_080921AC: .4byte sub_80921B0
- thumb_func_end sub_809217C
-
- thumb_func_start sub_80921B0
-sub_80921B0: @ 80921B0
- push {r4-r7,lr}
- lsls r0, 24
- lsrs r5, r0, 24
- ldr r1, _080921D8 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r0, r1
- movs r1, 0x8
- ldrsh r0, [r0, r1]
- cmp r0, 0
- beq _080921E4
- bl IsNationalPokedexEnabled
- ldr r6, _080921DC @ =gUnknown_083B586C
- cmp r0, 0
- bne _080921F0
- ldr r6, _080921E0 @ =gUnknown_083B58A4
- b _080921F0
- .align 2, 0
-_080921D8: .4byte gTasks
-_080921DC: .4byte gUnknown_083B586C
-_080921E0: .4byte gUnknown_083B58A4
-_080921E4:
- bl IsNationalPokedexEnabled
- ldr r6, _0809221C @ =gUnknown_083B5850
- cmp r0, 0
- bne _080921F0
- ldr r6, _08092220 @ =gUnknown_083B5888
-_080921F0:
- ldr r0, _08092224 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x2
- ands r0, r1
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r3, 0
- beq _08092230
- movs r0, 0x17
- bl PlaySE
- adds r0, r5, 0
- bl sub_8092EB0
- ldr r0, _08092228 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r1, r0
- ldr r0, _0809222C @ =sub_809204C
- str r0, [r1]
- b _080923EC
- .align 2, 0
-_0809221C: .4byte gUnknown_083B5850
-_08092220: .4byte gUnknown_083B5888
-_08092224: .4byte gMain
-_08092228: .4byte gTasks
-_0809222C: .4byte sub_809204C
-_08092230:
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _08092300
- ldr r0, _080922B4 @ =gTasks
- lsls r1, r5, 2
- adds r1, r5
- lsls r1, 3
- adds r6, r1, r0
- movs r2, 0xA
- ldrsh r0, [r6, r2]
- cmp r0, 0x6
- bne _080922F0
- movs r1, 0x8
- ldrsh r0, [r6, r1]
- cmp r0, 0
- beq _080922D4
- ldr r1, _080922B8 @ =gUnknown_0202FFBA
- movs r0, 0x40
- strb r0, [r1]
- ldr r7, _080922BC @ =gPokedexView
- ldr r1, [r7]
- ldr r0, _080922C0 @ =0x0000062a
- adds r2, r1, r0
- movs r0, 0x40
- strh r0, [r2]
- ldr r0, _080922C4 @ =gUnknown_0202FFB8
- strh r3, [r0]
- movs r2, 0xC2
- lsls r2, 3
- adds r1, r2
- strh r3, [r1]
- adds r0, r5, 0
- movs r1, 0x5
- bl sub_8092E10
- ldr r4, _080922C8 @ =gSaveBlock2
- strb r0, [r4, 0x19]
- bl IsNationalPokedexEnabled
- cmp r0, 0
- bne _08092288
- movs r0, 0
- strb r0, [r4, 0x19]
-_08092288:
- ldr r0, [r7]
- ldrb r1, [r4, 0x19]
- ldr r2, _080922CC @ =0x00000614
- adds r0, r2
- strh r1, [r0]
- adds r0, r5, 0
- movs r1, 0x4
- bl sub_8092E10
- strb r0, [r4, 0x18]
- ldr r0, [r7]
- ldrb r1, [r4, 0x18]
- movs r2, 0xC3
- lsls r2, 3
- adds r0, r2
- strh r1, [r0]
- movs r0, 0x3
- bl PlaySE
- ldr r0, _080922D0 @ =sub_80927B8
- str r0, [r6]
- b _080923EC
- .align 2, 0
-_080922B4: .4byte gTasks
-_080922B8: .4byte gUnknown_0202FFBA
-_080922BC: .4byte gPokedexView
-_080922C0: .4byte 0x0000062a
-_080922C4: .4byte gUnknown_0202FFB8
-_080922C8: .4byte gSaveBlock2
-_080922CC: .4byte 0x00000614
-_080922D0: .4byte sub_80927B8
-_080922D4:
- ldr r0, _080922E8 @ =gDexText_Searching
- bl sub_8091E20
- ldr r0, _080922EC @ =sub_80923FC
- str r0, [r6]
- movs r0, 0x70
- bl PlaySE
- b _080923EC
- .align 2, 0
-_080922E8: .4byte gDexText_Searching
-_080922EC: .4byte sub_80923FC
-_080922F0:
- movs r0, 0x15
- bl PlaySE
- ldr r0, _080922FC @ =sub_80925CC
- str r0, [r6]
- b _080923EC
- .align 2, 0
-_080922FC: .4byte sub_80925CC
-_08092300:
- movs r0, 0x20
- ands r0, r1
- cmp r0, 0
- beq _08092338
- ldr r1, _080923F4 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r4, r0, r1
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r6
- ldrb r0, [r0]
- cmp r0, 0xFF
- beq _08092338
- movs r0, 0x5
- bl PlaySE
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- lsls r0, 2
- adds r0, r6
- ldrb r1, [r0]
- strh r1, [r4, 0xA]
- ldrb r0, [r4, 0x8]
- bl sub_8092AD4
-_08092338:
- ldr r0, _080923F8 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x10
- ands r0, r1
- cmp r0, 0
- beq _08092374
- ldr r1, _080923F4 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r4, r0, r1
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r6
- ldrb r0, [r0, 0x1]
- cmp r0, 0xFF
- beq _08092374
- movs r0, 0x5
- bl PlaySE
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- lsls r0, 2
- adds r0, r6
- ldrb r1, [r0, 0x1]
- strh r1, [r4, 0xA]
- ldrb r0, [r4, 0x8]
- bl sub_8092AD4
-_08092374:
- ldr r0, _080923F8 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _080923B0
- ldr r1, _080923F4 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r4, r0, r1
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r6
- ldrb r0, [r0, 0x2]
- cmp r0, 0xFF
- beq _080923B0
- movs r0, 0x5
- bl PlaySE
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- lsls r0, 2
- adds r0, r6
- ldrb r1, [r0, 0x2]
- strh r1, [r4, 0xA]
- ldrb r0, [r4, 0x8]
- bl sub_8092AD4
-_080923B0:
- ldr r0, _080923F8 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _080923EC
- ldr r1, _080923F4 @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r4, r0, r1
- movs r1, 0xA
- ldrsh r0, [r4, r1]
- lsls r0, 2
- adds r0, r6
- ldrb r0, [r0, 0x3]
- cmp r0, 0xFF
- beq _080923EC
- movs r0, 0x5
- bl PlaySE
- movs r2, 0xA
- ldrsh r0, [r4, r2]
- lsls r0, 2
- adds r0, r6
- ldrb r1, [r0, 0x3]
- strh r1, [r4, 0xA]
- ldrb r0, [r4, 0x8]
- bl sub_8092AD4
-_080923EC:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_080923F4: .4byte gTasks
-_080923F8: .4byte gMain
- thumb_func_end sub_80921B0
-
- thumb_func_start sub_80923FC
-sub_80923FC: @ 80923FC
- push {r4-r6,lr}
- mov r6, r10
- mov r5, r9
- mov r4, r8
- push {r4-r6}
- sub sp, 0x8
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- adds r0, r5, 0
- movs r1, 0x5
- bl sub_8092E10
- mov r10, r0
- mov r0, r10
- lsls r0, 24
- lsrs r0, 24
- mov r10, r0
- adds r0, r5, 0
- movs r1, 0x4
- bl sub_8092E10
- mov r9, r0
- mov r0, r9
- lsls r0, 24
- lsrs r0, 24
- mov r9, r0
- adds r0, r5, 0
- movs r1, 0
- bl sub_8092E10
- mov r8, r0
- mov r0, r8
- lsls r0, 24
- lsrs r0, 24
- mov r8, r0
- adds r0, r5, 0
- movs r1, 0x1
- bl sub_8092E10
- adds r6, r0, 0
- lsls r6, 24
- lsrs r6, 24
- adds r0, r5, 0
- movs r1, 0x2
- bl sub_8092E10
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r5, 0
- movs r1, 0x3
- bl sub_8092E10
- lsls r0, 24
- lsrs r0, 24
- str r4, [sp]
- str r0, [sp, 0x4]
- mov r0, r10
- mov r1, r9
- mov r2, r8
- adds r3, r6, 0
- bl sub_8091AF8
- ldr r1, _0809249C @ =gTasks
- lsls r0, r5, 2
- adds r0, r5
- lsls r0, 3
- adds r0, r1
- ldr r1, _080924A0 @ =sub_80924A4
- str r1, [r0]
- add sp, 0x8
- pop {r3-r5}
- mov r8, r3
- mov r9, r4
- mov r10, r5
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_0809249C: .4byte gTasks
-_080924A0: .4byte sub_80924A4
- thumb_func_end sub_80923FC
-
- thumb_func_start sub_80924A4
-sub_80924A4: @ 80924A4
- push {r4,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- bl IsSEPlaying
- lsls r0, 24
- cmp r0, 0
- bne _080924F6
- ldr r0, _080924D0 @ =gPokedexView
- ldr r0, [r0]
- ldr r1, _080924D4 @ =0x0000060c
- adds r0, r1
- ldrh r0, [r0]
- cmp r0, 0
- beq _080924DC
- movs r0, 0x1F
- bl PlaySE
- ldr r0, _080924D8 @ =gDexText_SearchComplete
- bl sub_8091E20
- b _080924E8
- .align 2, 0
-_080924D0: .4byte gPokedexView
-_080924D4: .4byte 0x0000060c
-_080924D8: .4byte gDexText_SearchComplete
-_080924DC:
- movs r0, 0x20
- bl PlaySE
- ldr r0, _080924FC @ =gDexText_NoMatching
- bl sub_8091E20
-_080924E8:
- ldr r0, _08092500 @ =gTasks
- lsls r1, r4, 2
- adds r1, r4
- lsls r1, 3
- adds r1, r0
- ldr r0, _08092504 @ =sub_8092508
- str r0, [r1]
-_080924F6:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080924FC: .4byte gDexText_NoMatching
-_08092500: .4byte gTasks
-_08092504: .4byte sub_8092508
- thumb_func_end sub_80924A4
-
- thumb_func_start sub_8092508
-sub_8092508: @ 8092508
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- adds r2, r4, 0
- ldr r0, _08092570 @ =gMain
- ldrh r1, [r0, 0x2E]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _080925A4
- ldr r5, _08092574 @ =gPokedexView
- ldr r1, [r5]
- ldr r3, _08092578 @ =0x0000060c
- adds r0, r1, r3
- ldrh r0, [r0]
- cmp r0, 0
- beq _08092590
- ldr r0, _0809257C @ =0x0000064f
- adds r1, r0
- movs r0, 0x1
- strb r0, [r1]
- adds r0, r4, 0
- movs r1, 0x5
- bl sub_8092E10
- ldr r1, [r5]
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08092580 @ =0x00000612
- adds r1, r2
- strh r0, [r1]
- adds r0, r4, 0
- movs r1, 0x4
- bl sub_8092E10
- ldr r1, [r5]
- lsls r0, 24
- lsrs r0, 24
- ldr r3, _08092584 @ =0x00000616
- adds r1, r3
- strh r0, [r1]
- ldr r1, _08092588 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _0809258C @ =sub_80927B8
- str r1, [r0]
- movs r0, 0x3
- bl PlaySE
- b _080925A4
- .align 2, 0
-_08092570: .4byte gMain
-_08092574: .4byte gPokedexView
-_08092578: .4byte 0x0000060c
-_0809257C: .4byte 0x0000064f
-_08092580: .4byte 0x00000612
-_08092584: .4byte 0x00000616
-_08092588: .4byte gTasks
-_0809258C: .4byte sub_80927B8
-_08092590:
- ldr r0, _080925AC @ =gTasks
- lsls r1, r2, 2
- adds r1, r2
- lsls r1, 3
- adds r1, r0
- ldr r0, _080925B0 @ =sub_809217C
- str r0, [r1]
- movs r0, 0x17
- bl PlaySE
-_080925A4:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_080925AC: .4byte gTasks
-_080925B0: .4byte sub_809217C
- thumb_func_end sub_8092508
-
- thumb_func_start sub_80925B4
-sub_80925B4: @ 80925B4
- push {lr}
- adds r1, r0, 0
- lsls r1, 16
- lsrs r1, 15
- adds r1, 0x1
- lsls r1, 27
- lsrs r1, 24
- movs r0, 0x90
- bl sub_814AD7C
- pop {r0}
- bx r0
- thumb_func_end sub_80925B4
-
- thumb_func_start sub_80925CC
-sub_80925CC: @ 80925CC
- push {r4-r6,lr}
- sub sp, 0x4
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0
- bl sub_8092C8C
- ldr r2, _08092630 @ =gTasks
- lsls r1, r4, 2
- adds r1, r4
- lsls r1, 3
- adds r6, r1, r2
- ldrb r0, [r6, 0xA]
- adds r2, 0x8
- adds r1, r2
- ldr r2, _08092634 @ =gUnknown_083B5A7C
- lsls r0, 3
- adds r0, r2
- ldrb r5, [r0, 0x4]
- lsls r5, 1
- adds r5, r1, r5
- ldrb r0, [r0, 0x5]
- lsls r0, 1
- adds r1, r0
- ldrh r0, [r5]
- strh r0, [r6, 0x24]
- ldrh r0, [r1]
- strh r0, [r6, 0x26]
- adds r0, r4, 0
- bl sub_8092D78
- ldr r1, _08092638 @ =0x0000ffff
- ldr r3, _0809263C @ =0x00002d9f
- movs r0, 0xB
- str r0, [sp]
- movs r0, 0x10
- movs r2, 0xC
- bl CreateBlendedOutlineCursor
- ldrh r0, [r5]
- movs r1, 0x1
- bl sub_80925B4
- ldr r0, _08092640 @ =sub_8092644
- str r0, [r6]
- add sp, 0x4
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08092630: .4byte gTasks
-_08092634: .4byte gUnknown_083B5A7C
-_08092638: .4byte 0x0000ffff
-_0809263C: .4byte 0x00002d9f
-_08092640: .4byte sub_8092644
- thumb_func_end sub_80925CC
-
- thumb_func_start sub_8092644
-sub_8092644: @ 8092644
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- lsls r0, 24
- lsrs r7, r0, 24
- ldr r3, _080926A8 @ =gTasks
- lsls r2, r7, 2
- adds r2, r7
- lsls r2, 3
- adds r6, r2, r3
- ldrb r1, [r6, 0xA]
- ldr r0, _080926AC @ =gUnknown_083B5A7C
- lsls r1, 3
- adds r1, r0
- ldr r0, [r1]
- mov r8, r0
- adds r3, 0x8
- adds r2, r3
- ldrb r0, [r1, 0x4]
- lsls r0, 1
- adds r4, r2, r0
- ldrb r0, [r1, 0x5]
- lsls r0, 1
- adds r5, r2, r0
- ldrh r0, [r1, 0x6]
- subs r0, 0x1
- lsls r0, 16
- lsrs r2, r0, 16
- ldr r0, _080926B0 @ =gMain
- mov r12, r0
- ldrh r1, [r0, 0x2E]
- movs r0, 0x1
- ands r0, r1
- cmp r0, 0
- beq _080926B4
- bl sub_814ADC8
- movs r0, 0x15
- bl PlaySE
- movs r0, 0x12
- movs r1, 0x1
- movs r2, 0x1C
- movs r3, 0xC
- bl MenuZeroFillWindowRect
- movs r0, 0x1
- bl sub_8092C8C
- b _080926E0
- .align 2, 0
-_080926A8: .4byte gTasks
-_080926AC: .4byte gUnknown_083B5A7C
-_080926B0: .4byte gMain
-_080926B4:
- movs r0, 0x2
- ands r0, r1
- cmp r0, 0
- beq _080926EC
- bl sub_814ADC8
- movs r0, 0x17
- bl PlaySE
- movs r0, 0x12
- movs r1, 0x1
- movs r2, 0x1C
- movs r3, 0xC
- bl MenuZeroFillWindowRect
- movs r0, 0x1
- bl sub_8092C8C
- ldrh r0, [r6, 0x24]
- strh r0, [r4]
- ldrh r0, [r6, 0x26]
- strh r0, [r5]
-_080926E0:
- ldr r0, _080926E8 @ =sub_809217C
- str r0, [r6]
- b _080927AE
- .align 2, 0
-_080926E8: .4byte sub_809217C
-_080926EC:
- movs r3, 0
- mov r0, r12
- ldrh r1, [r0, 0x30]
- movs r0, 0x40
- ands r0, r1
- cmp r0, 0
- beq _0809274C
- ldrh r0, [r4]
- cmp r0, 0
- beq _08092716
- movs r1, 0
- bl sub_80925B4
- ldrh r0, [r4]
- subs r0, 0x1
- strh r0, [r4]
- ldrh r0, [r4]
- movs r1, 0x1
- bl sub_80925B4
- b _08092734
-_08092716:
- ldrh r0, [r5]
- cmp r0, 0
- beq _08092730
- subs r0, 0x1
- strh r0, [r5]
- adds r0, r7, 0
- bl sub_8092D78
- ldrh r0, [r4]
- movs r1, 0x1
- bl sub_80925B4
- movs r3, 0x1
-_08092730:
- cmp r3, 0
- beq _080927AE
-_08092734:
- movs r0, 0x5
- bl PlaySE
- ldrh r0, [r4]
- ldrh r1, [r5]
- adds r0, r1
- lsls r0, 3
- add r0, r8
- ldr r0, [r0]
- bl sub_8091E20
- b _080927AE
-_0809274C:
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- beq _080927AE
- ldrh r0, [r4]
- cmp r0, 0x4
- bhi _08092774
- cmp r0, r2
- bcs _08092774
- movs r1, 0
- bl sub_80925B4
- ldrh r0, [r4]
- adds r0, 0x1
- strh r0, [r4]
- ldrh r0, [r4]
- movs r1, 0x1
- bl sub_80925B4
- b _08092798
-_08092774:
- cmp r2, 0x5
- bls _08092794
- ldrh r1, [r5]
- subs r0, r2, 0x5
- cmp r1, r0
- bge _08092794
- adds r0, r1, 0x1
- strh r0, [r5]
- adds r0, r7, 0
- bl sub_8092D78
- movs r0, 0x5
- movs r1, 0x1
- bl sub_80925B4
- movs r3, 0x1
-_08092794:
- cmp r3, 0
- beq _080927AE
-_08092798:
- movs r0, 0x5
- bl PlaySE
- ldrh r0, [r4]
- ldrh r1, [r5]
- adds r0, r1
- lsls r0, 3
- add r0, r8
- ldr r0, [r0]
- bl sub_8091E20
-_080927AE:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8092644
-
- thumb_func_start sub_80927B8
-sub_80927B8: @ 80927B8
- push {r4,lr}
- sub sp, 0x4
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0x1
- negs r0, r0
- movs r1, 0
- str r1, [sp]
- movs r2, 0
- movs r3, 0x10
- bl BeginNormalPaletteFade
- ldr r1, _080927E8 @ =gTasks
- lsls r0, r4, 2
- adds r0, r4
- lsls r0, 3
- adds r0, r1
- ldr r1, _080927EC @ =sub_80927F0
- str r1, [r0]
- add sp, 0x4
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_080927E8: .4byte gTasks
-_080927EC: .4byte sub_80927F0
- thumb_func_end sub_80927B8
-
- thumb_func_start sub_80927F0
-sub_80927F0: @ 80927F0
- push {lr}
- lsls r0, 24
- lsrs r2, r0, 24
- ldr r0, _0809280C @ =gPaletteFade
- ldrb r1, [r0, 0x7]
- movs r0, 0x80
- ands r0, r1
- cmp r0, 0
- bne _08092808
- adds r0, r2, 0
- bl DestroyTask
-_08092808:
- pop {r0}
- bx r0
- .align 2, 0
-_0809280C: .4byte gPaletteFade
- thumb_func_end sub_80927F0
-
- thumb_func_start sub_8092810
-sub_8092810: @ 8092810
- push {r4-r7,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 24
- lsrs r1, 24
- mov r12, r1
- lsls r2, 24
- lsrs r1, r2, 24
- lsls r3, 24
- lsrs r5, r3, 8
- movs r3, 0
- cmp r5, 0
- beq _0809285A
- lsls r7, r1, 6
- ldr r6, _08092860 @ =0x00000fff
- lsls r4, r0, 12
-_08092830:
- mov r0, r12
- adds r1, r0, r3
- lsls r1, 1
- adds r1, r7, r1
- ldr r0, _08092864 @ =0x06007800
- adds r2, r1, r0
- ldrh r0, [r2]
- ands r0, r6
- orrs r0, r4
- strh r0, [r2]
- ldr r0, _08092868 @ =0x06007840
- adds r1, r0
- ldrh r0, [r1]
- ands r0, r6
- orrs r0, r4
- strh r0, [r1]
- adds r0, r3, 0x1
- lsls r0, 16
- lsrs r3, r0, 16
- cmp r0, r5
- bcc _08092830
-_0809285A:
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08092860: .4byte 0x00000fff
-_08092864: .4byte 0x06007800
-_08092868: .4byte 0x06007840
- thumb_func_end sub_8092810
-
- thumb_func_start sub_809286C
-sub_809286C: @ 809286C
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- lsls r1, 24
- lsrs r5, r1, 24
- lsls r2, 24
- lsrs r2, 24
- movs r0, 0x1
- ands r5, r0
- ands r2, r0
- lsls r2, 1
- orrs r5, r2
- cmp r4, 0xA
- bhi _08092958
- lsls r0, r4, 2
- ldr r1, _08092894 @ =_08092898
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08092894: .4byte _08092898
- .align 2, 0
-_08092898:
- .4byte _080928C4
- .4byte _080928C4
- .4byte _080928C4
- .4byte _080928D4
- .4byte _080928D4
- .4byte _080928EC
- .4byte _080928EC
- .4byte _080928D4
- .4byte _080928D4
- .4byte _08092914
- .4byte _08092904
-_080928C4:
- ldr r1, _080928D0 @ =gUnknown_083B57E4
- lsls r0, r4, 3
- adds r0, r1
- ldrb r1, [r0, 0x4]
- ldrb r2, [r0, 0x5]
- b _08092932
- .align 2, 0
-_080928D0: .4byte gUnknown_083B57E4
-_080928D4:
- ldr r2, _08092900 @ =gUnknown_083B57FC
- subs r1, r4, 0x3
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x4]
- ldrb r2, [r0, 0x5]
- ldrb r3, [r0, 0x6]
- adds r0, r5, 0
- bl sub_8092810
-_080928EC:
- ldr r2, _08092900 @ =gUnknown_083B57FC
- subs r1, r4, 0x3
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x7]
- ldrb r2, [r0, 0x8]
- ldrb r3, [r0, 0x9]
- b _08092934
- .align 2, 0
-_08092900: .4byte gUnknown_083B57FC
-_08092904:
- ldr r0, _08092910 @ =gUnknown_083B57FC
- ldrb r1, [r0, 0x1C]
- ldrb r2, [r0, 0x1D]
- ldrb r3, [r0, 0x1E]
- b _08092934
- .align 2, 0
-_08092910: .4byte gUnknown_083B57FC
-_08092914:
- bl IsNationalPokedexEnabled
- cmp r0, 0
- bne _08092940
- ldr r2, _0809293C @ =gUnknown_083B57FC
- subs r1, r4, 0x3
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x4]
- ldrb r2, [r0, 0x5]
- subs r2, 0x2
- lsls r2, 24
- lsrs r2, 24
-_08092932:
- ldrb r3, [r0, 0x6]
-_08092934:
- adds r0, r5, 0
- bl sub_8092810
- b _08092958
- .align 2, 0
-_0809293C: .4byte gUnknown_083B57FC
-_08092940:
- ldr r2, _08092960 @ =gUnknown_083B57FC
- subs r1, r4, 0x3
- lsls r0, r1, 1
- adds r0, r1
- lsls r0, 2
- adds r0, r2
- ldrb r1, [r0, 0x4]
- ldrb r2, [r0, 0x5]
- ldrb r3, [r0, 0x6]
- adds r0, r5, 0
- bl sub_8092810
-_08092958:
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08092960: .4byte gUnknown_083B57FC
- thumb_func_end sub_809286C
-
- thumb_func_start sub_8092964
-sub_8092964: @ 8092964
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- adds r1, r0, 0
- cmp r0, 0x1
- beq _080929CE
- cmp r0, 0x1
- bgt _0809297A
- cmp r0, 0
- beq _08092980
- b _08092AAC
-_0809297A:
- cmp r1, 0x2
- beq _08092A3E
- b _08092AAC
-_08092980:
- movs r0, 0
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- movs r0, 0x1
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x2
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x3
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x4
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0xA
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x5
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x6
- movs r1, 0x1
- movs r2, 0
- b _08092A1A
-_080929CE:
- movs r0, 0
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x1
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- movs r0, 0x2
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x3
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x4
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0xA
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x5
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x6
- movs r1, 0x1
- movs r2, 0x1
-_08092A1A:
- bl sub_809286C
- movs r0, 0x7
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x8
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x9
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- b _08092AAC
-_08092A3E:
- movs r0, 0
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x1
- movs r1, 0x1
- movs r2, 0
- bl sub_809286C
- movs r0, 0x2
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- movs r0, 0x3
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x4
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0xA
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x5
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x6
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x7
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x8
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
- movs r0, 0x9
- movs r1, 0x1
- movs r2, 0x1
- bl sub_809286C
-_08092AAC:
- pop {r0}
- bx r0
- thumb_func_end sub_8092964
-
- thumb_func_start sub_8092AB0
-sub_8092AB0: @ 8092AB0
- push {r4,lr}
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r4, 0
- bl sub_8092964
- ldr r0, _08092AD0 @ =gUnknown_083B57E4
- lsls r4, 3
- adds r4, r0
- ldr r0, [r4]
- bl sub_8091E20
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08092AD0: .4byte gUnknown_083B57E4
- thumb_func_end sub_8092AB0
-
- thumb_func_start sub_8092AD4
-sub_8092AD4: @ 8092AD4
- push {r4,lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 24
- lsrs r4, r1, 24
- bl sub_8092964
- cmp r4, 0x6
- bhi _08092B4E
- lsls r0, r4, 2
- ldr r1, _08092AF0 @ =_08092AF4
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08092AF0: .4byte _08092AF4
- .align 2, 0
-_08092AF4:
- .4byte _08092B10
- .4byte _08092B14
- .4byte _08092B18
- .4byte _08092B26
- .4byte _08092B34
- .4byte _08092B38
- .4byte _08092B44
-_08092B10:
- movs r0, 0x3
- b _08092B3A
-_08092B14:
- movs r0, 0x4
- b _08092B3A
-_08092B18:
- movs r0, 0xA
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- movs r0, 0x5
- b _08092B3A
-_08092B26:
- movs r0, 0xA
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- movs r0, 0x6
- b _08092B3A
-_08092B34:
- movs r0, 0x7
- b _08092B3A
-_08092B38:
- movs r0, 0x8
-_08092B3A:
- movs r1, 0
- movs r2, 0
- bl sub_809286C
- b _08092B4E
-_08092B44:
- movs r0, 0x9
- movs r1, 0
- movs r2, 0
- bl sub_809286C
-_08092B4E:
- ldr r0, _08092B64 @ =gUnknown_083B57FC
- lsls r1, r4, 1
- adds r1, r4
- lsls r1, 2
- adds r1, r0
- ldr r0, [r1]
- bl sub_8091E20
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08092B64: .4byte gUnknown_083B57FC
- thumb_func_end sub_8092AD4
-
- thumb_func_start sub_8092B68
-sub_8092B68: @ 8092B68
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- lsls r0, 24
- lsrs r0, 24
- ldr r2, _08092C68 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r6, r1, r2
- ldrh r0, [r6, 0x16]
- ldrh r1, [r6, 0x14]
- adds r0, r1
- lsls r0, 16
- ldr r7, _08092C6C @ =gStringVar1
- ldr r1, _08092C70 @ =gUnknown_083B5910
- lsrs r0, 13
- adds r1, 0x4
- adds r0, r1
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- ldr r0, _08092C74 @ =gUnknown_083B5AB2
- mov r8, r0
- movs r1, 0x2D
- movs r2, 0x10
- movs r3, 0x1
- bl MenuPrint_PixelCoords
- ldrh r0, [r6, 0x1A]
- ldrh r1, [r6, 0x18]
- adds r0, r1
- lsls r0, 16
- ldr r1, _08092C78 @ =gUnknown_083B5968
- lsrs r0, 13
- adds r1, 0x4
- adds r0, r1
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- mov r0, r8
- movs r1, 0x2D
- movs r2, 0x20
- movs r3, 0x1
- bl MenuPrint_PixelCoords
- ldrh r0, [r6, 0x1E]
- ldrh r1, [r6, 0x1C]
- adds r0, r1
- lsls r0, 16
- ldr r4, _08092C7C @ =gUnknown_083B59C8
- lsrs r0, 13
- adds r4, 0x4
- adds r0, r4
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- ldr r5, _08092C80 @ =gUnknown_083B5AAC
- adds r0, r5, 0
- movs r1, 0x2D
- movs r2, 0x30
- movs r3, 0x1
- bl MenuPrint_PixelCoords
- ldrh r0, [r6, 0x22]
- ldrh r1, [r6, 0x20]
- adds r0, r1
- lsls r0, 16
- lsrs r0, 13
- adds r0, r4
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- adds r0, r5, 0
- movs r1, 0x5D
- movs r2, 0x30
- movs r3, 0x1
- bl MenuPrint_PixelCoords
- ldrh r0, [r6, 0x12]
- ldrh r1, [r6, 0x10]
- adds r0, r1
- lsls r0, 16
- ldr r1, _08092C84 @ =gUnknown_083B58D8
- lsrs r0, 13
- adds r1, 0x4
- adds r0, r1
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- mov r0, r8
- movs r1, 0x2D
- movs r2, 0x40
- movs r3, 0x1
- bl MenuPrint_PixelCoords
- bl IsNationalPokedexEnabled
- cmp r0, 0
- beq _08092C5E
- ldrh r0, [r6, 0xE]
- ldrh r6, [r6, 0xC]
- adds r0, r6
- lsls r0, 16
- ldr r1, _08092C88 @ =gUnknown_083B58C0
- lsrs r0, 13
- adds r1, 0x4
- adds r0, r1
- ldr r1, [r0]
- adds r0, r7, 0
- bl StringCopy
- mov r0, r8
- movs r1, 0x2D
- movs r2, 0x50
- movs r3, 0x1
- bl MenuPrint_PixelCoords
-_08092C5E:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- .align 2, 0
-_08092C68: .4byte gTasks
-_08092C6C: .4byte gStringVar1
-_08092C70: .4byte gUnknown_083B5910
-_08092C74: .4byte gUnknown_083B5AB2
-_08092C78: .4byte gUnknown_083B5968
-_08092C7C: .4byte gUnknown_083B59C8
-_08092C80: .4byte gUnknown_083B5AAC
-_08092C84: .4byte gUnknown_083B58D8
-_08092C88: .4byte gUnknown_083B58C0
- thumb_func_end sub_8092B68
-
- thumb_func_start sub_8092C8C
-sub_8092C8C: @ 8092C8C
- push {r4-r6,lr}
- lsls r0, 24
- cmp r0, 0
- bne _08092D48
- ldr r1, _08092D1C @ =0x06007822
- ldr r2, _08092D20 @ =0x00000c0b
- adds r0, r2, 0
- strh r0, [r1]
- movs r1, 0x12
- ldr r3, _08092D24 @ =0x06007800
- ldr r4, _08092D28 @ =0x0000080d
- adds r2, r4, 0
-_08092CA4:
- lsls r0, r1, 1
- adds r0, r3
- strh r2, [r0]
- adds r0, r1, 0x1
- lsls r0, 16
- lsrs r1, r0, 16
- cmp r1, 0x1C
- bls _08092CA4
- ldr r1, _08092D2C @ =0x0600783a
- ldr r2, _08092D30 @ =0x0000080b
- adds r0, r2, 0
- strh r0, [r1]
- movs r3, 0x1
- ldr r6, _08092D24 @ =0x06007800
- movs r5, 0x2
-_08092CC2:
- lsls r2, r3, 6
- ldr r4, _08092D1C @ =0x06007822
- adds r1, r2, r4
- ldr r4, _08092D34 @ =0x0000040a
- adds r0, r4, 0
- strh r0, [r1]
- movs r1, 0x12
- adds r4, r3, 0x1
- adds r3, r2, 0
-_08092CD4:
- lsls r0, r1, 1
- adds r0, r3, r0
- adds r0, r6
- strh r5, [r0]
- adds r0, r1, 0x1
- lsls r0, 16
- lsrs r1, r0, 16
- cmp r1, 0x1C
- bls _08092CD4
- ldr r1, _08092D2C @ =0x0600783a
- adds r0, r2, r1
- movs r1, 0xA
- strh r1, [r0]
- lsls r0, r4, 16
- lsrs r3, r0, 16
- cmp r3, 0xC
- bls _08092CC2
- ldr r1, _08092D38 @ =0x06007b62
- ldr r2, _08092D3C @ =0x0000040b
- adds r0, r2, 0
- strh r0, [r1]
- movs r1, 0x12
- ldr r3, _08092D40 @ =0x06007b40
- movs r2, 0xD
-_08092D04:
- lsls r0, r1, 1
- adds r0, r3
- strh r2, [r0]
- adds r0, r1, 0x1
- lsls r0, 16
- lsrs r1, r0, 16
- cmp r1, 0x1C
- bls _08092D04
- ldr r1, _08092D44 @ =0x06007b7a
- movs r0, 0xB
- strh r0, [r1]
- b _08092D6E
- .align 2, 0
-_08092D1C: .4byte 0x06007822
-_08092D20: .4byte 0x00000c0b
-_08092D24: .4byte 0x06007800
-_08092D28: .4byte 0x0000080d
-_08092D2C: .4byte 0x0600783a
-_08092D30: .4byte 0x0000080b
-_08092D34: .4byte 0x0000040a
-_08092D38: .4byte 0x06007b62
-_08092D3C: .4byte 0x0000040b
-_08092D40: .4byte 0x06007b40
-_08092D44: .4byte 0x06007b7a
-_08092D48:
- movs r3, 0
- ldr r6, _08092D74 @ =0x06007800
- movs r5, 0x4F
-_08092D4E:
- movs r1, 0x11
- adds r4, r3, 0x1
- lsls r2, r3, 6
-_08092D54:
- lsls r0, r1, 1
- adds r0, r2, r0
- adds r0, r6
- strh r5, [r0]
- adds r0, r1, 0x1
- lsls r0, 16
- lsrs r1, r0, 16
- cmp r1, 0x1D
- bls _08092D54
- lsls r0, r4, 16
- lsrs r3, r0, 16
- cmp r3, 0xD
- bls _08092D4E
-_08092D6E:
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08092D74: .4byte 0x06007800
- thumb_func_end sub_8092C8C
-
- thumb_func_start sub_8092D78
-sub_8092D78: @ 8092D78
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- lsls r0, 24
- lsrs r0, 24
- ldr r4, _08092DBC @ =gUnknown_083B5A7C
- ldr r3, _08092DC0 @ =gTasks
- lsls r2, r0, 2
- adds r2, r0
- lsls r2, 3
- adds r0, r2, r3
- movs r5, 0xA
- ldrsh r1, [r0, r5]
- lsls r1, 3
- adds r1, r4
- ldr r6, [r1]
- adds r3, 0x8
- adds r2, r3
- ldrb r0, [r1, 0x4]
- lsls r0, 1
- adds r0, r2
- mov r8, r0
- ldrb r0, [r1, 0x5]
- lsls r0, 1
- adds r7, r2, r0
- movs r0, 0x12
- movs r1, 0x1
- movs r2, 0x1C
- movs r3, 0xC
- bl MenuZeroFillWindowRect
- movs r5, 0
- ldrh r4, [r7]
- b _08092DE8
- .align 2, 0
-_08092DBC: .4byte gUnknown_083B5A7C
-_08092DC0: .4byte gTasks
-_08092DC4:
- lsls r0, r4, 3
- adds r0, r6
- ldr r0, [r0, 0x4]
- lsls r2, r5, 1
- adds r2, 0x1
- lsls r2, 24
- lsrs r2, 24
- movs r1, 0x12
- bl MenuPrint
- adds r0, r5, 0x1
- lsls r0, 16
- lsrs r5, r0, 16
- adds r0, r4, 0x1
- lsls r0, 16
- lsrs r4, r0, 16
- cmp r5, 0x5
- bhi _08092DF2
-_08092DE8:
- lsls r0, r4, 3
- adds r0, r6
- ldr r0, [r0, 0x4]
- cmp r0, 0
- bne _08092DC4
-_08092DF2:
- mov r1, r8
- ldrh r0, [r1]
- ldrh r1, [r7]
- adds r0, r1
- lsls r0, 3
- adds r0, r6
- ldr r0, [r0]
- bl sub_8091E20
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8092D78
-
- thumb_func_start sub_8092E10
-sub_8092E10: @ 8092E10
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- lsls r1, 24
- lsrs r3, r1, 24
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- ldr r0, _08092E50 @ =gTasks + 0x8
- adds r1, r0
- ldr r2, _08092E54 @ =gUnknown_083B5A7C
- lsls r0, r3, 3
- adds r0, r2
- ldrb r2, [r0, 0x4]
- lsls r2, 1
- adds r2, r1, r2
- ldrb r0, [r0, 0x5]
- lsls r0, 1
- adds r1, r0
- ldrh r0, [r1]
- ldrh r2, [r2]
- adds r0, r2
- lsls r0, 16
- lsrs r2, r0, 16
- cmp r3, 0x5
- bhi _08092E74
- lsls r0, r3, 2
- ldr r1, _08092E58 @ =_08092E5C
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08092E50: .4byte gTasks + 0x8
-_08092E54: .4byte gUnknown_083B5A7C
-_08092E58: .4byte _08092E5C
- .align 2, 0
-_08092E5C:
- .4byte _08092E88
- .4byte _08092E92
- .4byte _08092EA2
- .4byte _08092EA2
- .4byte _08092E80
- .4byte _08092E78
-_08092E74:
- movs r0, 0
- b _08092EA8
-_08092E78:
- ldr r0, _08092E7C @ =gUnknown_083B5A60
- b _08092EA4
- .align 2, 0
-_08092E7C: .4byte gUnknown_083B5A60
-_08092E80:
- ldr r0, _08092E84 @ =gUnknown_083B5A62
- b _08092EA4
- .align 2, 0
-_08092E84: .4byte gUnknown_083B5A62
-_08092E88:
- cmp r2, 0
- beq _08092E96
- lsls r0, r2, 24
- lsrs r0, 24
- b _08092EA8
-_08092E92:
- cmp r2, 0
- bne _08092E9A
-_08092E96:
- movs r0, 0xFF
- b _08092EA8
-_08092E9A:
- subs r0, r2, 0x1
- lsls r0, 24
- lsrs r0, 24
- b _08092EA8
-_08092EA2:
- ldr r0, _08092EAC @ =gUnknown_083B5A68
-_08092EA4:
- adds r0, r2, r0
- ldrb r0, [r0]
-_08092EA8:
- pop {r1}
- bx r1
- .align 2, 0
-_08092EAC: .4byte gUnknown_083B5A68
- thumb_func_end sub_8092E10
-
- thumb_func_start sub_8092EB0
-sub_8092EB0: @ 8092EB0
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- ldr r1, _08092ED0 @ =gPokedexView
- ldr r0, [r1]
- ldr r2, _08092ED4 @ =0x00000614
- adds r0, r2
- ldrh r0, [r0]
- adds r5, r1, 0
- cmp r0, 0
- beq _08092ECA
- cmp r0, 0x1
- beq _08092ED8
-_08092ECA:
- movs r3, 0
- b _08092EDA
- .align 2, 0
-_08092ED0: .4byte gPokedexView
-_08092ED4: .4byte 0x00000614
-_08092ED8:
- movs r3, 0x1
-_08092EDA:
- ldr r1, _08092F00 @ =gTasks
- lsls r2, r4, 2
- adds r0, r2, r4
- lsls r0, 3
- adds r0, r1
- strh r3, [r0, 0xC]
- ldr r0, [r5]
- movs r3, 0xC3
- lsls r3, 3
- adds r0, r3
- ldrh r0, [r0]
- adds r5, r1, 0
- cmp r0, 0x5
- bhi _08092F20
- lsls r0, 2
- ldr r1, _08092F04 @ =_08092F08
- adds r0, r1
- ldr r0, [r0]
- mov pc, r0
- .align 2, 0
-_08092F00: .4byte gTasks
-_08092F04: .4byte _08092F08
- .align 2, 0
-_08092F08:
- .4byte _08092F20
- .4byte _08092F24
- .4byte _08092F28
- .4byte _08092F2C
- .4byte _08092F30
- .4byte _08092F34
-_08092F20:
- movs r3, 0
- b _08092F36
-_08092F24:
- movs r3, 0x1
- b _08092F36
-_08092F28:
- movs r3, 0x2
- b _08092F36
-_08092F2C:
- movs r3, 0x3
- b _08092F36
-_08092F30:
- movs r3, 0x4
- b _08092F36
-_08092F34:
- movs r3, 0x5
-_08092F36:
- adds r0, r2, r4
- lsls r0, 3
- adds r0, r5
- strh r3, [r0, 0x10]
- pop {r4,r5}
- pop {r0}
- bx r0
- thumb_func_end sub_8092EB0
-
- thumb_func_start sub_8092F44
-sub_8092F44: @ 8092F44
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r3, _08092F7C @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r0, r1, r3
- ldrb r2, [r0, 0xA]
- adds r3, 0x8
- adds r1, r3
- ldr r0, _08092F80 @ =gUnknown_083B5A7C
- lsls r2, 3
- adds r2, r0
- ldrb r0, [r2, 0x5]
- lsls r0, 1
- adds r1, r0
- ldrh r0, [r2, 0x6]
- subs r0, 0x1
- lsls r0, 16
- lsrs r0, 16
- cmp r0, 0x5
- bls _08092F84
- ldrh r0, [r1]
- cmp r0, 0
- beq _08092F84
- movs r0, 0
- b _08092F86
- .align 2, 0
-_08092F7C: .4byte gTasks
-_08092F80: .4byte gUnknown_083B5A7C
-_08092F84:
- movs r0, 0x1
-_08092F86:
- pop {r1}
- bx r1
- thumb_func_end sub_8092F44
-
- thumb_func_start sub_8092F8C
-sub_8092F8C: @ 8092F8C
- push {lr}
- lsls r0, 24
- lsrs r0, 24
- ldr r3, _08092FC8 @ =gTasks
- lsls r1, r0, 2
- adds r1, r0
- lsls r1, 3
- adds r0, r1, r3
- ldrb r2, [r0, 0xA]
- adds r3, 0x8
- adds r1, r3
- ldr r0, _08092FCC @ =gUnknown_083B5A7C
- lsls r2, 3
- adds r2, r0
- ldrb r0, [r2, 0x5]
- lsls r0, 1
- adds r1, r0
- ldrh r0, [r2, 0x6]
- subs r0, 0x1
- lsls r0, 16
- lsrs r0, 16
- cmp r0, 0x5
- bls _08092FD0
- ldrh r1, [r1]
- subs r0, 0x5
- cmp r1, r0
- bge _08092FD0
- movs r0, 0
- b _08092FD2
- .align 2, 0
-_08092FC8: .4byte gTasks
-_08092FCC: .4byte gUnknown_083B5A7C
-_08092FD0:
- movs r0, 0x1
-_08092FD2:
- pop {r1}
- bx r1
- thumb_func_end sub_8092F8C
-
- thumb_func_start sub_8092FD8
-sub_8092FD8: @ 8092FD8
- push {r4,lr}
- adds r4, r0, 0
- ldr r2, _08093018 @ =gTasks
- movs r0, 0x2E
- ldrsh r1, [r4, r0]
- lsls r0, r1, 2
- adds r0, r1
- lsls r0, 3
- adds r0, r2
- ldr r1, [r0]
- ldr r0, _0809301C @ =sub_8092644
- cmp r1, r0
- bne _08093078
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- cmp r0, 0
- beq _08093020
- ldrh r0, [r4, 0x2E]
- lsls r0, 24
- lsrs r0, 24
- bl sub_8092F8C
- lsls r0, 24
- cmp r0, 0
- beq _0809303C
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r0, [r2]
- movs r1, 0x4
- orrs r0, r1
- b _08093048
- .align 2, 0
-_08093018: .4byte gTasks
-_0809301C: .4byte sub_8092644
-_08093020:
- ldrh r0, [r4, 0x2E]
- lsls r0, 24
- lsrs r0, 24
- bl sub_8092F44
- lsls r0, 24
- cmp r0, 0
- beq _0809303C
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r0, [r2]
- movs r1, 0x4
- orrs r0, r1
- b _08093048
-_0809303C:
- adds r2, r4, 0
- adds r2, 0x3E
- ldrb r1, [r2]
- movs r0, 0x5
- negs r0, r0
- ands r0, r1
-_08093048:
- strb r0, [r2]
- ldrh r2, [r4, 0x32]
- movs r1, 0x30
- ldrsh r0, [r4, r1]
- lsls r0, 7
- adds r0, r2, r0
- lsls r0, 24
- ldr r1, _08093074 @ =gSineTable
- lsrs r0, 23
- adds r0, r1
- movs r1, 0
- ldrsh r0, [r0, r1]
- cmp r0, 0
- bge _08093066
- adds r0, 0x7F
-_08093066:
- asrs r0, 7
- strh r0, [r4, 0x26]
- adds r0, r2, 0
- adds r0, 0x8
- strh r0, [r4, 0x32]
- b _08093084
- .align 2, 0
-_08093074: .4byte gSineTable
-_08093078:
- adds r0, r4, 0
- adds r0, 0x3E
- ldrb r1, [r0]
- movs r2, 0x4
- orrs r1, r2
- strb r1, [r0]
-_08093084:
- pop {r4}
- pop {r0}
- bx r0
- thumb_func_end sub_8092FD8
-
- thumb_func_start sub_809308C
-sub_809308C: @ 809308C
- push {r4-r6,lr}
- mov r6, r9
- mov r5, r8
- push {r5,r6}
- adds r5, r0, 0
- lsls r5, 24
- lsrs r5, 24
- ldr r6, _08093104 @ =gSpriteTemplate_83A053C
- adds r0, r6, 0
- movs r1, 0xB8
- movs r2, 0x4
- movs r3, 0
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- ldr r4, _08093108 @ =gSprites
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r0, r1, r4
- movs r2, 0
- strh r5, [r0, 0x2E]
- strh r2, [r0, 0x30]
- movs r0, 0x1C
- adds r0, r4
- mov r9, r0
- add r1, r9
- ldr r0, _0809310C @ =sub_8092FD8
- mov r8, r0
- str r0, [r1]
- adds r0, r6, 0
- movs r1, 0xB8
- movs r2, 0x6C
- movs r3, 0
- bl CreateSprite
- lsls r0, 24
- lsrs r0, 24
- lsls r1, r0, 4
- adds r1, r0
- lsls r1, 2
- adds r4, r1, r4
- strh r5, [r4, 0x2E]
- movs r0, 0x1
- strh r0, [r4, 0x30]
- adds r4, 0x3F
- ldrb r0, [r4]
- movs r2, 0x2
- orrs r0, r2
- strb r0, [r4]
- add r1, r9
- mov r0, r8
- str r0, [r1]
- pop {r3,r4}
- mov r8, r3
- mov r9, r4
- pop {r4-r6}
- pop {r0}
- bx r0
- .align 2, 0
-_08093104: .4byte gSpriteTemplate_83A053C
-_08093108: .4byte gSprites
-_0809310C: .4byte sub_8092FD8
- thumb_func_end sub_809308C
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/pokemon_menu.s b/asm/pokemon_menu.s
index 57bcd4904..3a1552f70 100644
--- a/asm/pokemon_menu.s
+++ b/asm/pokemon_menu.s
@@ -718,7 +718,7 @@ PokemonMenu_Switch: @ 808A02C
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r0, _0808A054 @ =0x02001000
ldr r1, _0808A058 @ =sub_806CD5C
str r1, [r0, 0xC]
@@ -849,7 +849,7 @@ PokemonMenu_Item: @ 808A140
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r1, _0808A174 @ =gUnknown_0202FFA8
movs r0, 0
strb r0, [r1]
@@ -1497,7 +1497,7 @@ PokemonMenu_TakeItem: @ 808A688
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x13
movs r1, 0
movs r2, 0x1D
@@ -1520,7 +1520,7 @@ PokemonMenu_TakeMail: @ 808A6B8
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x13
movs r1, 0
movs r2, 0x1D
@@ -1543,7 +1543,7 @@ PokemonMenu_Mail: @ 808A6E8
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r1, _0808A728 @ =gUnknown_0202FFA8
movs r0, 0
strb r0, [r1]
@@ -1812,7 +1812,7 @@ PokemonMenu_Cancel: @ 808A918
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x5
bl PlaySE
adds r0, r4, 0
@@ -1828,7 +1828,7 @@ PokemonMenu_CancelSubmenu: @ 808A938
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0x5
bl PlaySE
movs r0, 0x13
@@ -1867,7 +1867,7 @@ PokemonMenu_FieldMove: @ 808A984
lsls r6, r0, 3
ldr r7, _0808A9D0 @ =gTasks + 0x8
adds r4, r6, r7
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r1, _0808A9D4 @ =gUnknown_0202FFAA
ldr r0, _0808A9D8 @ =gUnknown_0202FFA8
ldrb r0, [r0]
@@ -2215,7 +2215,7 @@ SetUpFieldMove_Surf: @ 808AC48
lsrs r0, 24
cmp r0, 0x1
bne _0808AC84
- ldr r1, _0808AC74 @ =gUnknown_0300485C
+ ldr r1, _0808AC74 @ =gFieldCallback
ldr r0, _0808AC78 @ =sub_808AB90
str r0, [r1]
ldr r1, _0808AC7C @ =gUnknown_03005CE4
@@ -2224,7 +2224,7 @@ SetUpFieldMove_Surf: @ 808AC48
movs r0, 0x1
b _0808AC86
.align 2, 0
-_0808AC74: .4byte gUnknown_0300485C
+_0808AC74: .4byte gFieldCallback
_0808AC78: .4byte sub_808AB90
_0808AC7C: .4byte gUnknown_03005CE4
_0808AC80: .4byte sub_808AC2C
@@ -2258,14 +2258,14 @@ SetUpFieldMove_Fly: @ 808ACA8
lsls r0, 24
cmp r0, 0
beq _0808ACD0
- ldr r1, _0808ACC0 @ =gUnknown_0300485C
+ ldr r1, _0808ACC0 @ =gFieldCallback
ldr r0, _0808ACC4 @ =sub_808AB90
str r0, [r1]
ldr r1, _0808ACC8 @ =gUnknown_03005CE4
ldr r0, _0808ACCC @ =DoBrailleFlyEffect
b _0808ACF2
.align 2, 0
-_0808ACC0: .4byte gUnknown_0300485C
+_0808ACC0: .4byte gFieldCallback
_0808ACC4: .4byte sub_808AB90
_0808ACC8: .4byte gUnknown_03005CE4
_0808ACCC: .4byte DoBrailleFlyEffect
@@ -2282,7 +2282,7 @@ _0808ACD0:
.align 2, 0
_0808ACE4: .4byte gMapHeader
_0808ACE8:
- ldr r1, _0808ACFC @ =gUnknown_0300485C
+ ldr r1, _0808ACFC @ =gFieldCallback
ldr r0, _0808AD00 @ =sub_808AB90
str r0, [r1]
ldr r1, _0808AD04 @ =gUnknown_03005CE4
@@ -2294,7 +2294,7 @@ _0808ACF6:
pop {r1}
bx r1
.align 2, 0
-_0808ACFC: .4byte gUnknown_0300485C
+_0808ACFC: .4byte gFieldCallback
_0808AD00: .4byte sub_808AB90
_0808AD04: .4byte gUnknown_03005CE4
_0808AD08: .4byte sub_808AC8C
@@ -2411,7 +2411,7 @@ SetUpFieldMove_Dive: @ 808ADC8
.align 2, 0
_0808ADE0: .4byte gUnknown_0202FF84
_0808ADE4:
- ldr r1, _0808ADF8 @ =gUnknown_0300485C
+ ldr r1, _0808ADF8 @ =gFieldCallback
ldr r0, _0808ADFC @ =sub_808AB90
str r0, [r1]
ldr r1, _0808AE00 @ =gUnknown_03005CE4
@@ -2422,7 +2422,7 @@ _0808ADF2:
pop {r1}
bx r1
.align 2, 0
-_0808ADF8: .4byte gUnknown_0300485C
+_0808ADF8: .4byte gFieldCallback
_0808ADFC: .4byte sub_808AB90
_0808AE00: .4byte gUnknown_03005CE4
_0808AE04: .4byte sub_808ADAC
@@ -2471,7 +2471,7 @@ SetUpFieldMove_Waterfall: @ 808AE24
lsrs r0, 24
cmp r0, 0x1
bne _0808AE80
- ldr r1, _0808AE70 @ =gUnknown_0300485C
+ ldr r1, _0808AE70 @ =gFieldCallback
ldr r0, _0808AE74 @ =sub_808AB90
str r0, [r1]
ldr r1, _0808AE78 @ =gUnknown_03005CE4
@@ -2480,7 +2480,7 @@ SetUpFieldMove_Waterfall: @ 808AE24
movs r0, 0x1
b _0808AE82
.align 2, 0
-_0808AE70: .4byte gUnknown_0300485C
+_0808AE70: .4byte gFieldCallback
_0808AE74: .4byte sub_808AB90
_0808AE78: .4byte gUnknown_03005CE4
_0808AE7C: .4byte sub_808AE08
@@ -2997,7 +2997,7 @@ sub_808B288: @ 808B288
ands r0, r1
cmp r0, 0
bne _0808B2A6
- ldr r0, _0808B2B0 @ =sub_813B6F8
+ ldr r0, _0808B2B0 @ =Mailbox_ReturnToMailListAfterDeposit
bl SetMainCallback2
adds r0, r4, 0
bl DestroyTask
@@ -3007,7 +3007,7 @@ _0808B2A6:
bx r0
.align 2, 0
_0808B2AC: .4byte gPaletteFade
-_0808B2B0: .4byte sub_813B6F8
+_0808B2B0: .4byte Mailbox_ReturnToMailListAfterDeposit
thumb_func_end sub_808B288
thumb_func_start sub_808B2B4
diff --git a/asm/pokemon_storage_system.s b/asm/pokemon_storage_system.s
index 176a42124..db16c2788 100644
--- a/asm/pokemon_storage_system.s
+++ b/asm/pokemon_storage_system.s
@@ -931,7 +931,7 @@ _08095FA2:
_08095FC0: .4byte gMain
_08095FC4: .4byte gUnknown_083B600C
_08095FC8:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0xD
@@ -1171,7 +1171,7 @@ sub_80961A8: @ 80961A8
ldr r0, [r0]
ldrb r0, [r0, 0x5]
strb r0, [r1]
- ldr r1, _080961CC @ =gUnknown_0300485C
+ ldr r1, _080961CC @ =gFieldCallback
ldr r0, _080961D0 @ =sub_8096130
str r0, [r1]
ldr r0, _080961D4 @ =c2_exit_to_overworld_2_switch
@@ -1181,7 +1181,7 @@ sub_80961A8: @ 80961A8
.align 2, 0
_080961C4: .4byte gUnknown_02038474
_080961C8: .4byte gUnknown_083B6DB4
-_080961CC: .4byte gUnknown_0300485C
+_080961CC: .4byte gFieldCallback
_080961D0: .4byte sub_8096130
_080961D4: .4byte c2_exit_to_overworld_2_switch
thumb_func_end sub_80961A8
@@ -5915,7 +5915,7 @@ sub_8098A38: @ 8098A38
thumb_func_start sub_8098A5C
sub_8098A5C: @ 8098A5C
push {lr}
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0xA
movs r1, 0x10
movs r2, 0x1D
@@ -14831,7 +14831,7 @@ _0809CF8E:
negs r0, r0
cmp r5, r0
beq _0809CFB2
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r0, _0809CFD0 @ =gUnknown_083B6DB4
ldr r1, [r0]
ldr r2, _0809CFD4 @ =0x000011ba
diff --git a/asm/rom_8094928.s b/asm/rom_8094928.s
deleted file mode 100644
index a9d0e3dcc..000000000
--- a/asm/rom_8094928.s
+++ /dev/null
@@ -1,411 +0,0 @@
- .include "constants/gba_constants.inc"
- .include "constants/species_constants.inc"
- .include "asm/macros.inc"
-
- .syntax unified
-
- .text
-
- thumb_func_start sub_8094B6C
-sub_8094B6C: @ 8094B6C
- push {r4-r7,lr}
- sub sp, 0x8
- lsls r0, 24
- lsrs r4, r0, 24
- lsls r1, 24
- lsrs r5, r1, 24
- lsls r2, 24
- lsrs r6, r2, 24
- movs r7, 0
- bl IsLinkDoubleBattle
- lsls r0, 24
- cmp r0, 0
- beq _08094C16
- lsls r0, r4, 1
- adds r0, r4
- ldr r1, _08094BCC @ =0x0201606c
- adds r4, r0, r1
- movs r2, 0
- add r6, sp
- mov r12, r6
- movs r6, 0xF
- mov r3, sp
-_08094B9A:
- adds r1, r4, r2
- ldrb r0, [r1]
- lsrs r0, 4
- strb r0, [r3]
- adds r3, 0x1
- ldrb r1, [r1]
- adds r0, r6, 0
- ands r0, r1
- strb r0, [r3]
- adds r3, 0x1
- adds r2, 0x1
- cmp r2, 0x2
- ble _08094B9A
- mov r0, r12
- ldrb r3, [r0]
- movs r2, 0
- mov r0, sp
- ldrb r0, [r0]
- cmp r0, r5
- bne _08094BD0
- mov r0, sp
- ldrb r7, [r0]
- strb r3, [r0]
- b _08094BE4
- .align 2, 0
-_08094BCC: .4byte 0x0201606c
-_08094BD0:
- adds r2, 0x1
- cmp r2, 0x5
- bgt _08094BE4
- mov r0, sp
- adds r1, r0, r2
- ldrb r0, [r1]
- cmp r0, r5
- bne _08094BD0
- adds r7, r0, 0
- strb r3, [r1]
-_08094BE4:
- cmp r2, 0x6
- beq _08094C16
- mov r0, r12
- strb r7, [r0]
- mov r0, sp
- ldrb r0, [r0]
- lsls r0, 4
- mov r1, sp
- ldrb r1, [r1, 0x1]
- orrs r0, r1
- strb r0, [r4]
- mov r0, sp
- ldrb r0, [r0, 0x2]
- lsls r0, 4
- mov r1, sp
- ldrb r1, [r1, 0x3]
- orrs r0, r1
- strb r0, [r4, 0x1]
- mov r0, sp
- ldrb r0, [r0, 0x4]
- lsls r0, 4
- mov r1, sp
- ldrb r1, [r1, 0x5]
- orrs r0, r1
- strb r0, [r4, 0x2]
-_08094C16:
- add sp, 0x8
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end sub_8094B6C
-
- thumb_func_start sub_8094C20
-sub_8094C20: @ 8094C20
- push {lr}
- lsls r0, 24
- lsrs r2, r0, 24
- movs r1, 0x1
- ands r1, r2
- lsrs r2, r0, 25
- cmp r1, 0
- beq _08094C40
- ldr r0, _08094C3C @ =gUnknown_02038470
- adds r0, r2, r0
- ldrb r0, [r0]
- movs r1, 0xF
- ands r1, r0
- b _08094C48
- .align 2, 0
-_08094C3C: .4byte gUnknown_02038470
-_08094C40:
- ldr r0, _08094C50 @ =gUnknown_02038470
- adds r0, r2, r0
- ldrb r0, [r0]
- lsrs r1, r0, 4
-_08094C48:
- adds r0, r1, 0
- pop {r1}
- bx r1
- .align 2, 0
-_08094C50: .4byte gUnknown_02038470
- thumb_func_end sub_8094C20
-
- thumb_func_start sub_8094C54
-sub_8094C54: @ 8094C54
- push {r4,lr}
- lsls r0, 24
- lsrs r3, r0, 24
- lsls r1, 24
- lsrs r4, r1, 24
- movs r1, 0x1
- ands r1, r3
- lsrs r3, r0, 25
- cmp r1, 0
- beq _08094C7C
- ldr r0, _08094C78 @ =gUnknown_02038470
- adds r0, r3, r0
- ldrb r2, [r0]
- movs r1, 0xF0
- ands r1, r2
- orrs r1, r4
- strb r1, [r0]
- b _08094C8C
- .align 2, 0
-_08094C78: .4byte gUnknown_02038470
-_08094C7C:
- ldr r2, _08094C94 @ =gUnknown_02038470
- adds r2, r3, r2
- ldrb r1, [r2]
- movs r0, 0xF
- ands r0, r1
- lsls r1, r4, 4
- orrs r0, r1
- strb r0, [r2]
-_08094C8C:
- pop {r4}
- pop {r0}
- bx r0
- .align 2, 0
-_08094C94: .4byte gUnknown_02038470
- thumb_func_end sub_8094C54
-
- thumb_func_start sub_8094C98
-sub_8094C98: @ 8094C98
- push {r4-r6,lr}
- adds r5, r0, 0
- adds r6, r1, 0
- lsls r5, 24
- lsrs r5, 24
- lsls r6, 24
- lsrs r6, 24
- adds r0, r5, 0
- bl sub_8094C20
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- adds r0, r6, 0
- bl sub_8094C20
- adds r1, r0, 0
- lsls r1, 24
- lsrs r1, 24
- adds r0, r5, 0
- bl sub_8094C54
- adds r0, r6, 0
- adds r1, r4, 0
- bl sub_8094C54
- pop {r4-r6}
- pop {r0}
- bx r0
- thumb_func_end sub_8094C98
-
- thumb_func_start pokemon_order_func
-pokemon_order_func: @ 8094CD4
- push {r4,r5,lr}
- lsls r0, 24
- lsrs r4, r0, 24
- movs r3, 0
- movs r2, 0
- ldr r5, _08094CFC @ =gUnknown_02038470
-_08094CE0:
- adds r0, r3, r5
- ldrb r1, [r0]
- lsrs r0, r1, 4
- cmp r0, r4
- beq _08094CF8
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r2, r0, 24
- movs r0, 0xF
- ands r0, r1
- cmp r0, r4
- bne _08094D00
-_08094CF8:
- adds r0, r2, 0
- b _08094D12
- .align 2, 0
-_08094CFC: .4byte gUnknown_02038470
-_08094D00:
- adds r0, r2, 0x1
- lsls r0, 24
- lsrs r2, r0, 24
- adds r0, r3, 0x1
- lsls r0, 24
- lsrs r3, r0, 24
- cmp r3, 0x2
- bls _08094CE0
- movs r0, 0
-_08094D12:
- pop {r4,r5}
- pop {r1}
- bx r1
- thumb_func_end pokemon_order_func
-
- thumb_func_start pokemon_change_order
-pokemon_change_order: @ 8094D18
- push {r4,r5,lr}
- ldr r0, _08094D58 @ =0x0201b000
- ldr r1, _08094D5C @ =gPlayerParty
- movs r2, 0x96
- lsls r2, 2
- bl memcpy
- movs r4, 0
- movs r5, 0x64
-_08094D2A:
- adds r0, r4, 0
- bl pokemon_order_func
- lsls r0, 24
- lsrs r0, 24
- muls r0, r5
- ldr r1, _08094D5C @ =gPlayerParty
- adds r0, r1
- adds r1, r4, 0
- muls r1, r5
- ldr r2, _08094D58 @ =0x0201b000
- adds r1, r2
- movs r2, 0x64
- bl memcpy
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x5
- bls _08094D2A
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08094D58: .4byte 0x0201b000
-_08094D5C: .4byte gPlayerParty
- thumb_func_end pokemon_change_order
-
- thumb_func_start sub_8094D60
-sub_8094D60: @ 8094D60
- push {r4,r5,lr}
- ldr r4, _08094DA8 @ =0xfffffda8
- add sp, r4
- ldr r1, _08094DAC @ =gPlayerParty
- movs r2, 0x96
- lsls r2, 2
- mov r0, sp
- bl memcpy
- movs r4, 0
- movs r5, 0x64
-_08094D76:
- adds r0, r4, 0
- bl sub_8094C20
- lsls r0, 24
- lsrs r0, 24
- muls r0, r5
- ldr r1, _08094DAC @ =gPlayerParty
- adds r0, r1
- adds r1, r4, 0
- muls r1, r5
- add r1, sp
- movs r2, 0x64
- bl memcpy
- adds r0, r4, 0x1
- lsls r0, 24
- lsrs r4, r0, 24
- cmp r4, 0x5
- bls _08094D76
- movs r3, 0x96
- lsls r3, 2
- add sp, r3
- pop {r4,r5}
- pop {r0}
- bx r0
- .align 2, 0
-_08094DA8: .4byte 0xfffffda8
-_08094DAC: .4byte gPlayerParty
- thumb_func_end sub_8094D60
-
- thumb_func_start unref_sub_8094DB0
-unref_sub_8094DB0: @ 8094DB0
- push {r4-r7,lr}
- mov r7, r8
- push {r7}
- movs r6, 0x1
- movs r7, 0x64
- ldr r0, _08094E08 @ =gPlayerParty
- mov r8, r0
-_08094DBE:
- adds r0, r6, 0
- bl sub_8094C20
- lsls r0, 24
- lsrs r0, 24
- muls r0, r7
- mov r1, r8
- adds r5, r0, r1
- adds r0, r5, 0
- movs r1, 0xB
- bl GetMonData
- cmp r0, 0
- beq _08094E0C
- adds r0, r5, 0
- movs r1, 0x39
- bl GetMonData
- cmp r0, 0
- beq _08094E0C
- movs r0, 0
- bl sub_8094C20
- adds r4, r0, 0
- lsls r4, 24
- lsrs r4, 24
- movs r0, 0
- adds r1, r6, 0
- bl sub_8094C98
- adds r0, r4, 0
- muls r0, r7
- add r0, r8
- adds r1, r5, 0
- bl sub_806E6F0
- b _08094E16
- .align 2, 0
-_08094E08: .4byte gPlayerParty
-_08094E0C:
- adds r0, r6, 0x1
- lsls r0, 24
- lsrs r6, r0, 24
- cmp r6, 0x5
- bls _08094DBE
-_08094E16:
- pop {r3}
- mov r8, r3
- pop {r4-r7}
- pop {r0}
- bx r0
- thumb_func_end unref_sub_8094DB0
-
- thumb_func_start sub_8094E20
-sub_8094E20: @ 8094E20
- push {lr}
- ldr r3, _08094E44 @ =gPaletteFade
- ldrb r1, [r3, 0x8]
- movs r2, 0x80
- orrs r1, r2
- strb r1, [r3, 0x8]
- ldr r1, _08094E48 @ =gUnknown_02038473
- strb r0, [r1]
- bl nullsub_14
- bl pokemon_change_order
- movs r0, 0x1
- movs r1, 0xFF
- bl OpenPartyMenu
- pop {r0}
- bx r0
- .align 2, 0
-_08094E44: .4byte gPaletteFade
-_08094E48: .4byte gUnknown_02038473
- thumb_func_end sub_8094E20
-
- thumb_func_start sub_8094E4C
-sub_8094E4C: @ 8094E4C
- push {lr}
- movs r0, 0x3
- bl sub_8094E20
- pop {r0}
- bx r0
- thumb_func_end sub_8094E4C
-
- .align 2, 0 @ Don't pad with nop.
diff --git a/asm/roulette.s b/asm/roulette.s
index 6382ecf0b..fcfedbd80 100644
--- a/asm/roulette.s
+++ b/asm/roulette.s
@@ -733,7 +733,7 @@ sub_8115734: @ 8115734
bl MenuPrint
ldr r1, _08115778 @ =gUnknown_083F8EBC
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
pop {r4}
pop {r0}
bx r0
@@ -3245,7 +3245,7 @@ sub_8116B40: @ 8116B40
strh r4, [r0]
adds r0, 0x2
strh r4, [r0]
- ldr r1, _08116BB4 @ =gUnknown_0300485C
+ ldr r1, _08116BB4 @ =gFieldCallback
ldr r0, _08116BB8 @ =sub_8080990
str r0, [r1]
ldr r0, _08116BBC @ =c2_exit_to_overworld_2_switch
@@ -3261,7 +3261,7 @@ _08116BA4: .4byte 0x02019000
_08116BA8: .4byte gSpriteCoordOffsetX
_08116BAC: .4byte gSpriteCoordOffsetY
_08116BB0: .4byte REG_BLDCNT
-_08116BB4: .4byte gUnknown_0300485C
+_08116BB4: .4byte gFieldCallback
_08116BB8: .4byte sub_8080990
_08116BBC: .4byte c2_exit_to_overworld_2_switch
thumb_func_end sub_8116B40
@@ -4483,7 +4483,7 @@ sub_81174F8: @ 81174F8
bl sub_814AAF8
ldr r1, _08117524 @ =gUnknown_083F8EB4
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
pop {r4}
pop {r0}
bx r0
diff --git a/asm/secret_base.s b/asm/secret_base.s
index 8f2df8396..9fd741aa0 100644
--- a/asm/secret_base.s
+++ b/asm/secret_base.s
@@ -584,7 +584,7 @@ _080BC8C2:
ldrsh r1, [r4, r2]
cmp r0, r1
bne _080BC8FC
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x1D
@@ -594,7 +594,7 @@ _080BC8C2:
bl sub_80BCC54
b _080BC940
_080BC8FC:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldrb r0, [r4, 0x4]
ldrb r1, [r4, 0x2]
adds r0, r1
@@ -614,7 +614,7 @@ _080BC91C:
beq _080BC940
movs r0, 0x5
bl PlaySE
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x1D
@@ -671,9 +671,9 @@ sub_80BC980: @ 80BC980
lsls r4, 24
lsrs r4, 24
movs r0, 0
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x1
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x1
movs r1, 0
movs r2, 0xC
@@ -799,7 +799,7 @@ sub_80BCA84: @ 80BCA84
bl DestroyVerticalScrollIndicator
movs r0, 0x1
bl DestroyVerticalScrollIndicator
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x1D
@@ -840,7 +840,7 @@ sub_80BCAEC: @ 80BCAEC
bl DisplayYesNoMenu
ldr r1, _080BCB0C @ =gUnknown_083D13E4
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
pop {r4}
pop {r0}
bx r0
@@ -994,9 +994,9 @@ sub_80BCBF8: @ 80BCBF8
movs r3, 0x5
bl MenuZeroFillWindowRect
movs r0, 0
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x1
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
subs r5, 0x8
adds r4, r5
ldr r0, _080BCC50 @ =sub_80BC824
diff --git a/asm/shop.s b/asm/shop.s
index 1d0863469..a341e90a1 100644
--- a/asm/shop.s
+++ b/asm/shop.s
@@ -1222,7 +1222,7 @@ sub_80B3D38: @ 80B3D38
bl sub_80A3FA0
ldr r1, _080B3D78 @ =gUnknown_083CC708
adds r0, r4, 0
- bl sub_80F914C
+ bl DoYesNoFuncWithChoice
add sp, 0x8
pop {r4}
pop {r0}
@@ -1767,9 +1767,9 @@ _080B41B8:
b _080B4350
_080B41CE:
movs r0, 0
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x1
- bl sub_80F996C
+ bl PauseVerticalScrollIndicator
movs r0, 0x1
movs r1, 0x1
bl sub_80F979C
@@ -1777,7 +1777,7 @@ _080B41CE:
adds r0, r1, 0
movs r2, 0x1
bl sub_80B39D0
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0xC
movs r2, 0xD
@@ -1978,9 +1978,9 @@ sub_80B4378: @ 80B4378
bl sub_80B3764
bl sub_80B37EC
movs r0, 0
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
movs r0, 0x1
- bl sub_80F98DC
+ bl StartVerticalScrollIndicators
bl sub_80B32A4
ldr r1, _080B43E8 @ =gTasks
lsls r0, r4, 2
@@ -2006,7 +2006,7 @@ sub_80B43F0: @ 80B43F0
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- ldr r1, _080B4428 @ =gUnknown_0300485C
+ ldr r1, _080B4428 @ =gFieldCallback
ldr r0, _080B442C @ =sub_80B3050
str r0, [r1]
movs r0, 0x1
@@ -2028,7 +2028,7 @@ sub_80B43F0: @ 80B43F0
pop {r0}
bx r0
.align 2, 0
-_080B4428: .4byte gUnknown_0300485C
+_080B4428: .4byte gFieldCallback
_080B442C: .4byte sub_80B3050
_080B4430: .4byte gTasks
_080B4434: .4byte Task_ExitBuyMenu
diff --git a/asm/trade.s b/asm/trade.s
index 756423ee7..e4d45ec73 100644
--- a/asm/trade.s
+++ b/asm/trade.s
@@ -3266,7 +3266,7 @@ _08049800: .4byte gUnknown_03004824
thumb_func_start sub_8049804
sub_8049804: @ 8049804
push {lr}
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
bl sub_804A80C
ldr r3, _08049850 @ =gUnknown_03004824
ldr r0, [r3]
@@ -4315,7 +4315,7 @@ _08049F8E:
lsls r0, 2
adds r0, r7
bl sub_8078A34
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r3, _0804A09C @ =gUnknown_03004824
ldr r0, [r3]
adds r0, 0x4
@@ -5363,7 +5363,7 @@ _0804A89C: .4byte gUnknown_03004824
_0804A8A0: .4byte gUnknown_0820C330
_0804A8A4: .4byte gTradePartyBoxTilemap
_0804A8A8:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
ldr r4, _0804A924 @ =gUnknown_03004824
ldr r0, [r4]
adds r0, 0x4
@@ -7560,10 +7560,10 @@ sub_804BA18: @ 804BA18
lsrs r4, 16
adds r0, r4, 0
movs r1, 0x2
- bl sub_8090D90
+ bl GetNationalPokedexFlag
adds r0, r4, 0
movs r1, 0x3
- bl sub_8090D90
+ bl GetNationalPokedexFlag
_0804BA5A:
pop {r4}
pop {r0}
@@ -12051,7 +12051,7 @@ sub_804E1A0: @ 804E1A0
bne _0804E1C4
ldr r0, _0804E1D0 @ =sub_804B790
bl SetMainCallback2
- ldr r1, _0804E1D4 @ =gUnknown_0300485C
+ ldr r1, _0804E1D4 @ =gFieldCallback
ldr r0, _0804E1D8 @ =sub_8080990
str r0, [r1]
adds r0, r4, 0
@@ -12063,7 +12063,7 @@ _0804E1C4:
.align 2, 0
_0804E1CC: .4byte gPaletteFade
_0804E1D0: .4byte sub_804B790
-_0804E1D4: .4byte gUnknown_0300485C
+_0804E1D4: .4byte gFieldCallback
_0804E1D8: .4byte sub_8080990
thumb_func_end sub_804E1A0
diff --git a/asm/trader.s b/asm/trader.s
index be3627e90..3bda1d8dc 100644
--- a/asm/trader.s
+++ b/asm/trader.s
@@ -290,7 +290,7 @@ _08109B54:
ldr r0, _08109B78 @ =gSpecialVar_0x8004
strh r1, [r0]
_08109B58:
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0x1
movs r2, 0xC
@@ -509,7 +509,7 @@ sub_8109D04: @ 8109D04
push {r4-r6,lr}
lsls r0, 24
lsrs r6, r0, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x1D
@@ -581,7 +581,7 @@ sub_8109DAC: @ 8109DAC
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
- bl sub_8072DEC
+ bl HandleDestroyMenuCursors
movs r0, 0
movs r1, 0
movs r2, 0x1D
diff --git a/data/decoration_inventory.s b/data/decoration_inventory.s
deleted file mode 100644
index a70dedbe5..000000000
--- a/data/decoration_inventory.s
+++ /dev/null
@@ -1,16 +0,0 @@
- .include "asm/macros.inc"
- .include "constants/constants.inc"
-
- .section .rodata
-
-@ pointer to decorations, capacity
- .align 2
-gDecorationInventories:: @ 8402E40
- .4byte gSaveBlock1 + 0x26A0, 10 @ DESK
- .4byte gSaveBlock1 + 0x26AA, 10 @ CHAIR
- .4byte gSaveBlock1 + 0x26B4, 10 @ PLANT
- .4byte gSaveBlock1 + 0x26BE, 30 @ ORNAMENT
- .4byte gSaveBlock1 + 0x26DC, 30 @ MAT
- .4byte gSaveBlock1 + 0x26FA, 10 @ POSTER
- .4byte gSaveBlock1 + 0x2704, 40 @ DOLL
- .4byte gSaveBlock1 + 0x272C, 10 @ CUSHION
diff --git a/data/field_effect.s b/data/field_effect.s
deleted file mode 100644
index 3347bc19c..000000000
--- a/data/field_effect.s
+++ /dev/null
@@ -1,433 +0,0 @@
- .include "asm/macros.inc"
- .include "constants/constants.inc"
-
- .section .rodata
-
- .align 2
-gSpriteImage_839DC14:: @ 839DC14
- .incbin "graphics/birch_speech/birch.4bpp"
-
- .align 2
-gBirchPalette:: @ 839E414
- .incbin "graphics/birch_speech/birch.gbapal"
-
- .align 2
-gSpriteImage_839E434:: @ 839E434
- .incbin "graphics/misc/pokeball_glow.4bpp"
-
- .align 2
-gFieldEffectObjectPalette4: @ 839E454
- .incbin "graphics/field_effect_objects/palettes/04.gbapal"
-
- .align 2
-gSpriteImage_839E474:: @ 839E474
- .incbin "graphics/misc/pokecenter_monitor/0.4bpp"
-
- .align 2
-gSpriteImage_839E534:: @ 839E534
- .incbin "graphics/misc/pokecenter_monitor/1.4bpp"
-
- .align 2
-gSpriteImage_839E5F4:: @ 839E5F4
- .incbin "graphics/misc/big_hof_monitor.4bpp"
-
- .align 2
-gSpriteImage_839E7F4:: @ 839E7F4
- .incbin "graphics/misc/small_hof_monitor.4bpp"
-
- .align 2
-gFieldEffectObjectPalette5: @ 839E8F4
- .incbin "graphics/field_effect_objects/palettes/05.gbapal"
-
-@ Graphics for the lights streaking past your Pokémon when it uses a field move.
-
- .align 2
-gFieldMoveStreaksTiles:: @ 839E914
- .incbin "graphics/misc/field_move_streaks.4bpp"
-
- .align 2
-gFieldMoveStreaksPalette:: @ 839EB14
- .incbin "graphics/misc/field_move_streaks.gbapal"
-
- .align 2
-gFieldMoveStreaksTilemap:: @ 839EB34
- .incbin "graphics/misc/field_move_streaks_map.bin"
-
-@ The following light streaks effect is used when the map is dark (e.g. a cave).
-
- .align 2
-gDarknessFieldMoveStreaksTiles:: @ 839EDB4
- .incbin "graphics/misc/darkness_field_move_streaks.4bpp"
-
- .align 2
-gDarknessFieldMoveStreaksPalette:: @ 839EE34
- .incbin "graphics/misc/darkness_field_move_streaks.gbapal"
-
- .align 2
-gDarknessFieldMoveStreaksTilemap:: @ 839EE54
- .incbin "graphics/misc/darkness_field_move_streaks_map.bin"
-
- .align 2
-gFieldEffectScriptFuncs:: @ 839F0D4
- .4byte FieldEffectCmd_loadtiles
- .4byte FieldEffectCmd_loadfadedpal
- .4byte FieldEffectCmd_loadpal
- .4byte FieldEffectCmd_callnative
- .4byte FieldEffectCmd_end
- .4byte FieldEffectCmd_loadgfx_callnative
- .4byte FieldEffectCmd_loadtiles_callnative
- .4byte FieldEffectCmd_loadfadedpal_callnative
-
- .align 2
-gOamData_839F0F4:: @ 839F0F4
- .2byte 0x0000
- .2byte 0xC000
- .2byte 0x0000
-
- .align 2
-gOamData_839F0FC:: @ 839F0FC
- .2byte 0x0000
- .2byte 0x0000
- .2byte 0x0000
-
- .align 2
-gOamData_839F104:: @ 839F104
- .2byte 0x0000
- .2byte 0x4000
- .2byte 0x0000
-
- .align 2
-gSpriteImageTable_839F10C:: @ 839F10C
- obj_frame_tiles gSpriteImage_839DC14, 0x800
-
- .align 2
-gUnknown_0839F114:: @ 839F114
- obj_pal gBirchPalette, 0x1006
-
- .align 2
-gSpriteAnim_839F11C:: @ 839F11C
- obj_image_anim_frame 0, 1
- obj_image_anim_end
-
- .align 2
-gSpriteAnimTable_839F124:: @ 839F124
- .4byte gSpriteAnim_839F11C
-
- .align 2
-gSpriteTemplate_839F128:: @ 839F128
- spr_template 0xFFFF, 4102, gOamData_839F0F4, gSpriteAnimTable_839F124, gSpriteImageTable_839F10C, gDummySpriteAffineAnimTable, SpriteCallbackDummy
-
- .align 2
-gFieldEffectObjectPaletteInfo4:: @ 839F140
- obj_pal gFieldEffectObjectPalette4, 0x1007
-
- .align 2
-gFieldEffectObjectPaletteInfo5:: @ 839F148
- obj_pal gFieldEffectObjectPalette5, 0x1010
-
- .align 2
-gOamData_839F150:: @ 839F150
- .2byte 0x4000
- .2byte 0x8000
- .2byte 0x0000
-
- .align 2
-gSpriteImageTable_839F158:: @ 839F158
- obj_frame_tiles gSpriteImage_839E434, 0x20
-
- .align 2
-gSpriteImageTable_839F160:: @ 839F160
- obj_frame_tiles gSpriteImage_839E474, 0xc0
- obj_frame_tiles gSpriteImage_839E534, 0xc0
-
- .align 2
-gSpriteImageTable_839F170:: @ 839F170
- obj_frame_tiles gSpriteImage_839E5F4, 0x200
-
- .align 2
-gSpriteImageTable_839F178:: @ 839F178
- obj_frame_tiles gSpriteImage_839E7F4, 0x200
-
- .align 2
-Unknown_39F180:: @ 839F180
- subsprite -12, -8, 2, 0, 16x8
- subsprite 4, -8, 2, 2, 8x8
- subsprite -12, 0, 2, 3, 16x8
- subsprite 4, 0, 2, 5, 8x8
-
- .align 2
-gUnknown_0839F1A0:: @ 839F1A0
- .4byte 4, Unknown_39F180
-
- .align 2
-Unknown_39F1A8:: @ 39F1A8
- subsprite -32, -8, 2, 0, 32x8
- subsprite 0, -8, 2, 4, 32x8
- subsprite -32, 0, 2, 8, 32x8
- subsprite 0, 0, 2, 12, 32x8
-
- .align 2
-gUnknown_0839F1C8:: @ 839F1C8
- .4byte 4, Unknown_39F1A8
-
- .align 2
-gSpriteAnim_839F1D0:: @ 839F1D0
- obj_image_anim_frame 0, 1
- obj_image_anim_jump 0
-
- .align 2
-gSpriteAnim_839F1D8:: @ 839F1D8
- obj_image_anim_frame 0, 16
- obj_image_anim_frame 1, 16
- obj_image_anim_frame 0, 16
- obj_image_anim_frame 1, 16
- obj_image_anim_frame 0, 16
- obj_image_anim_frame 1, 16
- obj_image_anim_frame 0, 16
- obj_image_anim_frame 1, 16
- obj_image_anim_end
-
- .align 2
-gSpriteAnimTable_839F1FC:: @ 839F1FC
- .4byte gSpriteAnim_839F1D0
- .4byte gSpriteAnim_839F1D8
-
- .align 2
-gSpriteAnimTable_839F204:: @ 839F204
- .4byte gSpriteAnim_839F1D0
-
- .align 2
-gSpriteTemplate_839F208:: @ 839F208
- spr_template 0xFFFF, 4103, gOamData_839F0FC, gSpriteAnimTable_839F1FC, gSpriteImageTable_839F158, gDummySpriteAffineAnimTable, SpriteCB_PokeballGlow
-
- .align 2
-gSpriteTemplate_839F220:: @ 839F220
- spr_template 0xFFFF, 4100, gOamData_839F104, gSpriteAnimTable_839F1FC, gSpriteImageTable_839F160, gDummySpriteAffineAnimTable, SpriteCB_PokecenterMonitor
-
- .align 2
-gSpriteTemplate_839F238:: @ 839F238
- spr_template 0xFFFF, 4112, gOamData_839F104, gSpriteAnimTable_839F204, gSpriteImageTable_839F170, gDummySpriteAffineAnimTable, SpriteCB_HallOfFameMonitor
-
- .align 2
-gSpriteTemplate_839F250:: @ 839F250
- spr_template 0xFFFF, 4112, gOamData_839F150, gSpriteAnimTable_839F204, gSpriteImageTable_839F178, gDummySpriteAffineAnimTable, SpriteCB_HallOfFameMonitor
-
- .align 2
-gUnknown_0839F268:: @ 839F268
- .4byte PokecenterHealEffect_0
- .4byte PokecenterHealEffect_1
- .4byte PokecenterHealEffect_2
- .4byte PokecenterHealEffect_3
-
- .align 2
-gUnknown_0839F278:: @ 839F278
- .4byte HallOfFameRecordEffect_0
- .4byte HallOfFameRecordEffect_1
- .4byte HallOfFameRecordEffect_2
- .4byte HallOfFameRecordEffect_3
-
- .align 2
-gUnknown_0839F288:: @ 839F288
- .4byte PokeballGlowEffect_0
- .4byte PokeballGlowEffect_1
- .4byte PokeballGlowEffect_2
- .4byte PokeballGlowEffect_3
- .4byte PokeballGlowEffect_4
- .4byte PokeballGlowEffect_5
- .4byte PokeballGlowEffect_6
- .4byte PokeballGlowEffect_7
-
-gUnknown_0839F2A8:: @ 839F2A8
- .2byte 0, 0
- .2byte 6, 0
- .2byte 0, 4
- .2byte 6, 4
- .2byte 0, 8
- .2byte 6, 8
-
-gUnknown_0839F2C0:: @ 839F2C0
- .byte 16, 12, 8, 0
-
-gUnknown_0839F2C4:: @ 839F2C4
- .byte 16, 12, 8, 0
-
-gUnknown_0839F2C8:: @ 839F2C8
- .space 4
-
- .align 2
-gUnknown_0839F2CC:: @ 839F2CC
- .4byte sub_80867AC
- .4byte sub_8086854
- .4byte sub_8086870
- .4byte sub_80868E4
- .4byte sub_808699C
- .4byte sub_80869B8
- .4byte sub_80869F8
-
- .align 2
-gUnknown_0839F2E8:: @ 839F2E8
- .4byte sub_8086AA0
- .4byte sub_8086AC0
- .4byte sub_8086B30
- .4byte sub_8086B54
- .4byte sub_8086B64
- .4byte sub_8086B88
-
- .align 2
-gUnknown_0839F300:: @ 839F300
- .4byte sub_8086CF4
- .4byte sub_8086D70
- .4byte sub_8086DB0
- .4byte sub_8086E10
- .4byte sub_8086E50
- .4byte sub_8086EB0
- .4byte sub_8086ED4
-
- .align 2
-gUnknown_0839F31C:: @ 839F31C
- .4byte sub_8086FB0
- .4byte waterfall_1_do_anim_probably
- .4byte waterfall_2_wait_anim_finish_probably
- .4byte sub_8087030
- .4byte sub_8087058
-
- .align 2
-gUnknown_0839F330:: @ 839F330
- .4byte sub_8087124
- .4byte dive_2_unknown
- .4byte dive_3_unknown
-
- .align 2
-gUnknown_0839F33C:: @ 839F33C
- .4byte sub_808722C
- .4byte sub_8087264
- .4byte sub_8087298
- .4byte sub_80872E4
- .4byte sub_80873D8
- .4byte sub_80873F4
-
- .align 2
-gUnknown_0839F354:: @ 839F354
- .4byte sub_80874CC
- .4byte sub_80874FC
- .4byte sub_8087548
- .4byte sub_808759C
-
- .align 2
-gUnknown_0839F364:: @ 839F364
- .4byte sub_80876C8
- .4byte sub_80876F8
- .4byte sub_8087774
- .4byte sub_80877AC
- .4byte sub_80877D4
-
- .align 2
-gUnknown_0839F378:: @ 839F378
- .4byte sub_80878F4
- .4byte sub_8087914
-
-gUnknown_0839F380:: @ 839F380
- .byte 1, 3, 4, 2, 1
-
- .align 2
-gUnknown_0839F388:: @ 839F388
- .4byte sub_8087AA4
- .4byte sub_8087AC8
-
- .align 2
-gUnknown_0839F390:: @ 839F390
- .4byte sub_8087BEC
- .4byte sub_8087C14
- .4byte sub_8087CA4
- .4byte sub_8087D78
-
- .align 2
-gUnknown_0839F3A0:: @ 839F3A0
- .4byte sub_8087E4C
- .4byte sub_8087ED8
- .4byte sub_8087FDC
-
- .align 2
-gUnknown_0839F3AC:: @ 839F3AC
- .4byte sub_8088150
- .4byte sub_80881C0
- .4byte sub_8088228
- .4byte sub_80882B4
- .4byte sub_80882E4
- .4byte sub_8088338
- .4byte sub_8088380
-
- .align 2
-gUnknown_0839F3C8:: @ 839F3C8
- .4byte sub_80884AC
- .4byte sub_80884E8
- .4byte sub_8088554
- .4byte sub_80885A8
- .4byte sub_80885D8
- .4byte sub_808860C
- .4byte sub_808862C
-
- .align 2
-gUnknown_0839F3E4:: @ 839F3E4
- .4byte sub_8088984
- .4byte sub_80889E4
- .4byte sub_8088A30
- .4byte sub_8088A78
- .4byte sub_8088AF4
-
- .align 2
-gUnknown_0839F3F8:: @ 839F3F8
- .4byte sub_8088CA0
- .4byte sub_8088CF8
- .4byte sub_8088D3C
- .4byte sub_8088D94
- .4byte sub_8088DD8
- .4byte sub_8088E2C
- .4byte sub_8088EB4
- .4byte sub_8088F10
- .4byte sub_8088F30
-
-SpriteAffineAnim_839F41C:
- obj_rot_scal_anim_frame 8, 8, -30, 0
- obj_rot_scal_anim_frame 28, 28, 0, 30
- obj_rot_scal_anim_end
-
-SpriteAffineAnim_839F434:
- obj_rot_scal_anim_frame 256, 256, 64, 0
- obj_rot_scal_anim_frame -10, -10, 0, 22
- obj_rot_scal_anim_end
-
- .align 2
-gSpriteAffineAnimTable_0839F44C:: @ 839F44C
- .4byte SpriteAffineAnim_839F41C
- .4byte SpriteAffineAnim_839F434
-
- .align 2
-gUnknown_0839F454:: @ 839F454
- .4byte sub_80892A0
- .4byte sub_8089354
- .4byte sub_80893C0
- .4byte sub_8089414
- .4byte sub_808948C
- .4byte sub_80894C4
- .4byte fishE
-
-gUnknown_0839F470:: @ 839F470
- .2byte -2
- .2byte -4
- .2byte -5
- .2byte -6
- .2byte -7
- .2byte -8
- .2byte -8
- .2byte -8
- .2byte -7
- .2byte -7
- .2byte -6
- .2byte -5
- .2byte -3
- .2byte -2
- .2byte 0
- .2byte 2
- .2byte 4
- .2byte 8
diff --git a/data/graphics/pokemon/footprint_table.inc b/data/graphics/pokemon/footprint_table.inc
deleted file mode 100644
index 675a3bce4..000000000
--- a/data/graphics/pokemon/footprint_table.inc
+++ /dev/null
@@ -1,415 +0,0 @@
- .align 2
-gMonFootprintTable:: @ 83B4EE4
- .4byte gMonFootprint_Bulbasaur
- .4byte gMonFootprint_Bulbasaur
- .4byte gMonFootprint_Ivysaur
- .4byte gMonFootprint_Venusaur
- .4byte gMonFootprint_Charmander
- .4byte gMonFootprint_Charmeleon
- .4byte gMonFootprint_Charizard
- .4byte gMonFootprint_Squirtle
- .4byte gMonFootprint_Wartortle
- .4byte gMonFootprint_Blastoise
- .4byte gMonFootprint_Caterpie
- .4byte gMonFootprint_Metapod
- .4byte gMonFootprint_Butterfree
- .4byte gMonFootprint_Weedle
- .4byte gMonFootprint_Kakuna
- .4byte gMonFootprint_Beedrill
- .4byte gMonFootprint_Pidgey
- .4byte gMonFootprint_Pidgeotto
- .4byte gMonFootprint_Pidgeot
- .4byte gMonFootprint_Rattata
- .4byte gMonFootprint_Raticate
- .4byte gMonFootprint_Spearow
- .4byte gMonFootprint_Fearow
- .4byte gMonFootprint_Ekans
- .4byte gMonFootprint_Arbok
- .4byte gMonFootprint_Pikachu
- .4byte gMonFootprint_Raichu
- .4byte gMonFootprint_Sandshrew
- .4byte gMonFootprint_Sandslash
- .4byte gMonFootprint_NidoranF
- .4byte gMonFootprint_Nidorina
- .4byte gMonFootprint_Nidoqueen
- .4byte gMonFootprint_NidoranM
- .4byte gMonFootprint_Nidorino
- .4byte gMonFootprint_Nidoking
- .4byte gMonFootprint_Clefairy
- .4byte gMonFootprint_Clefable
- .4byte gMonFootprint_Vulpix
- .4byte gMonFootprint_Ninetales
- .4byte gMonFootprint_Jigglypuff
- .4byte gMonFootprint_Wigglytuff
- .4byte gMonFootprint_Zubat
- .4byte gMonFootprint_Golbat
- .4byte gMonFootprint_Oddish
- .4byte gMonFootprint_Gloom
- .4byte gMonFootprint_Vileplume
- .4byte gMonFootprint_Paras
- .4byte gMonFootprint_Parasect
- .4byte gMonFootprint_Venonat
- .4byte gMonFootprint_Venomoth
- .4byte gMonFootprint_Diglett
- .4byte gMonFootprint_Dugtrio
- .4byte gMonFootprint_Meowth
- .4byte gMonFootprint_Persian
- .4byte gMonFootprint_Psyduck
- .4byte gMonFootprint_Golduck
- .4byte gMonFootprint_Mankey
- .4byte gMonFootprint_Primeape
- .4byte gMonFootprint_Growlithe
- .4byte gMonFootprint_Arcanine
- .4byte gMonFootprint_Poliwag
- .4byte gMonFootprint_Poliwhirl
- .4byte gMonFootprint_Poliwrath
- .4byte gMonFootprint_Abra
- .4byte gMonFootprint_Kadabra
- .4byte gMonFootprint_Alakazam
- .4byte gMonFootprint_Machop
- .4byte gMonFootprint_Machoke
- .4byte gMonFootprint_Machamp
- .4byte gMonFootprint_Bellsprout
- .4byte gMonFootprint_Weepinbell
- .4byte gMonFootprint_Victreebel
- .4byte gMonFootprint_Tentacool
- .4byte gMonFootprint_Tentacruel
- .4byte gMonFootprint_Geodude
- .4byte gMonFootprint_Graveler
- .4byte gMonFootprint_Golem
- .4byte gMonFootprint_Ponyta
- .4byte gMonFootprint_Rapidash
- .4byte gMonFootprint_Slowpoke
- .4byte gMonFootprint_Slowbro
- .4byte gMonFootprint_Magnemite
- .4byte gMonFootprint_Magneton
- .4byte gMonFootprint_Farfetchd
- .4byte gMonFootprint_Doduo
- .4byte gMonFootprint_Dodrio
- .4byte gMonFootprint_Seel
- .4byte gMonFootprint_Dewgong
- .4byte gMonFootprint_Grimer
- .4byte gMonFootprint_Muk
- .4byte gMonFootprint_Shellder
- .4byte gMonFootprint_Cloyster
- .4byte gMonFootprint_Gastly
- .4byte gMonFootprint_Haunter
- .4byte gMonFootprint_Gengar
- .4byte gMonFootprint_Onix
- .4byte gMonFootprint_Drowzee
- .4byte gMonFootprint_Hypno
- .4byte gMonFootprint_Krabby
- .4byte gMonFootprint_Kingler
- .4byte gMonFootprint_Voltorb
- .4byte gMonFootprint_Electrode
- .4byte gMonFootprint_Exeggcute
- .4byte gMonFootprint_Exeggutor
- .4byte gMonFootprint_Cubone
- .4byte gMonFootprint_Marowak
- .4byte gMonFootprint_Hitmonlee
- .4byte gMonFootprint_Hitmonchan
- .4byte gMonFootprint_Lickitung
- .4byte gMonFootprint_Koffing
- .4byte gMonFootprint_Weezing
- .4byte gMonFootprint_Rhyhorn
- .4byte gMonFootprint_Rhydon
- .4byte gMonFootprint_Chansey
- .4byte gMonFootprint_Tangela
- .4byte gMonFootprint_Kangaskhan
- .4byte gMonFootprint_Horsea
- .4byte gMonFootprint_Seadra
- .4byte gMonFootprint_Goldeen
- .4byte gMonFootprint_Seaking
- .4byte gMonFootprint_Staryu
- .4byte gMonFootprint_Starmie
- .4byte gMonFootprint_Mrmime
- .4byte gMonFootprint_Scyther
- .4byte gMonFootprint_Jynx
- .4byte gMonFootprint_Electabuzz
- .4byte gMonFootprint_Magmar
- .4byte gMonFootprint_Pinsir
- .4byte gMonFootprint_Tauros
- .4byte gMonFootprint_Magikarp
- .4byte gMonFootprint_Gyarados
- .4byte gMonFootprint_Lapras
- .4byte gMonFootprint_Ditto
- .4byte gMonFootprint_Eevee
- .4byte gMonFootprint_Vaporeon
- .4byte gMonFootprint_Jolteon
- .4byte gMonFootprint_Flareon
- .4byte gMonFootprint_Porygon
- .4byte gMonFootprint_Omanyte
- .4byte gMonFootprint_Omastar
- .4byte gMonFootprint_Kabuto
- .4byte gMonFootprint_Kabutops
- .4byte gMonFootprint_Aerodactyl
- .4byte gMonFootprint_Snorlax
- .4byte gMonFootprint_Articuno
- .4byte gMonFootprint_Zapdos
- .4byte gMonFootprint_Moltres
- .4byte gMonFootprint_Dratini
- .4byte gMonFootprint_Dragonair
- .4byte gMonFootprint_Dragonite
- .4byte gMonFootprint_Mewtwo
- .4byte gMonFootprint_Mew
- .4byte gMonFootprint_Chikorita
- .4byte gMonFootprint_Bayleef
- .4byte gMonFootprint_Meganium
- .4byte gMonFootprint_Cyndaquil
- .4byte gMonFootprint_Quilava
- .4byte gMonFootprint_Typhlosion
- .4byte gMonFootprint_Totodile
- .4byte gMonFootprint_Croconaw
- .4byte gMonFootprint_Feraligatr
- .4byte gMonFootprint_Sentret
- .4byte gMonFootprint_Furret
- .4byte gMonFootprint_Hoothoot
- .4byte gMonFootprint_Noctowl
- .4byte gMonFootprint_Ledyba
- .4byte gMonFootprint_Ledian
- .4byte gMonFootprint_Spinarak
- .4byte gMonFootprint_Ariados
- .4byte gMonFootprint_Crobat
- .4byte gMonFootprint_Chinchou
- .4byte gMonFootprint_Lanturn
- .4byte gMonFootprint_Pichu
- .4byte gMonFootprint_Cleffa
- .4byte gMonFootprint_Igglybuff
- .4byte gMonFootprint_Togepi
- .4byte gMonFootprint_Togetic
- .4byte gMonFootprint_Natu
- .4byte gMonFootprint_Xatu
- .4byte gMonFootprint_Mareep
- .4byte gMonFootprint_Flaaffy
- .4byte gMonFootprint_Ampharos
- .4byte gMonFootprint_Bellossom
- .4byte gMonFootprint_Marill
- .4byte gMonFootprint_Azumarill
- .4byte gMonFootprint_Sudowoodo
- .4byte gMonFootprint_Politoed
- .4byte gMonFootprint_Hoppip
- .4byte gMonFootprint_Skiploom
- .4byte gMonFootprint_Jumpluff
- .4byte gMonFootprint_Aipom
- .4byte gMonFootprint_Sunkern
- .4byte gMonFootprint_Sunflora
- .4byte gMonFootprint_Yanma
- .4byte gMonFootprint_Wooper
- .4byte gMonFootprint_Quagsire
- .4byte gMonFootprint_Espeon
- .4byte gMonFootprint_Umbreon
- .4byte gMonFootprint_Murkrow
- .4byte gMonFootprint_Slowking
- .4byte gMonFootprint_Misdreavus
- .4byte gMonFootprint_Unown
- .4byte gMonFootprint_Wobbuffet
- .4byte gMonFootprint_Girafarig
- .4byte gMonFootprint_Pineco
- .4byte gMonFootprint_Forretress
- .4byte gMonFootprint_Dunsparce
- .4byte gMonFootprint_Gligar
- .4byte gMonFootprint_Steelix
- .4byte gMonFootprint_Snubbull
- .4byte gMonFootprint_Granbull
- .4byte gMonFootprint_Qwilfish
- .4byte gMonFootprint_Scizor
- .4byte gMonFootprint_Shuckle
- .4byte gMonFootprint_Heracross
- .4byte gMonFootprint_Sneasel
- .4byte gMonFootprint_Teddiursa
- .4byte gMonFootprint_Ursaring
- .4byte gMonFootprint_Slugma
- .4byte gMonFootprint_Magcargo
- .4byte gMonFootprint_Swinub
- .4byte gMonFootprint_Piloswine
- .4byte gMonFootprint_Corsola
- .4byte gMonFootprint_Remoraid
- .4byte gMonFootprint_Octillery
- .4byte gMonFootprint_Delibird
- .4byte gMonFootprint_Mantine
- .4byte gMonFootprint_Skarmory
- .4byte gMonFootprint_Houndour
- .4byte gMonFootprint_Houndoom
- .4byte gMonFootprint_Kingdra
- .4byte gMonFootprint_Phanpy
- .4byte gMonFootprint_Donphan
- .4byte gMonFootprint_Porygon2
- .4byte gMonFootprint_Stantler
- .4byte gMonFootprint_Smeargle
- .4byte gMonFootprint_Tyrogue
- .4byte gMonFootprint_Hitmontop
- .4byte gMonFootprint_Smoochum
- .4byte gMonFootprint_Elekid
- .4byte gMonFootprint_Magby
- .4byte gMonFootprint_Miltank
- .4byte gMonFootprint_Blissey
- .4byte gMonFootprint_Raikou
- .4byte gMonFootprint_Entei
- .4byte gMonFootprint_Suicune
- .4byte gMonFootprint_Larvitar
- .4byte gMonFootprint_Pupitar
- .4byte gMonFootprint_Tyranitar
- .4byte gMonFootprint_Lugia
- .4byte gMonFootprint_HoOh
- .4byte gMonFootprint_Celebi
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_QuestionMark
- .4byte gMonFootprint_Treecko
- .4byte gMonFootprint_Grovyle
- .4byte gMonFootprint_Sceptile
- .4byte gMonFootprint_Torchic
- .4byte gMonFootprint_Combusken
- .4byte gMonFootprint_Blaziken
- .4byte gMonFootprint_Mudkip
- .4byte gMonFootprint_Marshtomp
- .4byte gMonFootprint_Swampert
- .4byte gMonFootprint_Poochyena
- .4byte gMonFootprint_Mightyena
- .4byte gMonFootprint_Zigzagoon
- .4byte gMonFootprint_Linoone
- .4byte gMonFootprint_Wurmple
- .4byte gMonFootprint_Silcoon
- .4byte gMonFootprint_Beautifly
- .4byte gMonFootprint_Cascoon
- .4byte gMonFootprint_Dustox
- .4byte gMonFootprint_Lotad
- .4byte gMonFootprint_Lombre
- .4byte gMonFootprint_Ludicolo
- .4byte gMonFootprint_Seedot
- .4byte gMonFootprint_Nuzleaf
- .4byte gMonFootprint_Shiftry
- .4byte gMonFootprint_Nincada
- .4byte gMonFootprint_Ninjask
- .4byte gMonFootprint_Shedinja
- .4byte gMonFootprint_Taillow
- .4byte gMonFootprint_Swellow
- .4byte gMonFootprint_Shroomish
- .4byte gMonFootprint_Breloom
- .4byte gMonFootprint_Spinda
- .4byte gMonFootprint_Wingull
- .4byte gMonFootprint_Pelipper
- .4byte gMonFootprint_Surskit
- .4byte gMonFootprint_Masquerain
- .4byte gMonFootprint_Wailmer
- .4byte gMonFootprint_Wailord
- .4byte gMonFootprint_Skitty
- .4byte gMonFootprint_Delcatty
- .4byte gMonFootprint_Kecleon
- .4byte gMonFootprint_Baltoy
- .4byte gMonFootprint_Claydol
- .4byte gMonFootprint_Nosepass
- .4byte gMonFootprint_Torkoal
- .4byte gMonFootprint_Sableye
- .4byte gMonFootprint_Barboach
- .4byte gMonFootprint_Whiscash
- .4byte gMonFootprint_Luvdisc
- .4byte gMonFootprint_Corphish
- .4byte gMonFootprint_Crawdaunt
- .4byte gMonFootprint_Feebas
- .4byte gMonFootprint_Milotic
- .4byte gMonFootprint_Carvanha
- .4byte gMonFootprint_Sharpedo
- .4byte gMonFootprint_Trapinch
- .4byte gMonFootprint_Vibrava
- .4byte gMonFootprint_Flygon
- .4byte gMonFootprint_Makuhita
- .4byte gMonFootprint_Hariyama
- .4byte gMonFootprint_Electrike
- .4byte gMonFootprint_Manectric
- .4byte gMonFootprint_Numel
- .4byte gMonFootprint_Camerupt
- .4byte gMonFootprint_Spheal
- .4byte gMonFootprint_Sealeo
- .4byte gMonFootprint_Walrein
- .4byte gMonFootprint_Cacnea
- .4byte gMonFootprint_Cacturne
- .4byte gMonFootprint_Snorunt
- .4byte gMonFootprint_Glalie
- .4byte gMonFootprint_Lunatone
- .4byte gMonFootprint_Solrock
- .4byte gMonFootprint_Azurill
- .4byte gMonFootprint_Spoink
- .4byte gMonFootprint_Grumpig
- .4byte gMonFootprint_Plusle
- .4byte gMonFootprint_Minun
- .4byte gMonFootprint_Mawile
- .4byte gMonFootprint_Meditite
- .4byte gMonFootprint_Medicham
- .4byte gMonFootprint_Swablu
- .4byte gMonFootprint_Altaria
- .4byte gMonFootprint_Wynaut
- .4byte gMonFootprint_Duskull
- .4byte gMonFootprint_Dusclops
- .4byte gMonFootprint_Roselia
- .4byte gMonFootprint_Slakoth
- .4byte gMonFootprint_Vigoroth
- .4byte gMonFootprint_Slaking
- .4byte gMonFootprint_Gulpin
- .4byte gMonFootprint_Swalot
- .4byte gMonFootprint_Tropius
- .4byte gMonFootprint_Whismur
- .4byte gMonFootprint_Loudred
- .4byte gMonFootprint_Exploud
- .4byte gMonFootprint_Clamperl
- .4byte gMonFootprint_Huntail
- .4byte gMonFootprint_Gorebyss
- .4byte gMonFootprint_Absol
- .4byte gMonFootprint_Shuppet
- .4byte gMonFootprint_Banette
- .4byte gMonFootprint_Seviper
- .4byte gMonFootprint_Zangoose
- .4byte gMonFootprint_Relicanth
- .4byte gMonFootprint_Aron
- .4byte gMonFootprint_Lairon
- .4byte gMonFootprint_Aggron
- .4byte gMonFootprint_Castform
- .4byte gMonFootprint_Volbeat
- .4byte gMonFootprint_Illumise
- .4byte gMonFootprint_Lileep
- .4byte gMonFootprint_Cradily
- .4byte gMonFootprint_Anorith
- .4byte gMonFootprint_Armaldo
- .4byte gMonFootprint_Ralts
- .4byte gMonFootprint_Kirlia
- .4byte gMonFootprint_Gardevoir
- .4byte gMonFootprint_Bagon
- .4byte gMonFootprint_Shelgon
- .4byte gMonFootprint_Salamence
- .4byte gMonFootprint_Beldum
- .4byte gMonFootprint_Metang
- .4byte gMonFootprint_Metagross
- .4byte gMonFootprint_Regirock
- .4byte gMonFootprint_Regice
- .4byte gMonFootprint_Registeel
- .4byte gMonFootprint_Kyogre
- .4byte gMonFootprint_Groudon
- .4byte gMonFootprint_Rayquaza
- .4byte gMonFootprint_Latias
- .4byte gMonFootprint_Latios
- .4byte gMonFootprint_Jirachi
- .4byte gMonFootprint_Deoxys
- .4byte gMonFootprint_Chimecho
- .4byte gMonFootprint_Bulbasaur
diff --git a/data/maps/UnknownMap_082CF564/border.bin b/data/maps/UnknownMap_082CF564/border.bin
index 19d906679..19d906679 100755..100644
--- a/data/maps/UnknownMap_082CF564/border.bin
+++ b/data/maps/UnknownMap_082CF564/border.bin
diff --git a/data/maps/UnknownMap_082CF564/map.bin b/data/maps/UnknownMap_082CF564/map.bin
index ca93fa0e2..ca93fa0e2 100755..100644
--- a/data/maps/UnknownMap_082CF564/map.bin
+++ b/data/maps/UnknownMap_082CF564/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082D05D8/border.bin b/data/maps/UnknownMap_082D05D8/border.bin
index 19d906679..19d906679 100755..100644
--- a/data/maps/UnknownMap_082D05D8/border.bin
+++ b/data/maps/UnknownMap_082D05D8/border.bin
diff --git a/data/maps/UnknownMap_082D05D8/map.bin b/data/maps/UnknownMap_082D05D8/map.bin
index 37f05b971..37f05b971 100755..100644
--- a/data/maps/UnknownMap_082D05D8/map.bin
+++ b/data/maps/UnknownMap_082D05D8/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082D05FC/border.bin b/data/maps/UnknownMap_082D05FC/border.bin
index 19d906679..19d906679 100755..100644
--- a/data/maps/UnknownMap_082D05FC/border.bin
+++ b/data/maps/UnknownMap_082D05FC/border.bin
diff --git a/data/maps/UnknownMap_082D05FC/map.bin b/data/maps/UnknownMap_082D05FC/map.bin
index ca93fa0e2..ca93fa0e2 100755..100644
--- a/data/maps/UnknownMap_082D05FC/map.bin
+++ b/data/maps/UnknownMap_082D05FC/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E55C8/border.bin b/data/maps/UnknownMap_082E55C8/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E55C8/border.bin
+++ b/data/maps/UnknownMap_082E55C8/border.bin
diff --git a/data/maps/UnknownMap_082E55C8/map.bin b/data/maps/UnknownMap_082E55C8/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E55C8/map.bin
+++ b/data/maps/UnknownMap_082E55C8/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E55EC/border.bin b/data/maps/UnknownMap_082E55EC/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E55EC/border.bin
+++ b/data/maps/UnknownMap_082E55EC/border.bin
diff --git a/data/maps/UnknownMap_082E55EC/map.bin b/data/maps/UnknownMap_082E55EC/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E55EC/map.bin
+++ b/data/maps/UnknownMap_082E55EC/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5610/border.bin b/data/maps/UnknownMap_082E5610/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5610/border.bin
+++ b/data/maps/UnknownMap_082E5610/border.bin
diff --git a/data/maps/UnknownMap_082E5610/map.bin b/data/maps/UnknownMap_082E5610/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5610/map.bin
+++ b/data/maps/UnknownMap_082E5610/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5634/border.bin b/data/maps/UnknownMap_082E5634/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5634/border.bin
+++ b/data/maps/UnknownMap_082E5634/border.bin
diff --git a/data/maps/UnknownMap_082E5634/map.bin b/data/maps/UnknownMap_082E5634/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5634/map.bin
+++ b/data/maps/UnknownMap_082E5634/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5658/border.bin b/data/maps/UnknownMap_082E5658/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5658/border.bin
+++ b/data/maps/UnknownMap_082E5658/border.bin
diff --git a/data/maps/UnknownMap_082E5658/map.bin b/data/maps/UnknownMap_082E5658/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5658/map.bin
+++ b/data/maps/UnknownMap_082E5658/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E567C/border.bin b/data/maps/UnknownMap_082E567C/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E567C/border.bin
+++ b/data/maps/UnknownMap_082E567C/border.bin
diff --git a/data/maps/UnknownMap_082E567C/map.bin b/data/maps/UnknownMap_082E567C/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E567C/map.bin
+++ b/data/maps/UnknownMap_082E567C/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E56A0/border.bin b/data/maps/UnknownMap_082E56A0/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E56A0/border.bin
+++ b/data/maps/UnknownMap_082E56A0/border.bin
diff --git a/data/maps/UnknownMap_082E56A0/map.bin b/data/maps/UnknownMap_082E56A0/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E56A0/map.bin
+++ b/data/maps/UnknownMap_082E56A0/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E56C4/border.bin b/data/maps/UnknownMap_082E56C4/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E56C4/border.bin
+++ b/data/maps/UnknownMap_082E56C4/border.bin
diff --git a/data/maps/UnknownMap_082E56C4/map.bin b/data/maps/UnknownMap_082E56C4/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E56C4/map.bin
+++ b/data/maps/UnknownMap_082E56C4/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E56E8/border.bin b/data/maps/UnknownMap_082E56E8/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E56E8/border.bin
+++ b/data/maps/UnknownMap_082E56E8/border.bin
diff --git a/data/maps/UnknownMap_082E56E8/map.bin b/data/maps/UnknownMap_082E56E8/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E56E8/map.bin
+++ b/data/maps/UnknownMap_082E56E8/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E570C/border.bin b/data/maps/UnknownMap_082E570C/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E570C/border.bin
+++ b/data/maps/UnknownMap_082E570C/border.bin
diff --git a/data/maps/UnknownMap_082E570C/map.bin b/data/maps/UnknownMap_082E570C/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E570C/map.bin
+++ b/data/maps/UnknownMap_082E570C/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5730/border.bin b/data/maps/UnknownMap_082E5730/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5730/border.bin
+++ b/data/maps/UnknownMap_082E5730/border.bin
diff --git a/data/maps/UnknownMap_082E5730/map.bin b/data/maps/UnknownMap_082E5730/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5730/map.bin
+++ b/data/maps/UnknownMap_082E5730/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5754/border.bin b/data/maps/UnknownMap_082E5754/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5754/border.bin
+++ b/data/maps/UnknownMap_082E5754/border.bin
diff --git a/data/maps/UnknownMap_082E5754/map.bin b/data/maps/UnknownMap_082E5754/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5754/map.bin
+++ b/data/maps/UnknownMap_082E5754/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E5778/border.bin b/data/maps/UnknownMap_082E5778/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E5778/border.bin
+++ b/data/maps/UnknownMap_082E5778/border.bin
diff --git a/data/maps/UnknownMap_082E5778/map.bin b/data/maps/UnknownMap_082E5778/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E5778/map.bin
+++ b/data/maps/UnknownMap_082E5778/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082E579C/border.bin b/data/maps/UnknownMap_082E579C/border.bin
index b15c94f96..b15c94f96 100755..100644
--- a/data/maps/UnknownMap_082E579C/border.bin
+++ b/data/maps/UnknownMap_082E579C/border.bin
diff --git a/data/maps/UnknownMap_082E579C/map.bin b/data/maps/UnknownMap_082E579C/map.bin
index 22a47d94e..22a47d94e 100755..100644
--- a/data/maps/UnknownMap_082E579C/map.bin
+++ b/data/maps/UnknownMap_082E579C/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_082EDF30/border.bin b/data/maps/UnknownMap_082EDF30/border.bin
index 9e4b3fb7a..9e4b3fb7a 100755..100644
--- a/data/maps/UnknownMap_082EDF30/border.bin
+++ b/data/maps/UnknownMap_082EDF30/border.bin
diff --git a/data/maps/UnknownMap_082EDF30/map.bin b/data/maps/UnknownMap_082EDF30/map.bin
index 028da0526..028da0526 100755..100644
--- a/data/maps/UnknownMap_082EDF30/map.bin
+++ b/data/maps/UnknownMap_082EDF30/map.bin
diff --git a/data/maps/UnknownMap_082FF894/border.bin b/data/maps/UnknownMap_082FF894/border.bin
index f1629c020..f1629c020 100755..100644
--- a/data/maps/UnknownMap_082FF894/border.bin
+++ b/data/maps/UnknownMap_082FF894/border.bin
diff --git a/data/maps/UnknownMap_082FF894/map.bin b/data/maps/UnknownMap_082FF894/map.bin
index fd294d9b6..fd294d9b6 100755..100644
--- a/data/maps/UnknownMap_082FF894/map.bin
+++ b/data/maps/UnknownMap_082FF894/map.bin
Binary files differ
diff --git a/data/maps/UnknownMap_08302970/border.bin b/data/maps/UnknownMap_08302970/border.bin
index c3fe51511..c3fe51511 100755..100644
--- a/data/maps/UnknownMap_08302970/border.bin
+++ b/data/maps/UnknownMap_08302970/border.bin
diff --git a/data/maps/UnknownMap_08302970/map.bin b/data/maps/UnknownMap_08302970/map.bin
index dd82c58d3..dd82c58d3 100755..100644
--- a/data/maps/UnknownMap_08302970/map.bin
+++ b/data/maps/UnknownMap_08302970/map.bin
diff --git a/data/maps/UnknownMap_083041B4/border.bin b/data/maps/UnknownMap_083041B4/border.bin
index f0eabd248..f0eabd248 100755..100644
--- a/data/maps/UnknownMap_083041B4/border.bin
+++ b/data/maps/UnknownMap_083041B4/border.bin
diff --git a/data/maps/UnknownMap_083041B4/map.bin b/data/maps/UnknownMap_083041B4/map.bin
index ec344933f..ec344933f 100755..100644
--- a/data/maps/UnknownMap_083041B4/map.bin
+++ b/data/maps/UnknownMap_083041B4/map.bin
diff --git a/data/maps/UnreferencedMap/border.bin b/data/maps/UnreferencedMap/border.bin
index c3fe51511..c3fe51511 100755..100644
--- a/data/maps/UnreferencedMap/border.bin
+++ b/data/maps/UnreferencedMap/border.bin
diff --git a/data/maps/UnreferencedMap/map.bin b/data/maps/UnreferencedMap/map.bin
index 17a14a8d5..17a14a8d5 100755..100644
--- a/data/maps/UnreferencedMap/map.bin
+++ b/data/maps/UnreferencedMap/map.bin
diff --git a/data/player_pc.s b/data/player_pc.s
deleted file mode 100644
index 200ae19c2..000000000
--- a/data/player_pc.s
+++ /dev/null
@@ -1,77 +0,0 @@
- .include "asm/macros.inc"
- .include "constants/constants.inc"
-
- .section .rodata
-
- .align 2
-gUnknown_08406288:: @ 8406288
- .4byte PCText_TakeOutItems
- .4byte PCText_StoreItems
- .4byte PCText_ThrowAwayItems
- .4byte gMenuText_GoBackToPrev
-
- .align 2
-gUnknown_08406298:: @ 8406298
- .4byte SecretBaseText_ItemStorage, PlayerPC_ItemStorage
- .4byte gPCText_Mailbox, PlayerPC_Mailbox
- .4byte SecretBaseText_Decoration, PlayerPC_Decoration
- .4byte SecretBaseText_TurnOff, PlayerPC_TurnOff
-
-gUnknown_084062B8:: @ 84062B8
- .byte 0, 1, 2, 3
-
-gUnknown_084062BC:: @ 84062BC
- .byte 0, 1, 3
-
- .align 2
-gUnknown_084062C0:: @ 84062C0
- .4byte PCText_WithdrawItem, ItemStorage_Withdraw
- .4byte PCText_DepositItem, ItemStorage_Deposit
- .4byte PCText_TossItem, ItemStorage_Toss
- .4byte gUnknownText_Exit, ItemStorage_Exit
-
- .align 2
-gUnknown_084062E0:: @ 84062E0
- .4byte sub_813A83C
- .4byte sub_813A878
-
- .align 2
-gUnknown_084062E8:: @ 84062E8
- .4byte sub_813B578
- .4byte sub_813B610
-
- .align 2
-gNewGamePCItems:: @ 84062F0
- .2byte ITEM_POTION, 1
- .2byte ITEM_NONE, 0
-
- .align 2
-gUnknown_084062F8:: @ 84062F8
- .4byte OtherText_Read, Mailbox_Read
- .4byte gOtherText_MoveToBag, Mailbox_MoveToBag
- .4byte OtherText_Give, Mailbox_Give
- .4byte gOtherText_CancelNoTerminator, Mailbox_Cancel
-
-gUnknown_08406318:: @ 8406318
- .string "{STR_VAR_1}{CLEAR_TO 80}$"
-
-gUnknown_0840631E:: @ 840631E
- .string "{COLOR RED}{STR_VAR_1}{CLEAR_TO 80}$"
-
-gUnknown_08406327:: @ 8406327
- .string "{STR_VAR_1}$"
-
-gUnknown_0840632A:: @ 840632A
- .string "{COLOR RED}{STR_VAR_1}$"
-
-gUnknown_08406330:: @ 8406330
- .string "{CLEAR_TO 32}$"
-
- .align 1
-gUnknown_08406334:: @ 8406334
- .2byte 0x5294
- .2byte 0x6B5A
- .2byte 0x7FFF
-
-gUnknown_0840633A:: @ 840633A
- .string "{COLOR RED}{STR_VAR_1}$"
diff --git a/data/pokedex.s b/data/pokedex.s
deleted file mode 100644
index a9ee7a9be..000000000
--- a/data/pokedex.s
+++ /dev/null
@@ -1,538 +0,0 @@
- .include "asm/macros.inc"
- .include "constants/constants.inc"
-
- .section .rodata
-
- .align 2
-gUnknown_0839F67C:: @ 839F67C
- .incbin "graphics/pokedex/search.gbapal"
-
- .align 2
-gUnknown_0839F73C:: @ 839F73C
- .incbin "graphics/pokedex/national.gbapal"
-
- .space 0xA4
-
- .align 2
-gUnknown_0839F8A0:: @ 839F8A0
- .incbin "graphics/pokedex/pokedex_cry_layout.bin.lz"
-
- .align 2
-gUnknown_0839F988:: @ 839F988
- .incbin "graphics/pokedex/pokedex_size_layout.bin.lz"
-
-gUnknown_0839FA7C:: @ 839FA7C
- .incbin "graphics/pokedex/noball.4bpp.lz"
-
-@ 839FAC4
- .include "data/pokedex_orders.inc"
-
- .align 2
-gOamData_83A0404:: @ 83A0404
- .2byte 0x00A0
- .2byte 0x0000
- .2byte 0x0400
-
- .align 2
-gOamData_83A040C:: @ 83A040C
- .2byte 0x40A0
- .2byte 0x0000
- .2byte 0x0000
-
- .align 2
-gOamData_83A0414:: @ 83A0414
- .2byte 0x40A0
- .2byte 0xC000
- .2byte 0x0000
-
- .align 2
-gOamData_83A041C:: @ 83A041C
- .2byte 0x08A0
- .2byte 0x8000
- .2byte 0x0400
-
- .align 2
-gOamData_83A0424:: @ 83A0424
- .2byte 0x40A0
- .2byte 0xC000
- .2byte 0x0000
-
- .align 2
-gOamData_83A042C:: @ 83A042C
- .2byte 0x80A0
- .2byte 0x0000
- .2byte 0x0000
-
- .align 2
-gSpriteAnim_83A0434:: @ 83A0434
- obj_image_anim_frame 3, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A043C:: @ 83A043C
- obj_image_anim_frame 1, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0444:: @ 83A0444
- obj_image_anim_frame 16, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A044C:: @ 83A044C
- obj_image_anim_frame 32, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0454:: @ 83A0454
- obj_image_anim_frame 64, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A045C:: @ 83A045C
- obj_image_anim_frame 96, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0464:: @ 83A0464
- obj_image_anim_frame 128, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A046C:: @ 83A046C
- obj_image_anim_frame 160, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0474:: @ 83A0474
- obj_image_anim_frame 192, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A047C:: @ 83A047C
- obj_image_anim_frame 224, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0484:: @ 83A0484
- obj_image_anim_frame 226, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A048C:: @ 83A048C
- obj_image_anim_frame 228, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A0494:: @ 83A0494
- obj_image_anim_frame 230, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A049C:: @ 83A049C
- obj_image_anim_frame 232, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04A4:: @ 83A04A4
- obj_image_anim_frame 234, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04AC:: @ 83A04AC
- obj_image_anim_frame 236, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04B4:: @ 83A04B4
- obj_image_anim_frame 238, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04BC:: @ 83A04BC
- obj_image_anim_frame 240, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04C4:: @ 83A04C4
- obj_image_anim_frame 242, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnim_83A04CC:: @ 83A04CC
- obj_image_anim_frame 4, 30
- obj_image_anim_end
-
- .align 2
-gSpriteAnimTable_83A04D4:: @ 83A04D4
- .4byte gSpriteAnim_83A0434
-
- .align 2
-gSpriteAnimTable_83A04D8:: @ 83A04D8
- .4byte gSpriteAnim_83A043C
-
- .align 2
-gSpriteAnimTable_83A04DC:: @ 83A04DC
- .4byte gSpriteAnim_83A0444
-
- .align 2
-gSpriteAnimTable_83A04E0:: @ 83A04E0
- .4byte gSpriteAnim_83A044C
- .4byte gSpriteAnim_83A0454
- .4byte gSpriteAnim_83A045C
- .4byte gSpriteAnim_83A0464
-
- .align 2
-gSpriteAnimTable_83A04F0:: @ 83A04F0
- .4byte gSpriteAnim_83A046C
- .4byte gSpriteAnim_83A0474
-
- .align 2
-gSpriteAnimTable_83A04F8:: @ 83A04F8
- .4byte gSpriteAnim_83A047C
- .4byte gSpriteAnim_83A0484
- .4byte gSpriteAnim_83A048C
- .4byte gSpriteAnim_83A0494
- .4byte gSpriteAnim_83A049C
- .4byte gSpriteAnim_83A04A4
- .4byte gSpriteAnim_83A04AC
- .4byte gSpriteAnim_83A04B4
- .4byte gSpriteAnim_83A04BC
- .4byte gSpriteAnim_83A04C4
-
- .align 2
-gSpriteAnimTable_83A0520:: @ 83A0520
- .4byte gSpriteAnim_83A04CC
-
- .align 2
-gSpriteTemplate_83A0524:: @ 83A0524
- spr_template 4096, 4096, gOamData_83A0404, gSpriteAnimTable_83A04D4, NULL, gDummySpriteAffineAnimTable, sub_808EF38
-
- .align 2
-gSpriteTemplate_83A053C:: @ 83A053C
- spr_template 4096, 4096, gOamData_83A040C, gSpriteAnimTable_83A04D8, NULL, gDummySpriteAffineAnimTable, sub_808EF8C
-
- .align 2
-gSpriteTemplate_83A0554:: @ 83A0554
- spr_template 4096, 4096, gOamData_83A0414, gSpriteAnimTable_83A04E0, NULL, gDummySpriteAffineAnimTable, sub_808F08C
-
- .align 2
-gSpriteTemplate_83A056C:: @ 83A056C
- spr_template 4096, 4096, gOamData_83A041C, gSpriteAnimTable_83A04DC, NULL, gDummySpriteAffineAnimTable, sub_808F0B4
-
- .align 2
-gSpriteTemplate_83A0584:: @ 83A0584
- spr_template 4096, 4096, gOamData_83A0424, gSpriteAnimTable_83A04F0, NULL, gDummySpriteAffineAnimTable, sub_808ED94
-
- .align 2
-gSpriteTemplate_83A059C:: @ 83A059C
- spr_template 4096, 4096, gOamData_83A042C, gSpriteAnimTable_83A04F8, NULL, gDummySpriteAffineAnimTable, sub_808ED94
-
- .align 2
-gSpriteTemplate_83A05B4:: @ 83A05B4
- spr_template 4096, 4096, gOamData_83A042C, gSpriteAnimTable_83A0520, NULL, gDummySpriteAffineAnimTable, sub_808F168
-
- .align 2
-gUnknown_083A05CC:: @ 83A05CC
- obj_tiles gPokedexMenu2_Gfx, 0x1F00, 0x1000
- null_obj_tiles
-
- .align 2
-gUnknown_083A05DC:: @ 83A05DC
- obj_pal gPokedexMenu_Pal, 0x1000
- null_obj_pal
-
-gUnknown_083A05EC:: @ 83A05EC
- .byte 2, 4, 8, 16, 32
-
-gUnknown_083A05F1:: @ 83A05F1
- .byte 16, 8, 4, 2, 1
-
- .align 2
-gUnknown_083A05F8:: @ 83A05F8
- .string "$"
-
-@ 83A05F9
- .include "data/pokedex_entries.inc"
-
-gUnknown_083B4EC4:: @ 83B4EC4
- .space 32
-
-@ 83B4EE4
- .include "data/graphics/pokemon/footprint_table.inc"
-
-gUnknown_083B5558:: @ 83B5558
- .string "{CLEAR_TO 0}$"
-
- .incbin "graphics/unknown/unknown_3B555C.bin"
-
- .align 2
-gOamData_83B557C:: @ 83B557C
- .2byte 0x0000
- .2byte 0xC000
- .2byte 0x0400
-
- .align 2
-gUnknown_083B5584:: @ 83B5584
- .4byte 0x02008000
- .4byte 0x0200c000
- .4byte 0x02010000
- .4byte 0x02014000
-
- .align 2
-gSpriteImageTable_83B5594:: @ 83B5594
- obj_frame_tiles 0x02008000, 0x800
- obj_frame_tiles 0x02008800, 0x800
- obj_frame_tiles 0x02009000, 0x800
- obj_frame_tiles 0x02009800, 0x800
- obj_frame_tiles 0x0200A000, 0x800
- obj_frame_tiles 0x0200A800, 0x800
- obj_frame_tiles 0x0200B000, 0x800
- obj_frame_tiles 0x0200B800, 0x800
- obj_frame_tiles 0x0200C000, 0x800
- obj_frame_tiles 0x0200C800, 0x800
- obj_frame_tiles 0x0200D000, 0x800
- obj_frame_tiles 0x0200D800, 0x800
- obj_frame_tiles 0x0200E000, 0x800
- obj_frame_tiles 0x0200E800, 0x800
- obj_frame_tiles 0x0200F000, 0x800
- obj_frame_tiles 0x0200F800, 0x800
-
- .align 2
-gSpriteImageTable_83B5614:: @ 83B5614
- obj_frame_tiles 0x0200C000, 0x800
- obj_frame_tiles 0x0200C800, 0x800
- obj_frame_tiles 0x0200D000, 0x800
- obj_frame_tiles 0x0200D800, 0x800
- obj_frame_tiles 0x0200E000, 0x800
- obj_frame_tiles 0x0200E800, 0x800
- obj_frame_tiles 0x0200F000, 0x800
- obj_frame_tiles 0x0200F800, 0x800
- obj_frame_tiles 0x02010000, 0x800
- obj_frame_tiles 0x02010800, 0x800
- obj_frame_tiles 0x02011000, 0x800
- obj_frame_tiles 0x02011800, 0x800
- obj_frame_tiles 0x02012000, 0x800
- obj_frame_tiles 0x02012800, 0x800
- obj_frame_tiles 0x02013000, 0x800
- obj_frame_tiles 0x02013800, 0x800
-
- .align 2
-gSpriteImageTable_83B5694:: @ 83B5694
- obj_frame_tiles 0x02010000, 0x800
- obj_frame_tiles 0x02010800, 0x800
- obj_frame_tiles 0x02011000, 0x800
- obj_frame_tiles 0x02011800, 0x800
- obj_frame_tiles 0x02012000, 0x800
- obj_frame_tiles 0x02012800, 0x800
- obj_frame_tiles 0x02013000, 0x800
- obj_frame_tiles 0x02013800, 0x800
- obj_frame_tiles 0x02014000, 0x800
- obj_frame_tiles 0x02014800, 0x800
- obj_frame_tiles 0x02015000, 0x800
- obj_frame_tiles 0x02015800, 0x800
- obj_frame_tiles 0x02016000, 0x800
- obj_frame_tiles 0x02016800, 0x800
- obj_frame_tiles 0x02017000, 0x800
- obj_frame_tiles 0x02017800, 0x800
-
- .align 2
-gSpriteImageTable_83B5714:: @ 83B5714
- obj_frame_tiles 0x02014000, 0x800
- obj_frame_tiles 0x02014800, 0x800
- obj_frame_tiles 0x02015000, 0x800
- obj_frame_tiles 0x02015800, 0x800
- obj_frame_tiles 0x02016000, 0x800
- obj_frame_tiles 0x02016800, 0x800
- obj_frame_tiles 0x02017000, 0x800
- obj_frame_tiles 0x02017800, 0x800
- obj_frame_tiles 0x02018000, 0x800
- obj_frame_tiles 0x02018800, 0x800
- obj_frame_tiles 0x02019000, 0x800
- obj_frame_tiles 0x02019800, 0x800
- obj_frame_tiles 0x0201A000, 0x800
- obj_frame_tiles 0x0201A800, 0x800
- obj_frame_tiles 0x0201B000, 0x800
- obj_frame_tiles 0x0201B800, 0x800
-
- .align 2
-gUnknown_083B5794:: @ 83B5794
- .4byte gSpriteImageTable_83B5594
- .4byte gSpriteImageTable_83B5614
- .4byte gSpriteImageTable_83B5694
- .4byte gSpriteImageTable_83B5714
-
- .align 2
-gUnknown_083B57A4:: @ 83B57A4
- spr_template 0xFFFF, 0, gOamData_83B557C, NULL, gSpriteImageTable_83B5594, gDummySpriteAffineAnimTable, nullsub_59
-
-gUnknown_083B57BC:: @ 83B57BC
- .byte 0, 0, 0, 0
- .byte 187, 3, 213, 3
- .byte 190, 3, 216, 3
- .byte 193, 3, 219, 3
- .byte 196, 3, 222, 3
- .byte 199, 3, 225, 3
- .byte 202, 3, 228, 3
- .byte 205, 3, 231, 3
- .byte 208, 3, 234, 3
- .byte 211, 2, 237, 2
-
- .align 2
-gUnknown_083B57E4:: @ 83B57E4
- .4byte DexText_SearchForPoke
- .2byte 0, 5
- .4byte DexText_SwitchDex
- .2byte 6, 5
- .4byte DexText_ReturnToDex
- .2byte 12, 5
-
- .align 2
-gUnknown_083B57FC:: @ 83B57FC
- .4byte DexText_ListByABC
- .byte 0, 2, 5, 5, 2, 12, 0, 0
- .4byte DexText_ListByColor
- .byte 0, 4, 5, 5, 4, 12, 0, 0
- .4byte DexText_ListByType
- .byte 0, 6, 5, 5, 6, 6, 0, 0
- .4byte DexText_ListByType
- .byte 0, 6, 5, 11, 6, 6, 0, 0
- .4byte DexText_SelectDexList
- .byte 0, 8, 5, 5, 8, 12, 0, 0
- .4byte DexText_SelectDexMode
- .byte 0, 10, 5, 5, 10, 12, 0, 0
- .4byte DexText_ExecuteSearchSwitch
- .byte 0, 12, 5, 0, 0, 0, 0, 0
-
-gUnknown_083B5850:: @ 83B5850
- .byte 0xFF, 0xFF, 0xFF, 1
- .byte 0xFF, 0xFF, 0, 2
- .byte 0xFF, 3, 1, 4
- .byte 2, 0xFF, 1, 4
- .byte 0xFF, 0xFF, 2, 5
- .byte 0xFF, 0xFF, 4, 6
- .byte 0xFF, 0xFF, 5, 0xFF
-
-gUnknown_083B586C:: @ 83B586C
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 5
- .byte 0xFF, 0xFF, 4, 6
- .byte 0xFF, 0xFF, 5, 0xFF
-
-gUnknown_083B5888:: @ 83B5888
- .byte 0xFF, 0xFF, 0xFF, 1
- .byte 0xFF, 0xFF, 0, 2
- .byte 0xFF, 3, 1, 4
- .byte 2, 0xFF, 1, 4
- .byte 0xFF, 0xFF, 2, 6
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 4, 0xFF
-
-gUnknown_083B58A4:: @ 83B58A4
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 0xFF, 6
- .byte 0xFF, 0xFF, 0xFF, 0xFF
- .byte 0xFF, 0xFF, 4, 0xFF
-
- .align 2
-gUnknown_083B58C0:: @ 83B58C0
- .4byte DexText_HoennDex2, DexText_HoennDex
- .4byte DexText_NationalDex2, DexText_NationalDex
- .4byte 0x0, 0x0
-
- .align 2
-gUnknown_083B58D8:: @ 83B58D8
- .4byte DexText_ListByNumber, DexText_NumericalMode
- .4byte DexText_ListByABC2, DexText_ABCMode
- .4byte DexText_ListByHeavyToLightest, DexText_HeaviestMode
- .4byte DexText_ListByLightToHeaviest, DexText_LightestMode
- .4byte DexText_ListByTallToSmallest, DexText_TallestMode
- .4byte DexText_ListBySmallToTallest, DexText_SmallestMode
- .4byte 0x0, 0x0
-
- .align 2
-gUnknown_083B5910:: @ 83B5910
- .4byte DexText_Terminator5, DexText_DontSpecify
- .4byte DexText_Terminator5, DexText_ABC
- .4byte DexText_Terminator5, DexText_DEF
- .4byte DexText_Terminator5, DexText_GHI
- .4byte DexText_Terminator5, DexText_JKL
- .4byte DexText_Terminator5, DexText_MNO
- .4byte DexText_Terminator5, DexText_PQR
- .4byte DexText_Terminator5, DexText_STU
- .4byte DexText_Terminator5, DexText_VWX
- .4byte DexText_Terminator5, DexText_YZ
- .4byte 0x0, 0x0
-
- .align 2
-gUnknown_083B5968:: @ 83B5968
- .4byte DexText_Terminator5, DexText_DontSpecify
- .4byte DexText_Terminator5, DexText_Red
- .4byte DexText_Terminator5, DexText_Blue
- .4byte DexText_Terminator5, DexText_Yellow
- .4byte DexText_Terminator5, DexText_Green
- .4byte DexText_Terminator5, DexText_Black
- .4byte DexText_Terminator5, DexText_Brown
- .4byte DexText_Terminator5, DexText_Purple
- .4byte DexText_Terminator5, DexText_Gray
- .4byte DexText_Terminator5, DexText_White
- .4byte DexText_Terminator5, DexText_Pink
- .4byte 0x0, 0x0
-
- .align 2
-gUnknown_083B59C8:: @ 83B59C8
- .4byte DexText_Terminator5, DexText_None
- .4byte DexText_Terminator5, gTypeNames + TYPE_NORMAL * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_FIGHTING * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_FLYING * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_POISON * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_GROUND * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_ROCK * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_BUG * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_GHOST * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_STEEL * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_FIRE * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_WATER * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_GRASS * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_ELECTRIC * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_PSYCHIC * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_ICE * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_DRAGON * 7
- .4byte DexText_Terminator5, gTypeNames + TYPE_DARK * 7
- .4byte 0x0, 0x0
-
-gUnknown_083B5A60:: @ 83B5A60
- .byte 0, 1
-
-gUnknown_083B5A62:: @ 83B5A62
- .byte 0, 1, 2, 3, 4, 5
-
-gUnknown_083B5A68:: @ 83B5A68
- .byte -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17
-
- .align 2
-gUnknown_083B5A7C:: @ 83B5A7C
- .4byte gUnknown_083B5910
- .byte 6, 7, 10, 0
- .4byte gUnknown_083B5968
- .byte 8, 9, 11, 0
- .4byte gUnknown_083B59C8
- .byte 10, 11, 18, 0
- .4byte gUnknown_083B59C8
- .byte 12, 13, 18, 0
- .4byte gUnknown_083B58D8
- .byte 4, 5, 6, 0
- .4byte gUnknown_083B58C0
- .byte 2, 3, 2, 0
-
-gUnknown_083B5AAC:: @ 83B5AAC
- .string "{STR_VAR_1}{CLEAR_TO 43}$"
-
-gUnknown_083B5AB2:: @ 83B5AB2
- .string "{STR_VAR_1}{CLEAR_TO 96}$"
diff --git a/data/pokedex_entries.inc b/data/pokedex_entries.inc
deleted file mode 100644
index f1c206e3c..000000000
--- a/data/pokedex_entries.inc
+++ /dev/null
@@ -1,4164 +0,0 @@
-DexDescription_Dummy_1:
- .string "This is a newly discovered POKéMON.\nIt is currently under investigation.$"
-DexDescription_Dummy_2:
- .string "No detailed information is available\nat this time.$"
-
-DexDescription_Bulbasaur_1:
- .string "BULBASAUR can be seen napping in\nbright sunlight.\nThere is a seed on its back.$"
-DexDescription_Bulbasaur_2:
- .string "By soaking up the sun’s rays, the seed\ngrows progressively larger.$"
-
-DexDescription_Ivysaur_1:
- .string "There is a bud on this POKéMON’s back.\nTo support its weight, IVYSAUR’s legs\nand trunk grow thick and strong.$"
-DexDescription_Ivysaur_2:
- .string "If it starts spending more time lying\nin the sunlight, it’s a sign that the\nbud will bloom into a large flower soon.$"
-
-DexDescription_Venusaur_1:
- .string "There is a large flower on VENUSAUR’s\nback. The flower is said to take on vivid\ncolors if it gets plenty of nutrition$"
-DexDescription_Venusaur_2:
- .string "and sunlight. The flower’s aroma\nsoothes the emotions of people.$"
-
-DexDescription_Charmander_1:
- .string "The flame that burns at the tip of its\ntail is an indication of its emotions.\nThe flame wavers when CHARMANDER is$"
-DexDescription_Charmander_2:
- .string "enjoying itself. If the POKéMON becomes\nenraged, the flame burns fiercely.$"
-
-DexDescription_Charmeleon_1:
- .string "CHARMELEON mercilessly destroys its\nfoes using its sharp claws.\nIf it encounters a strong foe, it turns$"
-DexDescription_Charmeleon_2:
- .string "aggressive. In this excited state, the\nflame at the tip of its tail flares with a\nbluish white color.$"
-
-DexDescription_Charizard_1:
- .string "CHARIZARD flies around the sky in\nsearch of powerful opponents.\nIt breathes fire of such great heat$"
-DexDescription_Charizard_2:
- .string "that it melts anything. However, it\nnever turns its fiery breath on any\nopponent weaker than itself.$"
-
-DexDescription_Squirtle_1:
- .string "SQUIRTLE’s shell is not merely used\nfor protection.\nThe shell’s rounded shape and the$"
-DexDescription_Squirtle_2:
- .string "grooves on its surface help minimize\nresistance in water, enabling this\nPOKéMON to swim at high speeds.$"
-
-DexDescription_Wartortle_1:
- .string "Its tail is large and covered with a rich,\nthick fur. The tail becomes increasingly\ndeeper in color as WARTORTLE ages.$"
-DexDescription_Wartortle_2:
- .string "The scratches on its shell are evidence\nof this POKéMON’s toughness as a\nbattler.$"
-
-DexDescription_Blastoise_1:
- .string "BLASTOISE has water spouts that\nprotrude from its shell. The water\nspouts are very accurate.$"
-DexDescription_Blastoise_2:
- .string "They can shoot bullets of water with\nenough accuracy to strike empty cans\nfrom a distance of over 160 feet.$"
-
-DexDescription_Caterpie_1:
- .string "CATERPIE has a voracious appetite.\nIt can devour leaves bigger than its\nbody right before your eyes.$"
-DexDescription_Caterpie_2:
- .string "From its antenna, this POKéMON releases\na terrifically strong odor.$"
-
-DexDescription_Metapod_1:
- .string "The shell covering this POKéMON’s body\nis as hard as an iron slab.\nMETAPOD does not move very much.$"
-DexDescription_Metapod_2:
- .string "It stays still because it is preparing\nits soft innards for evolution inside\nthe hard shell.$"
-
-DexDescription_Butterfree_1:
- .string "BUTTERFREE has a superior ability to\nsearch for delicious honey from\nflowers.$"
-DexDescription_Butterfree_2:
- .string "It can even search out, extract, and\ncarry honey from flowers that are\nblooming over six miles from its nest.$"
-
-DexDescription_Weedle_1:
- .string "WEEDLE has an extremely acute sense\nof smell.\nIt is capable of distinguishing its$"
-DexDescription_Weedle_2:
- .string "favorite kinds of leaves from those it\ndislikes just by sniffing with its big\nred proboscis (nose).$"
-
-DexDescription_Kakuna_1:
- .string "KAKUNA remains virtually immobile as it\nclings to a tree. However, on the\ninside, it is extremely busy as it$"
-DexDescription_Kakuna_2:
- .string "prepares for its coming evolution.\nThis is evident from how hot the shell\nbecomes to the touch.$"
-
-DexDescription_Beedrill_1:
- .string "BEEDRILL is extremely territorial.\nNo one should ever approach its nest -\nthis is for their own safety.$"
-DexDescription_Beedrill_2:
- .string "If angered, they will attack in a furious\nswarm.$"
-
-DexDescription_Pidgey_1:
- .string "PIDGEY has an extremely sharp sense\nof direction.\nIt is capable of unerringly returning$"
-DexDescription_Pidgey_2:
- .string "home to its nest, however far it may be\nremoved from its familiar surroundings.$"
-
-DexDescription_Pidgeotto_1:
- .string "PIDGEOTTO claims a large area as its\nown territory. This POKéMON flies\naround, patrolling its living space.$"
-DexDescription_Pidgeotto_2:
- .string "If its territory is violated, it shows\nno mercy in thoroughly punishing the\nfoe with its sharp claws.$"
-
-DexDescription_Pidgeot_1:
- .string "This POKéMON has a dazzling plumage of\nbeautifully glossy feathers.\nMany TRAINERS are captivated by the$"
-DexDescription_Pidgeot_2:
- .string "striking beauty of the feathers on its\nhead, compelling them to choose PIDGEOT\nas their POKéMON.$"
-
-DexDescription_Rattata_1:
- .string "RATTATA is cautious in the extreme.\nEven while it is asleep, it constantly\nlistens by moving its ears around.$"
-DexDescription_Rattata_2:
- .string "It is not picky about where it lives -\nit will make its nest anywhere.$"
-
-DexDescription_Raticate_1:
- .string "RATICATE’s sturdy fangs grow steadily.\nTo keep them ground down, it gnaws\non rocks and logs.$"
-DexDescription_Raticate_2:
- .string "It may even chew on the walls of\nhouses.$"
-
-DexDescription_Spearow_1:
- .string "SPEAROW has a very loud cry that can\nbe heard over half a mile away.\nIf its high, keening cry is heard$"
-DexDescription_Spearow_2:
- .string "echoing all around, it is a sign that\nthey are warning each other of danger.$"
-
-DexDescription_Fearow_1:
- .string "FEAROW is recognized by its long neck\nand elongated beak.\nThey are conveniently shaped for$"
-DexDescription_Fearow_2:
- .string "catching prey in soil or water.\nIt deftly moves its long and skinny\nbeak to pluck prey.$"
-
-DexDescription_Ekans_1:
- .string "EKANS curls itself up in a spiral while\nit rests.\nAssuming this position allows it to$"
-DexDescription_Ekans_2:
- .string "quickly respond to a threat from any\ndirection with a glare from its upraised\nhead.$"
-
-DexDescription_Arbok_1:
- .string "This POKéMON is terrifically strong in\norder to constrict things with its body.\nIt can even flatten steel oil drums.$"
-DexDescription_Arbok_2:
- .string "Once ARBOK wraps its body around its\nfoe, escaping its crunching embrace is\nimpossible.$"
-
- .ifdef SAPPHIRE
-DexDescription_Pikachu_1:
- .string "This POKéMON has electricity-storing\npouches on its cheeks. These appear to\nbecome electrically charged during the$"
-DexDescription_Pikachu_2:
- .string "night while PIKACHU sleeps.\nIt occasionally discharges electricity\nwhen it is dozy after waking up.$"
- .else
-DexDescription_Pikachu_1:
- .string "Whenever PIKACHU comes across\nsomething new, it blasts it with a jolt\nof electricity.$"
-DexDescription_Pikachu_2:
- .string "If you come across a blackened berry,\nit’s evidence that this POKéMON\nmistook the intensity of its charge.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Raichu_1:
- .string "This POKéMON exudes a weak electrical\ncharge from all over its body that makes\nit take on a slight glow in darkness.$"
-DexDescription_Raichu_2:
- .string "RAICHU searches for electricity by\nplanting its tail in the ground.$"
- .else
-DexDescription_Raichu_1:
- .string "If the electrical sacks become\nexcessively charged, RAICHU plants its\ntail in the ground and discharges.$"
-DexDescription_Raichu_2:
- .string "Scorched patches of ground will be\nfound near this POKéMON’s nest.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sandshrew_1:
- .string "SANDSHREW has a very dry hide that is\nextremely tough. The POKéMON can roll\ninto a ball that repels any attack.$"
-DexDescription_Sandshrew_2:
- .string "At night, it burrows into the desert\nsand to sleep.$"
- .else
-DexDescription_Sandshrew_1:
- .string "SANDSHREW’s body is configured to\nabsorb water without waste, enabling it\nto survive in an arid desert.$"
-DexDescription_Sandshrew_2:
- .string "This POKéMON curls up to protect itself\nfrom its enemies.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sandslash_1:
- .string "SANDSLASH can roll up its body as if it\nwere a ball covered with large spikes.\nIn battle, this POKéMON will try to make$"
-DexDescription_Sandslash_2:
- .string "the foe flinch by jabbing it with its\nspines. It then leaps at the stunned\nfoe to tear wildly with its sharp claws.$"
- .else
-DexDescription_Sandslash_1:
- .string "SANDSLASH’s body is covered by tough\nspikes, which are hardened sections of\nits hide. Once a year, the old spikes fall$"
-DexDescription_Sandslash_2:
- .string "out, to be replaced with new spikes that\ngrow out from beneath the old ones.$"
- .endif
-
-DexDescription_NidoranF_1:
- .string "NIDORAN has barbs that secrete a\npowerful poison. They are thought to\nhave developed as protection for this$"
-DexDescription_NidoranF_2:
- .string "small-bodied POKéMON.\nWhen enraged, it releases a horrible\ntoxin from its horn.$"
-
-DexDescription_Nidorina_1:
- .string "When NIDORINA are with their friends or\nfamily, they keep their barbs tucked\naway to prevent hurting each other.$"
-DexDescription_Nidorina_2:
- .string "This POKéMON appears to become\nnervous if separated from the others.$"
-
-DexDescription_Nidoqueen_1:
- .string "NIDOQUEEN’s body is encased in\nextremely hard scales. It is adept at\nsending foes flying with harsh tackles.$"
-DexDescription_Nidoqueen_2:
- .string "This POKéMON is at its strongest when\nit is defending its young.$"
-
-DexDescription_NidoranM_1:
- .string "The male NIDORAN has developed\nmuscles for moving its ears. Thanks to\nthem, the ears can be freely moved in$"
-DexDescription_NidoranM_2:
- .string "any direction. Even the slightest sound\ndoes not escape this POKéMON’s notice.$"
-
-DexDescription_Nidorino_1:
- .string "NIDORINO has a horn that is harder than\na diamond. If it senses a hostile\npresence, all the barbs on its back$"
-DexDescription_Nidorino_2:
- .string "bristle up at once, and it challenges\nthe foe with all its might.$"
-
-DexDescription_Nidoking_1:
- .string "NIDOKING’s thick tail packs enormously\ndestructive power. With one swing, it\ncan topple a metal transmission tower.$"
-DexDescription_Nidoking_2:
- .string "Once this POKéMON goes on a rampage,\nthere is no stopping it.$"
-
-DexDescription_Clefairy_1:
- .string "On every night of a full moon, groups of\nthis POKéMON come out to play.\nWhen dawn arrives, the tired CLEFAIRY$"
-DexDescription_Clefairy_2:
- .string "return to their quiet mountain retreats\nand go to sleep nestled up against each\nother.$"
-
-DexDescription_Clefable_1:
- .string "CLEFABLE moves by skipping lightly as if\nit were flying using its wings. Its\nbouncy step lets it even walk on water.$"
-DexDescription_Clefable_2:
- .string "It is known to take strolls on lakes on\nquiet, moonlit nights.$"
-
- .ifdef SAPPHIRE
-DexDescription_Vulpix_1:
- .string "Inside VULPIX’s body burns a flame that\nnever goes out. During the daytime,\nwhen the temperatures rise, this$"
-DexDescription_Vulpix_2:
- .string "POKéMON releases flames from its mouth\nto prevent its body from growing too\nhot.$"
- .else
-DexDescription_Vulpix_1:
- .string "At the time of its birth, VULPIX has one\nwhite tail. The tail separates into six\nif this POKéMON receives plenty of love$"
-DexDescription_Vulpix_2:
- .string "from its TRAINER.\nThe six tails become magnificently\ncurled.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Ninetales_1:
- .string "Legend has it that NINETALES came into\nbeing when nine wizards possessing\nsacred powers merged into one.$"
-DexDescription_Ninetales_2:
- .string "This POKéMON is highly intelligent - it\ncan understand human speech.$"
- .else
-DexDescription_Ninetales_1:
- .string "NINETALES casts a sinister light from\nits bright red eyes to gain total\ncontrol over its foe’s mind.$"
-DexDescription_Ninetales_2:
- .string "This POKéMON is said to live for a\nthousand years.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Jigglypuff_1:
- .string "When this POKéMON sings, it never\npauses to breathe. If it is in a battle\nagainst an opponent that does not$"
-DexDescription_Jigglypuff_2:
- .string "easily fall asleep, JIGGLYPUFF cannot\nbreathe, endangering its life.$"
- .else
-DexDescription_Jigglypuff_1:
- .string "JIGGLYPUFF’s vocal chords can freely\nadjust the wavelength of its voice.\nThis POKéMON uses this ability to sing$"
-DexDescription_Jigglypuff_2:
- .string "at precisely the right wavelength to\nmake its foes most drowsy.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wigglytuff_1:
- .string "WIGGLYTUFF’s body is very flexible.\nBy inhaling deeply, this POKéMON can\ninflate itself seemingly without end.$"
-DexDescription_Wigglytuff_2:
- .string "Once inflated, WIGGLYTUFF bounces\nalong lightly like a balloon.$"
- .else
-DexDescription_Wigglytuff_1:
- .string "WIGGLYTUFF has large, saucerlike eyes.\nThe surfaces of its eyes are always\ncovered with a thin layer of tears.$"
-DexDescription_Wigglytuff_2:
- .string "If any dust gets in this POKéMON’s\neyes, it is quickly washed away.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Zubat_1:
- .string "ZUBAT avoids sunlight because exposure\ncauses it to become unhealthy.\nDuring the daytime, it stays in caves or$"
-DexDescription_Zubat_2:
- .string "under the eaves of old houses, sleeping\nwhile hanging upside down.$"
- .else
-DexDescription_Zubat_1:
- .string "ZUBAT remains quietly unmoving in a\ndark spot during the bright daylight\nhours. It does so because prolonged$"
-DexDescription_Zubat_2:
- .string "exposure to the sun causes its body to\nbecome slightly burned.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Golbat_1:
- .string "GOLBAT bites down on prey with its four\nfangs and drinks the victim’s blood.\nIt becomes active on inky dark$"
-DexDescription_Golbat_2:
- .string "moonless nights, flying around to\nattack people and POKéMON.$"
- .else
-DexDescription_Golbat_1:
- .string "GOLBAT loves to drink the blood of\nliving things. It is particularly active\nin the pitch black of night.$"
-DexDescription_Golbat_2:
- .string "This POKéMON flits around in the night\nskies, seeking fresh blood.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Oddish_1:
- .string "ODDISH searches for fertile, nutrient-\nrich soil, then plants itself.\nDuring the daytime, while it is planted,$"
-DexDescription_Oddish_2:
- .string "this POKéMON’s feet are thought to\nchange shape and become similar to\nthe roots of trees.$"
- .else
-DexDescription_Oddish_1:
- .string "During the daytime, ODDISH buries\nitself in soil to absorb nutrients from \nthe ground using its entire body.$"
-DexDescription_Oddish_2:
- .string "The more fertile the soil, the glossier\nits leaves become.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Gloom_1:
- .string "From its mouth GLOOM drips honey that\nsmells absolutely horrible.\nApparently, it loves the horrid stench.$"
-DexDescription_Gloom_2:
- .string "It sniffs the noxious fumes and then \ndrools even more of its honey.$"
- .else
-DexDescription_Gloom_1:
- .string "GLOOM releases a foul fragrance from\nthe pistil of its flower. When faced\nwith danger, the stench worsens.$"
-DexDescription_Gloom_2:
- .string "If this POKéMON is feeling calm and\nsecure, it does not release its usual\nstinky aroma.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Vileplume_1:
- .string "VILEPLUME has the world’s largest\npetals. They are used to attract prey\nthat are then doused with toxic spores.$"
-DexDescription_Vileplume_2:
- .string "Once the prey are immobilized, this\nPOKéMON catches and devours them.$"
- .else
-DexDescription_Vileplume_1:
- .string "VILEPLUME’s toxic pollen triggers\natrocious allergy attacks. That’s why\nit is advisable never to approach any$"
-DexDescription_Vileplume_2:
- .string "attractive flowers in a jungle, however\npretty they may be.$"
- .endif
-
- .ifdef SAPPHIRE
-
- .if REVISION >= 1
-DexDescription_Paras_1:
- .string "PARAS has parasitic mushrooms growing\non its back called tochukaso. They grow\nlarge by drawing nutrients from this$"
-DexDescription_Paras_2:
- .string "BUG/GRASS POKéMON host. They are\nhighly valued as a medicine for\nextending life.$"
- .else
-DexDescription_Paras_1:
- .string "PARAS has parasitic mushrooms growing\non its back called tochukaso. They grow\nlarge by drawing nutrients from this$"
-DexDescription_Paras_2:
- .string "BUG POKéMON host. They are highly\nvalued as a medicine for extending life.$"
- .endif @ REVISION >= 1
-
- .else
-
- .if REVISION >= 1
-DexDescription_Paras_1:
- .string "PARAS has parasitic mushrooms growing\non its back called tochukaso. They grow\nlarge by drawing nutrients from this$"
-DexDescription_Paras_2:
- .string "BUG/GRASS POKéMON host. They are\nhighly valued as a medicine for\nextending life.$"
- .else
-DexDescription_Paras_1:
- .string "PARAS has parasitic mushrooms growing\non its back called tochukaso. They grow\nlarge by drawing nutrients from the BUG$"
-DexDescription_Paras_2:
- .string "POKéMON host. They are highly valued as\na medicine for extending life.$"
- .endif @ REVISION >= 1
-
- .endif @ SAPPHIRE
-
-DexDescription_Parasect_1:
- .string "PARASECT is known to infest large trees\nen masse and drain nutrients from the\nlower trunk and roots.$"
-DexDescription_Parasect_2:
- .string "When an infested tree dies, they move\nonto another tree all at once.$"
-
-DexDescription_Venonat_1:
- .string "VENONAT is said to have evolved with\na coat of thin, stiff hair that covers\nits entire body for protection.$"
-DexDescription_Venonat_2:
- .string "It possesses large eyes that never fail\nto spot even miniscule prey.$"
-
-DexDescription_Venomoth_1:
- .string "VENOMOTH is nocturnal - it is a POKéMON\nthat only becomes active at night.\nIts favorite prey are small insects$"
-DexDescription_Venomoth_2:
- .string "that gather around streetlights,\nattracted by the light in the darkness.$"
-
-DexDescription_Diglett_1:
- .string "DIGLETT are raised in most farms.\nThe reason is simple - wherever this\nPOKéMON burrows, the soil is left$"
-DexDescription_Diglett_2:
- .string "perfectly tilled for planting crops.\nThis soil is made ideal for growing\ndelicious vegetables.$"
-
-DexDescription_Dugtrio_1:
- .string "DUGTRIO are actually triplets that\nemerged from one body. As a result,\neach triplet thinks exactly like the$"
-DexDescription_Dugtrio_2:
- .string "other two triplets.\nThey work cooperatively to burrow\nendlessly.$"
-
-DexDescription_Meowth_1:
- .string "MEOWTH withdraws its sharp claws into\nits paws to slinkily sneak about without\nmaking any incriminating footsteps.$"
-DexDescription_Meowth_2:
- .string "For some reason, this POKéMON loves\nshiny coins that glitter with light.$"
-
-DexDescription_Persian_1:
- .string "PERSIAN has six bold whiskers that give\nit a look of toughness. The whiskers \nsense air movements to determine what$"
-DexDescription_Persian_2:
- .string "is in the POKéMON’s surrounding\nvicinity. It becomes docile if grabbed\nby the whiskers.$"
-
- .ifdef SAPPHIRE
-DexDescription_Psyduck_1:
- .string "If it uses its mysterious power,\nPSYDUCK can’t remember having done so.\nIt apparently can’t form a memory of$"
-DexDescription_Psyduck_2:
- .string "such an event because it goes into\nan altered state that is much like\ndeep sleep.$"
- .else
-DexDescription_Psyduck_1:
- .string "PSYDUCK uses a mysterious power.\nWhen it does so, this POKéMON \ngenerates brain waves that are$"
-DexDescription_Psyduck_2:
- .string "supposedly only seen in sleepers.\nThis discovery spurred controversy\namong scholars.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Golduck_1:
- .string "GOLDUCK is the fastest swimmer among\nall POKéMON. It swims effortlessly, even\nin a rough, stormy sea.$"
-DexDescription_Golduck_2:
- .string "It sometimes rescues people from\nwrecked ships floundering in high seas.$"
- .else
-DexDescription_Golduck_1:
- .string "The webbed flippers on its forelegs and\nhind legs and the streamlined body of\nGOLDUCK give it frightening speed.$"
-DexDescription_Golduck_2:
- .string "This POKéMON is definitely much faster\nthan even the most athletic swimmer.$"
- .endif
-
-DexDescription_Mankey_1:
- .string "When MANKEY starts shaking and its\nnasal breathing turns rough, it’s a sure\nsign that it is becoming angry.$"
-DexDescription_Mankey_2:
- .string "However, because it goes into a\ntowering rage almost instantly, it is\nimpossible for anyone to flee its wrath.$"
-
-DexDescription_Primeape_1:
- .string "When PRIMEAPE becomes furious, its\nblood circulation is boosted. In turn,\nits muscles are made even stronger.$"
-DexDescription_Primeape_2:
- .string "However, it also becomes much less\nintelligent at the same time.$"
-
-DexDescription_Growlithe_1:
- .string "GROWLITHE has a superb sense of smell.\nOnce it smells anything, this POKéMON\nwon’t forget the scent, no matter what.$"
-DexDescription_Growlithe_2:
- .string "It uses its advanced olfactory sense\nto determine the emotions of other\nliving things.$"
-
-DexDescription_Arcanine_1:
- .string "ARCANINE is known for its high speed.\nIt is said to be capable of running over\n6,200 miles in a single day and night.$"
-DexDescription_Arcanine_2:
- .string "The fire that blazes wildly within this\nPOKéMON’s body is its source of power.$"
-
-DexDescription_Poliwag_1:
- .string "POLIWAG has a very thin skin. It is\npossible to see the POKéMON’s spiral\ninnards right through the skin.$"
-DexDescription_Poliwag_2:
- .string "Despite its thinness, however, the skin\nis also very flexible. Even sharp fangs\nbounce right off it.$"
-
-DexDescription_Poliwhirl_1:
- .string "The surface of POLIWHIRL’s body is\nalways wet and slick with an oily fluid.\nBecause of this greasy covering, it can$"
-DexDescription_Poliwhirl_2:
- .string "easily slip and slide out of the clutches\nof any enemy in battle.$"
-
-DexDescription_Poliwrath_1:
- .string "POLIWRATH’s highly developed, brawny\nmuscles never grow fatigued, however\nmuch it exercises.$"
-DexDescription_Poliwrath_2:
- .string "It is so tirelessly strong, this POKéMON\ncan swim back and forth across the\nPacific Ocean without effort.$"
-
- .ifdef SAPPHIRE
-DexDescription_Abra_1:
- .string "ABRA needs to sleep for eighteen hours\na day. If it doesn’t, this POKéMON loses\nits ability to use telekinetic powers.$"
-DexDescription_Abra_2:
- .string "If it is attacked, ABRA escapes using\nTELEPORT while it is still sleeping.$"
- .else
-DexDescription_Abra_1:
- .string "ABRA sleeps for eighteen hours a day.\nHowever, it can sense the presence of\nfoes even while it is sleeping.$"
-DexDescription_Abra_2:
- .string "In such a situation, this POKéMON\nimmediately teleports to safety.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Kadabra_1:
- .string "KADABRA holds a silver spoon in its\nhand. The spoon is used to amplify the\nalpha waves in its brain.$"
-DexDescription_Kadabra_2:
- .string "Without the spoon, the POKéMON is said\nto be limited to half the usual amount\nof its telekinetic powers.$"
- .else
-DexDescription_Kadabra_1:
- .string "KADABRA emits a peculiar alpha wave\nif it develops a headache. Only those\npeople with a particularly strong$"
-DexDescription_Kadabra_2:
- .string "psyche can hope to become a TRAINER\nof this POKéMON.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Alakazam_1:
- .string "ALAKAZAM’s brain continually grows,\ninfinitely multiplying brain cells.\nThis amazing brain gives this POKéMON$"
-DexDescription_Alakazam_2:
- .string "an astoundingly high IQ of 5,000.\nIt has a thorough memory of everything\nthat has occurred in the world.$"
- .else
-DexDescription_Alakazam_1:
- .string "ALAKAZAM’s brain continually grows,\nmaking its head far too heavy to\nsupport with its neck.$"
-DexDescription_Alakazam_2:
- .string "This POKéMON holds its head up using\nits psychokinetic power instead.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Machop_1:
- .string "MACHOP exercises by hefting around\na GRAVELER as if it were a barbell.\nThere are some MACHOP that travel$"
-DexDescription_Machop_2:
- .string "the world in a quest to master all\nkinds of martial arts.$"
- .else
-DexDescription_Machop_1:
- .string "MACHOP’s muscles are special - they\nnever get sore no matter how much they\nare used in exercise.$"
-DexDescription_Machop_2:
- .string "This POKéMON has sufficient power to\nhurl a hundred adult humans.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Machoke_1:
- .string "MACHOKE undertakes bodybuilding every\nday even as it helps people with tough,\nphysically demanding labor.$"
-DexDescription_Machoke_2:
- .string "On its days off, this POKéMON heads to\nthe fields and mountains to exercise\nand train.$"
- .else
-DexDescription_Machoke_1:
- .string "MACHOKE’s thoroughly toned muscles\npossess the hardness of steel.\nThis POKéMON has so much strength,$"
-DexDescription_Machoke_2:
- .string "it can easily hold aloft a sumo wrestler\non just one finger.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Machamp_1:
- .string "MACHAMP is known as the POKéMON that\nhas mastered every kind of martial arts.\nIf it grabs hold of the foe with its four$"
-DexDescription_Machamp_2:
- .string "arms, the battle is all but over.\nThe hapless foe is thrown far over the\nhorizon.$"
- .else
-DexDescription_Machamp_1:
- .string "MACHAMP has the power to hurl anything\naside. However, trying to do any work\nrequiring care and dexterity causes$"
-DexDescription_Machamp_2:
- .string "its arms to get tangled.\nThis POKéMON tends to leap into action\nbefore it thinks.$"
- .endif
-
-DexDescription_Bellsprout_1:
- .string "BELLSPROUT’s thin and flexible body\nlets it bend and sway to avoid any\nattack, however strong it may be.$"
-DexDescription_Bellsprout_2:
- .string "From its mouth, this POKéMON spits a\ncorrosive fluid that melts even iron.$"
-
-DexDescription_Weepinbell_1:
- .string "WEEPINBELL has a large hook on its rear\nend. At night, the POKéMON hooks on to\na tree branch and goes to sleep.$"
-DexDescription_Weepinbell_2:
- .string "If it moves around in its sleep, it may\nwake up to find itself on the ground.$"
-
-DexDescription_Victreebel_1:
- .string "VICTREEBEL has a long vine that\nextends from its head. This vine is\nwaved and flicked about as if it were$"
-DexDescription_Victreebel_2:
- .string "an animal to attract prey. When an\nunsuspecting prey draws near, this\nPOKéMON swallows it whole.$"
-
- .ifdef SAPPHIRE
-DexDescription_Tentacool_1:
- .string "TENTACOOL absorbs sunlight and\nrefracts it using water inside its body\nto convert it into beam energy.$"
-DexDescription_Tentacool_2:
- .string "This POKéMON shoots beams from its\ncrystal-like eyes.$"
- .else
-DexDescription_Tentacool_1:
- .string "TENTACOOL’s body is largely composed\nof water. If it is removed from the\nsea, it dries up like parchment.$"
-DexDescription_Tentacool_2:
- .string "If this POKéMON happens to become\ndehydrated, put it back into the sea.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Tentacruel_1:
- .string "TENTACRUEL has tentacles that can be\nfreely elongated and shortened at will.\nIt ensnares prey with its tentacles and$"
-DexDescription_Tentacruel_2:
- .string "weakens the prey by dosing it with a\nharsh toxin. It can catch up to 80\nprey at the same time.$"
- .else
-DexDescription_Tentacruel_1:
- .string "TENTACRUEL has large red orbs on its\nhead. The orbs glow before lashing the\nvicinity with a harsh ultrasonic blast.$"
-DexDescription_Tentacruel_2:
- .string "This POKéMON’s outburst creates rough\nwaves around it.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Geodude_1:
- .string "When GEODUDE sleeps deeply, it buries\nitself halfway into the ground.\nIt will not awaken even if hikers step$"
-DexDescription_Geodude_2:
- .string "on it unwittingly.\nIn the morning, this POKéMON rolls\ndownhill in search of food.$"
- .else
-DexDescription_Geodude_1:
- .string "The longer a GEODUDE lives, the more\nits edges are chipped and worn away,\nmaking it more rounded in appearance.$"
-DexDescription_Geodude_2:
- .string "However, this POKéMON’s heart will\nremain hard, craggy, and rough always.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Graveler_1:
- .string "Rocks are GRAVELER’s favorite food.\nThis POKéMON will climb a mountain from\nthe base to the summit, crunchingly$"
-DexDescription_Graveler_2:
- .string "feasting on rocks all the while.\nUpon reaching the peak, it rolls back\ndown to the bottom.$"
- .else
-DexDescription_Graveler_1:
- .string "GRAVELER grows by feeding on rocks.\nApparently, it prefers to eat rocks\nthat are covered in moss.$"
-DexDescription_Graveler_2:
- .string "This POKéMON eats its way through\na ton of rocks on a daily basis.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Golem_1:
- .string "GOLEM is known for rolling down from\nmountains. To prevent them from rolling\ninto the homes of people downhill,$"
-DexDescription_Golem_2:
- .string "grooves have been dug into the sides of\nmountains to serve as guideways for\ndiverting this POKéMON’s course.$"
- .else
-DexDescription_Golem_1:
- .string "GOLEM live up on mountains.\nIf there is a large earthquake, these\nPOKéMON will come rolling down off$"
-DexDescription_Golem_2:
- .string "the mountains en masse to the\nfoothills below.$"
- .endif
-
-DexDescription_Ponyta_1:
- .string "PONYTA is very weak at birth.\nIt can barely stand up.\nThis POKéMON becomes stronger by$"
-DexDescription_Ponyta_2:
- .string "stumbling and falling to keep up with\nits parent.$"
-
-DexDescription_Rapidash_1:
- .string "RAPIDASH usually can be seen casually\ncantering in the fields and plains.\nHowever, when this POKéMON turns$"
-DexDescription_Rapidash_2:
- .string "serious, its fiery manes flare and blaze\nas it gallops its way up to 150 mph.$"
-
-DexDescription_Slowpoke_1:
- .string "SLOWPOKE uses its tail to catch prey by\ndipping it in water at the side of a\nriver.$"
-DexDescription_Slowpoke_2:
- .string "However, this POKéMON often forgets\nwhat it’s doing and often spends entire\ndays just loafing at water’s edge.$"
-
-DexDescription_Slowbro_1:
- .string "SLOWBRO’s tail has a SHELLDER firmly\nattached with a bite. As a result, the\ntail can’t be used for fishing anymore.$"
-DexDescription_Slowbro_2:
- .string "This causes SLOWBRO to grudgingly swim\nand catch prey instead.$"
-
- .ifdef SAPPHIRE
-DexDescription_Magnemite_1:
- .string "MAGNEMITE floats in the air by emitting\nelectromagnetic waves from the units\nat its sides. These waves block gravity.$"
-DexDescription_Magnemite_2:
- .string "This POKéMON becomes incapable of\nflight if its internal electrical supply\nis depleted.$"
- .else
-DexDescription_Magnemite_1:
- .string "MAGNEMITE attaches itself to power\nlines to feed on electricity.\nIf your house has a power outage,$"
-DexDescription_Magnemite_2:
- .string "check your circuit breakers. You may\nfind a large number of this POKéMON\nclinging to the breaker box.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Magneton_1:
- .string "MAGNETON emits a powerful magnetic\nforce that is fatal to electronics and\nprecision instruments. Because of$"
-DexDescription_Magneton_2:
- .string "this, it is said that some towns warn\npeople to keep this POKéMON inside\na POKé BALL.$"
- .else
-DexDescription_Magneton_1:
- .string "MAGNETON emits a powerful magnetic\nforce that is fatal to mechanical\ndevices. As a result, large cities sound$"
-DexDescription_Magneton_2:
- .string "sirens to warn citizens of large-scale\noutbreaks of this POKéMON.$"
- .endif
-
-DexDescription_Farfetchd_1:
- .string "FARFETCH’D is always seen with a stick\nfrom a plant of some sort. Apparently,\nthere are good sticks and bad sticks.$"
-DexDescription_Farfetchd_2:
- .string "This POKéMON has been known to fight\nwith others over sticks.$"
-
- .ifdef SAPPHIRE
-DexDescription_Doduo_1:
- .string "DODUO’s two heads contain completely\nidentical brains.\nA scientific study reported that on$"
-DexDescription_Doduo_2:
- .string "rare occasions, there will be examples\nof this POKéMON possessing different\nsets of brains.$"
- .else
-DexDescription_Doduo_1:
- .string "DODUO’s two heads never sleep at the\nsame time.\nIts two heads take turns sleeping,$"
-DexDescription_Doduo_2:
- .string "so one head can always keep watch for\nenemies while the other one sleeps.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Dodrio_1:
- .string "Apparently, the heads aren’t the only\nparts of the body that DODRIO has\nthree of.$"
-DexDescription_Dodrio_2:
- .string "It has three sets of hearts and lungs\nas well, so it is capable of running long\ndistances without rest.$"
- .else
-DexDescription_Dodrio_1:
- .string "Watch out if DODRIO’s three heads are\nlooking in three separate directions.\nIt’s a sure sign that it is on its guard.$"
-DexDescription_Dodrio_2:
- .string "Don’t go near this POKéMON if it’s being\nwary - it may decide to peck you.$"
- .endif
-
-DexDescription_Seel_1:
- .string "SEEL hunts for prey in the frigid sea\nunderneath sheets of ice.\nWhen it needs to breathe, it punches$"
-DexDescription_Seel_2:
- .string "a hole through the ice with the\nsharply protruding section of its head.$"
-
-DexDescription_Dewgong_1:
- .string "DEWGONG loves to snooze on bitterly\ncold ice.\nThe sight of this POKéMON sleeping on$"
-DexDescription_Dewgong_2:
- .string "a glacier was mistakenly thought to be\na mermaid by a mariner long ago.$"
-
- .ifdef SAPPHIRE
-DexDescription_Grimer_1:
- .string "GRIMER emerged from the sludge that\nsettled on a polluted seabed.\nThis POKéMON loves anything filthy.$"
-DexDescription_Grimer_2:
- .string "It constantly leaks a horribly germ-\ninfested fluid from all over its body.$"
- .else
-DexDescription_Grimer_1:
- .string "GRIMER’s sludgy and rubbery body can\nbe forced through any opening, however\nsmall it may be.$"
-DexDescription_Grimer_2:
- .string "This POKéMON enters sewer pipes to\ndrink filthy wastewater.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Muk_1:
- .string "This POKéMON’s favorite food is\nanything that is repugnantly filthy.\nIn dirty towns where people think$"
-DexDescription_Muk_2:
- .string "nothing of throwing away litter on the\nstreets, MUK are certain to gather.$"
- .else
-DexDescription_Muk_1:
- .string "From MUK’s body seeps a foul fluid that\ngives off a nose-bendingly horrible\nstench.$"
-DexDescription_Muk_2:
- .string "Just one drop of this POKéMON’s body\nfluid can turn a pool stagnant and\nrancid.$"
- .endif
-
-DexDescription_Shellder_1:
- .string "At night, this POKéMON uses its broad\ntongue to burrow a hole in the seafloor\nsand and then sleep in it.$"
-DexDescription_Shellder_2:
- .string "While it is sleeping, SHELLDER closes its\nshell, but leaves its tongue hanging\nout.$"
-
-DexDescription_Cloyster_1:
- .string "CLOYSTER is capable of swimming in the\nsea. It does so by swallowing water,\nthen jetting it out toward the rear.$"
-DexDescription_Cloyster_2:
- .string "This POKéMON shoots spikes from its\nshell using the same system.$"
-
-DexDescription_Gastly_1:
- .string "GASTLY is largely composed of gaseous\nmatter. When exposed to a strong wind,\nthe gaseous body quickly dwindles away.$"
-DexDescription_Gastly_2:
- .string "Groups of this POKéMON cluster under\nthe eaves of houses to escape the\nravages of wind.$"
-
-DexDescription_Haunter_1:
- .string "HAUNTER is a dangerous POKéMON.\nIf one beckons you while floating in\ndarkness, you must never approach it.$"
-DexDescription_Haunter_2:
- .string "This POKéMON will try to lick you with its\ntongue and steal your life away.$"
-
-DexDescription_Gengar_1:
- .string "Sometimes, on a dark night, your shadow\nthrown by a streetlight will suddenly\nand startlingly overtake you.$"
-DexDescription_Gengar_2:
- .string "It is actually a GENGAR running past\nyou, pretending to be your shadow.$"
-
-DexDescription_Onix_1:
- .string "ONIX has a magnet in its brain. It acts\nas a compass so that this POKéMON does\nnot lose direction while it is tunneling.$"
-DexDescription_Onix_2:
- .string "As it grows older, its body becomes\nincreasingly rounder and smoother.$"
-
-DexDescription_Drowzee_1:
- .string "If your nose becomes itchy while you\nare sleeping, it’s a sure sign that one\nof these POKéMON is standing above$"
-DexDescription_Drowzee_2:
- .string "your pillow and trying to eat your dream\nthrough your nostrils.$"
-
-DexDescription_Hypno_1:
- .string "HYPNO holds a pendulum in its hand.\nThe arcing movement and glitter of the\npendulum lull the foe into a deep state$"
-DexDescription_Hypno_2:
- .string "of hypnosis.\nWhile this POKéMON searches for prey,\nit polishes the pendulum.$"
-
-DexDescription_Krabby_1:
- .string "KRABBY live on beaches, burrowed inside\nholes dug into the sand.\nOn sandy beaches with little in the way$"
-DexDescription_Krabby_2:
- .string "of food, these POKéMON can be seen\nsquabbling with each other over\nterritory.$"
-
-DexDescription_Kingler_1:
- .string "KINGLER has an enormous, oversized\nclaw. It waves this huge claw in the\nair to communicate with others.$"
-DexDescription_Kingler_2:
- .string "However, because the claw is so heavy,\nthe POKéMON quickly tires.$"
-
- .ifdef SAPPHIRE
-DexDescription_Voltorb_1:
- .string "VOLTORB is extremely sensitive - it\nexplodes at the slightest of shocks.\nIt is rumored that it was first created$"
-DexDescription_Voltorb_2:
- .string "when a POKé BALL was exposed to a\npowerful pulse of energy.$"
- .else
-DexDescription_Voltorb_1:
- .string "VOLTORB was first sighted at a company\nthat manufactures POKé BALLS.\nThe link between that sighting and$"
-DexDescription_Voltorb_2:
- .string "the fact that this POKéMON looks very\nsimilar to a POKé BALL remains a\nmystery.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Electrode_1:
- .string "One of ELECTRODE’s characteristics is\nits attraction to electricity.\nIt is a problematical POKéMON that$"
-DexDescription_Electrode_2:
- .string "congregates mostly at electrical\npower plants to feed on electricity\nthat has just been generated.$"
- .else
-DexDescription_Electrode_1:
- .string "ELECTRODE eats electricity in the\natmosphere. On days when lightning\nstrikes, you can see this POKéMON$"
-DexDescription_Electrode_2:
- .string "exploding all over the place from\neating too much electricity.$"
- .endif
-
-DexDescription_Exeggcute_1:
- .string "This POKéMON consists of six eggs that\nform a closely knit cluster. The six eggs\nattract each other and spin around.$"
-DexDescription_Exeggcute_2:
- .string "When cracks increasingly appear on the\neggs, EXEGGCUTE is close to evolution.$"
-
-DexDescription_Exeggutor_1:
- .string "EXEGGUTOR originally came from the\ntropics. Its heads steadily grow larger\nfrom exposure to strong sunlight.$"
-DexDescription_Exeggutor_2:
- .string "It is said that when the heads fall off,\nthey group together to form EXEGGCUTE.$"
-
-DexDescription_Cubone_1:
- .string "CUBONE pines for the mother it will\nnever see again. Seeing a likeness of\nits mother in the full moon, it cries.$"
-DexDescription_Cubone_2:
- .string "The stains on the skull the POKéMON\nwears are made by the tears it sheds.$"
-
-DexDescription_Marowak_1:
- .string "MAROWAK is the evolved form of a CUBONE\nthat has overcome its sadness at the\nloss of its mother and grown tough.$"
-DexDescription_Marowak_2:
- .string "This POKéMON’s tempered and hardened\nspirit is not easily broken.$"
-
-DexDescription_Hitmonlee_1:
- .string "HITMONLEE’s legs freely contract and\nstretch. Using these springlike legs, it\nbowls over foes with devastating kicks.$"
-DexDescription_Hitmonlee_2:
- .string "After battle, it rubs down its legs and\nloosens the muscles to overcome\nfatigue.$"
-
-DexDescription_Hitmonchan_1:
- .string "HITMONCHAN is said to possess the\nspirit of a boxer who had been working\ntowards a world championship.$"
-DexDescription_Hitmonchan_2:
- .string "This POKéMON has an indomitable spirit\nand will never give up in the face of\nadversity.$"
-
-DexDescription_Lickitung_1:
- .string "Whenever LICKITUNG comes across\nsomething new, it will unfailingly give it\na lick. It does so because it memorizes$"
-DexDescription_Lickitung_2:
- .string "things by texture and by taste.\nIt is somewhat put off by sour things.$"
-
- .ifdef SAPPHIRE
-DexDescription_Koffing_1:
- .string "KOFFING embodies toxic substances.\nIt mixes the toxins with raw garbage to\nset off a chemical reaction that$"
-DexDescription_Koffing_2:
- .string "results in a terribly powerful poison\ngas. The higher the temperature, the\nmore gas is concocted by this POKéMON.$"
- .else
-DexDescription_Koffing_1:
- .string "If KOFFING becomes agitated, it raises\nthe toxicity of its internal gases and\njets them out from all over its body.$"
-DexDescription_Koffing_2:
- .string "This POKéMON may also overinflate its\nround body, then explode.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Weezing_1:
- .string "WEEZING alternately shrinks and\ninflates its twin bodies to mix together\ntoxic gases inside.$"
-DexDescription_Weezing_2:
- .string "The more the gases are mixed, the more\npowerful the toxins become. The\nPOKéMON also becomes more putrid.$"
- .else
-DexDescription_Weezing_1:
- .string "WEEZING loves the gases given off by\nrotted kitchen garbage. This POKéMON\nwill find a dirty, unkempt house and$"
-DexDescription_Weezing_2:
- .string "make it its home. At night, when the\npeople in the house are asleep, it will\ngo through the trash.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Rhyhorn_1:
- .string "RHYHORN’s brain is very small. It is so\ndense, while on a run it forgets why it\nstarted running in the first place.$"
-DexDescription_Rhyhorn_2:
- .string "It apparently remembers sometimes if it\ndemolishes something.$"
- .else
-DexDescription_Rhyhorn_1:
- .string "RHYHORN runs in a straight line,\nsmashing everything in its path.\nIt is not bothered even if it rushes$"
-DexDescription_Rhyhorn_2:
- .string "headlong into a block of steel.\nThis POKéMON may feel some pain from\nthe collision the next day, however.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Rhydon_1:
- .string "RHYDON has a horn that serves as a\ndrill. It is used for destroying rocks\nand boulders.$"
-DexDescription_Rhydon_2:
- .string "This POKéMON occasionally rams into\nstreams of magma, but the armor-like\nhide prevents it from feeling the heat.$"
- .else
-DexDescription_Rhydon_1:
- .string "RHYDON’s horn can crush even uncut\ndiamonds. One sweeping blow of its tail\ncan topple a building.$"
-DexDescription_Rhydon_2:
- .string "This POKéMON’s hide is extremely tough.\nEven direct cannon hits don’t leave\na scratch.$"
- .endif
-
-DexDescription_Chansey_1:
- .string "CHANSEY lays nutritionally excellent\neggs on an everyday basis.\nThe eggs are so delicious, they are$"
-DexDescription_Chansey_2:
- .string "easily and eagerly devoured by even\nthose people who have lost their\nappetite.$"
-
-DexDescription_Tangela_1:
- .string "TANGELA’s vines snap off easily if they\nare grabbed. This happens without pain,\nallowing it to make a quick getaway.$"
-DexDescription_Tangela_2:
- .string "The lost vines are replaced by newly\ngrown vines the very next day.$"
-
-DexDescription_Kangaskhan_1:
- .string "If you come across a young KANGASKHAN\nplaying by itself, you must never\ndisturb it or attempt to catch it.$"
-DexDescription_Kangaskhan_2:
- .string "The baby POKéMON’s parent is sure to\nbe in the area, and it will become\nviolently enraged at you.$"
-
- .ifdef SAPPHIRE
-DexDescription_Horsea_1:
- .string "If HORSEA senses danger, it will\nreflexively spray a dense black ink\nfrom its mouth and try to escape.$"
-DexDescription_Horsea_2:
- .string "This POKéMON swims by cleverly flapping\nthe fins on its back.$"
- .else
-DexDescription_Horsea_1:
- .string "HORSEA eats small insects and moss off\nof rocks. If the ocean current turns\nfast, this POKéMON anchors itself by$"
-DexDescription_Horsea_2:
- .string "wrapping its tail around rocks or coral\nto prevent being washed away.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Seadra_1:
- .string "SEADRA generates whirlpools by spinning\nits body. The whirlpools are strong\nenough to swallow even fishing boats.$"
-DexDescription_Seadra_2:
- .string "This POKéMON weakens prey with these\ncurrents, then swallows it whole.$"
- .else
-DexDescription_Seadra_1:
- .string "SEADRA sleeps after wriggling itself\nbetween the branches of coral.\nThose trying to harvest coral are$"
-DexDescription_Seadra_2:
- .string "occasionally stung by this POKéMON’s\npoison barbs if they fail to notice it.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Goldeen_1:
- .string "GOLDEEN loves swimming wild and free\nin rivers and ponds.\nIf one of these POKéMON is placed in an$"
-DexDescription_Goldeen_2:
- .string "aquarium, it will shatter even the\nthickest glass with one ram of its horn\nand make its escape.$"
- .else
-DexDescription_Goldeen_1:
- .string "GOLDEEN is a very beautiful POKéMON\nwith fins that billow elegantly in water.\nHowever, don’t let your guard down$"
-DexDescription_Goldeen_2:
- .string "around this POKéMON - it could ram you\npowerfully with its horn.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Seaking_1:
- .string "SEAKING is very protective of its eggs.\nThe male and female will take turns\npatrolling around their nest and eggs.$"
-DexDescription_Seaking_2:
- .string "The guarding of eggs by these POKéMON\ngoes on for over a month.$"
- .else
-DexDescription_Seaking_1:
- .string "In the autumn, SEAKING males can be\nseen performing courtship dances in\nriverbeds to woo females.$"
-DexDescription_Seaking_2:
- .string "During this season, this POKéMON’s body\ncoloration is at its most beautiful.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Staryu_1:
- .string "STARYU apparently communicates with\nthe stars in the night sky by flashing\nthe red core at the center of its body.$"
-DexDescription_Staryu_2:
- .string "If parts of its body are torn, this\nPOKéMON simply regenerates the\nmissing pieces and limbs.$"
- .else
-DexDescription_Staryu_1:
- .string "STARYU’s center section has an organ\ncalled the core that shines bright red.\nIf you go to a beach toward the$"
-DexDescription_Staryu_2:
- .string "end of summer, the glowing cores of\nthese POKéMON look like the stars\nin the sky.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Starmie_1:
- .string "STARMIE swims through water by\nspinning its star-shaped body as if it\nwere a propeller on a ship.$"
-DexDescription_Starmie_2:
- .string "The core at the center of this\nPOKéMON’s body glows in seven colors.$"
- .else
-DexDescription_Starmie_1:
- .string "STARMIE’s center section - the core -\nglows brightly in seven colors.\nBecause of its luminous nature, this$"
-DexDescription_Starmie_2:
- .string "POKéMON has been given the nickname\n“the gem of the sea.”$"
- .endif
-
-DexDescription_Mrmime_1:
- .string "MR. MIME is a master of pantomime.\nIts gestures and motions convince\nwatchers that something unseeable$"
-DexDescription_Mrmime_2:
- .string "actually exists. Once it is believed,\nit will exist as if it were a real thing.$"
-
-DexDescription_Scyther_1:
- .string "SCYTHER is blindingly fast. Its blazing\nspeed enhances the effectiveness of\nthe twin scythes on its forearms.$"
-DexDescription_Scyther_2:
- .string "This POKéMON’s scythes are so\neffective, they can slice through thick\nlogs in one wicked stroke.$"
-
-DexDescription_Jynx_1:
- .string "JYNX walks rhythmically, swaying and\nshaking its hips as if it were dancing.\nIts motions are so bouncingly alluring,$"
-DexDescription_Jynx_2:
- .string "people seeing it are compelled to shake\ntheir hips without giving any thought\nto what they are doing.$"
-
-DexDescription_Electabuzz_1:
- .string "When a storm arrives, gangs of this\nPOKéMON compete with each other to\nscale heights that are likely to be$"
-DexDescription_Electabuzz_2:
- .string "stricken by lightning bolts.\nSome towns use ELECTABUZZ in place of\nlightning rods.$"
-
-DexDescription_Magmar_1:
- .string "In battle, MAGMAR blows out intensely\nhot flames from all over its body to\nintimidate its opponent.$"
-DexDescription_Magmar_2:
- .string "This POKéMON’s fiery bursts create\nheat waves that ignite grass and trees\nin its surroundings.$"
-
- .ifdef SAPPHIRE
-DexDescription_Pinsir_1:
- .string "PINSIR has a pair of massive horns \nProtruding from the surface of these\nhorns are thorns.$"
-DexDescription_Pinsir_2:
- .string "These thorns are driven deeply into the\nfoe’s body when the pincer closes,\nmaking it tough for the foe to escape.$"
- .else
-DexDescription_Pinsir_1:
- .string "PINSIR is astoundingly strong. It can\ngrip a foe weighing twice its weight\nin its horns and easily lift it.$"
-DexDescription_Pinsir_2:
- .string "This POKéMON’s movements turn sluggish\nin cold places.$"
- .endif
-
-DexDescription_Tauros_1:
- .string "This POKéMON is not satisfied unless\nit is rampaging at all times.\nIf there is no opponent for TAUROS to$"
-DexDescription_Tauros_2:
- .string "battle, it will charge at thick trees and\nknock them down to calm itself.$"
-
- .ifdef SAPPHIRE
-DexDescription_Magikarp_1:
- .string "MAGIKARP is virtually useless in battle\nas it can only splash around.\nAs a result, it is considered to be weak.$"
-DexDescription_Magikarp_2:
- .string "However, it is actually a very hardy\nPOKéMON that can survive in any body of\nwater no matter how polluted it is.$"
- .else
-DexDescription_Magikarp_1:
- .string "MAGIKARP is a pathetic excuse for a\nPOKéMON that is only capable of\nflopping and splashing.$"
-DexDescription_Magikarp_2:
- .string "This behavior prompted scientists to\nundertake research into it.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Gyarados_1:
- .string "Once GYARADOS goes on a rampage, its\nferociously violent blood doesn’t calm\nuntil it has burned everything down.$"
-DexDescription_Gyarados_2:
- .string "There are records of this POKéMON’s\nrampages lasting a whole month.$"
- .else
-DexDescription_Gyarados_1:
- .string "When MAGIKARP evolves into GYARADOS,\nits brain cells undergo a structural\ntransformation. It is said that this$"
-DexDescription_Gyarados_2:
- .string "transformation is to blame for this\nPOKéMON’s wildly violent nature.$"
- .endif
-
-DexDescription_Lapras_1:
- .string "People have driven LAPRAS almost to the\npoint of extinction. In the evenings,\nthis POKéMON is said to sing plaintively$"
-DexDescription_Lapras_2:
- .string "as it seeks what few others of its kind\nstill remain.$"
-
-DexDescription_Ditto_1:
- .string "DITTO rearranges its cell structure to\ntransform itself into other shapes.\nHowever, if it tries to transform itself$"
-DexDescription_Ditto_2:
- .string "into something by relying on its memory,\nthis POKéMON manages to get details\nwrong.$"
-
-DexDescription_Eevee_1:
- .string "EEVEE has an unstable genetic makeup\nthat suddenly mutates due to the\nenvironment in which it lives.$"
-DexDescription_Eevee_2:
- .string "Radiation from various STONES causes\nthis POKéMON to evolve.$"
-
-DexDescription_Vaporeon_1:
- .string "VAPOREON underwent a spontaneous\nmutation and grew fins and gills that\nallow it to live underwater.$"
-DexDescription_Vaporeon_2:
- .string "This POKéMON has the ability to freely\ncontrol water.$"
-
-DexDescription_Jolteon_1:
- .string "JOLTEON’s cells generate a low level of\nelectricity. This power is amplified by\nthe static electricity of its fur,$"
-DexDescription_Jolteon_2:
- .string "enabling the POKéMON to drop\nthunderbolts. The bristling fur is made\nof electrically charged needles.$"
-
-DexDescription_Flareon_1:
- .string "FLAREON’s fluffy fur has a functional\npurpose - it releases heat into the air\nso that its body does not get$"
-DexDescription_Flareon_2:
- .string "excessively hot.\nThis POKéMON’s body temperature can\nrise to a maximum of 1,650 degrees F.$"
-
-DexDescription_Porygon_1:
- .string "PORYGON is capable of reverting itself\nentirely back to program data and\nentering cyberspace.$"
-DexDescription_Porygon_2:
- .string "This POKéMON is copy-protected so it\ncannot be duplicated by copying.$"
-
-DexDescription_Omanyte_1:
- .string "OMANYTE is one of the ancient and long-\nsince-extinct POKéMON that have been\nregenerated from fossils by people.$"
-DexDescription_Omanyte_2:
- .string "If attacked by an enemy, it withdraws\nitself inside its hard shell.$"
-
-DexDescription_Omastar_1:
- .string "OMASTAR uses its tentacles to capture\nits prey. It is believed to have become\nextinct because its shell grew too large$"
-DexDescription_Omastar_2:
- .string "and heavy, causing its movements to\nbecome too slow and ponderous.$"
-
-DexDescription_Kabuto_1:
- .string "KABUTO is a POKéMON that has been\nregenerated from a fossil. However, in\nextremely rare cases, living examples$"
-DexDescription_Kabuto_2:
- .string "have been discovered.\nThe POKéMON has not changed at all for\n300 million years.$"
-
-DexDescription_Kabutops_1:
- .string "KABUTOPS swam underwater to hunt for\nits prey in ancient times.\nThe POKéMON was apparently evolving$"
-DexDescription_Kabutops_2:
- .string "from being a water-dweller to living on\nland as evident from the beginnings of\nchange in its gills and legs.$"
-
-DexDescription_Aerodactyl_1:
- .string "AERODACTYL is a POKéMON from the age\nof dinosaurs. It was regenerated from\ngenetic material extracted from amber.$"
-DexDescription_Aerodactyl_2:
- .string "It is imagined to have been the king of\nthe skies in ancient times.$"
-
-DexDescription_Snorlax_1:
- .string "SNORLAX’s typical day consists of\nnothing more than eating and sleeping.\nIt is such a docile POKéMON that there$"
-DexDescription_Snorlax_2:
- .string "are children who use its expansive belly\nas a place to play.$"
-
-DexDescription_Articuno_1:
- .string "ARTICUNO is a legendary bird POKéMON\nthat can control ice.\nThe flapping of its wings chills the air.$"
-DexDescription_Articuno_2:
- .string "As a result, it is said that when this\nPOKéMON flies, snow will fall.$"
-
-DexDescription_Zapdos_1:
- .string "ZAPDOS is a legendary bird POKéMON that\nhas the ability to control electricity.\nIt usually lives in thunderclouds.$"
-DexDescription_Zapdos_2:
- .string "The POKéMON gains power if it is\nstricken by lightning bolts.$"
-
-DexDescription_Moltres_1:
- .string "MOLTRES is a legendary bird POKéMON\nthat has the ability to control fire.\nIf this POKéMON is injured, it is said to$"
-DexDescription_Moltres_2:
- .string "dip its body in the molten magma of a\nvolcano to burn and heal itself.$"
-
-DexDescription_Dratini_1:
- .string "DRATINI continually molts and sloughs\noff its old skin.\nIt does so because the life energy$"
-DexDescription_Dratini_2:
- .string "within its body steadily builds to reach\nuncontrollable levels.$"
-
-DexDescription_Dragonair_1:
- .string "DRAGONAIR stores an enormous amount\nof energy inside its body.\nIt is said to alter weather conditions$"
-DexDescription_Dragonair_2:
- .string "in its vicinity by discharging energy\nfrom the crystals on its neck and tail.$"
-
-DexDescription_Dragonite_1:
- .string "DRAGONITE is capable of circling the\nglobe in just sixteen hours.\nIt is a kindhearted POKéMON that leads$"
-DexDescription_Dragonite_2:
- .string "lost and foundering ships in a storm to\nthe safety of land.$"
-
-DexDescription_Mewtwo_1:
- .string "MEWTWO is a POKéMON that was created\nby genetic manipulation.\nHowever, even though the scientific$"
-DexDescription_Mewtwo_2:
- .string "power of humans created this POKéMON’s\nbody, they failed to endow MEWTWO with\na compassionate heart.$"
-
-DexDescription_Mew_1:
- .string "MEW is said to possess the genetic\ncomposition of all POKéMON.\nIt is capable of making itself invisible$"
-DexDescription_Mew_2:
- .string "at will, so it entirely avoids notice even\nif it approaches people.$"
-
-DexDescription_Chikorita_1:
- .string "In battle, CHIKORITA waves its leaf\naround to keep the foe at bay.\nHowever, a sweet fragrance also wafts$"
-DexDescription_Chikorita_2:
- .string "from the leaf, becalming the battling\nPOKéMON and creating a cozy, friendly\natmosphere all around.$"
-
-DexDescription_Bayleef_1:
- .string "BAYLEEF’s neck is ringed by curled-up\nleaves. Inside each tubular leaf is a\nsmall shoot of a tree.$"
-DexDescription_Bayleef_2:
- .string "The fragrance of this shoot makes\npeople peppy.$"
-
-DexDescription_Meganium_1:
- .string "The fragrance of MEGANIUM’s flower\nsoothes and calms emotions.\nIn battle, this POKéMON gives off more$"
-DexDescription_Meganium_2:
- .string "of its becalming scent to blunt the\nfoe’s fighting spirit.$"
-
-DexDescription_Cyndaquil_1:
- .string "CYNDAQUIL protects itself by flaring up\nthe flames on its back.\nThe flames are vigorous if the POKéMON$"
-DexDescription_Cyndaquil_2:
- .string "is angry. However, if it is tired, the\nflames splutter fitfully with incomplete\ncombustion.$"
-
-DexDescription_Quilava_1:
- .string "QUILAVA keeps its foes at bay with the\nintensity of its flames and gusts of\nsuperheated air.$"
-DexDescription_Quilava_2:
- .string "This POKéMON applies its outstanding\nnimbleness to dodge attacks even while\nscorching the foe with flames.$"
-
-DexDescription_Typhlosion_1:
- .string "TYPHLOSION obscures itself behind a\nshimmering heat haze that it creates\nusing its intensely hot flames.$"
-DexDescription_Typhlosion_2:
- .string "This POKéMON creates blazing explosive\nblasts that burn everything to cinders.$"
-
-DexDescription_Totodile_1:
- .string "Despite the smallness of its body,\nTOTODILE’s jaws are very powerful.\nWhile the POKéMON may think it is just$"
-DexDescription_Totodile_2:
- .string "playfully nipping, its bite has enough\npower to cause serious injury.$"
-
-DexDescription_Croconaw_1:
- .string "Once CROCONAW has clamped its jaws on\nits foe, it will absolutely not let go.\nBecause the tips of its fangs are$"
-DexDescription_Croconaw_2:
- .string "forked back like barbed fishhooks, they\nbecome impossible to remove when \nthey have sunk in.$"
-
-DexDescription_Feraligatr_1:
- .string "FERALIGATR intimidates its foes by\nopening its huge mouth.\nIn battle, it will kick the ground hard$"
-DexDescription_Feraligatr_2:
- .string "with its thick and powerful hind legs to\ncharge at the foe at an incredible\nspeed.$"
-
-DexDescription_Sentret_1:
- .string "When SENTRET sleeps, it does so while\nanother stands guard. The sentry wakes\nthe others at the first sign of danger.$"
-DexDescription_Sentret_2:
- .string "When this POKéMON becomes separated\nfrom its pack, it becomes incapable of\nsleep due to fear.$"
-
-DexDescription_Furret_1:
- .string "FURRET has a very slim build.\nWhen under attack, it can slickly squirm\nthrough narrow spaces and get away.$"
-DexDescription_Furret_2:
- .string "In spite of its short limbs, this\nPOKéMON is very nimble and fleet.$"
-
-DexDescription_Hoothoot_1:
- .string "HOOTHOOT has an internal organ that\nsenses and tracks the earth’s rotation.\nUsing this special organ, this POKéMON$"
-DexDescription_Hoothoot_2:
- .string "begins hooting at precisely the same\ntime every day.$"
-
-DexDescription_Noctowl_1:
- .string "NOCTOWL never fails at catching prey in\ndarkness. This POKéMON owes its\nsuccess to its superior vision that$"
-DexDescription_Noctowl_2:
- .string "allows it to see in minimal light, and to\nits soft, supple wings that make no\nsound in flight.$"
-
-DexDescription_Ledyba_1:
- .string "LEDYBA secretes an aromatic fluid from\nwhere its legs join its body. This fluid\nis used for communicating with others.$"
-DexDescription_Ledyba_2:
- .string "This POKéMON conveys its feelings to\nothers by altering the fluid’s scent.$"
-
-DexDescription_Ledian_1:
- .string "It is said that in lands with clean air,\nwhere the stars fill the sky, there live\nLEDIAN in countless numbers.$"
-DexDescription_Ledian_2:
- .string "There is a good reason for this - the\nPOKéMON uses the light of the stars\nas its energy.$"
-
-DexDescription_Spinarak_1:
- .string "The web spun by SPINARAK can be\nconsidered its second nervous system.\nIt is said that this POKéMON can$"
-DexDescription_Spinarak_2:
- .string "determine what kind of prey is touching\nits web just by the tiny vibrations it\nfeels through the web’s strands.$"
-
-DexDescription_Ariados_1:
- .string "ARIADOS’s feet are tipped with tiny\nhooked claws that enable it to scuttle\non ceilings and vertical walls.$"
-DexDescription_Ariados_2:
- .string "This POKéMON constricts the foe with\nthin and strong silk webbing.$"
-
- .ifdef SAPPHIRE
-DexDescription_Crobat_1:
- .string "CROBAT sneaks up on its intended prey\nusing wings that barely make a sound.\nThis POKéMON rests by hanging on a$"
-DexDescription_Crobat_2:
- .string "tree branch with its rear legs that\nserve as wings.$"
- .else
-DexDescription_Crobat_1:
- .string "If this POKéMON is flying by fluttering\nonly a pair of wings on either the\nforelegs or hind legs, it’s proof that$"
-DexDescription_Crobat_2:
- .string "CROBAT has been flying a long distance.\nIt switches the wings it uses if it is\ntired.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Chinchou_1:
- .string "CHINCHOU’s two antennas are filled with\ncells that generate strong electricity.\nThis POKéMON’s cells create so much$"
-DexDescription_Chinchou_2:
- .string "electrical power, it even makes itself\ntingle slightly.$"
- .else
-DexDescription_Chinchou_1:
- .string "CHINCHOU lets loose positive and\nnegative electrical charges from its\ntwo antennas to make its prey faint.$"
-DexDescription_Chinchou_2:
- .string "This POKéMON flashes its electric\nlights to exchange signals with others.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lanturn_1:
- .string "LANTURN is known to emit light.\nIf you peer down into the dark sea from\na ship at night, you can sometimes see$"
-DexDescription_Lanturn_2:
- .string "this POKéMON’s light rising from the\ndepths where it swims. It gives the sea\nan appearance of a starlit night.$"
- .else
-DexDescription_Lanturn_1:
- .string "LANTURN is nicknamed “the deep-sea\nstar” for its illuminated antenna.\nThis POKéMON produces light by$"
-DexDescription_Lanturn_2:
- .string "causing a chemical reaction between\nbacteria and its bodily fluids inside\nthe antenna.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Pichu_1:
- .string "When PICHU plays with others, it may\nshort out electricity with another\nPICHU, creating a shower of sparks.$"
-DexDescription_Pichu_2:
- .string "In that event, this POKéMON will begin\ncrying, startled by the flash of sparks.$"
- .else
-DexDescription_Pichu_1:
- .string "PICHU charges itself with electricity\nmore easily on days with thunderclouds\nor when the air is very dry.$"
-DexDescription_Pichu_2:
- .string "You can hear the crackling of static\nelectricity coming off this POKéMON.$"
- .endif
-
-DexDescription_Cleffa_1:
- .string "On nights with many shooting stars,\nCLEFFA can be seen dancing in a ring.\nThey dance through the night and stop$"
-DexDescription_Cleffa_2:
- .string "only at the break of day, when these\nPOKéMON quench their thirst with the\nmorning dew.$"
-
- .ifdef SAPPHIRE
-DexDescription_Igglybuff_1:
- .string "IGGLYBUFF has a soft and plushy body\nthat feels very much like a marshmallow.\nFrom this body wafts a gently sweet$"
-DexDescription_Igglybuff_2:
- .string "fragrance that soothes and calms the\nemotions of its foes.$"
- .else
-DexDescription_Igglybuff_1:
- .string "IGGLYBUFF’s vocal chords are not\nsufficiently developed. It would hurt\nits throat if it were to sing too much.$"
-DexDescription_Igglybuff_2:
- .string "This POKéMON gargles with freshwater\nfrom a clean stream.$"
- .endif
-
-DexDescription_Togepi_1:
- .string "As its energy, TOGEPI uses the positive\nemotions of compassion and pleasure\nexuded by people and POKéMON.$"
-DexDescription_Togepi_2:
- .string "This POKéMON stores up feelings of\nhappiness inside its shell, then shares\nthem with others.$"
-
-DexDescription_Togetic_1:
- .string "TOGETIC is said to be a POKéMON that\nbrings good fortune. When the POKéMON\nspots someone who is pure of heart,$"
-DexDescription_Togetic_2:
- .string "it is said to appear and share its\nhappiness with that person.$"
-
- .ifdef SAPPHIRE
-DexDescription_Natu_1:
- .string "NATU has a highly developed jumping\nability. The POKéMON flaps and leaps\nonto tree branches that are taller than$"
-DexDescription_Natu_2:
- .string "grown-up people to pick at the tree’s\nnew shoots.$"
- .else
-DexDescription_Natu_1:
- .string "NATU cannot fly because its wings are\nnot yet fully grown. If your eyes meet\nwith this POKéMON’s eyes, it will stare$"
-DexDescription_Natu_2:
- .string "back intently at you. But if you move\neven slightly, it will hop away to safety.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Xatu_1:
- .string "XATU is known to stand motionless while\nstaring at the sun all day long.\nSome people revere it as a mystical$"
-DexDescription_Xatu_2:
- .string "POKéMON out of their belief that XATU\nis in possession of the power to see\ninto the future.$"
- .else
-DexDescription_Xatu_1:
- .string "XATU stands rooted and still in one\nspot all day long. People believe that\nthis POKéMON does so out of fear of$"
-DexDescription_Xatu_2:
- .string "the terrible things it has foreseen in\nthe future.$"
- .endif
-
-DexDescription_Mareep_1:
- .string "MAREEP’s fluffy coat of wool rubs\ntogether and builds a static charge.\nThe more static electricity is charged,$"
-DexDescription_Mareep_2:
- .string "the more brightly the lightbulb at the\ntip of its tail grows.$"
-
-DexDescription_Flaaffy_1:
- .string "FLAAFFY’s wool quality changes so that\nit can generate a high amount of static\nelectricity with a small amount of wool.$"
-DexDescription_Flaaffy_2:
- .string "The bare and slick parts of its hide are\nshielded against electricity.$"
-
-DexDescription_Ampharos_1:
- .string "AMPHAROS gives off so much light that\nit can be seen even from space.\nPeople in the old days used the light of$"
-DexDescription_Ampharos_2:
- .string "this POKéMON to send signals back and\nforth with others far away.$"
-
- .ifdef SAPPHIRE
-DexDescription_Bellossom_1:
- .string "A BELLOSSOM grows flowers more\nbeautifully if it has evolved from a\nsmelly GLOOM - the stinkier the better.$"
-DexDescription_Bellossom_2:
- .string "At night, this POKéMON closes its\npetals and goes to sleep.$"
- .else
-DexDescription_Bellossom_1:
- .string "When BELLOSSOM gets exposed to plenty\nof sunlight, the leaves ringing its body\nbegin to spin around.$"
-DexDescription_Bellossom_2:
- .string "This POKéMON’s dancing is renowned in\nthe southern lands.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Marill_1:
- .string "When fishing for food at the edge of a\nfast-running stream, MARILL wraps its\ntail around the trunk of a tree.$"
-DexDescription_Marill_2:
- .string "This POKéMON’s tail is flexible and\nconfigured to stretch.$"
- .else
-DexDescription_Marill_1:
- .string "MARILL’s oil-filled tail acts much like\na life preserver. If you see just its\ntail bobbing on the water’s surface,$"
-DexDescription_Marill_2:
- .string "it’s a sure indication that this POKéMON\nis diving beneath the water to feed on\naquatic plants.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Azumarill_1:
- .string "AZUMARILL can make balloons out of\nair. It makes these air balloons if it\nspots a drowning POKéMON.$"
-DexDescription_Azumarill_2:
- .string "The air balloons enable the POKéMON in\ntrouble to breathe.$"
- .else
-DexDescription_Azumarill_1:
- .string "AZUMARILL’s long ears are indispensable\nsensors. By focusing its hearing, this\nPOKéMON can identify what kinds of$"
-DexDescription_Azumarill_2:
- .string "prey are around, even in rough and\nfast-running rivers.$"
- .endif
-
-DexDescription_Sudowoodo_1:
- .string "SUDOWOODO camouflages itself as a tree\nto avoid being attacked by enemies.\nHowever, because the forelegs remain$"
-DexDescription_Sudowoodo_2:
- .string "green throughout the year, the POKéMON\nis easily identified as a fake during\nthe winter.$"
-
-DexDescription_Politoed_1:
- .string "The curled hair on POLITOED’s head is\nproof of its status as a king. It is said\nthat the longer and more curled the$"
-DexDescription_Politoed_2:
- .string "hair, the more respect this POKéMON\nearns from its peers.$"
-
-DexDescription_Hoppip_1:
- .string "This POKéMON drifts and floats with the\nwind. If it senses the approach of\nstrong winds, HOPPIP links its leaves$"
-DexDescription_Hoppip_2:
- .string "with other HOPPIP to prepare against\nbeing blown away.$"
-
-DexDescription_Skiploom_1:
- .string "SKIPLOOM’s flower blossoms when the\ntemperature rises above 64 degrees F.\nHow much the flower opens depends on$"
-DexDescription_Skiploom_2:
- .string "the temperature. For that reason, this\nPOKéMON is sometimes used as a\nthermometer.$"
-
-DexDescription_Jumpluff_1:
- .string "JUMPLUFF rides warm southern winds to\ncross the sea and fly to foreign lands.\nThe POKéMON descends to the ground$"
-DexDescription_Jumpluff_2:
- .string "when it encounters cold air while it is\nfloating.$"
-
-DexDescription_Aipom_1:
- .string "AIPOM’s tail ends in a hand-like\nappendage that can be cleverly\nmanipulated.$"
-DexDescription_Aipom_2:
- .string "However, because the POKéMON uses its\ntail so much, its real hands have become\nrather clumsy.$"
-
-DexDescription_Sunkern_1:
- .string "SUNKERN tries to move as little as it\npossibly can. It does so because it\ntries to conserve all the nutrients it$"
-DexDescription_Sunkern_2:
- .string "has stored in its body for its\nevolution. It will not eat a thing, \nsubsisting only on morning dew.$"
-
-DexDescription_Sunflora_1:
- .string "SUNFLORA converts solar energy into\nnutrition. It moves around actively in\nthe daytime when it is warm.$"
-DexDescription_Sunflora_2:
- .string "It stops moving as soon as the sun goes\ndown for the night.$"
-
-DexDescription_Yanma_1:
- .string "YANMA is capable of seeing 360 degrees\nwithout having to move its eyes.\nIt is a great flier that is adept at$"
-DexDescription_Yanma_2:
- .string "making sudden stops and turning midair.\nThis POKéMON uses its flying ability to\nquickly chase down targeted prey.$"
-
-DexDescription_Wooper_1:
- .string "WOOPER usually lives in water.\nHowever, it occasionally comes out onto\nland in search of food.$"
-DexDescription_Wooper_2:
- .string "On land, it coats its body with a gooey,\ntoxic film.$"
-
-DexDescription_Quagsire_1:
- .string "QUAGSIRE hunts for food by leaving\nits mouth wide open in water and waiting\nfor its prey to blunder in unaware.$"
-DexDescription_Quagsire_2:
- .string "Because the POKéMON does not move,\nit does not get very hungry.$"
-
-DexDescription_Espeon_1:
- .string "ESPEON is extremely loyal to any\nTRAINER it considers to be worthy.\nIt is said that this POKéMON developed$"
-DexDescription_Espeon_2:
- .string "its precognitive powers to protect its\nTRAINER from harm.$"
-
-DexDescription_Umbreon_1:
- .string "UMBREON evolved as a result of exposure\nto the moon’s waves.\nIt hides silently in darkness and waits$"
-DexDescription_Umbreon_2:
- .string "for its foes to make a move.\nThe rings on its body glow when it leaps\nto attack.$"
-
-DexDescription_Murkrow_1:
- .string "MURKROW was feared and loathed as the\nalleged bearer of ill fortune.\nThis POKéMON shows strong interest in$"
-DexDescription_Murkrow_2:
- .string "anything that sparkles or glitters.\nIt will even try to steal rings from\nwomen.$"
-
-DexDescription_Slowking_1:
- .string "SLOWKING undertakes research every\nday in an effort to solve the mysteries\nof the world.$"
-DexDescription_Slowking_2:
- .string "However, this POKéMON apparently\nforgets everything it has learned if\nthe SHELLDER on its head comes off.$"
-
-DexDescription_Misdreavus_1:
- .string "MISDREAVUS frightens people with a\ncreepy, sobbing cry. The POKéMON\napparently uses its red spheres to$"
-DexDescription_Misdreavus_2:
- .string "absorb the fearful feelings of foes and\nturn them into nutrition.$"
-
-DexDescription_Unown_1:
- .string "This POKéMON is shaped like ancient\nwriting. It is a mystery as to which\ncame first, the ancient writings or the$"
-DexDescription_Unown_2:
- .string "various UNOWN. Research into this\ntopic is ongoing but nothing is known.$"
-
- .ifdef SAPPHIRE
-DexDescription_Wobbuffet_1:
- .string "WOBBUFFET does nothing but endure\nattacks - it won’t attack on its own.\nHowever, it won’t endure an attack on$"
-DexDescription_Wobbuffet_2:
- .string "its tail. When that happens, the\nPOKéMON will try to take the foe with it\nusing DESTINY BOND.$"
- .else
-DexDescription_Wobbuffet_1:
- .string "If two or more WOBBUFFET meet, they will\nturn competitive and try to outdo each\nother’s endurance.$"
-DexDescription_Wobbuffet_2:
- .string "However, they may try to see which one\ncan endure the longest without food.\nTRAINERS need to beware of this habit.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Girafarig_1:
- .string "GIRAFARIG’s rear head contains a tiny\nbrain that is too small for thinking.\nHowever, the rear head doesn’t need to$"
-DexDescription_Girafarig_2:
- .string "sleep, so it can keep watch over its\nsurroundings 24 hours a day.$"
- .else
-DexDescription_Girafarig_1:
- .string "GIRAFARIG’s rear head also has a brain,\nbut it is small. The rear head attacks in\nresponse to smells and sounds.$"
-DexDescription_Girafarig_2:
- .string "Approaching this POKéMON from behind\ncan cause the rear head to suddenly\nlash out and bite.$"
- .endif
-
-DexDescription_Pineco_1:
- .string "PINECO hangs from a tree branch and\npatiently waits for prey to come along.\nIf the POKéMON is disturbed while$"
-DexDescription_Pineco_2:
- .string "eating by someone shaking its tree, it\ndrops down to the ground and explodes\nwith no warning.$"
-
-DexDescription_Forretress_1:
- .string "FORRETRESS conceals itself inside its\nhardened steel shell. The shell is opened\nwhen the POKéMON is catching prey,$"
-DexDescription_Forretress_2:
- .string "but it does so at such a quick pace\nthat the shell’s inside cannot be seen.$"
-
-DexDescription_Dunsparce_1:
- .string "DUNSPARCE has a drill for its tail.\nIt uses this tail to burrow into the\nground backwards.$"
-DexDescription_Dunsparce_2:
- .string "This POKéMON is known to make its nest\nin complex shapes deep under the\nground.$"
-
-DexDescription_Gligar_1:
- .string "GLIGAR glides through the air without\na sound as if it were sliding.\nThis POKéMON hangs on to the face of$"
-DexDescription_Gligar_2:
- .string "its foe using its clawed hind legs and\nthe large pincers on its forelegs, then\ninjects the prey with its poison barb.$"
-
-DexDescription_Steelix_1:
- .string "STEELIX lives even further underground\nthan ONIX. This POKéMON is known to dig\ntowards the earth’s core.$"
-DexDescription_Steelix_2:
- .string "There are records of this POKéMON\nreaching a depth of over six-tenths\nof a mile underground.$"
-
-DexDescription_Snubbull_1:
- .string "By baring its fangs and making a scary\nface, SNUBBULL sends smaller POKéMON\nscurrying away in terror.$"
-DexDescription_Snubbull_2:
- .string "However, this POKéMON seems a little\nsad at making its foes flee.$"
-
-DexDescription_Granbull_1:
- .string "GRANBULL has a particularly well-\ndeveloped lower jaw. The enormous fangs\nare heavy, causing the POKéMON to tip$"
-DexDescription_Granbull_2:
- .string "its head back for balance.\nUnless it is startled, it will not try to\nbite indiscriminately.$"
-
-DexDescription_Qwilfish_1:
- .string "QWILFISH sucks in water, inflating\nitself. This POKéMON uses the pressure\nof the water it swallowed to shoot$"
-DexDescription_Qwilfish_2:
- .string "toxic quills all at once from all over\nits body. It finds swimming somewhat\nchallenging.$"
-
-DexDescription_Scizor_1:
- .string "SCIZOR has a body with the hardness of\nsteel. It is not easily fazed by ordinary\nsorts of attacks.$"
-DexDescription_Scizor_2:
- .string "This POKéMON flaps its wings to\nregulate its body temperature.$"
-
-DexDescription_Shuckle_1:
- .string "SHUCKLE quietly hides itself under\nrocks, keeping its body concealed\ninside its hard shell while eating$"
-DexDescription_Shuckle_2:
- .string "berries it has stored away.\nThe berries mix with its body fluids to\nbecome a juice.$"
-
- .ifdef SAPPHIRE
-DexDescription_Heracross_1:
- .string "HERACROSS has sharp claws on its feet.\nThese are planted firmly into the\nground or the bark of a tree, giving the$"
-DexDescription_Heracross_2:
- .string "POKéMON a secure and solid footing\nto forcefully fling away foes with\nits proud horn.$"
- .else
-DexDescription_Heracross_1:
- .string "HERACROSS charges in a straight line at\nits foe, slips beneath the foe’s grasp,\nand then scoops up and hurls the$"
-DexDescription_Heracross_2:
- .string "opponent with its mighty horn.\nThis POKéMON even has enough power\nto topple a massive tree.$"
- .endif
-
-DexDescription_Sneasel_1:
- .string "SNEASEL scales trees by punching its\nhooked claws into the bark.\nThis POKéMON seeks out unguarded$"
-DexDescription_Sneasel_2:
- .string "nests and steals eggs for food while\nthe parents are away.$"
-
-DexDescription_Teddiursa_1:
- .string "This POKéMON likes to lick its palms that\nare sweetened by being soaked in honey.\nTEDDIURSA concocts its own honey by$"
-DexDescription_Teddiursa_2:
- .string "blending fruits and pollen collected by\nBEEDRILL.$"
-
-DexDescription_Ursaring_1:
- .string "In the forests inhabited by URSARING,\nit is said that there are many streams\nand towering trees where they$"
-DexDescription_Ursaring_2:
- .string "gather food. This POKéMON walks\nthrough its forest gathering food\nevery day.$"
-
- .ifdef SAPPHIRE
-DexDescription_Slugma_1:
- .string "SLUGMA does not have any blood in its\nbody. Instead, intensely hot magma\ncirculates throughout this POKéMON’s$"
-DexDescription_Slugma_2:
- .string "body, carrying essential nutrients and\noxygen to its organs.$"
- .else
-DexDescription_Slugma_1:
- .string "Molten magma courses throughout\nSLUGMA’s circulatory system.\nIf this POKéMON is chilled, the magma$"
-DexDescription_Slugma_2:
- .string "cools and hardens. Its body turns\nbrittle and chunks fall off, reducing\nits size.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Magcargo_1:
- .string "MAGCARGO’s body temperature is\napproximately 18,000 degrees F.\nWater is vaporized on contact.$"
-DexDescription_Magcargo_2:
- .string "If this POKéMON is caught in the rain,\nthe raindrops instantly turn into\nsteam, cloaking the area in a thick fog.$"
- .else
-DexDescription_Magcargo_1:
- .string "MAGCARGO’s shell is actually its skin\nthat hardened as a result of cooling.\nIts shell is very brittle and fragile -$"
-DexDescription_Magcargo_2:
- .string "just touching it causes it to crumble\napart. This POKéMON returns to its\noriginal size by dipping itself in magma.$"
- .endif
-
-DexDescription_Swinub_1:
- .string "SWINUB roots for food by rubbing its\nsnout against the ground. Its favorite\nfood is a mushroom that grows under$"
-DexDescription_Swinub_2:
- .string "the cover of dead grass.\nThis POKéMON occasionally roots out\nhot springs.$"
-
-DexDescription_Piloswine_1:
- .string "PILOSWINE is covered by a thick coat\nof long hair that enables it to endure\nthe freezing cold.$"
-DexDescription_Piloswine_2:
- .string "This POKéMON uses its tusks to dig up\nfood that has been buried under ice.$"
-
- .ifdef SAPPHIRE
-DexDescription_Corsola_1:
- .string "Clusters of CORSOLA congregate in warm\nseas where they serve as ideal hiding\nplaces for smaller POKéMON.$"
-DexDescription_Corsola_2:
- .string "When the water temperature falls, this\nPOKéMON migrates to the southern seas.$"
- .else
-DexDescription_Corsola_1:
- .string "CORSOLA’s branches glitter very\nbeautifully in seven colors when they\ncatch sunlight.$"
-DexDescription_Corsola_2:
- .string "If any branch breaks off, this POKéMON\ngrows it back in just one night.$"
- .endif
-
-DexDescription_Remoraid_1:
- .string "REMORAID sucks in water, then expels it\nat high velocity using its abdominal\nmuscles to shoot down flying prey.$"
-DexDescription_Remoraid_2:
- .string "When evolution draws near, this POKéMON\ntravels downstream from rivers.$"
-
-DexDescription_Octillery_1:
- .string "OCTILLERY grabs onto its foe using\nits tentacles. This POKéMON tries to\nimmobilize it before delivering the$"
-DexDescription_Octillery_2:
- .string "finishing blow.\nIf the foe turns out to be too strong,\nOCTILLERY spews ink to escape.$"
-
-DexDescription_Delibird_1:
- .string "DELIBIRD carries its food bundled up\nin its tail. There once was a famous\nexplorer who managed to reach the peak$"
-DexDescription_Delibird_2:
- .string "of Mt. Everest thanks to one of these\nPOKéMON sharing its food.$"
-
-DexDescription_Mantine_1:
- .string "On sunny days, schools of MANTINE can\nbe seen elegantly leaping over the\nsea’s waves.$"
-DexDescription_Mantine_2:
- .string "This POKéMON is not bothered by the\nREMORAID that hitches rides.$"
-
- .ifdef SAPPHIRE
-DexDescription_Skarmory_1:
- .string "SKARMORY’s steel wings become tattered\nand bashed in from repeated battles.\nOnce a year, the battered wings grow$"
-DexDescription_Skarmory_2:
- .string "back completely, restoring the cutting\nedges to their pristine state.$"
- .else
-DexDescription_Skarmory_1:
- .string "SKARMORY is entirely encased in hard,\nprotective armor. This POKéMON flies at\nclose to 190 mph.$"
-DexDescription_Skarmory_2:
- .string "It slashes foes with its wings that\npossess swordlike cutting edges.$"
- .endif
-
-DexDescription_Houndour_1:
- .string "HOUNDOUR hunt as a coordinated pack.\nThey communicate with each other using\na variety of cries to corner their prey.$"
-DexDescription_Houndour_2:
- .string "This POKéMON’s remarkable teamwork is\nunparalleled.$"
-
-DexDescription_Houndoom_1:
- .string "In a HOUNDOOM pack, the one with its\nhorns raked sharply towards the back\nserves a leadership role.$"
-DexDescription_Houndoom_2:
- .string "These POKéMON choose their leader by\nfighting amongst themselves.$"
-
- .ifdef SAPPHIRE
-DexDescription_Kingdra_1:
- .string "KINGDRA sleeps on the seafloor where\nit is otherwise devoid of life.\nWhen a storm arrives, the POKéMON is$"
-DexDescription_Kingdra_2:
- .string "said to awaken and wander about in\nsearch of prey.$"
- .else
-DexDescription_Kingdra_1:
- .string "KINGDRA lives at extreme ocean depths\nthat are otherwise uninhabited.\nIt has long been believed that the$"
-DexDescription_Kingdra_2:
- .string "yawning of this POKéMON creates\nspiraling ocean currents.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Phanpy_1:
- .string "PHANPY uses its long nose to shower\nitself. When others gather around, they\nthoroughly douse each other with water.$"
-DexDescription_Phanpy_2:
- .string "These POKéMON can be seen drying their\nsoaking-wet bodies at the edge of\nwater.$"
- .else
-DexDescription_Phanpy_1:
- .string "For its nest, PHANPY digs a vertical pit \nin the ground at the edge of a river.\nIt marks the area around its nest with$"
-DexDescription_Phanpy_2:
- .string "its trunk to let the others know that\nthe area has been claimed.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Donphan_1:
- .string "If DONPHAN were to tackle with its hard\nbody, even a house could be destroyed.\nUsing its massive strength, the$"
-DexDescription_Donphan_2:
- .string "POKéMON helps clear rock and mud slides\nthat block mountain trails.$"
- .else
-DexDescription_Donphan_1:
- .string "DONPHAN’s favorite attack is curling\nits body into a ball, then charging at\nits foe while rolling at high speed.$"
-DexDescription_Donphan_2:
- .string "Once it starts rolling, this POKéMON\ncan’t stop very easily.$"
- .endif
-
-DexDescription_Porygon2_1:
- .string "PORYGON2 was created by humans using\nthe power of science. The man-made\nPOKéMON has been endowed with$"
-DexDescription_Porygon2_2:
- .string "artificial intelligence that enables it\nto learn new gestures and emotions\non its own.$"
-
-DexDescription_Stantler_1:
- .string "STANTLER’s magnificent antlers were\ntraded at high prices as works of art.\nAs a result, this POKéMON was hunted$"
-DexDescription_Stantler_2:
- .string "close to extinction by those who were\nafter the priceless antlers.$"
-
-DexDescription_Smeargle_1:
- .string "SMEARGLE marks the boundaries of its\nterritory using a body fluid that leaks\nout from the tip of its tail.$"
-DexDescription_Smeargle_2:
- .string "Over 5,000 different marks left by this\nPOKéMON have been found.$"
-
-DexDescription_Tyrogue_1:
- .string "TYROGUE becomes stressed out if it\ndoes not get to train every day.\nWhen raising this POKéMON, the TRAINER$"
-DexDescription_Tyrogue_2:
- .string "must establish and uphold various\ntraining methods.$"
-
-DexDescription_Hitmontop_1:
- .string "HITMONTOP spins on its head at high\nspeed, all the while delivering kicks.\nThis technique is a remarkable mix of$"
-DexDescription_Hitmontop_2:
- .string "both offense and defense at the same\ntime. The POKéMON travels faster\nspinning than it does walking.$"
-
-DexDescription_Smoochum_1:
- .string "SMOOCHUM actively runs about, but\nalso falls quite often.\nWhenever the chance arrives, it will$"
-DexDescription_Smoochum_2:
- .string "look for its reflection to make sure its\nface hasn’t become dirty.$"
-
-DexDescription_Elekid_1:
- .string "ELEKID stores electricity in its body.\nIf it touches metal and accidentally\ndischarges all its built-up electricity,$"
-DexDescription_Elekid_2:
- .string "this POKéMON begins swinging its arms\nin circles to recharge itself.$"
-
-DexDescription_Magby_1:
- .string "MAGBY’s state of health is determined\nby observing the fire it breathes.\nIf the POKéMON is spouting yellow$"
-DexDescription_Magby_2:
- .string "flames from its mouth, it is in good\nhealth. When it is fatigued, black smoke\nwill be mixed in with the flames.$"
-
-DexDescription_Miltank_1:
- .string "MILTANK gives over five gallons of milk\non a daily basis. Its sweet milk is\nenjoyed by children and grown-ups alike.$"
-DexDescription_Miltank_2:
- .string "People who can’t drink milk turn it into\nyogurt and eat it instead.$"
-
-DexDescription_Blissey_1:
- .string "BLISSEY senses sadness with its fluffy\ncoat of fur. If it does so, this POKéMON\nwill rush over to the sad person,$"
-DexDescription_Blissey_2:
- .string "however far they may be, to share an\negg of happiness that brings a smile\nto any face.$"
-
-DexDescription_Raikou_1:
- .string "RAIKOU embodies the speed of lightning.\nThe roars of this POKéMON send shock\nwaves shuddering through the air and$"
-DexDescription_Raikou_2:
- .string "shake the ground as if lightning bolts\nhad come crashing down.$"
-
-DexDescription_Entei_1:
- .string "ENTEI embodies the passion of magma.\nThis POKéMON is thought to have been\nborn in the eruption of a volcano.$"
-DexDescription_Entei_2:
- .string "It sends up massive bursts of fire that\nutterly consume all that they touch.$"
-
-DexDescription_Suicune_1:
- .string "SUICUNE embodies the compassion of\na pure spring of water. It runs across\nthe land with gracefulness.$"
-DexDescription_Suicune_2:
- .string "This POKéMON has the power to purify\ndirty water.$"
-
-DexDescription_Larvitar_1:
- .string "LARVITAR is born deep under the ground.\nTo come up to the surface, this POKéMON\nmust eat its way through the soil above.$"
-DexDescription_Larvitar_2:
- .string "Until it does so, LARVITAR cannot see\nits parent’s face.$"
-
-DexDescription_Pupitar_1:
- .string "PUPITAR creates a gas inside its body\nthat it compresses and forcefully\nejects to propel itself like a jet.$"
-DexDescription_Pupitar_2:
- .string "The body is very durable - it avoids\ndamage even if it hits solid steel.$"
-
-DexDescription_Tyranitar_1:
- .string "TYRANITAR is so overwhelmingly\npowerful, it can bring down a whole\nmountain to make its nest.$"
-DexDescription_Tyranitar_2:
- .string "This POKéMON wanders about in\nmountains seeking new opponents to\nfight.$"
-
-DexDescription_Lugia_1:
- .string "LUGIA’s wings pack devastating power -\na light fluttering of its wings can blow\napart regular houses.$"
-DexDescription_Lugia_2:
- .string "As a result, this POKéMON chooses to\nlive out of sight deep under the sea.$"
-
-DexDescription_HoOh_1:
- .string "HO-OH’s feathers glow in seven colors\ndepending on the angle at which they\nare struck by light.$"
-DexDescription_HoOh_2:
- .string "These feathers are said to bring\nhappiness to the bearers. This POKéMON\nis said to live at the foot of a rainbow.$"
-
-DexDescription_Celebi_1:
- .string "This POKéMON came from the future by\ncrossing over time.\nIt is thought that so long as CELEBI$"
-DexDescription_Celebi_2:
- .string "appears, a bright and shining future\nawaits us.$"
-
- .ifdef SAPPHIRE
-DexDescription_Treecko_1:
- .string "TREECKO is cool, calm, and collected -\nit never panics under any situation.\nIf a bigger foe were to glare at this$"
-DexDescription_Treecko_2:
- .string "POKéMON, it would glare right back\nwithout conceding an inch of ground.$"
- .else
-DexDescription_Treecko_1:
- .string "TREECKO has small hooks on the bottom\nof its feet that enable it to scale\nvertical walls.$"
-DexDescription_Treecko_2:
- .string "This POKéMON attacks by slamming foes\nwith its thick tail.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Grovyle_1:
- .string "This POKéMON adeptly flies from branch\nto branch in trees.\nIn a forest, no POKéMON can ever hope$"
-DexDescription_Grovyle_2:
- .string "to catch a fleeing GROVYLE however\nfast they may be.$"
- .else
-DexDescription_Grovyle_1:
- .string "The leaves growing out of GROVYLE’s\nbody are convenient for camouflaging\nit from enemies in the forest.$"
-DexDescription_Grovyle_2:
- .string "This POKéMON is a master at climbing\ntrees in jungles.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sceptile_1:
- .string "SCEPTILE has seeds growing on its back.\nThey are said to be bursting with\nnutrients that revitalize trees.$"
-DexDescription_Sceptile_2:
- .string "This POKéMON raises the trees in a\nforest with loving care.$"
- .else
-DexDescription_Sceptile_1:
- .string "The leaves growing on SCEPTILE’s body\nare very sharp edged. This POKéMON is\nvery agile - it leaps all over the$"
-DexDescription_Sceptile_2:
- .string "branches of trees and jumps on its foe\nfrom above or behind.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Torchic_1:
- .string "TORCHIC has a place inside its body\nwhere it keeps its flame. Give it a hug -\nit will be glowing with warmth.$"
-DexDescription_Torchic_2:
- .string "This POKéMON is covered all over by a\nfluffy coat of down.$"
- .else
-DexDescription_Torchic_1:
- .string "TORCHIC sticks with its TRAINER,\nfollowing behind with unsteady\nsteps.$"
-DexDescription_Torchic_2:
- .string "This POKéMON breathes fire of over\n1,800 degrees F, including fireballs\nthat leave the foe scorched black.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Combusken_1:
- .string "COMBUSKEN battles with the intensely\nhot flames it spews from its beak and\nwith outstandingly destructive kicks.$"
-DexDescription_Combusken_2:
- .string "This POKéMON’s cry is very loud and\ndistracting.$"
- .else
-DexDescription_Combusken_1:
- .string "COMBUSKEN toughens up its legs and\nthighs by running through fields and\nmountains.$"
-DexDescription_Combusken_2:
- .string "This POKéMON’s legs possess both speed\nand power, enabling it to dole out ten\nkicks in one second.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Blaziken_1:
- .string "BLAZIKEN has incredibly strong legs -\nit can easily clear a 30-story building\nin one leap.$"
-DexDescription_Blaziken_2:
- .string "This POKéMON’s blazing punches leave\nits foes scorched and blackened.$"
- .else
-DexDescription_Blaziken_1:
- .string "In battle, BLAZIKEN blows out intense\nflames from its wrists and attacks foes\ncourageously.$"
-DexDescription_Blaziken_2:
- .string "The stronger the foe, the more\nintensely this POKéMON’s wrists burn.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Mudkip_1:
- .string "In water, MUDKIP breathes using the\ngills on its cheeks.\nIf it is faced with a tight situation in$"
-DexDescription_Mudkip_2:
- .string "battle, this POKéMON will unleash its\namazing power - it can crush rocks\nbigger than itself.$"
- .else
-DexDescription_Mudkip_1:
- .string "The fin on MUDKIP’s head acts as highly\nsensitive radar. Using this fin to sense\nmovements of water and air, this$"
-DexDescription_Mudkip_2:
- .string "POKéMON can determine what is taking\nplace around it without using its eyes.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Marshtomp_1:
- .string "MARSHTOMP is much faster at traveling\nthrough mud than it is at swimming.\nThis POKéMON’s hindquarters exhibit$"
-DexDescription_Marshtomp_2:
- .string "obvious development, giving it the\nability to walk on just its hind legs.$"
- .else
-DexDescription_Marshtomp_1:
- .string "The surface of MARSHTOMP’s body is\nenveloped by a thin, sticky film that\nenables it to live on land.$"
-DexDescription_Marshtomp_2:
- .string "This POKéMON plays in mud on beaches\nwhen the ocean tide is low.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Swampert_1:
- .string "SWAMPERT predicts storms by sensing\nsubtle differences in the sounds of\nwaves and tidal winds with its fins.$"
-DexDescription_Swampert_2:
- .string "If a storm is approaching, it piles up\nboulders to protect itself.$"
- .else
-DexDescription_Swampert_1:
- .string "SWAMPERT is very strong. It has enough\npower to easily drag a boulder weighing\nmore than a ton.$"
-DexDescription_Swampert_2:
- .string "This POKéMON also has powerful vision\nthat lets it see even in murky water.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Poochyena_1:
- .string "POOCHYENA is an omnivore - it will eat\nanything. A distinguishing feature is\nhow large its fangs are compared to$"
-DexDescription_Poochyena_2:
- .string "its body. This POKéMON tries to\nintimidate its foes by making the hair\non its tail bristle out.$"
- .else
-DexDescription_Poochyena_1:
- .string "At first sight, POOCHYENA takes a bite\nat anything that moves.\nThis POKéMON chases after prey until$"
-DexDescription_Poochyena_2:
- .string "the victim becomes exhausted.\nHowever, it may turn tail if the prey\nstrikes back.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Mightyena_1:
- .string "MIGHTYENA travel and act as a pack\nin the wild. The memory of its life in the\nwild compels the POKéMON to obey only$"
-DexDescription_Mightyena_2:
- .string "those TRAINERS that it recognizes to\npossess superior skill.$"
- .else
-DexDescription_Mightyena_1:
- .string "MIGHTYENA gives obvious signals when\nit is preparing to attack. It starts to\ngrowl deeply and then flattens its body.$"
-DexDescription_Mightyena_2:
- .string "This POKéMON will bite savagely with its\nsharply pointed fangs.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Zigzagoon_1:
- .string "The hair on ZIGZAGOON’s back is \nbristly. It rubs the hard back hair\nagainst trees to leave its territorial$"
-DexDescription_Zigzagoon_2:
- .string "markings.\nThis POKéMON may play dead to fool foes\nin battle.$"
- .else
-DexDescription_Zigzagoon_1:
- .string "ZIGZAGOON restlessly wanders\neverywhere at all times. This POKéMON\ndoes so because it is very curious.$"
-DexDescription_Zigzagoon_2:
- .string "It becomes interested in anything\nthat it happens to see.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Linoone_1:
- .string "When hunting, LINOONE will make a\nbeeline straight for the prey at a full\nrun. While this POKéMON is capable of$"
-DexDescription_Linoone_2:
- .string "topping 60 mph, it has to come to a\nscreeching halt before it can turn.$"
- .else
-DexDescription_Linoone_1:
- .string "LINOONE always runs full speed and only\nin straight lines. If facing an obstacle,\nit makes a right-angle turn to evade it.$"
-DexDescription_Linoone_2:
- .string "This POKéMON is very challenged by\ngently curving roads.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wurmple_1:
- .string "WURMPLE is targeted by SWELLOW as\nprey. This POKéMON will try to resist by\npointing the spikes on its rear at the$"
-DexDescription_Wurmple_2:
- .string "attacking predator.\nIt will weaken the foe by leaking poison\nfrom the spikes.$"
- .else
-DexDescription_Wurmple_1:
- .string "Using the spikes on its rear end, \nWURMPLE peels the bark off trees and\nfeeds on the sap that oozes out.$"
-DexDescription_Wurmple_2:
- .string "This POKéMON’s feet are tipped with\nsuction pads that allow it to cling to\nglass without slipping.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Silcoon_1:
- .string "SILCOON was thought to endure hunger\nand not consume anything before its\nevolution. However, it is now thought$"
-DexDescription_Silcoon_2:
- .string "that this POKéMON slakes its thirst by\ndrinking rainwater that collects on its\nsilk.$"
- .else
-DexDescription_Silcoon_1:
- .string "SILCOON tethers itself to a tree branch\nusing silk to keep from falling. There, \nthis POKéMON hangs quietly while it$"
-DexDescription_Silcoon_2:
- .string "awaits evolution.\nIt peers out of the silk cocoon through\na small hole.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Beautifly_1:
- .string "BEAUTIFLY has a long mouth like a coiled\nneedle, which is very convenient for\ncollecting pollen from flowers.$"
-DexDescription_Beautifly_2:
- .string "This POKéMON rides the spring winds as\nit flits around gathering pollen.$"
- .else
-DexDescription_Beautifly_1:
- .string "BEAUTIFLY’s favorite food is the sweet\npollen of flowers. If you want to see\nthis POKéMON, just leave a potted$"
-DexDescription_Beautifly_2:
- .string "flower by an open window. BEAUTIFLY\nis sure to come looking for pollen.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Cascoon_1:
- .string "If it is attacked, CASCOON remains\nmotionless however badly it may be\nhurt. It does so because if it were to$"
-DexDescription_Cascoon_2:
- .string "move, its body would be weak upon\nevolution. This POKéMON will also not\nforget the pain it endured.$"
- .else
-DexDescription_Cascoon_1:
- .string "CASCOON makes its protective cocoon\nby wrapping its body entirely with a\nfine silk from its mouth. Once the silk$"
-DexDescription_Cascoon_2:
- .string "goes around its body, it hardens.\nThis POKéMON prepares for its evolution\ninside the cocoon.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Dustox_1:
- .string "When DUSTOX flaps its wings, a fine\ndust is scattered all over. This dust is\nactually a powerful poison that will$"
-DexDescription_Dustox_2:
- .string "even make a pro wrestler sick.\nThis POKéMON searches for food using\nits antennae like radar.$"
- .else
-DexDescription_Dustox_1:
- .string "DUSTOX is instinctively drawn to light.\nSwarms of this POKéMON are attracted\nby the bright lights of cities, where$"
-DexDescription_Dustox_2:
- .string "they wreak havoc by stripping the\nleaves off roadside trees for food.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lotad_1:
- .string "LOTAD is said to have dwelled on land\nbefore. However, this POKéMON is\nthought to have returned to water$"
-DexDescription_Lotad_2:
- .string "because the leaf on its head grew large\nand heavy. It now lives by floating\natop the water.$"
- .else
-DexDescription_Lotad_1:
- .string "LOTAD live in ponds and lakes, where\nthey float on the surface.\nIt grows weak if its broad leaf dies.$"
-DexDescription_Lotad_2:
- .string "On rare occasions, this POKéMON travels\non land in search of clean water.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lombre_1:
- .string "LOMBRE’s entire body is covered by a\nslippery, slimy film. It feels horribly\nunpleasant to be touched by this$"
-DexDescription_Lombre_2:
- .string "POKéMON’s hands.\nLOMBRE is often mistaken for a human\nchild.$"
- .else
-DexDescription_Lombre_1:
- .string "LOMBRE is nocturnal - it will get active\nafter dusk. It is also a mischief-maker.\nWhen this POKéMON spots anglers,$"
-DexDescription_Lombre_2:
- .string "it tugs on their fishing lines from\nbeneath the surface and enjoys their\nconsternation.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Ludicolo_1:
- .string "Upon hearing an upbeat and cheerful\nrhythm, the cells in LUDICOLO’s body\nbecome very energetic and active.$"
-DexDescription_Ludicolo_2:
- .string "Even in battle, this POKéMON will\nexhibit an amazing amount of power.$"
- .else
-DexDescription_Ludicolo_1:
- .string "LUDICOLO begins dancing as soon as\nit hears cheerful, festive music.\nThis POKéMON is said to appear when it$"
-DexDescription_Ludicolo_2:
- .string "hears the singing of children on hiking\noutings.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Seedot_1:
- .string "SEEDOT looks exactly like an acorn\nwhen it is dangling from a tree branch.\nIt startles other POKéMON by suddenly$"
-DexDescription_Seedot_2:
- .string "moving.\nThis POKéMON polishes its body once a\nday using leaves.$"
- .else
-DexDescription_Seedot_1:
- .string "SEEDOT attaches itself to a tree\nbranch using the top of its head.\nIt sucks moisture from the tree while$"
-DexDescription_Seedot_2:
- .string "hanging off the branch.\nThe more water it drinks, the glossier\nthis POKéMON’s body becomes.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Nuzleaf_1:
- .string "This POKéMON pulls out the leaf on its\nhead and makes a flute with it.\nThe sound of NUZLEAF’s flute strikes$"
-DexDescription_Nuzleaf_2:
- .string "fear and uncertainty in the hearts of\npeople lost in a forest.$"
- .else
-DexDescription_Nuzleaf_1:
- .string "NUZLEAF live in densely overgrown\nforests. They occasionally venture out\nof the forest to startle people.$"
-DexDescription_Nuzleaf_2:
- .string "This POKéMON dislikes having its long\nnose pinched.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Shiftry_1:
- .string "SHIFTRY’s large fans generate awesome\ngusts of wind at a speed close to 100\nfeet per second. The whipped-up wind$"
-DexDescription_Shiftry_2:
- .string "blows anything away.\nThis POKéMON chooses to live quietly\ndeep in forests.$"
- .else
-DexDescription_Shiftry_1:
- .string "SHIFTRY is a mysterious POKéMON that\nis said to live atop towering trees \ndating back over a thousand years.$"
-DexDescription_Shiftry_2:
- .string "It creates terrific windstorms with\nthe fans it holds.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Taillow_1:
- .string "TAILLOW is young - it has only just\nleft its nest. As a result, it sometimes\nbecomes lonesome and cries at night.$"
-DexDescription_Taillow_2:
- .string "This POKéMON feeds on WURMPLE that\nlive in forests.$"
- .else
-DexDescription_Taillow_1:
- .string "TAILLOW courageously stands its\nground against foes, however strong\nthey may be.$"
-DexDescription_Taillow_2:
- .string "This gutsy POKéMON will remain defiant\neven after a loss. On the other hand,\nit cries loudly if it becomes hungry.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Swellow_1:
- .string "SWELLOW is very conscientious about\nthe upkeep of its glossy wings.\nOnce two SWELLOW are gathered, they$"
-DexDescription_Swellow_2:
- .string "diligently take care of cleaning each\nother’s wings.$"
- .else
-DexDescription_Swellow_1:
- .string "SWELLOW flies high above our heads,\nmaking graceful arcs in the sky.\nThis POKéMON dives at a steep angle as$"
-DexDescription_Swellow_2:
- .string "soon as it spots its prey. The hapless\nprey is tightly grasped by SWELLOW’s\nclawed feet, preventing escape.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wingull_1:
- .string "WINGULL rides updrafts rising from the\nsea by extending its long and narrow\nwings to glide.$"
-DexDescription_Wingull_2:
- .string "This POKéMON’s long beak is useful for\ncatching prey.$"
- .else
-DexDescription_Wingull_1:
- .string "WINGULL has the habit of carrying prey\nand valuables in its beak and hiding\nthem in all sorts of locations.$"
-DexDescription_Wingull_2:
- .string "This POKéMON rides the winds and flies\nas if it were skating across the sky.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Pelipper_1:
- .string "PELIPPER searches for food while in\nflight by skimming the wave tops.\nThis POKéMON dips its large bill in the$"
-DexDescription_Pelipper_2:
- .string "sea to scoop up food, then swallows\neverything in one big gulp.$"
- .else
-DexDescription_Pelipper_1:
- .string "PELIPPER is a flying transporter that\ncarries small POKéMON and eggs inside\nits massive bill.$"
-DexDescription_Pelipper_2:
- .string "This POKéMON builds its nest on steep\ncliffs facing the sea.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Ralts_1:
- .string "RALTS has the ability to sense the\nemotions of people.\nIf its TRAINER is in a cheerful mood,$"
-DexDescription_Ralts_2:
- .string "this POKéMON grows cheerful and joyous\nin the same way.$"
- .else
-DexDescription_Ralts_1:
- .string "RALTS senses the emotions of\npeople using the horns on its head.\nThis POKéMON rarely appears before$"
-DexDescription_Ralts_2:
- .string "people. But when it does, it draws\ncloser if it senses that the person has\na positive disposition.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Kirlia_1:
- .string "KIRLIA uses the horns on its head\nto amplify its psychokinetic power.\nWhen the POKéMON uses its power,$"
-DexDescription_Kirlia_2:
- .string "the air around it becomes distorted,\ncreating mirages of nonexistent\nscenery.$"
- .else
-DexDescription_Kirlia_1:
- .string "It is said that a KIRLIA that is\nexposed to the positive emotions of\nits TRAINER grows beautiful.$"
-DexDescription_Kirlia_2:
- .string "This POKéMON controls psychokinetic\npowers with its highly developed brain.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Gardevoir_1:
- .string "GARDEVOIR has the psychokinetic\npower to distort the dimensions and\ncreate a small black hole.$"
-DexDescription_Gardevoir_2:
- .string "This POKéMON will try to protect its\nTRAINER even at the risk of its own\nlife.$"
- .else
-DexDescription_Gardevoir_1:
- .string "GARDEVOIR has the ability to read the\nfuture. If it senses impending danger\nto its TRAINER, this POKéMON is said to$"
-DexDescription_Gardevoir_2:
- .string "unleash its psychokinetic energy at\nfull power.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Surskit_1:
- .string "If SURSKIT senses danger, it secretes\na thick, sugary syrup from the tip of\nits head.$"
-DexDescription_Surskit_2:
- .string "There are some POKéMON that love\neating this syrup.$"
- .else
-DexDescription_Surskit_1:
- .string "From the tips of its feet, SURSKIT\nsecretes an oil that enables it to walk\non water as if it were skating.$"
-DexDescription_Surskit_2:
- .string "This POKéMON feeds on microscopic\norganisms in ponds and lakes.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Masquerain_1:
- .string "MASQUERAIN’s antennas have eyelike\npatterns that usually give it an angry\nlook. If the “eyes” are droopy and$"
-DexDescription_Masquerain_2:
- .string "appear sad, it is said to be a sign\nthat a heavy rainfall is on its way.$"
- .else
-DexDescription_Masquerain_1:
- .string "MASQUERAIN intimidates enemies with\nthe eyelike patterns on its antennas.\nThis POKéMON flaps its four wings to$"
-DexDescription_Masquerain_2:
- .string "freely fly in any direction - even\nsideways and backwards - as if it were\na helicopter.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Shroomish_1:
- .string "If SHROOMISH senses danger, it shakes\nits body and scatters spores from the\ntop of its head.$"
-DexDescription_Shroomish_2:
- .string "This POKéMON’s spores are so toxic,\nthey make trees and weeds wilt.$"
- .else
-DexDescription_Shroomish_1:
- .string "SHROOMISH live in damp soil in the dark\ndepths of forests. They are often\nfound keeping still under fallen leaves.$"
-DexDescription_Shroomish_2:
- .string "This POKéMON feeds on compost that\nis made up of fallen, rotted leaves.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Breloom_1:
- .string "The seeds ringing BRELOOM’s tail are\nmade of hardened toxic spores. It is\nhorrible to eat the seeds.$"
-DexDescription_Breloom_2:
- .string "Just taking a bite of this POKéMON’s\nseed will cause your stomach to rumble.$"
- .else
-DexDescription_Breloom_1:
- .string "BRELOOM closes in on its foe with light\nand sprightly footwork, then throws\npunches with its stretchy arms.$"
-DexDescription_Breloom_2:
- .string "This POKéMON’s fighting technique puts\nboxers to shame.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Slakoth_1:
- .string "SLAKOTH’s heart beats just once a\nminute. Whatever happens, it is\ncontent to loaf around motionless.$"
-DexDescription_Slakoth_2:
- .string "It is rare to see this POKéMON in\nmotion.$"
- .else
-DexDescription_Slakoth_1:
- .string "SLAKOTH lolls around for over twenty\nhours every day. Because it moves so\nlittle, it does not need much food.$"
-DexDescription_Slakoth_2:
- .string "This POKéMON’s sole daily meal consists\nof just three leaves.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Vigoroth_1:
- .string "VIGOROTH is simply incapable of\nremaining still. Even when it tries to\nsleep, the blood in its veins grows$"
-DexDescription_Vigoroth_2:
- .string "agitated, compelling this POKéMON to\nrun wild throughout the jungle before\nit can settle down.$"
- .else
-DexDescription_Vigoroth_1:
- .string "VIGOROTH is always itching and agitated\nto go on a wild rampage. It simply can’t\ntolerate sitting still for even a minute.$"
-DexDescription_Vigoroth_2:
- .string "This POKéMON’s stress level rises if it\ncan’t be moving constantly.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Slaking_1:
- .string "Wherever SLAKING live, rings of over\na yard in diameter appear in grassy\nfields. They are made by the POKéMON$"
-DexDescription_Slaking_2:
- .string "as it eats all the grass within reach\nwhile lying prone on the ground.$"
- .else
-DexDescription_Slaking_1:
- .string "SLAKING spends all day lying down and\nlolling about.\nIt eats grass growing within its reach.$"
-DexDescription_Slaking_2:
- .string "If it eats all the grass it can reach,\nthis POKéMON reluctantly moves to\nanother spot.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Nincada_1:
- .string "NINCADA lives underground. It uses its\nsharp claws to carve the roots of trees\nand absorb moisture and nutrients.$"
-DexDescription_Nincada_2:
- .string "This POKéMON can’t withstand bright\nsunlight so avoids it.$"
- .else
-DexDescription_Nincada_1:
- .string "NINCADA lives underground for many\nyears in complete darkness.\nThis POKéMON absorbs nutrients from$"
-DexDescription_Nincada_2:
- .string "the roots of trees. It stays motionless\nas it waits for evolution.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Ninjask_1:
- .string "If NINJASK is not trained properly,\nit will refuse to obey the TRAINER and\ncry loudly continuously.$"
-DexDescription_Ninjask_2:
- .string "Because of this quality, this POKéMON\nis said to be one that puts the\nTRAINER’s abilities to the test.$"
- .else
-DexDescription_Ninjask_1:
- .string "NINJASK moves around at such a high\nspeed that it cannot be seen, even\nwhile its crying can be clearly heard.$"
-DexDescription_Ninjask_2:
- .string "For that reason, this POKéMON was long\nbelieved to be invisible.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Shedinja_1:
- .string "SHEDINJA is a peculiar POKéMON.\nIt seems to appear unsought in a POKé\nBALL after a NINCADA evolves.$"
-DexDescription_Shedinja_2:
- .string "This bizarre POKéMON is entirely\nimmobile - it doesn’t even breathe.$"
- .else
-DexDescription_Shedinja_1:
- .string "SHEDINJA’s hard body doesn’t move -\nnot even a twitch. In fact, its body\nappears to be merely a hollow shell.$"
-DexDescription_Shedinja_2:
- .string "It is believed that this POKéMON will\nsteal the spirit of anyone peering into\nits hollow body from its back.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Whismur_1:
- .string "WHISMUR is very timid. If it starts to\ncry loudly, it becomes startled by its\nown crying and cries even harder.$"
-DexDescription_Whismur_2:
- .string "When it finally stops crying, the\nPOKéMON goes to sleep, all tired out.$"
- .else
-DexDescription_Whismur_1:
- .string "Normally, WHISMUR’s voice is very quiet -\nit is barely audible even if one is\npaying close attention.$"
-DexDescription_Whismur_2:
- .string "However, if this POKéMON senses danger,\nit starts crying at an earsplitting\nvolume.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Loudred_1:
- .string "LOUDRED shouts while stamping its feet.\nAfter it finishes shouting, this\nPOKéMON becomes incapable of hearing$"
-DexDescription_Loudred_2:
- .string "anything for a while. This is considered\nto be a weak point.$"
- .else
-DexDescription_Loudred_1:
- .string "LOUDRED’s bellowing can completely\ndecimate a wood-frame house. It uses\nits voice to punish its foes.$"
-DexDescription_Loudred_2:
- .string "This POKéMON’s round ears serve as\nloudspeakers.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Exploud_1:
- .string "EXPLOUD communicates its feelings to\nthe others by emitting whistle-like\nsounds from the tubes on its body.$"
-DexDescription_Exploud_2:
- .string "This POKéMON only raises its voice when\nit is in battle.$"
- .else
-DexDescription_Exploud_1:
- .string "EXPLOUD triggers earthquakes with the\ntremors it creates by bellowing. If this\nPOKéMON violently inhales from the$"
-DexDescription_Exploud_2:
- .string "ports on its body, it’s a sign that it is\npreparing to let loose a huge bellow.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Makuhita_1:
- .string "MAKUHITA has a tireless spirit -\nit will never give up hope. It eats a lot\nof food, gets plenty of sleep, and it$"
-DexDescription_Makuhita_2:
- .string "trains very rigorously. By living that\nway, this POKéMON packs its body with\nenergy.$"
- .else
-DexDescription_Makuhita_1:
- .string "MAKUHITA is tenacious - it will keep\ngetting up and attacking its foe\nhowever many times it is knocked down.$"
-DexDescription_Makuhita_2:
- .string "Every time it gets back up, this\nPOKéMON stores more energy in its body\nfor evolving.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Hariyama_1:
- .string "HARIYAMA’s thick body may appear fat,\nbut it is actually a hunk of solid muscle.\nIf this POKéMON bears down and$"
-DexDescription_Hariyama_2:
- .string "tightens all its muscles, its body\nbecomes as hard as a rock.$"
- .else
-DexDescription_Hariyama_1:
- .string "HARIYAMA practices its straight-arm\nslaps in any number of locations.\nOne hit of this POKéMON’s powerful,$"
-DexDescription_Hariyama_2:
- .string "openhanded, straight-arm punches\ncould snap a telephone pole in two.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Azurill_1:
- .string "AZURILL’s tail is large and bouncy.\nIt is packed full of the nutrients this\nPOKéMON needs to grow.$"
-DexDescription_Azurill_2:
- .string "AZURILL can be seen bouncing and\nplaying on its big, rubbery tail.$"
- .else
-DexDescription_Azurill_1:
- .string "AZURILL spins its tail as if it were a\nlasso, then hurls it far. The momentum\nof the throw sends its body flying, too.$"
-DexDescription_Azurill_2:
- .string "Using this unique action, one of these\nPOKéMON managed to hurl itself a record\n33 feet.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Nosepass_1:
- .string "NOSEPASS had been said to be completely\nunmoving, with its magnetic nose\npointed due north.$"
-DexDescription_Nosepass_2:
- .string "However, close observation has revealed\nthat the POKéMON actually moves by a\nlittle over 3/8 of an inch every year.$"
- .else
-DexDescription_Nosepass_1:
- .string "NOSEPASS’s magnetic nose is always\npointed to the north. If two of these\nPOKéMON meet, they cannot turn$"
-DexDescription_Nosepass_2:
- .string "their faces to each other when they\nare close because their magnetic noses\nrepel one another.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Skitty_1:
- .string "SKITTY is known to chase around\nplayfully after its own tail. In the wild,\nthis POKéMON lives in holes in the trees$"
-DexDescription_Skitty_2:
- .string "of forests. It is very popular as a pet\nbecause of its adorable looks.$"
- .else
-DexDescription_Skitty_1:
- .string "SKITTY has the habit of becoming\nfascinated by moving objects and\nchasing them around.$"
-DexDescription_Skitty_2:
- .string "This POKéMON is known to chase after\nits own tail and become dizzy.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Delcatty_1:
- .string "DELCATTY sleeps anywhere it wants\nwithout keeping a permanent nest.\nIf other POKéMON approach it as it$"
-DexDescription_Delcatty_2:
- .string "sleeps, this POKéMON will never fight -\nit will just move away somewhere else.$"
- .else
-DexDescription_Delcatty_1:
- .string "DELCATTY prefers to live an unfettered\nexistence in which it can do as it\npleases at its own pace.$"
-DexDescription_Delcatty_2:
- .string "Because this POKéMON eats and sleeps\nwhenever it decides, its daily routines\nare completely random.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sableye_1:
- .string "SABLEYE digs the ground with sharpened\nclaws to find rocks that it eats.\nSubstances in the eaten rocks$"
-DexDescription_Sableye_2:
- .string "crystallize and rise up to the POKéMON’s\nbody surface.$"
- .else
-DexDescription_Sableye_1:
- .string "SABLEYE lead quiet lives deep inside\ncaverns. They are feared, however,\nbecause these POKéMON are thought to$"
-DexDescription_Sableye_2:
- .string "steal the spirits of people when their\neyes burn with a sinister glow in the\ndarkness.$"
- .endif
-
- .ifdef SAPPHIRE
-
-DexDescription_Mawile_1:
- .string "Don’t be taken in by this POKéMON’s\ncute face - it’s very dangerous. MAWILE\nfools the foe into letting down its$"
-DexDescription_Mawile_2:
- .string "guard, then chomps down with its\nmassive jaws. The steel jaws are really\nhorns that have been transformed.$"
-
- .else
-
- .if REVISION >= 1
-DexDescription_Mawile_1:
- .string "MAWILE’s huge jaws are actually steel\nhorns that have been transformed.\nIts docile-looking face serves to lull$"
-DexDescription_Mawile_2:
- .string "its foe into letting down its guard.\nWhen the foe least expects it, MAWILE\nchomps it with its gaping jaws.$"
- .else
-DexDescription_Mawile_1:
- .string "MAWHILE’s huge jaws are actually steel\nhorns that have been transformed.\nIts docile-looking face serves to lull$"
-DexDescription_Mawile_2:
- .string "its foe into letting down its guard.\nWhen the foe least expects it, MAWHILE\nchomps it with its gaping jaws.$"
- .endif @ REVISION >= 1
-
- .endif @ SAPPHIRE
-
- .ifdef SAPPHIRE
-DexDescription_Aron_1:
- .string "ARON has a body of steel.\nWith one all-out charge, this POKéMON\ncan demolish even a heavy dump truck.$"
-DexDescription_Aron_2:
- .string "The destroyed dump truck then becomes\na handy meal for the POKéMON.$"
- .else
-DexDescription_Aron_1:
- .string "This POKéMON has a body of steel.\nTo make its body, ARON feeds on\niron ore that it digs from mountains.$"
-DexDescription_Aron_2:
- .string "Occasionally, it causes major trouble by\neating bridges and rails.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lairon_1:
- .string "LAIRON feeds on iron contained in\nrocks and water. It makes its nest on\nmountains where iron ore is buried.$"
-DexDescription_Lairon_2:
- .string "As a result, the POKéMON often clashes\nwith humans mining the iron ore.$"
- .else
-DexDescription_Lairon_1:
- .string "LAIRON tempers its steel body by\ndrinking highly nutritious mineral\nspringwater until it is bloated.$"
-DexDescription_Lairon_2:
- .string "This POKéMON makes its nest close to\nsprings of delicious water.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Aggron_1:
- .string "AGGRON is surprisingly protective\nof its environment. If its mountain\nis ravaged by a landslide or a fire, this$"
-DexDescription_Aggron_2:
- .string "POKéMON will haul topsoil to the area,\nplant trees, and beautifully restore its\nown territory.$"
- .else
-DexDescription_Aggron_1:
- .string "AGGRON claims an entire mountain as its\nown territory. It mercilessly beats up\nanything that violates its environment.$"
-DexDescription_Aggron_2:
- .string "This POKéMON vigilantly patrols its\nterritory at all times.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Meditite_1:
- .string "MEDITITE heightens its inner energy\nthrough meditation. It survives on\njust one berry a day.$"
-DexDescription_Meditite_2:
- .string "Minimal eating is another aspect of\nthis POKéMON’s training.$"
- .else
-DexDescription_Meditite_1:
- .string "MEDITITE undertakes rigorous mental\ntraining deep in the mountains.\nHowever, whenever it meditates, this$"
-DexDescription_Meditite_2:
- .string "POKéMON always loses its concentration\nand focus. As a result, its training\nnever ends.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Medicham_1:
- .string "Through the power of meditation,\nMEDICHAM developed its sixth sense.\nIt gained the ability to use$"
-DexDescription_Medicham_2:
- .string "psychokinetic powers. This POKéMON is\nknown to meditate for a whole month\nwithout eating.$"
- .else
-DexDescription_Medicham_1:
- .string "It is said that through meditation,\nMEDICHAM heightens energy inside\nits body and sharpens its sixth sense.$"
-DexDescription_Medicham_2:
- .string "This POKéMON hides its presence by\nmerging itself with fields and\nmountains.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Electrike_1:
- .string "ELECTRIKE runs faster than the human\neye can follow. The friction from\nrunning is converted into electricity,$"
-DexDescription_Electrike_2:
- .string "which is then stored in this POKéMON’s\nfur.$"
- .else
-DexDescription_Electrike_1:
- .string "ELECTRIKE stores electricity in its\nlong body hair. This POKéMON stimulates\nits leg muscles with electric charges.$"
-DexDescription_Electrike_2:
- .string "These jolts of power give its legs\nexplosive acceleration performance.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Manectric_1:
- .string "MANECTRIC discharges strong\nelectricity from its mane. The mane is\nused for collecting electricity in the$"
-DexDescription_Manectric_2:
- .string "atmosphere. This POKéMON creates\nthunderclouds above its head.$"
- .else
-DexDescription_Manectric_1:
- .string "MANECTRIC is constantly discharging\nelectricity from its mane. The sparks\nsometimes ignite forest fires.$"
-DexDescription_Manectric_2:
- .string "When it enters a battle, this POKéMON\ncreates thunderclouds.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Plusle_1:
- .string "When PLUSLE is cheering on its partner,\nit flashes with electric sparks from all\nover its body.$"
-DexDescription_Plusle_2:
- .string "If its partner loses, this POKéMON cries\nloudly.$"
- .else
-DexDescription_Plusle_1:
- .string "PLUSLE always acts as a cheerleader\nfor its partners. Whenever a teammate\nputs out a good effort in battle, this$"
-DexDescription_Plusle_2:
- .string "POKéMON shorts out its body to create\nthe crackling noises of sparks to show\nits joy.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Minun_1:
- .string "MINUN loves to cheer on its partner in\nbattle. It gives off sparks from its\nbody while it is doing so.$"
-DexDescription_Minun_2:
- .string "If its partner is in trouble, this\nPOKéMON gives off increasing amounts\nof sparks.$"
- .else
-DexDescription_Minun_1:
- .string "MINUN is more concerned about cheering\non its partners than its own safety.\nIt shorts out the electricity in its$"
-DexDescription_Minun_2:
- .string "body to create brilliant showers of\nsparks to cheer on its teammates.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Volbeat_1:
- .string "VOLBEAT’s tail glows like a lightbulb.\nWith other VOLBEAT, it uses its tail to\ndraw geometric shapes in the night sky.$"
-DexDescription_Volbeat_2:
- .string "This POKéMON loves the sweet aroma\ngiven off by ILLUMISE.$"
- .else
-DexDescription_Volbeat_1:
- .string "With the arrival of night, VOLBEAT emits\nlight from its tail. It communicates with\nothers by adjusting the intensity and$"
-DexDescription_Volbeat_2:
- .string "flashing of its light.\nThis POKéMON is attracted by the sweet\naroma of ILLUMISE.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Illumise_1:
- .string "ILLUMISE leads a flight of illuminated\nVOLBEAT to draw signs in the night sky.\nThis POKéMON is said to earn greater$"
-DexDescription_Illumise_2:
- .string "respect from its peers by composing\nmore complex designs in the sky.$"
- .else
-DexDescription_Illumise_1:
- .string "ILLUMISE attracts a swarm of VOLBEAT\nusing a sweet fragrance. Once the\nVOLBEAT have gathered, this POKéMON$"
-DexDescription_Illumise_2:
- .string "leads the lit-up swarm in drawing\ngeometric designs on the canvas of\nthe night sky.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Roselia_1:
- .string "On extremely rare occasions, a ROSELIA\nis said to appear with its flowers in\nunusual colors.$"
-DexDescription_Roselia_2:
- .string "The thorns on this POKéMON’s head\ncontain a vicious poison.$"
- .else
-DexDescription_Roselia_1:
- .string "ROSELIA shoots sharp thorns as\nprojectiles at any opponent that tries\nto steal the flowers on its arms.$"
-DexDescription_Roselia_2:
- .string "The aroma of this POKéMON brings\nserenity to living things.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Gulpin_1:
- .string "Most of GULPIN’s body is made up of its\nstomach - its heart and brain are very\nsmall in comparison.$"
-DexDescription_Gulpin_2:
- .string "This POKéMON’s stomach contains\nspecial enzymes that dissolve anything.$"
- .else
-DexDescription_Gulpin_1:
- .string "Virtually all of GULPIN’s body is its\nstomach. As a result, it can swallow\nsomething its own size.$"
-DexDescription_Gulpin_2:
- .string "This POKéMON’s stomach contains a\nspecial fluid that digests anything.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Swalot_1:
- .string "SWALOT has no teeth, so what it\neats, it swallows whole, no matter what.\nIts cavernous mouth yawns widely.$"
-DexDescription_Swalot_2:
- .string "An automobile tire could easily fit\ninside this POKéMON’s mouth.$"
- .else
-DexDescription_Swalot_1:
- .string "When SWALOT spots prey, it spurts out\na hideously toxic fluid from its pores\nand sprays the target.$"
-DexDescription_Swalot_2:
- .string "Once the prey has weakened, this\nPOKéMON gulps it down whole with its\ncavernous mouth.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Carvanha_1:
- .string "If anything invades CARVANHA’s\nterritory, it will swarm and tear at the\nintruder with its pointed fangs.$"
-DexDescription_Carvanha_2:
- .string "On its own, however, this POKéMON turns\nsuddenly timid.$"
- .else
-DexDescription_Carvanha_1:
- .string "CARVANHA’s strongly developed jaws\nand its sharply pointed fangs pack the\ndestructive power to rip out boat hulls.$"
-DexDescription_Carvanha_2:
- .string "Many boats have been attacked and\nsunk by this POKéMON.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sharpedo_1:
- .string "SHARPEDO can swim at speeds of up to\n75 mph by jetting seawater out of its\nbackside.$"
-DexDescription_Sharpedo_2:
- .string "This POKéMON’s drawback is its inability\nto swim long distances.$"
- .else
-DexDescription_Sharpedo_1:
- .string "Nicknamed “the bully of the sea,”\nSHARPEDO is widely feared.\nIts cruel fangs grow back immediately$"
-DexDescription_Sharpedo_2:
- .string "if they snap off.\nJust one of these POKéMON can\nthoroughly tear apart a supertanker.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wailmer_1:
- .string "WAILMER can store water inside its body\nto transform itself into a ball for\nbouncing around on the ground.$"
-DexDescription_Wailmer_2:
- .string "By filling itself up with more water, this\nPOKéMON can elevate the height of its\nbounces.$"
- .else
-DexDescription_Wailmer_1:
- .string "WAILMER’s nostrils are located above\nits eyes. This playful POKéMON loves\nto startle people by forcefully snorting$"
-DexDescription_Wailmer_2:
- .string "out seawater it stores inside its body\nout of its nostrils.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wailord_1:
- .string "When chasing prey, WAILORD herds them\nby leaping out of the water and making\na humongous splash.$"
-DexDescription_Wailord_2:
- .string "It is breathtaking to see this POKéMON\nleaping out of the sea with others in\nits pod.$"
- .else
-DexDescription_Wailord_1:
- .string "WAILORD is the largest of all identified\nPOKéMON up to now.\nThis giant POKéMON swims languorously$"
-DexDescription_Wailord_2:
- .string "in the vast open sea, eating massive\namounts of food at once with its\nenormous mouth.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Numel_1:
- .string "NUMEL stores magma of almost 2,200\ndegrees F within its body. If it gets\nwet, the magma cools and hardens.$"
-DexDescription_Numel_2:
- .string "In that event, the POKéMON’s body\ngrows heavy and its movements become\nsluggish.$"
- .else
-DexDescription_Numel_1:
- .string "NUMEL is extremely dull witted - it\ndoesn’t notice being hit. However, it\ncan’t stand hunger for even a second.$"
-DexDescription_Numel_2:
- .string "This POKéMON’s body is a seething\ncauldron of boiling magma.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Camerupt_1:
- .string "The humps on CAMERUPT’s back are\nformed by a transformation of its\nbones. They sometimes blast out molten$"
-DexDescription_Camerupt_2:
- .string "magma. This POKéMON apparently erupts\noften when it is enraged.$"
- .else
-DexDescription_Camerupt_1:
- .string "CAMERUPT has a volcano inside its body.\nMagma of 18,000 degrees F courses\nthrough its body.$"
-DexDescription_Camerupt_2:
- .string "Occasionally, the humps on this\nPOKéMON’s back erupt, spewing the\nsuperheated magma.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Torkoal_1:
- .string "TORKOAL generates energy by burning\ncoal. It grows weaker as the fire\ndies down.$"
-DexDescription_Torkoal_2:
- .string "When it is preparing for battle, this\nPOKéMON burns more coal.$"
- .else
-DexDescription_Torkoal_1:
- .string "TORKOAL digs through mountains in\nsearch of coal. If it finds some, it fills\nhollow spaces on its shell with the coal$"
-DexDescription_Torkoal_2:
- .string "and burns it.\nIf it is attacked, this POKéMON spouts\nthick black smoke to beat a retreat.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Spoink_1:
- .string "SPOINK keeps a pearl on top of its head.\nThe pearl functions to amplify this\nPOKéMON’s psychokinetic powers.$"
-DexDescription_Spoink_2:
- .string "It is therefore on a constant search\nfor a bigger pearl.$"
- .else
-DexDescription_Spoink_1:
- .string "SPOINK bounces around on its tail.\nThe shock of its bouncing makes its\nheart pump. As a result, this POKéMON$"
-DexDescription_Spoink_2:
- .string "cannot afford to stop bouncing - if it\nstops, its heart will stop.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Grumpig_1:
- .string "GRUMPIG uses the black pearls on its\nbody to wield its fantastic powers.\nWhen it is doing so, it dances bizarrely.$"
-DexDescription_Grumpig_2:
- .string "This POKéMON’s black pearls are valuable\nas works of art.$"
- .else
-DexDescription_Grumpig_1:
- .string "GRUMPIG uses the black pearls on its\nbody to amplify its psychic power waves\nfor gaining total control over its foe.$"
-DexDescription_Grumpig_2:
- .string "When this POKéMON uses its special\npower, its snorting breath grows\nlabored.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Spinda_1:
- .string "No two SPINDA are said to have\nidentical spot patterns on their hides.\nThis POKéMON moves in a curious manner$"
-DexDescription_Spinda_2:
- .string "as if it is stumbling in dizziness.\nIts lurching movements can cause the\nopponent to become confused.$"
- .else
-DexDescription_Spinda_1:
- .string "All the SPINDA that exist in the\nworld are said to have utterly unique\nspot patterns.$"
-DexDescription_Spinda_2:
- .string "The shaky, tottering steps of this\nPOKéMON give it the appearance of\ndancing.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Trapinch_1:
- .string "TRAPINCH is a patient hunter. It digs\nan inescapable pit in a desert and waits\nfor its prey to come tumbling down.$"
-DexDescription_Trapinch_2:
- .string "This POKéMON can go a whole week\nwithout access to any water.$"
- .else
-DexDescription_Trapinch_1:
- .string "TRAPINCH’s nest is a sloped, bowl-like\npit dug in sand. This POKéMON patiently\nwaits for prey to tumble down the pit.$"
-DexDescription_Trapinch_2:
- .string "Its giant jaws have enough strength\nto crush even boulders.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Vibrava_1:
- .string "VIBRAVA’s wings have not yet\ncompleted the process of growing.\nRather than flying long distances,$"
-DexDescription_Vibrava_2:
- .string "they are more useful for generating\nultrasonic waves by vibrating.$"
- .else
-DexDescription_Vibrava_1:
- .string "To make prey faint, VIBRAVA generates\nultrasonic waves by vigorously making\nits two wings vibrate.$"
-DexDescription_Vibrava_2:
- .string "This POKéMON’s ultrasonic waves are so\npowerful, they can bring on headaches\nin people.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Flygon_1:
- .string "FLYGON whips up a sandstorm by\nflapping its wings. The wings create a\nseries of notes that sound like singing.$"
-DexDescription_Flygon_2:
- .string "Because the “singing” is the only thing\nthat can be heard in a sandstorm, this\nPOKéMON is said to be the desert spirit.$"
- .else
-DexDescription_Flygon_1:
- .string "FLYGON is nicknamed “the elemental \nspirit of the desert.” Because its\nflapping wings whip up a cloud of sand,$"
-DexDescription_Flygon_2:
- .string "this POKéMON is always enveloped in a\nsandstorm while flying.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Cacnea_1:
- .string "The more arid and harsh the\nenvironment, the more pretty and\nfragrant a flower CACNEA grows.$"
-DexDescription_Cacnea_2:
- .string "This POKéMON battles by wildly swinging\nits thorny arms.$"
- .else
-DexDescription_Cacnea_1:
- .string "CACNEA lives in arid locations such\nas deserts. It releases a strong aroma\nfrom its flower to attract prey.$"
-DexDescription_Cacnea_2:
- .string "When prey comes near, this POKéMON\nshoots sharp thorns from its body to\nbring the victim down.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Cacturne_1:
- .string "If a traveler is going through a desert\nin the thick of night, CACTURNE\nwill follow in a ragtag group.$"
-DexDescription_Cacturne_2:
- .string "The POKéMON are biding their time,\nwaiting for the traveler to tire and\nbecome incapable of moving.$"
- .else
-DexDescription_Cacturne_1:
- .string "During the daytime, CACTURNE remains\nunmoving so that it does not lose any\nmoisture to the harsh desert sun.$"
-DexDescription_Cacturne_2:
- .string "This POKéMON becomes active at night\nwhen the temperature drops.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Swablu_1:
- .string "SWABLU loves to make things clean.\nIf it spots something dirty, it will wipe\nand polish it with its cottony wings.$"
-DexDescription_Swablu_2:
- .string "If its wings become dirty, this POKéMON\nfinds a stream and showers itself.$"
- .else
-DexDescription_Swablu_1:
- .string "SWABLU has light and fluffy wings that\nare like cottony clouds. This POKéMON\nis not frightened of people.$"
-DexDescription_Swablu_2:
- .string "It lands on the heads of people and\nsits there like a cotton-fluff hat.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Altaria_1:
- .string "ALTARIA sings in a gorgeous soprano.\nIts wings are like cotton clouds.\nThis POKéMON catches updrafts with its$"
-DexDescription_Altaria_2:
- .string "buoyant wings and soars way up into\nthe wild blue yonder.$"
- .else
-DexDescription_Altaria_1:
- .string "ALTARIA dances and wheels through the\nsky among billowing, cotton-like clouds.\nBy singing melodies in its crystal-clear$"
-DexDescription_Altaria_2:
- .string "voice, this POKéMON makes its listeners\nexperience dreamy wonderment.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Zangoose_1:
- .string "ZANGOOSE usually stays on all fours,\nbut when angered, it gets up on its\nhind legs and extends its claws.$"
-DexDescription_Zangoose_2:
- .string "This POKéMON shares a bitter rivalry\nwith SEVIPER that dates back over\ngenerations.$"
- .else
-DexDescription_Zangoose_1:
- .string "Memories of battling its arch-rival\nSEVIPER are etched into every cell of\nZANGOOSE’s body.$"
-DexDescription_Zangoose_2:
- .string "This POKéMON adroitly dodges attacks\nwith incredible agility.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Seviper_1:
- .string "SEVIPER’s swordlike tail serves two\npurposes - it slashes foes and douses\nthem with secreted poison.$"
-DexDescription_Seviper_2:
- .string "This POKéMON will not give up its long-\nrunning blood feud with ZANGOOSE.$"
- .else
-DexDescription_Seviper_1:
- .string "SEVIPER shares a generations-long\nfeud with ZANGOOSE. The scars on its\nbody are evidence of vicious battles.$"
-DexDescription_Seviper_2:
- .string "This POKéMON attacks using its sword-\nedged tail.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lunatone_1:
- .string "LUNATONE becomes active around the\ntime of the full moon. Instead of\nwalking, it moves by floating in midair.$"
-DexDescription_Lunatone_2:
- .string "The POKéMON’s intimidating red eyes\ncause all those who see it to become\ntransfixed with fear.$"
- .else
-DexDescription_Lunatone_1:
- .string "LUNATONE was discovered at a location\nwhere a meteorite fell. As a result, some\npeople theorize that this POKéMON$"
-DexDescription_Lunatone_2:
- .string "came from space. However, no one has\nbeen able to prove this theory so far.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Solrock_1:
- .string "Sunlight is the source of SOLROCK’s\npower. It is said to possess the ability\nto read the emotions of others.$"
-DexDescription_Solrock_2:
- .string "This POKéMON gives off intense heat\nwhile rotating its body.$"
- .else
-DexDescription_Solrock_1:
- .string "SOLROCK is a new species of POKéMON\nthat is said to have fallen from space.\nIt floats in air and moves silently.$"
-DexDescription_Solrock_2:
- .string "In battle, this POKéMON releases\nintensely bright light.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Barboach_1:
- .string "BARBOACH’s body is covered with a\nslimy film. If a foe grabs it, this\nPOKéMON just slips out of the enemy’s$"
-DexDescription_Barboach_2:
- .string "grip.\nThis POKéMON grows weak if the slimy\ncoating dries up.$"
- .else
-DexDescription_Barboach_1:
- .string "BARBOACH’s sensitive whiskers serve\nas a superb radar system.\nThis POKéMON hides in mud, leaving only$"
-DexDescription_Barboach_2:
- .string "its two whiskers exposed while it waits\nfor prey to come along.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Whiscash_1:
- .string "If WHISCASH goes on a wild rampage,\nit sets off a quake-like tremor with a\nradius of over three miles.$"
-DexDescription_Whiscash_2:
- .string "This POKéMON has the ability to predict\nreal earthquakes.$"
- .else
-DexDescription_Whiscash_1:
- .string "WHISCASH is extremely territorial.\nJust one of these POKéMON will claim a\nlarge pond as its exclusive territory.$"
-DexDescription_Whiscash_2:
- .string "If a foe approaches it, it thrashes\nabout and triggers a massive\nearthquake.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Corphish_1:
- .string "CORPHISH catches prey with its sharp\nclaws. It has no likes or dislikes when it\ncomes to food - it will eat anything.$"
-DexDescription_Corphish_2:
- .string "This POKéMON has no trouble living in\nfilthy water.$"
- .else
-DexDescription_Corphish_1:
- .string "CORPHISH were originally foreign\nPOKéMON that were imported as pets.\nThey eventually turned up in the wild.$"
-DexDescription_Corphish_2:
- .string "This POKéMON is very hardy and has\ngreatly increased its population.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Crawdaunt_1:
- .string "CRAWDAUNT molts (sheds) its shell\nregularly. Immediately after molting,\nits shell is soft and tender.$"
-DexDescription_Crawdaunt_2:
- .string "Until the shell hardens, this POKéMON\nhides in its streambed burrow to avoid\nattack from its foes.$"
- .else
-DexDescription_Crawdaunt_1:
- .string "CRAWDAUNT has an extremely violent\nnature that compels it to challenge\nother living things to battle.$"
-DexDescription_Crawdaunt_2:
- .string "Other life-forms refuse to live in\nponds inhabited by this POKéMON,\nmaking them desolate places.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Baltoy_1:
- .string "As soon as it spots others of its kind,\nBALTOY congregates with them and\nthen begins crying noisily in unison.$"
-DexDescription_Baltoy_2:
- .string "This POKéMON sleeps while cleverly\nbalancing itself on its one foot.$"
- .else
-DexDescription_Baltoy_1:
- .string "BALTOY moves while spinning around on\nits one foot. Primitive wall paintings\ndepicting this POKéMON living among$"
-DexDescription_Baltoy_2:
- .string "people were discovered in some ancient\nruins.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Claydol_1:
- .string "CLAYDOL is an enigma that appeared\nfrom a clay statue made by an ancient\ncivilization dating back 20,000 years.$"
-DexDescription_Claydol_2:
- .string "This POKéMON shoots beams from both\nits hands.$"
- .else
-DexDescription_Claydol_1:
- .string "CLAYDOL are said to be dolls of mud made\nby primitive humans and brought to life\nby exposure to a mysterious ray.$"
-DexDescription_Claydol_2:
- .string "This POKéMON moves about while\nlevitating.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Lileep_1:
- .string "LILEEP is an ancient POKéMON that was\nregenerated from a fossil. It remains\npermanently anchored to a rock.$"
-DexDescription_Lileep_2:
- .string "From its immobile perch, this POKéMON\nintently scans for prey with its two\neyes.$"
- .else
-DexDescription_Lileep_1:
- .string "LILEEP became extinct approximately\na hundred million years ago.\nThis ancient POKéMON attaches itself$"
-DexDescription_Lileep_2:
- .string "to a rock on the seafloor and catches\napproaching prey using tentacles \nshaped like flower petals.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Cradily_1:
- .string "CRADILY’s body serves as an anchor,\npreventing it from being washed away in\nrough seas.$"
-DexDescription_Cradily_2:
- .string "This POKéMON secretes a strong\ndigestive fluid from its tentacles.$"
- .else
-DexDescription_Cradily_1:
- .string "CRADILY roams around the ocean floor\nin search of food. This POKéMON freely\nextends its tree trunk-like neck and$"
-DexDescription_Cradily_2:
- .string "captures unwary prey using its eight\ntentacles.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Anorith_1:
- .string "ANORITH is said to be a type of \nPOKéMON predecessor, with eight wings\nat the sides of its body.$"
-DexDescription_Anorith_2:
- .string "This POKéMON swam in the primordial sea\nby undulating these eight wings.$"
- .else
-DexDescription_Anorith_1:
- .string "ANORITH was regenerated from a\nprehistoric fossil. This primitive\nPOKéMON once lived in warm seas.$"
-DexDescription_Anorith_2:
- .string "It grips its prey firmly between its\ntwo large claws.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Armaldo_1:
- .string "ARMALDO is a POKéMON species that\nbecame extinct in prehistoric times.\nThis POKéMON is said to have walked on$"
-DexDescription_Armaldo_2:
- .string "its hind legs, which would have been\nmore convenient for life on land.$"
- .else
-DexDescription_Armaldo_1:
- .string "ARMALDO’s tough armor makes all attacks\nbounce off. This POKéMON’s two\nenormous claws can be freely extended$"
-DexDescription_Armaldo_2:
- .string "or contracted. They have the power to\npunch right through a steel slab.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Feebas_1:
- .string "While FEEBAS’s body is in tatters,\nit has a hardy and tenacious life force\nthat enables it to live anywhere.$"
-DexDescription_Feebas_2:
- .string "However, this POKéMON is also slow and\ndimwitted, making it an easy catch.$"
- .else
-DexDescription_Feebas_1:
- .string "FEEBAS’s fins are ragged and\ntattered from the start of its life.\nBecause of its shoddy appearance, this$"
-DexDescription_Feebas_2:
- .string "POKéMON is largely ignored.\nIt is capable of living in both the sea\nand in rivers.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Milotic_1:
- .string "MILOTIC live at the bottom of large\nlakes. When this POKéMON’s body glows a\nvivid pink, it releases a pulsing wave of$"
-DexDescription_Milotic_2:
- .string "energy that brings soothing calm to\nrestless spirits.$"
- .else
-DexDescription_Milotic_1:
- .string "MILOTIC is said to be the most\nbeautiful of all the POKéMON.\nIt has the power to becalm such$"
-DexDescription_Milotic_2:
- .string "emotions as anger and hostility to quell\nbitter feuding.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Castform_1:
- .string "CASTFORM borrows the power of nature\nto transform itself into the guises of\nthe sun, rain clouds, and snow clouds.$"
-DexDescription_Castform_2:
- .string "This POKéMON’s feelings change with the\nweather.$"
- .else
-DexDescription_Castform_1:
- .string "CASTFORM’s appearance changes with\nthe weather.\nThis POKéMON gained the ability to use$"
-DexDescription_Castform_2:
- .string "the vast power of nature to protect\nits tiny body.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Kecleon_1:
- .string "KECLEON alters its body coloration to\nblend in with its surroundings, allowing\nit to sneak up on its prey unnoticed.$"
-DexDescription_Kecleon_2:
- .string "Then it lashes out with its long,\nstretchy tongue to instantly ensnare\nthe unsuspecting target.$"
- .else
-DexDescription_Kecleon_1:
- .string "KECLEON is capable of changing its body\ncolors at will to blend in with its\nsurroundings.$"
-DexDescription_Kecleon_2:
- .string "There is one exception - this POKéMON\ncan’t change the zigzag pattern on its\nbelly.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Shuppet_1:
- .string "SHUPPET grows by feeding on dark\nemotions, such as vengefulness and \nenvy, in the hearts of people.$"
-DexDescription_Shuppet_2:
- .string "It roams through cities in search of\ngrudges that taint people.$"
- .else
-DexDescription_Shuppet_1:
- .string "SHUPPET is attracted by feelings\nof jealousy and vindictiveness.\nIf someone develops strong feelings of$"
-DexDescription_Shuppet_2:
- .string "vengeance, this POKéMON will appear\nin a swarm and line up beneath the eaves\nof that person’s home.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Banette_1:
- .string "A cursed energy permeated the stuffing\nof a discarded and forgotten plush doll,\ngiving it new life as BANETTE.$"
-DexDescription_Banette_2:
- .string "The POKéMON’s energy would escape if it\nwere to ever open its mouth.$"
- .else
-DexDescription_Banette_1:
- .string "BANETTE generates energy for laying\nstrong curses by sticking pins into its\nown body.$"
-DexDescription_Banette_2:
- .string "This POKéMON was originally a pitiful\nplush doll that was thrown away.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Duskull_1:
- .string "DUSKULL wanders lost among the deep\ndarkness of midnight. There is an oft-\ntold admonishment given to misbehaving$"
-DexDescription_Duskull_2:
- .string "children that this POKéMON will spirit\naway bad children who earn scoldings\nfrom their mothers.$"
- .else
-DexDescription_Duskull_1:
- .string "DUSKULL can pass through any wall no\nmatter how thick it may be.\nOnce this POKéMON chooses a target,$"
-DexDescription_Duskull_2:
- .string "it will doggedly pursue the intended\nvictim until the break of dawn.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Dusclops_1:
- .string "DUSCLOPS absorbs anything, however\nlarge the object may be. This POKéMON\nhypnotizes its foe by waving its hands$"
-DexDescription_Dusclops_2:
- .string "in a macabre manner and by bringing its\nsingle eye to bear. The hypnotized foe\nis made to do DUSCLOPS’s bidding.$"
- .else
-DexDescription_Dusclops_1:
- .string "DUSCLOPS’s body is completely hollow -\nthere is nothing at all inside.\nIt is said that its body is like a black$"
-DexDescription_Dusclops_2:
- .string "hole. This POKéMON will absorb anything\ninto its body, but nothing will ever come\nback out.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Tropius_1:
- .string "Children of the southern tropics eat\nas snacks the fruit that grows in\nbunches around the neck of TROPIUS.$"
-DexDescription_Tropius_2:
- .string "This POKéMON flies by flapping the\nleaves on its back as if they were\nwings.$"
- .else
-DexDescription_Tropius_1:
- .string "The bunches of fruit around TROPIUS’s\nneck are very popular with children.\nThis POKéMON loves fruit, and eats it$"
-DexDescription_Tropius_2:
- .string "continuously. Apparently, its love for\nfruit resulted in its own outgrowth\nof fruit.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Chimecho_1:
- .string "In high winds, CHIMECHO cries as it\nhangs from a tree branch or the eaves\nof a building using a suction cup on its$"
-DexDescription_Chimecho_2:
- .string "head.\nThis POKéMON plucks berries with its\nlong tail and eats them.$"
- .else
-DexDescription_Chimecho_1:
- .string "CHIMECHO makes its cries echo\ninside its hollow body. When this\nPOKéMON becomes enraged, its cries$"
-DexDescription_Chimecho_2:
- .string "result in ultrasonic waves that have\nthe power to knock foes flying.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Absol_1:
- .string "ABSOL has the ability to foretell the\ncoming of natural disasters.\nIt lives in a harsh, rugged mountain$"
-DexDescription_Absol_2:
- .string "environment. This POKéMON very rarely\nventures down from the mountains.$"
- .else
-DexDescription_Absol_1:
- .string "Every time ABSOL appears before people,\nit is followed by a disaster such as an\nearthquake or a tidal wave.$"
-DexDescription_Absol_2:
- .string "As a result, it came to be known as the\ndisaster POKéMON.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Wynaut_1:
- .string "WYNAUT gather on moonlit nights to play\nby squeezing up against each other.\nBy being squeezed, this POKéMON gains$"
-DexDescription_Wynaut_2:
- .string "endurance and is trained to dole out\npowerful counterattacks.$"
- .else
-DexDescription_Wynaut_1:
- .string "WYNAUT can always be seen with a big,\nhappy smile on its face. Look at its tail\nto determine if it is angry.$"
-DexDescription_Wynaut_2:
- .string "When angered, this POKéMON will be\nslapping the ground with its tail.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Snorunt_1:
- .string "SNORUNT survives by eating only snow\nand ice.\nOld folklore claims that a house visited$"
-DexDescription_Snorunt_2:
- .string "by this POKéMON is sure to prosper for\nmany generations to come.$"
- .else
-DexDescription_Snorunt_1:
- .string "SNORUNT live in regions with heavy\nsnowfall. In seasons without snow, such\nas spring and summer, this POKéMON$"
-DexDescription_Snorunt_2:
- .string "steals away to live quietly among\nstalactites and stalagmites deep in\ncaverns.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Glalie_1:
- .string "GLALIE has the ability to freely\ncontrol ice. For example, it can\ninstantly freeze its foe solid.$"
-DexDescription_Glalie_2:
- .string "After immobilizing its foe in ice, this\nPOKéMON enjoys eating it in leisurely\nfashion.$"
- .else
-DexDescription_Glalie_1:
- .string "GLALIE has a body made of rock, which it\nhardens with an armor of ice.\nThis POKéMON has the ability to freeze$"
-DexDescription_Glalie_2:
- .string "moisture in the atmosphere into any\nshape it desires.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Spheal_1:
- .string "SPHEAL always travels by rolling\naround on its ball-like body. When the\nseason for ice floes arrives, this$"
-DexDescription_Spheal_2:
- .string "POKéMON can be seen rolling about on\nice and crossing the sea.$"
- .else
-DexDescription_Spheal_1:
- .string "SPHEAL is much faster rolling than \nwalking to get around. When groups of\nthis POKéMON eat, they all clap at once$"
-DexDescription_Spheal_2:
- .string "to show their pleasure. Because of this,\ntheir mealtimes are noisy.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Sealeo_1:
- .string "SEALEO often balances and rolls\nthings on the tip of its nose. While the\nPOKéMON is rolling something, it checks$"
-DexDescription_Sealeo_2:
- .string "the object’s aroma and texture to\ndetermine whether it likes the object\nor not.$"
- .else
-DexDescription_Sealeo_1:
- .string "SEALEO has the habit of always juggling\non the tip of its nose anything it sees\nfor the first time.$"
-DexDescription_Sealeo_2:
- .string "This POKéMON occasionally entertains\nitself by balancing and rolling a SPHEAL\non its nose.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Walrein_1:
- .string "WALREIN swims all over in frigid\nseawater while crushing icebergs with\nits grand, imposing tusks.$"
-DexDescription_Walrein_2:
- .string "Its thick layer of blubber makes enemy\nattacks bounce off harmlessly.$"
- .else
-DexDescription_Walrein_1:
- .string "WALREIN’s two massively developed\ntusks can totally shatter blocks of\nice weighing ten tons with one blow.$"
-DexDescription_Walrein_2:
- .string "This POKéMON’s thick coat of blubber\ninsulates it from subzero temperatures.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Clamperl_1:
- .string "CLAMPERL grows while being protected\nby its rock-hard shell. When its body\nbecomes too large to fit inside the$"
-DexDescription_Clamperl_2:
- .string "shell, it is sure evidence that this\nPOKéMON is getting close to evolution.$"
- .else
-DexDescription_Clamperl_1:
- .string "CLAMPERL’s sturdy shell is not only good\nfor protection - it is also used for\nclamping and catching prey.$"
-DexDescription_Clamperl_2:
- .string "A fully grown CLAMPERL’s shell will be\nscored with nicks and scratches all\nover.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Huntail_1:
- .string "HUNTAIL’s tail is shaped like a fish.\nIt uses the tail to attract prey, then\nswallows the prey whole with its large,$"
-DexDescription_Huntail_2:
- .string "gaping mouth.\nThis POKéMON swims by wiggling its\nslender body like a snake.$"
- .else
-DexDescription_Huntail_1:
- .string "HUNTAIL’s presence went unnoticed by\npeople for a long time because it lives\nat extreme depths in the sea.$"
-DexDescription_Huntail_2:
- .string "This POKéMON’s eyes can see clearly\neven in the murky dark depths of the\nocean.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Gorebyss_1:
- .string "Although GOREBYSS is the very picture\nof elegance and beauty while swimming,\nit is also cruel. When it spots prey, this$"
-DexDescription_Gorebyss_2:
- .string "POKéMON inserts its thin mouth into the\nprey’s body and drains the prey of its\nbody fluids.$"
- .else
-DexDescription_Gorebyss_1:
- .string "GOREBYSS lives in the southern seas\nat extreme depths. Its body is built to\nwithstand the enormous pressure of$"
-DexDescription_Gorebyss_2:
- .string "water at incredible depths. Because of\nthis, this POKéMON’s body is unharmed\nby ordinary attacks.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Relicanth_1:
- .string "RELICANTH is a rare species that was\ndiscovered in deep-sea explorations.\nThis POKéMON’s body withstands the$"
-DexDescription_Relicanth_2:
- .string "enormous water pressure of the ocean\ndepths. Its body is covered in tough\nscales that are like craggy rocks.$"
- .else
-DexDescription_Relicanth_1:
- .string "RELICANTH is a POKéMON species that\nexisted for a hundred million years\nwithout ever changing its form.$"
-DexDescription_Relicanth_2:
- .string "This ancient POKéMON feeds on\nmicroscopic organisms with its\ntoothless mouth.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Luvdisc_1:
- .string "LUVDISC’s heart-shaped body is a\nsymbol of love and romance.\nIt is said that any couple meeting this$"
-DexDescription_Luvdisc_2:
- .string "POKéMON is promised a loving\nrelationship that never ends.$"
- .else
-DexDescription_Luvdisc_1:
- .string "LUVDISC live in shallow seas in the\ntropics. This heart-shaped POKéMON\nearned its name by swimming after$"
-DexDescription_Luvdisc_2:
- .string "loving couples it spotted in the\nocean’s waves.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Bagon_1:
- .string "BAGON harbors a never-ending dream of\none day soaring high among the clouds.\nAs if trying to dispel its frustration$"
-DexDescription_Bagon_2:
- .string "over its inability to fly, this POKéMON\nslams its hard head against huge rocks\nand shatters them into pebbles.$"
- .else
-DexDescription_Bagon_1:
- .string "BAGON has a dream of one day soaring\nin the sky. In doomed efforts to fly,\nthis POKéMON hurls itself off cliffs.$"
-DexDescription_Bagon_2:
- .string "As a result of its dives, its head has \ngrown tough and as hard as tempered\nsteel.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Shelgon_1:
- .string "Covering SHELGON’s body are outgrowths\nmuch like bones. The shell is very hard\nand bounces off enemy attacks.$"
-DexDescription_Shelgon_2:
- .string "When awaiting evolution, this POKéMON\nhides away in a cavern.$"
- .else
-DexDescription_Shelgon_1:
- .string "Inside SHELGON’s armor-like shell, cells\nare in the midst of transformation\nto create an entirely new body.$"
-DexDescription_Shelgon_2:
- .string "This POKéMON’s shell is extremely heavy,\nmaking its movements sluggish.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Salamence_1:
- .string "By evolving into SALAMENCE, this\nPOKéMON finally realizes its long-held\ndream of growing wings.$"
-DexDescription_Salamence_2:
- .string "To express its joy, it flies and wheels\nall over the sky while spouting flames\nfrom its mouth.$"
- .else
-DexDescription_Salamence_1:
- .string "SALAMENCE came about as a result of a\nstrong, long-held dream of growing\nwings. It is said that this powerful$"
-DexDescription_Salamence_2:
- .string "desire triggered a sudden mutation in\nthis POKéMON’s cells, causing it to\nsprout its magnificent wings.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Beldum_1:
- .string "BELDUM keeps itself floating by\ngenerating a magnetic force that\nrepels earth’s natural magnetism.$"
-DexDescription_Beldum_2:
- .string "When it sleeps, this POKéMON anchors\nitself to a cliff using the hooks on\nits rear.$"
- .else
-DexDescription_Beldum_1:
- .string "Instead of blood, a powerful magnetic\nforce courses throughout BELDUM’s\nbody. This POKéMON communicates with$"
-DexDescription_Beldum_2:
- .string "others by sending controlled pulses of\nmagnetism.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Metang_1:
- .string "When two BELDUM fuse together, METANG\nis formed. The brains of the BELDUM are\njoined by a magnetic nervous system.$"
-DexDescription_Metang_2:
- .string "This POKéMON turns its arms to the rear\nfor traveling at high speed.$"
- .else
-DexDescription_Metang_1:
- .string "When two BELDUM fuse together, METANG\nis formed. The brains of the BELDUM are\njoined by a magnetic nervous system.$"
-DexDescription_Metang_2:
- .string "By linking its brains magnetically,\nthis POKéMON generates strong\npsychokinetic power.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Metagross_1:
- .string "METAGROSS is the result of two METANG\nachieving fusion. When hunting, this\nPOKéMON pins the prey to the ground$"
-DexDescription_Metagross_2:
- .string "under its massive body. It then eats\nthe helpless victim using the large \nmouth on its stomach.$"
- .else
-DexDescription_Metagross_1:
- .string "METAGROSS has four brains in total.\nCombined, the four brains can breeze\nthrough difficult calculations faster$"
-DexDescription_Metagross_2:
- .string "than a supercomputer.\nThis POKéMON can float in the air by\ntucking in its four legs.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Regirock_1:
- .string "REGIROCK’s body is composed entirely of\nrocks. Recently, a study made the\nstartling discovery that the rocks$"
-DexDescription_Regirock_2:
- .string "were all unearthed from different\nlocations.$"
- .else
-DexDescription_Regirock_1:
- .string "REGIROCK was sealed away by people\nlong ago. If this POKéMON’s body is\ndamaged in battle, it is said to seek$"
-DexDescription_Regirock_2:
- .string "out suitable rocks on its own to repair\nitself.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Regice_1:
- .string "REGICE cloaks itself with frigid air of\nnegative 328 degrees F.\nThings will freeze solid just by going$"
-DexDescription_Regice_2:
- .string "near this POKéMON.\nIts icy body is so cold, it will not melt\neven if it is immersed in magma.$"
- .else
-DexDescription_Regice_1:
- .string "REGICE’s body was made during an ice\nage. The deep-frozen body can’t be\nmelted, even by fire.$"
-DexDescription_Regice_2:
- .string "This POKéMON controls frigid air of\nminus 328 degrees F.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Registeel_1:
- .string "REGISTEEL was imprisoned by people\nin ancient times.\nThe metal composing its body is thought$"
-DexDescription_Registeel_2:
- .string "to be a curious substance that is not\nof this earth.$"
- .else
-DexDescription_Registeel_1:
- .string "REGISTEEL has a body that is harder\nthan any kind of metal.\nIts body is apparently hollow.$"
-DexDescription_Registeel_2:
- .string "No one has any idea what this POKéMON\neats.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Latias_1:
- .string "LATIAS is highly intelligent and capable\nof understanding human speech.\nIt is covered with a glass-like down.$"
-DexDescription_Latias_2:
- .string "The POKéMON enfolds its body with its\ndown and refracts light to alter its\nappearance.$"
- .else
-DexDescription_Latias_1:
- .string "LATIAS is highly sensitive to the\nemotions of people. If it senses any\nhostility, this POKéMON ruffles the$"
-DexDescription_Latias_2:
- .string "feathers all over its body and cries\nshrilly to intimidate the foe.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Latios_1:
- .string "LATIOS will only open its heart to a\nTRAINER with a compassionate spirit.\nThis POKéMON can fly faster than a jet$"
-DexDescription_Latios_2:
- .string "plane by folding its forelegs to minimize\nair resistance.$"
- .else
-DexDescription_Latios_1:
- .string "LATIOS has the ability to make its foe\nsee an image of what it has seen or\nimagines in its head.$"
-DexDescription_Latios_2:
- .string "This POKéMON is intelligent and\nunderstands human speech.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Kyogre_1:
- .string "KYOGRE is named in mythology as the\nPOKéMON that expanded the sea by\ncovering the land with torrential rains$"
-DexDescription_Kyogre_2:
- .string "and towering tidal waves.\nIt took to sleep after a cataclysmic\nbattle with GROUDON.$"
- .else
-DexDescription_Kyogre_1:
- .string "KYOGRE has the power to create massive\nrain clouds that cover the entire sky\nand bring about torrential downpours.$"
-DexDescription_Kyogre_2:
- .string "This POKéMON saved people who were\nsuffering from droughts.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Groudon_1:
- .string "GROUDON has the power to scatter rain\nclouds and make water evaporate with\nlight and heat.$"
-DexDescription_Groudon_2:
- .string "It came as a savior to people who had\nbeen suffering from terrible floods.$"
- .else
-DexDescription_Groudon_1:
- .string "GROUDON has long been described in \nmythology as the POKéMON that raised\nlands and expanded continents.$"
-DexDescription_Groudon_2:
- .string "This POKéMON took to sleep after a\ncataclysmic battle with KYOGRE.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Rayquaza_1:
- .string "RAYQUAZA is said to have lived for\nhundreds of millions of years in the\nearth’s ozone layer, above the clouds.$"
-DexDescription_Rayquaza_2:
- .string "Its existence had been completely\nunknown because it lived so high in\nthe sky.$"
- .else
-DexDescription_Rayquaza_1:
- .string "RAYQUAZA lived for hundreds of millions\nof years in the earth’s ozone layer, \nnever descending to the ground.$"
-DexDescription_Rayquaza_2:
- .string "This POKéMON appears to feed on water\nand particles in the atmosphere.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Jirachi_1:
- .string "JIRACHI will awaken from its sleep of\na thousand years if you sing to it in a\nvoice of purity.$"
-DexDescription_Jirachi_2:
- .string "It is said to make true any wish that\npeople desire.$"
- .else
-DexDescription_Jirachi_1:
- .string "A legend states that JIRACHI will make\ntrue any wish that is written on notes\nattached to its head when it awakens.$"
-DexDescription_Jirachi_2:
- .string "If this POKéMON senses danger, it will\nfight without awakening.$"
- .endif
-
- .ifdef SAPPHIRE
-DexDescription_Deoxys_1:
- .string "DEOXYS emerged from a virus that came\nfrom space. It is highly intelligent and\nwields psychokinetic powers.$"
-DexDescription_Deoxys_2:
- .string "This POKéMON shoots lasers from the\ncrystalline organ on its chest.$"
- .else
-DexDescription_Deoxys_1:
- .string "The DNA of a space virus underwent a\nsudden mutation upon exposure to a\nlaser beam and resulted in DEOXYS.$"
-DexDescription_Deoxys_2:
- .string "The crystalline organ on this POKéMON’s\nchest appears to be its brain.$"
- .endif
-
-@ Unfortunately, preproc doesn't allow us to use strings inside macros,
-@ so the category names have to be on separate lines.
-
- .align 2
-gPokedexEntries:: @ 83B1858
- .string "UNKNOWN$", 12
- pokedex_entry Dummy, 0, 0, 256, 0, 256, 0
- .string "SEED$", 12
- pokedex_entry Bulbasaur, 7, 69, 356, 17, 256, 0
- .string "SEED$", 12
- pokedex_entry Ivysaur, 10, 130, 335, 13, 256, 0
- .string "SEED$", 12
- pokedex_entry Venusaur, 20, 1000, 256, 0, 388, 6
- .string "LIZARD$", 12
- pokedex_entry Charmander, 6, 85, 444, 18, 256, 0
- .string "FLAME$", 12
- pokedex_entry Charmeleon, 11, 190, 302, 9, 256, 0
- .string "FLAME$", 12
- pokedex_entry Charizard, 17, 905, 256, 1, 302, 3
- .string "TINY TURTLE$", 12
- pokedex_entry Squirtle, 5, 90, 412, 18, 256, 0
- .string "TURTLE$", 12
- pokedex_entry Wartortle, 10, 225, 332, 10, 256, 0
- .string "SHELLFISH$", 12
- pokedex_entry Blastoise, 16, 855, 256, -1, 293, 2
- .string "WORM$", 12
- pokedex_entry Caterpie, 3, 29, 549, 22, 256, 0
- .string "COCOON$", 12
- pokedex_entry Metapod, 7, 99, 350, 18, 256, 0
- .string "BUTTERFLY$", 12
- pokedex_entry Butterfree, 11, 320, 312, 2, 256, 0
- .string "HAIRY BUG$", 12
- pokedex_entry Weedle, 3, 32, 455, 22, 256, 0
- .string "COCOON$", 12
- pokedex_entry Kakuna, 6, 100, 424, 17, 256, 0
- .string "POISON BEE$", 12
- pokedex_entry Beedrill, 10, 295, 366, 2, 256, 0
- .string "TINY BIRD$", 12
- pokedex_entry Pidgey, 3, 18, 508, -3, 256, 0
- .string "BIRD$", 12
- pokedex_entry Pidgeotto, 11, 300, 331, 10, 256, 0
- .string "BIRD$", 12
- pokedex_entry Pidgeot, 15, 395, 269, 0, 256, 0
- .string "MOUSE$", 12
- pokedex_entry Rattata, 3, 35, 481, 21, 256, 0
- .string "MOUSE$", 12
- pokedex_entry Raticate, 7, 185, 459, 18, 256, 0
- .string "TINY BIRD$", 12
- pokedex_entry Spearow, 3, 20, 571, 22, 256, 0
- .string "BEAK$", 12
- pokedex_entry Fearow, 12, 380, 278, 1, 256, 0
- .string "SNAKE$", 12
- pokedex_entry Ekans, 20, 69, 298, 12, 256, 0
- .string "COBRA$", 12
- pokedex_entry Arbok, 35, 650, 256, 0, 296, 2
- .string "MOUSE$", 12
- pokedex_entry Pikachu, 4, 60, 479, 19, 256, 0
- .string "MOUSE$", 12
- pokedex_entry Raichu, 8, 300, 426, 13, 256, 0
- .string "MOUSE$", 12
- pokedex_entry Sandshrew, 6, 120, 365, 18, 256, 0
- .string "MOUSE$", 12
- pokedex_entry Sandslash, 10, 295, 341, 11, 256, 0
- .string "POISON PIN$", 12
- pokedex_entry NidoranF, 4, 70, 488, 21, 256, 0
- .string "POISON PIN$", 12
- pokedex_entry Nidorina, 8, 200, 381, 15, 256, 0
- .string "DRILL$", 12
- pokedex_entry Nidoqueen, 13, 600, 293, 4, 256, 0
- .string "POISON PIN$", 12
- pokedex_entry NidoranM, 5, 90, 511, 20, 256, 0
- .string "POISON PIN$", 12
- pokedex_entry Nidorino, 9, 195, 408, 15, 256, 0
- .string "DRILL$", 12
- pokedex_entry Nidoking, 14, 620, 256, 0, 256, 0
- .string "FAIRY$", 12
- pokedex_entry Clefairy, 6, 75, 441, 20, 256, 0
- .string "FAIRY$", 12
- pokedex_entry Clefable, 13, 400, 256, 5, 256, 0
- .string "FOX$", 12
- pokedex_entry Vulpix, 6, 99, 542, 19, 256, 0
- .string "FOX$", 12
- pokedex_entry Ninetales, 11, 199, 339, 10, 256, 0
- .string "BALLOON$", 12
- pokedex_entry Jigglypuff, 5, 55, 433, 2, 256, 0
- .string "BALLOON$", 12
- pokedex_entry Wigglytuff, 10, 120, 328, 11, 256, 0
- .string "BAT$", 12
- pokedex_entry Zubat, 8, 75, 362, -5, 256, 0
- .string "BAT$", 12
- pokedex_entry Golbat, 16, 550, 256, 1, 256, 0
- .string "WEED$", 12
- pokedex_entry Oddish, 5, 54, 423, 19, 256, 0
- .string "WEED$", 12
- pokedex_entry Gloom, 8, 86, 329, 13, 256, 0
- .string "FLOWER$", 12
- pokedex_entry Vileplume, 12, 186, 256, 4, 256, 0
- .string "MUSHROOM$", 12
- pokedex_entry Paras, 3, 54, 593, 22, 256, 0
- .string "MUSHROOM$", 12
- pokedex_entry Parasect, 10, 295, 307, 8, 256, 0
- .string "INSECT$", 12
- pokedex_entry Venonat, 10, 300, 360, 0, 256, -1
- .string "POISON MOTH$", 12
- pokedex_entry Venomoth, 15, 125, 285, 2, 256, 1
- .string "MOLE$", 12
- pokedex_entry Diglett, 2, 8, 833, 25, 256, 0
- .string "MOLE$", 12
- pokedex_entry Dugtrio, 7, 333, 406, 18, 256, 0
- .string "SCRATCH CAT$", 12
- pokedex_entry Meowth, 4, 42, 480, 19, 256, 0
- .string "CLASSY CAT$", 12
- pokedex_entry Persian, 10, 320, 320, 10, 256, 0
- .string "DUCK$", 12
- pokedex_entry Psyduck, 8, 196, 369, 15, 256, 0
- .string "DUCK$", 12
- pokedex_entry Golduck, 17, 766, 256, 1, 273, 1
- .string "PIG MONKEY$", 12
- pokedex_entry Mankey, 5, 280, 404, 19, 256, 0
- .string "PIG MONKEY$", 12
- pokedex_entry Primeape, 10, 320, 326, 10, 256, 0
- .string "PUPPY$", 12
- pokedex_entry Growlithe, 7, 190, 346, 14, 256, 0
- .string "LEGENDARY$", 12
- pokedex_entry Arcanine, 19, 1550, 256, 1, 312, 4
- .string "TADPOLE$", 12
- pokedex_entry Poliwag, 6, 124, 369, 20, 256, 0
- .string "TADPOLE$", 12
- pokedex_entry Poliwhirl, 10, 200, 288, 11, 256, 0
- .string "TADPOLE$", 12
- pokedex_entry Poliwrath, 13, 540, 256, 6, 256, 0
- .string "PSI$", 12
- pokedex_entry Abra, 9, 195, 363, 14, 256, 0
- .string "PSI$", 12
- pokedex_entry Kadabra, 13, 565, 256, 3, 256, 0
- .string "PSI$", 12
- pokedex_entry Alakazam, 15, 480, 256, 3, 256, 0
- .string "SUPERPOWER$", 12
- pokedex_entry Machop, 8, 195, 342, 14, 256, 0
- .string "SUPERPOWER$", 12
- pokedex_entry Machoke, 15, 705, 323, 9, 257, 0
- .string "SUPERPOWER$", 12
- pokedex_entry Machamp, 16, 1300, 280, 1, 269, -1
- .string "FLOWER$", 12
- pokedex_entry Bellsprout, 7, 40, 354, 16, 256, 0
- .string "FLYCATCHER$", 12
- pokedex_entry Weepinbell, 10, 64, 256, 0, 256, 0
- .string "FLYCATCHER$", 12
- pokedex_entry Victreebel, 17, 155, 256, 1, 312, 3
- .string "JELLYFISH$", 12
- pokedex_entry Tentacool, 9, 455, 256, 0, 256, 0
- .string "JELLYFISH$", 12
- pokedex_entry Tentacruel, 16, 550, 256, 0, 312, 1
- .string "ROCK$", 12
- pokedex_entry Geodude, 4, 200, 347, 18, 256, 0
- .string "ROCK$", 12
- pokedex_entry Graveler, 10, 1050, 256, 2, 256, 0
- .string "MEGATON$", 12
- pokedex_entry Golem, 14, 3000, 256, 3, 296, 2
- .string "FIRE HORSE$", 12
- pokedex_entry Ponyta, 10, 300, 283, 8, 256, 0
- .string "FIRE HORSE$", 12
- pokedex_entry Rapidash, 17, 950, 256, 0, 289, 1
- .string "DOPEY$", 12
- pokedex_entry Slowpoke, 12, 360, 256, 10, 256, 0
- .string "HERMIT CRAB$", 12
- pokedex_entry Slowbro, 16, 785, 256, 6, 296, 2
- .string "MAGNET$", 12
- pokedex_entry Magnemite, 3, 60, 288, -9, 256, 0
- .string "MAGNET$", 12
- pokedex_entry Magneton, 10, 600, 292, 1, 256, 0
- .string "WILD DUCK$", 12
- pokedex_entry Farfetchd, 8, 150, 330, 2, 293, 2
- .string "TWIN BIRD$", 12
- pokedex_entry Doduo, 14, 392, 256, 3, 257, -1
- .string "TRIPLE BIRD$", 12
- pokedex_entry Dodrio, 18, 852, 256, 0, 268, 0
- .string "SEA LION$", 12
- pokedex_entry Seel, 11, 900, 297, 8, 256, 0
- .string "SEA LION$", 12
- pokedex_entry Dewgong, 17, 1200, 256, 0, 275, 0
- .string "SLUDGE$", 12
- pokedex_entry Grimer, 9, 300, 258, 10, 256, 0
- .string "SLUDGE$", 12
- pokedex_entry Muk, 12, 300, 256, 2, 256, 0
- .string "BIVALVE$", 12
- pokedex_entry Shellder, 3, 40, 675, 24, 256, 0
- .string "BIVALVE$", 12
- pokedex_entry Cloyster, 15, 1325, 256, 0, 269, 1
- .string "GAS$", 12
- pokedex_entry Gastly, 13, 1, 256, 0, 256, 0
- .string "GAS$", 12
- pokedex_entry Haunter, 16, 1, 256, 2, 293, 2
- .string "SHADOW$", 12
- pokedex_entry Gengar, 15, 405, 256, 2, 302, 2
- .string "ROCK SNAKE$", 12
- pokedex_entry Onix, 88, 2100, 256, 1, 515, 14
- .string "HYPNOSIS$", 12
- pokedex_entry Drowzee, 10, 324, 274, 6, 256, 0
- .string "HYPNOSIS$", 12
- pokedex_entry Hypno, 16, 756, 256, 3, 257, 0
- .string "RIVER CRAB$", 12
- pokedex_entry Krabby, 4, 65, 469, 20, 256, 0
- .string "PINCER$", 12
- pokedex_entry Kingler, 13, 600, 256, 2, 256, 0
- .string "BALL$", 12
- pokedex_entry Voltorb, 5, 104, 364, -8, 256, 0
- .string "BALL$", 12
- pokedex_entry Electrode, 12, 666, 256, 0, 256, 0
- .string "EGG$", 12
- pokedex_entry Exeggcute, 4, 25, 489, -4, 256, 0
- .string "COCONUT$", 12
- pokedex_entry Exeggutor, 20, 1200, 256, 0, 309, 5
- .string "LONELY$", 12
- pokedex_entry Cubone, 4, 65, 545, 21, 256, 0
- .string "BONE KEEPER$", 12
- pokedex_entry Marowak, 10, 450, 293, 12, 256, 0
- .string "KICKING$", 12
- pokedex_entry Hitmonlee, 15, 498, 256, 3, 259, 1
- .string "PUNCHING$", 12
- pokedex_entry Hitmonchan, 14, 502, 256, 2, 277, 2
- .string "LICKING$", 12
- pokedex_entry Lickitung, 12, 655, 256, 4, 256, 0
- .string "POISON GAS$", 12
- pokedex_entry Koffing, 6, 10, 369, -1, 256, 0
- .string "POISON GAS$", 12
- pokedex_entry Weezing, 12, 95, 305, 3, 256, 0
- .string "SPIKES$", 12
- pokedex_entry Rhyhorn, 10, 1150, 267, 6, 256, 0
- .string "DRILL$", 12
- pokedex_entry Rhydon, 19, 1200, 256, 1, 299, 2
- .string "EGG$", 12
- pokedex_entry Chansey, 11, 346, 257, 7, 256, 0
- .string "VINE$", 12
- pokedex_entry Tangela, 10, 350, 304, 1, 256, 0
- .string "PARENT$", 12
- pokedex_entry Kangaskhan, 22, 800, 256, 0, 387, 8
- .string "DRAGON$", 12
- pokedex_entry Horsea, 4, 80, 399, -1, 256, 0
- .string "DRAGON$", 12
- pokedex_entry Seadra, 12, 250, 299, 3, 256, 0
- .string "GOLDFISH$", 12
- pokedex_entry Goldeen, 6, 150, 379, 4, 256, 0
- .string "GOLDFISH$", 12
- pokedex_entry Seaking, 13, 390, 256, 3, 256, 0
- .string "STAR SHAPE$", 12
- pokedex_entry Staryu, 8, 345, 326, 1, 256, 0
- .string "MYSTERIOUS$", 12
- pokedex_entry Starmie, 11, 800, 301, 3, 256, 0
- .string "BARRIER$", 12
- pokedex_entry Mrmime, 13, 545, 258, 6, 256, 0
- .string "MANTIS$", 12
- pokedex_entry Scyther, 15, 560, 256, 1, 293, 2
- .string "HUMAN SHAPE$", 12
- pokedex_entry Jynx, 14, 406, 256, 3, 300, 1
- .string "ELECTRIC$", 12
- pokedex_entry Electabuzz, 11, 300, 351, 8, 256, 0
- .string "SPITFIRE$", 12
- pokedex_entry Magmar, 13, 445, 277, 5, 256, 0
- .string "STAG BEETLE$", 12
- pokedex_entry Pinsir, 15, 550, 256, 2, 257, 0
- .string "WILD BULL$", 12
- pokedex_entry Tauros, 14, 884, 256, 0, 256, 0
- .string "FISH$", 12
- pokedex_entry Magikarp, 9, 100, 310, 4, 256, 0
- .string "ATROCIOUS$", 12
- pokedex_entry Gyarados, 65, 2350, 256, 6, 481, 13
- .string "TRANSPORT$", 12
- pokedex_entry Lapras, 25, 2200, 257, 10, 423, 8
- .string "TRANSFORM$", 12
- pokedex_entry Ditto, 3, 40, 633, 23, 256, 0
- .string "EVOLUTION$", 12
- pokedex_entry Eevee, 3, 65, 476, 18, 256, 0
- .string "BUBBLE JET$", 12
- pokedex_entry Vaporeon, 10, 290, 316, 8, 256, 0
- .string "LIGHTNING$", 12
- pokedex_entry Jolteon, 8, 245, 283, 8, 256, 0
- .string "FLAME$", 12
- pokedex_entry Flareon, 9, 250, 306, 12, 256, 0
- .string "VIRTUAL$", 12
- pokedex_entry Porygon, 8, 365, 328, 15, 256, 0
- .string "SPIRAL$", 12
- pokedex_entry Omanyte, 4, 75, 521, 22, 256, 0
- .string "SPIRAL$", 12
- pokedex_entry Omastar, 10, 350, 307, 7, 256, 0
- .string "SHELLFISH$", 12
- pokedex_entry Kabuto, 5, 115, 454, 21, 256, 0
- .string "SHELLFISH$", 12
- pokedex_entry Kabutops, 13, 405, 271, 3, 256, 0
- .string "FOSSIL$", 12
- pokedex_entry Aerodactyl, 18, 590, 256, 0, 302, 4
- .string "SLEEPING$", 12
- pokedex_entry Snorlax, 21, 4600, 256, 4, 423, 11
- .string "FREEZE$", 12
- pokedex_entry Articuno, 17, 554, 256, 0, 309, 2
- .string "ELECTRIC$", 12
- pokedex_entry Zapdos, 16, 526, 256, 0, 318, 3
- .string "FLAME$", 12
- pokedex_entry Moltres, 20, 600, 270, 0, 387, 8
- .string "DRAGON$", 12
- pokedex_entry Dratini, 18, 33, 256, 8, 386, 6
- .string "DRAGON$", 12
- pokedex_entry Dragonair, 40, 165, 256, 0, 411, 5
- .string "DRAGON$", 12
- pokedex_entry Dragonite, 22, 2100, 256, 0, 309, 4
- .string "GENETIC$", 12
- pokedex_entry Mewtwo, 20, 1220, 256, 0, 309, 4
- .string "NEW SPECIES$", 12
- pokedex_entry Mew, 4, 40, 457, -2, 256, 0
- .string "LEAF$", 12
- pokedex_entry Chikorita, 9, 64, 512, 20, 256, 0
- .string "LEAF$", 12
- pokedex_entry Bayleef, 12, 158, 296, 4, 256, 0
- .string "HERB$", 12
- pokedex_entry Meganium, 18, 1005, 256, 0, 277, 1
- .string "FIRE MOUSE$", 12
- pokedex_entry Cyndaquil, 5, 79, 539, 21, 256, 0
- .string "VOLCANO$", 12
- pokedex_entry Quilava, 9, 190, 329, 11, 256, 0
- .string "VOLCANO$", 12
- pokedex_entry Typhlosion, 17, 795, 256, 0, 268, 1
- .string "BIG JAW$", 12
- pokedex_entry Totodile, 6, 95, 487, 20, 256, 0
- .string "BIG JAW$", 12
- pokedex_entry Croconaw, 11, 250, 378, 13, 256, 0
- .string "BIG JAW$", 12
- pokedex_entry Feraligatr, 23, 888, 256, 0, 342, 7
- .string "SCOUT$", 12
- pokedex_entry Sentret, 8, 60, 439, 12, 256, 0
- .string "LONG BODY$", 12
- pokedex_entry Furret, 18, 325, 346, 11, 256, 0
- .string "OWL$", 12
- pokedex_entry Hoothoot, 7, 212, 380, -2, 256, 0
- .string "OWL$", 12
- pokedex_entry Noctowl, 16, 408, 278, 3, 256, 0
- .string "FIVE STAR$", 12
- pokedex_entry Ledyba, 10, 108, 256, 4, 256, 0
- .string "FIVE STAR$", 12
- pokedex_entry Ledian, 14, 356, 256, 2, 256, 0
- .string "STRING SPIT$", 12
- pokedex_entry Spinarak, 5, 85, 414, 21, 256, 0
- .string "LONG LEG$", 12
- pokedex_entry Ariados, 11, 335, 316, 8, 256, 0
- .string "BAT$", 12
- pokedex_entry Crobat, 18, 750, 256, 0, 281, 1
- .string "ANGLER$", 12
- pokedex_entry Chinchou, 5, 120, 424, -2, 256, 0
- .string "LIGHT$", 12
- pokedex_entry Lanturn, 12, 225, 269, 6, 256, 0
- .string "TINY MOUSE$", 12
- pokedex_entry Pichu, 3, 20, 508, 20, 256, 0
- .string "STAR SHAPE$", 12
- pokedex_entry Cleffa, 3, 30, 462, 23, 256, 0
- .string "BALLOON$", 12
- pokedex_entry Igglybuff, 3, 10, 457, -1, 256, 0
- .string "SPIKE BALL$", 12
- pokedex_entry Togepi, 3, 15, 507, 23, 256, 0
- .string "HAPPINESS$", 12
- pokedex_entry Togetic, 6, 32, 424, 17, 256, 0
- .string "TINY BIRD$", 12
- pokedex_entry Natu, 2, 20, 610, 25, 256, 0
- .string "MYSTIC$", 12
- pokedex_entry Xatu, 15, 150, 256, 6, 318, 4
- .string "WOOL$", 12
- pokedex_entry Mareep, 6, 78, 379, 18, 256, 0
- .string "WOOL$", 12
- pokedex_entry Flaaffy, 8, 133, 372, 15, 256, 0
- .string "LIGHT$", 12
- pokedex_entry Ampharos, 14, 615, 256, 4, 256, 0
- .string "FLOWER$", 12
- pokedex_entry Bellossom, 4, 58, 472, 21, 256, 0
- .string "AQUA MOUSE$", 12
- pokedex_entry Marill, 4, 85, 476, 20, 256, 0
- .string "AQUA RABBIT$", 12
- pokedex_entry Azumarill, 8, 285, 448, 16, 256, 0
- .string "IMITATION$", 12
- pokedex_entry Sudowoodo, 12, 380, 305, 8, 256, 0
- .string "FROG$", 12
- pokedex_entry Politoed, 11, 339, 289, 6, 256, 0
- .string "COTTONWEED$", 12
- pokedex_entry Hoppip, 4, 5, 562, -7, 256, 0
- .string "COTTONWEED$", 12
- pokedex_entry Skiploom, 6, 10, 387, 0, 256, 0
- .string "COTTONWEED$", 12
- pokedex_entry Jumpluff, 8, 30, 418, -4, 256, 0
- .string "LONG TAIL$", 12
- pokedex_entry Aipom, 8, 115, 363, 6, 256, 0
- .string "SEED$", 12
- pokedex_entry Sunkern, 3, 18, 541, 0, 256, 0
- .string "SUN$", 12
- pokedex_entry Sunflora, 8, 85, 444, 15, 256, 0
- .string "CLEAR WING$", 12
- pokedex_entry Yanma, 12, 380, 274, -1, 256, 0
- .string "WATER FISH$", 12
- pokedex_entry Wooper, 4, 85, 479, 21, 256, 0
- .string "WATER FISH$", 12
- pokedex_entry Quagsire, 14, 750, 256, 4, 256, 0
- .string "SUN$", 12
- pokedex_entry Espeon, 9, 265, 363, 14, 256, 0
- .string "MOONLIGHT$", 12
- pokedex_entry Umbreon, 10, 270, 317, 11, 256, 0
- .string "DARKNESS$", 12
- pokedex_entry Murkrow, 5, 21, 401, -8, 256, 1
- .string "ROYAL$", 12
- pokedex_entry Slowking, 20, 795, 256, 0, 309, 5
- .string "SCREECH$", 12
- pokedex_entry Misdreavus, 7, 10, 407, -8, 256, 0
- .string "SYMBOL$", 12
- pokedex_entry Unown, 5, 50, 411, 2, 256, 0
- .string "PATIENT$", 12
- pokedex_entry Wobbuffet, 13, 285, 274, 4, 256, 0
- .string "LONG NECK$", 12
- pokedex_entry Girafarig, 15, 415, 281, 1, 256, 0
- .string "BAGWORM$", 12
- pokedex_entry Pineco, 6, 72, 445, 2, 256, 0
- .string "BAGWORM$", 12
- pokedex_entry Forretress, 12, 1258, 293, 5, 256, 0
- .string "LAND SNAKE$", 12
- pokedex_entry Dunsparce, 15, 140, 316, 17, 256, 0
- .string "FLYSCORPION$", 12
- pokedex_entry Gligar, 11, 648, 350, -1, 256, 0
- .string "IRON SNAKE$", 12
- pokedex_entry Steelix, 92, 4000, 256, 0, 516, 13
- .string "FAIRY$", 12
- pokedex_entry Snubbull, 6, 78, 465, 19, 256, 0
- .string "FAIRY$", 12
- pokedex_entry Granbull, 14, 487, 256, 4, 256, 0
- .string "BALLOON$", 12
- pokedex_entry Qwilfish, 5, 39, 430, 0, 256, 0
- .string "PINCER$", 12
- pokedex_entry Scizor, 18, 1180, 278, 1, 256, 0
- .string "MOLD$", 12
- pokedex_entry Shuckle, 6, 205, 485, 18, 256, 0
- .string "SINGLE HORN$", 12
- pokedex_entry Heracross, 15, 540, 256, 0, 256, 0
- .string "SHARP CLAW$", 12
- pokedex_entry Sneasel, 9, 280, 413, -3, 256, 0
- .string "LITTLE BEAR$", 12
- pokedex_entry Teddiursa, 6, 88, 455, 19, 256, 0
- .string "HIBERNATOR$", 12
- pokedex_entry Ursaring, 18, 1258, 256, 0, 256, 0
- .string "LAVA$", 12
- pokedex_entry Slugma, 7, 350, 329, 15, 256, 0
- .string "LAVA$", 12
- pokedex_entry Magcargo, 8, 550, 332, 15, 256, 0
- .string "PIG$", 12
- pokedex_entry Swinub, 4, 65, 324, 20, 256, 0
- .string "SWINE$", 12
- pokedex_entry Piloswine, 11, 558, 306, 10, 256, 0
- .string "CORAL$", 12
- pokedex_entry Corsola, 6, 50, 410, 15, 256, 0
- .string "JET$", 12
- pokedex_entry Remoraid, 6, 120, 316, 4, 256, 0
- .string "JET$", 12
- pokedex_entry Octillery, 9, 285, 296, 3, 256, 0
- .string "DELIVERY$", 12
- pokedex_entry Delibird, 9, 160, 293, 11, 256, 0
- .string "KITE$", 12
- pokedex_entry Mantine, 21, 2200, 256, 0, 342, 7
- .string "ARMOR BIRD$", 12
- pokedex_entry Skarmory, 17, 505, 256, 0, 271, 1
- .string "DARK$", 12
- pokedex_entry Houndour, 6, 108, 393, 16, 256, 0
- .string "DARK$", 12
- pokedex_entry Houndoom, 14, 350, 256, 4, 256, 0
- .string "DRAGON$", 12
- pokedex_entry Kingdra, 18, 1520, 256, 0, 287, 0
- .string "LONG NOSE$", 12
- pokedex_entry Phanpy, 5, 335, 465, 21, 256, 0
- .string "ARMOR$", 12
- pokedex_entry Donphan, 11, 1200, 313, 9, 256, 0
- .string "VIRTUAL$", 12
- pokedex_entry Porygon2, 6, 325, 320, 17, 256, 0
- .string "BIG HORN$", 12
- pokedex_entry Stantler, 14, 712, 256, 0, 256, 0
- .string "PAINTER$", 12
- pokedex_entry Smeargle, 12, 580, 287, 5, 256, 0
- .string "SCUFFLE$", 12
- pokedex_entry Tyrogue, 7, 210, 292, 9, 256, 0
- .string "HANDSTAND$", 12
- pokedex_entry Hitmontop, 14, 480, 256, 2, 257, 0
- .string "KISS$", 12
- pokedex_entry Smoochum, 4, 60, 440, 20, 256, 0
- .string "ELECTRIC$", 12
- pokedex_entry Elekid, 6, 235, 363, 14, 256, 0
- .string "LIVE COAL$", 12
- pokedex_entry Magby, 7, 214, 284, 13, 256, 0
- .string "MILK COW$", 12
- pokedex_entry Miltank, 12, 755, 280, 5, 256, 0
- .string "HAPPINESS$", 12
- pokedex_entry Blissey, 15, 468, 256, 4, 310, 3
- .string "THUNDER$", 12
- pokedex_entry Raikou, 19, 1780, 256, 0, 345, 7
- .string "VOLCANO$", 12
- pokedex_entry Entei, 21, 1980, 259, 0, 345, 7
- .string "AURORA$", 12
- pokedex_entry Suicune, 20, 1870, 269, 0, 345, 7
- .string "ROCK SKIN$", 12
- pokedex_entry Larvitar, 6, 720, 472, 18, 256, 0
- .string "HARD SHELL$", 12
- pokedex_entry Pupitar, 12, 1520, 292, 8, 256, 0
- .string "ARMOR$", 12
- pokedex_entry Tyranitar, 20, 2020, 256, 0, 345, 7
- .string "DIVING$", 12
- pokedex_entry Lugia, 52, 2160, 256, 0, 721, 19
- .string "RAINBOW$", 12
- pokedex_entry HoOh, 38, 1990, 256, 0, 610, 17
- .string "TIME TRAVEL$", 12
- pokedex_entry Celebi, 6, 50, 393, -10, 256, 0
- .string "WOOD GECKO$", 12
- pokedex_entry Treecko, 5, 50, 541, 19, 256, 0
- .string "WOOD GECKO$", 12
- pokedex_entry Grovyle, 9, 216, 360, 5, 256, 0
- .string "FOREST$", 12
- pokedex_entry Sceptile, 17, 522, 256, -1, 275, 2
- .string "CHICK$", 12
- pokedex_entry Torchic, 4, 25, 566, 19, 256, 0
- .string "YOUNG FOWL$", 12
- pokedex_entry Combusken, 9, 195, 343, 5, 256, 0
- .string "BLAZE$", 12
- pokedex_entry Blaziken, 19, 520, 256, 0, 301, 4
- .string "MUD FISH$", 12
- pokedex_entry Mudkip, 4, 76, 535, 20, 256, 0
- .string "MUD FISH$", 12
- pokedex_entry Marshtomp, 7, 280, 340, 7, 256, 0
- .string "MUD FISH$", 12
- pokedex_entry Swampert, 15, 819, 256, 0, 256, 0
- .string "BITE$", 12
- pokedex_entry Poochyena, 5, 136, 481, 19, 256, 0
- .string "BITE$", 12
- pokedex_entry Mightyena, 10, 370, 362, 9, 256, 0
- .string "TINYRACCOON$", 12
- pokedex_entry Zigzagoon, 4, 175, 560, 22, 256, 0
- .string "RUSHING$", 12
- pokedex_entry Linoone, 5, 325, 321, 7, 256, 0
- .string "WORM$", 12
- pokedex_entry Wurmple, 3, 36, 711, 24, 256, 0
- .string "COCOON$", 12
- pokedex_entry Silcoon, 6, 100, 431, 19, 256, 0
- .string "BUTTERFLY$", 12
- pokedex_entry Beautifly, 10, 284, 298, -1, 256, 0
- .string "COCOON$", 12
- pokedex_entry Cascoon, 7, 115, 391, 20, 256, 0
- .string "POISON MOTH$", 12
- pokedex_entry Dustox, 12, 316, 269, 1, 256, 0
- .string "WATER WEED$", 12
- pokedex_entry Lotad, 5, 26, 406, 19, 256, 0
- .string "JOLLY$", 12
- pokedex_entry Lombre, 12, 325, 277, 9, 256, 0
- .string "CAREFREE$", 12
- pokedex_entry Ludicolo, 15, 550, 256, 0, 268, -1
- .string "ACORN$", 12
- pokedex_entry Seedot, 5, 40, 472, 20, 256, 0
- .string "WILY$", 12
- pokedex_entry Nuzleaf, 10, 280, 299, 10, 256, 0
- .string "WICKED$", 12
- pokedex_entry Shiftry, 13, 596, 290, 4, 256, 0
- .string "TINYSWALLOW$", 12
- pokedex_entry Taillow, 3, 23, 465, 21, 256, 0
- .string "SWALLOW$", 12
- pokedex_entry Swellow, 7, 198, 428, 15, 256, 0
- .string "SEAGULL$", 12
- pokedex_entry Wingull, 6, 95, 295, -2, 256, 0
- .string "WATER BIRD$", 12
- pokedex_entry Pelipper, 12, 280, 288, 1, 256, 0
- .string "FEELING$", 12
- pokedex_entry Ralts, 4, 66, 457, -3, 256, 0
- .string "EMOTION$", 12
- pokedex_entry Kirlia, 8, 202, 354, 0, 256, 0
- .string "EMBRACE$", 12
- pokedex_entry Gardevoir, 16, 484, 256, 0, 256, 0
- .string "POND SKATER$", 12
- pokedex_entry Surskit, 5, 17, 375, 17, 256, 0
- .string "EYEBALL$", 12
- pokedex_entry Masquerain, 8, 36, 378, 8, 256, 0
- .string "MUSHROOM$", 12
- pokedex_entry Shroomish, 4, 45, 513, 22, 256, 0
- .string "MUSHROOM$", 12
- pokedex_entry Breloom, 12, 392, 324, 6, 256, 0
- .string "SLACKER$", 12
- pokedex_entry Slakoth, 8, 240, 291, 16, 256, 0
- .string "WILD MONKEY$", 12
- pokedex_entry Vigoroth, 14, 465, 301, 2, 256, 0
- .string "LAZY$", 12
- pokedex_entry Slaking, 20, 1305, 256, 2, 300, 1
- .string "TRAINEE$", 12
- pokedex_entry Nincada, 5, 55, 405, 21, 256, 0
- .string "NINJA$", 12
- pokedex_entry Ninjask, 8, 120, 383, -9, 256, 0
- .string "SHED$", 12
- pokedex_entry Shedinja, 8, 12, 372, -8, 256, 0
- .string "WHISPER$", 12
- pokedex_entry Whismur, 6, 163, 373, 17, 256, 0
- .string "BIG VOICE$", 12
- pokedex_entry Loudred, 10, 405, 356, 10, 256, 0
- .string "LOUD NOISE$", 12
- pokedex_entry Exploud, 15, 840, 284, 1, 256, 0
- .string "GUTS$", 12
- pokedex_entry Makuhita, 10, 864, 256, 10, 256, 0
- .string "ARM THRUST$", 12
- pokedex_entry Hariyama, 23, 2538, 256, 0, 343, 7
- .string "POLKA DOT$", 12
- pokedex_entry Azurill, 2, 20, 603, 23, 256, 0
- .string "COMPASS$", 12
- pokedex_entry Nosepass, 10, 970, 256, 9, 289, 3
- .string "KITTEN$", 12
- pokedex_entry Skitty, 6, 110, 492, 19, 256, 0
- .string "PRIM$", 12
- pokedex_entry Delcatty, 11, 326, 322, 10, 256, 0
- .string "DARKNESS$", 12
- pokedex_entry Sableye, 5, 110, 451, 17, 256, 0
- .string "DECEIVER$", 12
- pokedex_entry Mawile, 6, 115, 466, 17, 256, 0
- .string "IRON ARMOR$", 12
- pokedex_entry Aron, 4, 600, 419, 23, 256, 0
- .string "IRON ARMOR$", 12
- pokedex_entry Lairon, 9, 1200, 275, 12, 256, 0
- .string "IRON ARMOR$", 12
- pokedex_entry Aggron, 21, 3600, 256, -1, 350, 6
- .string "MEDITATE$", 12
- pokedex_entry Meditite, 6, 112, 465, 17, 256, 0
- .string "MEDITATE$", 12
- pokedex_entry Medicham, 13, 315, 298, 5, 256, 0
- .string "LIGHTNING$", 12
- pokedex_entry Electrike, 6, 152, 290, 15, 256, 0
- .string "DISCHARGE$", 12
- pokedex_entry Manectric, 15, 402, 256, 3, 257, 0
- .string "CHEERING$", 12
- pokedex_entry Plusle, 4, 42, 515, -9, 256, 0
- .string "CHEERING$", 12
- pokedex_entry Minun, 4, 42, 512, -7, 256, 0
- .string "FIREFLY$", 12
- pokedex_entry Volbeat, 7, 177, 442, 16, 256, 0
- .string "FIREFLY$", 12
- pokedex_entry Illumise, 6, 177, 572, 19, 256, 0
- .string "THORN$", 12
- pokedex_entry Roselia, 3, 20, 677, 20, 256, 0
- .string "STOMACH$", 12
- pokedex_entry Gulpin, 4, 103, 593, 23, 256, 0
- .string "POISON BAG$", 12
- pokedex_entry Swalot, 17, 800, 256, 6, 345, 3
- .string "SAVAGE$", 12
- pokedex_entry Carvanha, 8, 208, 362, 0, 256, 0
- .string "BRUTAL$", 12
- pokedex_entry Sharpedo, 18, 888, 256, 0, 317, 3
- .string "BALL WHALE$", 12
- pokedex_entry Wailmer, 20, 1300, 256, 2, 493, 0
- .string "FLOAT WHALE$", 12
- pokedex_entry Wailord, 145, 3980, 256, 0, 1352, 18
- .string "NUMB$", 12
- pokedex_entry Numel, 7, 240, 342, 17, 256, 0
- .string "ERUPTION$", 12
- pokedex_entry Camerupt, 19, 2200, 256, 7, 345, 6
- .string "COAL$", 12
- pokedex_entry Torkoal, 5, 804, 390, 9, 256, 0
- .string "BOUNCE$", 12
- pokedex_entry Spoink, 7, 306, 423, 17, 256, 0
- .string "MANIPULATE$", 12
- pokedex_entry Grumpig, 9, 715, 358, 10, 256, 0
- .string "SPOT PANDA$", 12
- pokedex_entry Spinda, 11, 50, 321, 4, 256, 0
- .string "ANT PIT$", 12
- pokedex_entry Trapinch, 7, 150, 298, 17, 256, 0
- .string "VIBRATION$", 12
- pokedex_entry Vibrava, 11, 153, 370, 11, 256, 0
- .string "MYSTIC$", 12
- pokedex_entry Flygon, 20, 820, 256, 0, 268, 1
- .string "CACTUS$", 12
- pokedex_entry Cacnea, 4, 513, 455, 20, 256, 0
- .string "SCARECROW$", 12
- pokedex_entry Cacturne, 13, 774, 327, 5, 256, 0
- .string "COTTON BIRD$", 12
- pokedex_entry Swablu, 4, 12, 422, -8, 256, 0
- .string "HUMMING$", 12
- pokedex_entry Altaria, 11, 206, 327, 0, 256, 0
- .string "CAT FERRET$", 12
- pokedex_entry Zangoose, 13, 403, 256, 3, 256, 0
- .string "FANG SNAKE$", 12
- pokedex_entry Seviper, 27, 525, 275, 7, 256, 0
- .string "METEORITE$", 12
- pokedex_entry Lunatone, 10, 1680, 300, 3, 256, 0
- .string "METEORITE$", 12
- pokedex_entry Solrock, 12, 1540, 328, 0, 256, 0
- .string "WHISKERS$", 12
- pokedex_entry Barboach, 4, 19, 581, -3, 256, 0
- .string "WHISKERS$", 12
- pokedex_entry Whiscash, 9, 236, 317, 1, 256, 0
- .string "RUFFIAN$", 12
- pokedex_entry Corphish, 6, 115, 484, 19, 256, 0
- .string "ROGUE$", 12
- pokedex_entry Crawdaunt, 11, 328, 365, 9, 256, 0
- .string "CLAY DOLL$", 12
- pokedex_entry Baltoy, 5, 215, 457, 21, 256, 0
- .string "CLAY DOLL$", 12
- pokedex_entry Claydol, 15, 1080, 256, 3, 280, 1
- .string "SEA LILY$", 12
- pokedex_entry Lileep, 10, 238, 305, 8, 256, 0
- .string "BARNACLE$", 12
- pokedex_entry Cradily, 15, 604, 267, 0, 256, 0
- .string "OLD SHRIMP$", 12
- pokedex_entry Anorith, 7, 125, 296, 4, 256, 0
- .string "PLATE$", 12
- pokedex_entry Armaldo, 15, 682, 312, 3, 271, 0
- .string "FISH$", 12
- pokedex_entry Feebas, 6, 74, 423, -4, 256, 0
- .string "TENDER$", 12
- pokedex_entry Milotic, 62, 1620, 256, 0, 360, 7
- .string "WEATHER$", 12
- pokedex_entry Castform, 3, 8, 435, -5, 256, 0
- .string "COLOR SWAP$", 12
- pokedex_entry Kecleon, 10, 220, 316, 10, 256, 0
- .string "PUPPET$", 12
- pokedex_entry Shuppet, 6, 23, 440, 20, 256, 0
- .string "MARIONETTE$", 12
- pokedex_entry Banette, 11, 125, 262, 9, 256, 0
- .string "REQUIEM$", 12
- pokedex_entry Duskull, 8, 150, 406, -4, 256, 0
- .string "BECKON$", 12
- pokedex_entry Dusclops, 16, 306, 256, 3, 299, 1
- .string "FRUIT$", 12
- pokedex_entry Tropius, 20, 1000, 256, 0, 344, 7
- .string "WIND CHIME$", 12
- pokedex_entry Chimecho, 6, 10, 505, 0, 256, 0
- .string "DISASTER$", 12
- pokedex_entry Absol, 12, 470, 301, 3, 256, 0
- .string "BRIGHT$", 12
- pokedex_entry Wynaut, 6, 140, 484, 19, 256, 0
- .string "SNOW HAT$", 12
- pokedex_entry Snorunt, 7, 168, 380, 15, 256, 0
- .string "FACE$", 12
- pokedex_entry Glalie, 15, 2565, 256, 3, 344, 0
- .string "CLAP$", 12
- pokedex_entry Spheal, 8, 395, 315, 16, 256, 0
- .string "BALL ROLL$", 12
- pokedex_entry Sealeo, 11, 876, 338, 13, 256, 0
- .string "ICE BREAK$", 12
- pokedex_entry Walrein, 14, 1506, 316, 4, 256, 0
- .string "BIVALVE$", 12
- pokedex_entry Clamperl, 4, 525, 691, 22, 256, 0
- .string "DEEP SEA$", 12
- pokedex_entry Huntail, 17, 270, 307, 1, 256, 0
- .string "SOUTH SEA$", 12
- pokedex_entry Gorebyss, 18, 226, 278, 5, 256, 0
- .string "LONGEVITY$", 12
- pokedex_entry Relicanth, 10, 234, 316, 7, 256, 0
- .string "RENDEZVOUS$", 12
- pokedex_entry Luvdisc, 6, 87, 371, 2, 256, 0
- .string "ROCK HEAD$", 12
- pokedex_entry Bagon, 6, 421, 448, 18, 256, 0
- .string "ENDURANCE$", 12
- pokedex_entry Shelgon, 11, 1105, 311, 12, 256, 0
- .string "DRAGON$", 12
- pokedex_entry Salamence, 15, 1026, 256, 0, 256, 0
- .string "IRON BALL$", 12
- pokedex_entry Beldum, 6, 952, 414, -1, 256, 0
- .string "IRON CLAW$", 12
- pokedex_entry Metang, 12, 2025, 256, 6, 256, 0
- .string "IRON LEG$", 12
- pokedex_entry Metagross, 16, 5500, 256, 4, 447, 9
- .string "ROCK PEAK$", 12
- pokedex_entry Regirock, 17, 2300, 256, 2, 309, 1
- .string "ICEBERG$", 12
- pokedex_entry Regice, 18, 1750, 256, 0, 301, 2
- .string "IRON$", 12
- pokedex_entry Registeel, 19, 2050, 256, 0, 359, 6
- .string "EON$", 12
- pokedex_entry Latias, 14, 400, 304, 3, 256, 0
- .string "EON$", 12
- pokedex_entry Latios, 20, 600, 256, 0, 294, 3
- .string "SEA BASIN$", 12
- pokedex_entry Kyogre, 45, 3520, 256, 0, 614, 13
- .string "CONTINENT$", 12
- pokedex_entry Groudon, 35, 9500, 256, 0, 515, 14
- .string "SKY HIGH$", 12
- pokedex_entry Rayquaza, 70, 2065, 256, 0, 448, 12
- .string "WISH$", 12
- pokedex_entry Jirachi, 3, 11, 608, -8, 256, 0
- .string "DNA$", 12
- pokedex_entry Deoxys, 17, 608, 256, 0, 290, 2
diff --git a/data/pokedex_orders.inc b/data/pokedex_orders.inc
deleted file mode 100644
index db1cf7e07..000000000
--- a/data/pokedex_orders.inc
+++ /dev/null
@@ -1,1191 +0,0 @@
- .align 1
-gPokedexOrder_Alphabetical:: @ 839FAC4
- .2byte 387
- .2byte 388
- .2byte 389
- .2byte 390
- .2byte 391
- .2byte 392
- .2byte 393
- .2byte 394
- .2byte 395
- .2byte 396
- .2byte 397
- .2byte 398
- .2byte 399
- .2byte 400
- .2byte 401
- .2byte 402
- .2byte 403
- .2byte 404
- .2byte 405
- .2byte 406
- .2byte 407
- .2byte 408
- .2byte 409
- .2byte 410
- .2byte 411
- .2byte 63 @ Abra
- .2byte 359 @ Absol
- .2byte 142 @ Aerodactyl
- .2byte 306 @ Aggron
- .2byte 190 @ Aipom
- .2byte 65 @ Alakazam
- .2byte 334 @ Altaria
- .2byte 181 @ Ampharos
- .2byte 347 @ Anorith
- .2byte 24 @ Arbok
- .2byte 59 @ Arcanine
- .2byte 168 @ Ariados
- .2byte 348 @ Armaldo
- .2byte 304 @ Aron
- .2byte 144 @ Articuno
- .2byte 184 @ Azumarill
- .2byte 298 @ Azurill
- .2byte 371 @ Bagon
- .2byte 343 @ Baltoy
- .2byte 354 @ Banette
- .2byte 339 @ Barboach
- .2byte 153 @ Bayleef
- .2byte 267 @ Beautifly
- .2byte 15 @ Beedrill
- .2byte 374 @ Beldum
- .2byte 182 @ Bellossom
- .2byte 69 @ Bellsprout
- .2byte 9 @ Blastoise
- .2byte 257 @ Blaziken
- .2byte 242 @ Blissey
- .2byte 286 @ Breloom
- .2byte 1 @ Bulbasaur
- .2byte 12 @ Butterfree
- .2byte 331 @ Cacnea
- .2byte 332 @ Cacturne
- .2byte 323 @ Camerupt
- .2byte 318 @ Carvanha
- .2byte 268 @ Cascoon
- .2byte 351 @ Castform
- .2byte 10 @ Caterpie
- .2byte 251 @ Celebi
- .2byte 113 @ Chansey
- .2byte 6 @ Charizard
- .2byte 4 @ Charmander
- .2byte 5 @ Charmeleon
- .2byte 152 @ Chikorita
- .2byte 358 @ Chimecho
- .2byte 170 @ Chinchou
- .2byte 366 @ Clamperl
- .2byte 344 @ Claydol
- .2byte 36 @ Clefable
- .2byte 35 @ Clefairy
- .2byte 173 @ Cleffa
- .2byte 91 @ Cloyster
- .2byte 256 @ Combusken
- .2byte 341 @ Corphish
- .2byte 222 @ Corsola
- .2byte 346 @ Cradily
- .2byte 342 @ Crawdaunt
- .2byte 169 @ Crobat
- .2byte 159 @ Croconaw
- .2byte 104 @ Cubone
- .2byte 155 @ Cyndaquil
- .2byte 301 @ Delcatty
- .2byte 225 @ Delibird
- .2byte 386 @ Deoxys
- .2byte 87 @ Dewgong
- .2byte 50 @ Diglett
- .2byte 132 @ Ditto
- .2byte 85 @ Dodrio
- .2byte 84 @ Doduo
- .2byte 232 @ Donphan
- .2byte 148 @ Dragonair
- .2byte 149 @ Dragonite
- .2byte 147 @ Dratini
- .2byte 96 @ Drowzee
- .2byte 51 @ Dugtrio
- .2byte 206 @ Dunsparce
- .2byte 356 @ Dusclops
- .2byte 355 @ Duskull
- .2byte 269 @ Dustox
- .2byte 133 @ Eevee
- .2byte 23 @ Ekans
- .2byte 125 @ Electabuzz
- .2byte 309 @ Electrike
- .2byte 101 @ Electrode
- .2byte 239 @ Elekid
- .2byte 244 @ Entei
- .2byte 196 @ Espeon
- .2byte 102 @ Exeggcute
- .2byte 103 @ Exeggutor
- .2byte 295 @ Exploud
- .2byte 83 @ Farfetch’d
- .2byte 22 @ Fearow
- .2byte 349 @ Feebas
- .2byte 160 @ Feraligatr
- .2byte 180 @ Flaaffy
- .2byte 136 @ Flareon
- .2byte 330 @ Flygon
- .2byte 205 @ Forretress
- .2byte 162 @ Furret
- .2byte 282 @ Gardevoir
- .2byte 92 @ Gastly
- .2byte 94 @ Gengar
- .2byte 74 @ Geodude
- .2byte 203 @ Girafarig
- .2byte 362 @ Glalie
- .2byte 207 @ Gligar
- .2byte 44 @ Gloom
- .2byte 42 @ Golbat
- .2byte 118 @ Goldeen
- .2byte 55 @ Golduck
- .2byte 76 @ Golem
- .2byte 368 @ Gorebyss
- .2byte 210 @ Granbull
- .2byte 75 @ Graveler
- .2byte 88 @ Grimer
- .2byte 383 @ Groudon
- .2byte 253 @ Grovyle
- .2byte 58 @ Growlithe
- .2byte 326 @ Grumpig
- .2byte 316 @ Gulpin
- .2byte 130 @ Gyarados
- .2byte 297 @ Hariyama
- .2byte 93 @ Haunter
- .2byte 214 @ Heracross
- .2byte 107 @ Hitmonchan
- .2byte 106 @ Hitmonlee
- .2byte 237 @ Hitmontop
- .2byte 250 @ Ho-Oh
- .2byte 163 @ Hoothoot
- .2byte 187 @ Hoppip
- .2byte 116 @ Horsea
- .2byte 229 @ Houndoom
- .2byte 228 @ Houndour
- .2byte 367 @ Huntail
- .2byte 97 @ Hypno
- .2byte 174 @ Igglybuff
- .2byte 314 @ Illumise
- .2byte 2 @ Ivysaur
- .2byte 39 @ Jigglypuff
- .2byte 385 @ Jirachi
- .2byte 135 @ Jolteon
- .2byte 189 @ Jumpluff
- .2byte 124 @ Jynx
- .2byte 140 @ Kabuto
- .2byte 141 @ Kabutops
- .2byte 64 @ Kadabra
- .2byte 14 @ Kakuna
- .2byte 115 @ Kangaskhan
- .2byte 352 @ Kecleon
- .2byte 230 @ Kingdra
- .2byte 99 @ Kingler
- .2byte 281 @ Kirlia
- .2byte 109 @ Koffing
- .2byte 98 @ Krabby
- .2byte 382 @ Kyogre
- .2byte 305 @ Lairon
- .2byte 171 @ Lanturn
- .2byte 131 @ Lapras
- .2byte 246 @ Larvitar
- .2byte 380 @ Latias
- .2byte 381 @ Latios
- .2byte 166 @ Ledian
- .2byte 165 @ Ledyba
- .2byte 108 @ Lickitung
- .2byte 345 @ Lileep
- .2byte 264 @ Linoone
- .2byte 271 @ Lombre
- .2byte 270 @ Lotad
- .2byte 294 @ Loudred
- .2byte 272 @ Ludicolo
- .2byte 249 @ Lugia
- .2byte 337 @ Lunatone
- .2byte 370 @ Luvdisc
- .2byte 68 @ Machamp
- .2byte 67 @ Machoke
- .2byte 66 @ Machop
- .2byte 240 @ Magby
- .2byte 219 @ Magcargo
- .2byte 129 @ Magikarp
- .2byte 126 @ Magmar
- .2byte 81 @ Magnemite
- .2byte 82 @ Magneton
- .2byte 296 @ Makuhita
- .2byte 310 @ Manectric
- .2byte 56 @ Mankey
- .2byte 226 @ Mantine
- .2byte 179 @ Mareep
- .2byte 183 @ Marill
- .2byte 105 @ Marowak
- .2byte 259 @ Marshtomp
- .2byte 284 @ Masquerain
- .2byte 303 @ Mawile
- .2byte 308 @ Medicham
- .2byte 307 @ Meditite
- .2byte 154 @ Meganium
- .2byte 52 @ Meowth
- .2byte 376 @ Metagross
- .2byte 375 @ Metang
- .2byte 11 @ Metapod
- .2byte 151 @ Mew
- .2byte 150 @ Mewtwo
- .2byte 262 @ Mightyena
- .2byte 350 @ Milotic
- .2byte 241 @ Miltank
- .2byte 312 @ Minun
- .2byte 200 @ Misdreavus
- .2byte 146 @ Moltres
- .2byte 122 @ Mr. mime
- .2byte 258 @ Mudkip
- .2byte 89 @ Muk
- .2byte 198 @ Murkrow
- .2byte 177 @ Natu
- .2byte 34 @ Nidoking
- .2byte 31 @ Nidoqueen
- .2byte 29 @ Nidoran♀
- .2byte 32 @ Nidoran♂
- .2byte 30 @ Nidorina
- .2byte 33 @ Nidorino
- .2byte 290 @ Nincada
- .2byte 38 @ Ninetales
- .2byte 291 @ Ninjask
- .2byte 164 @ Noctowl
- .2byte 299 @ Nosepass
- .2byte 322 @ Numel
- .2byte 274 @ Nuzleaf
- .2byte 224 @ Octillery
- .2byte 43 @ Oddish
- .2byte 138 @ Omanyte
- .2byte 139 @ Omastar
- .2byte 95 @ Onix
- .2byte 46 @ Paras
- .2byte 47 @ Parasect
- .2byte 279 @ Pelipper
- .2byte 53 @ Persian
- .2byte 231 @ Phanpy
- .2byte 172 @ Pichu
- .2byte 18 @ Pidgeot
- .2byte 17 @ Pidgeotto
- .2byte 16 @ Pidgey
- .2byte 25 @ Pikachu
- .2byte 221 @ Piloswine
- .2byte 204 @ Pineco
- .2byte 127 @ Pinsir
- .2byte 311 @ Plusle
- .2byte 186 @ Politoed
- .2byte 60 @ Poliwag
- .2byte 61 @ Poliwhirl
- .2byte 62 @ Poliwrath
- .2byte 77 @ Ponyta
- .2byte 261 @ Poochyena
- .2byte 137 @ Porygon
- .2byte 233 @ Porygon2
- .2byte 57 @ Primeape
- .2byte 54 @ Psyduck
- .2byte 247 @ Pupitar
- .2byte 195 @ Quagsire
- .2byte 156 @ Quilava
- .2byte 211 @ Qwilfish
- .2byte 26 @ Raichu
- .2byte 243 @ Raikou
- .2byte 280 @ Ralts
- .2byte 78 @ Rapidash
- .2byte 20 @ Raticate
- .2byte 19 @ Rattata
- .2byte 384 @ Rayquaza
- .2byte 378 @ Regice
- .2byte 377 @ Regirock
- .2byte 379 @ Registeel
- .2byte 369 @ Relicanth
- .2byte 223 @ Remoraid
- .2byte 112 @ Rhydon
- .2byte 111 @ Rhyhorn
- .2byte 315 @ Roselia
- .2byte 302 @ Sableye
- .2byte 373 @ Salamence
- .2byte 27 @ Sandshrew
- .2byte 28 @ Sandslash
- .2byte 254 @ Sceptile
- .2byte 212 @ Scizor
- .2byte 123 @ Scyther
- .2byte 117 @ Seadra
- .2byte 119 @ Seaking
- .2byte 364 @ Sealeo
- .2byte 273 @ Seedot
- .2byte 86 @ Seel
- .2byte 161 @ Sentret
- .2byte 336 @ Seviper
- .2byte 319 @ Sharpedo
- .2byte 292 @ Shedinja
- .2byte 372 @ Shelgon
- .2byte 90 @ Shellder
- .2byte 275 @ Shiftry
- .2byte 285 @ Shroomish
- .2byte 213 @ Shuckle
- .2byte 353 @ Shuppet
- .2byte 266 @ Silcoon
- .2byte 227 @ Skarmory
- .2byte 188 @ Skiploom
- .2byte 300 @ Skitty
- .2byte 289 @ Slaking
- .2byte 287 @ Slakoth
- .2byte 80 @ Slowbro
- .2byte 199 @ Slowking
- .2byte 79 @ Slowpoke
- .2byte 218 @ Slugma
- .2byte 235 @ Smeargle
- .2byte 238 @ Smoochum
- .2byte 215 @ Sneasel
- .2byte 143 @ Snorlax
- .2byte 361 @ Snorunt
- .2byte 209 @ Snubbull
- .2byte 338 @ Solrock
- .2byte 21 @ Spearow
- .2byte 363 @ Spheal
- .2byte 167 @ Spinarak
- .2byte 327 @ Spinda
- .2byte 325 @ Spoink
- .2byte 7 @ Squirtle
- .2byte 234 @ Stantler
- .2byte 121 @ Starmie
- .2byte 120 @ Staryu
- .2byte 208 @ Steelix
- .2byte 185 @ Sudowoodo
- .2byte 245 @ Suicune
- .2byte 192 @ Sunflora
- .2byte 191 @ Sunkern
- .2byte 283 @ Surskit
- .2byte 333 @ Swablu
- .2byte 317 @ Swalot
- .2byte 260 @ Swampert
- .2byte 277 @ Swellow
- .2byte 220 @ Swinub
- .2byte 276 @ Taillow
- .2byte 114 @ Tangela
- .2byte 128 @ Tauros
- .2byte 216 @ Teddiursa
- .2byte 72 @ Tentacool
- .2byte 73 @ Tentacruel
- .2byte 175 @ Togepi
- .2byte 176 @ Togetic
- .2byte 255 @ Torchic
- .2byte 324 @ Torkoal
- .2byte 158 @ Totodile
- .2byte 328 @ Trapinch
- .2byte 252 @ Treecko
- .2byte 357 @ Tropius
- .2byte 157 @ Typhlosion
- .2byte 248 @ Tyranitar
- .2byte 236 @ Tyrogue
- .2byte 197 @ Umbreon
- .2byte 201 @ Unown
- .2byte 217 @ Ursaring
- .2byte 134 @ Vaporeon
- .2byte 49 @ Venomoth
- .2byte 48 @ Venonat
- .2byte 3 @ Venusaur
- .2byte 329 @ Vibrava
- .2byte 71 @ Victreebel
- .2byte 288 @ Vigoroth
- .2byte 45 @ Vileplume
- .2byte 313 @ Volbeat
- .2byte 100 @ Voltorb
- .2byte 37 @ Vulpix
- .2byte 320 @ Wailmer
- .2byte 321 @ Wailord
- .2byte 365 @ Walrein
- .2byte 8 @ Wartortle
- .2byte 13 @ Weedle
- .2byte 70 @ Weepinbell
- .2byte 110 @ Weezing
- .2byte 340 @ Whiscash
- .2byte 293 @ Whismur
- .2byte 40 @ Wigglytuff
- .2byte 278 @ Wingull
- .2byte 202 @ Wobbuffet
- .2byte 194 @ Wooper
- .2byte 265 @ Wurmple
- .2byte 360 @ Wynaut
- .2byte 178 @ Xatu
- .2byte 193 @ Yanma
- .2byte 335 @ Zangoose
- .2byte 145 @ Zapdos
- .2byte 263 @ Zigzagoon
- .2byte 41 @ Zubat
-
- .align 1
-gPokedexOrder_Weight:: @ 839FDFA
- .2byte 92 @ Gastly
- .2byte 93 @ Haunter
- .2byte 187 @ Hoppip
- .2byte 50 @ Diglett
- .2byte 351 @ Castform
- .2byte 109 @ Koffing
- .2byte 174 @ Igglybuff
- .2byte 200 @ Misdreavus
- .2byte 358 @ Chimecho
- .2byte 188 @ Skiploom
- .2byte 385 @ Jirachi
- .2byte 333 @ Swablu
- .2byte 292 @ Shedinja
- .2byte 175 @ Togepi
- .2byte 283 @ Surskit
- .2byte 16 @ Pidgey
- .2byte 191 @ Sunkern
- .2byte 339 @ Barboach
- .2byte 172 @ Pichu
- .2byte 298 @ Azurill
- .2byte 315 @ Roselia
- .2byte 177 @ Natu
- .2byte 21 @ Spearow
- .2byte 198 @ Murkrow
- .2byte 353 @ Shuppet
- .2byte 276 @ Taillow
- .2byte 102 @ Exeggcute
- .2byte 255 @ Torchic
- .2byte 270 @ Lotad
- .2byte 10 @ Caterpie
- .2byte 189 @ Jumpluff
- .2byte 173 @ Cleffa
- .2byte 13 @ Weedle
- .2byte 176 @ Togetic
- .2byte 147 @ Dratini
- .2byte 19 @ Rattata
- .2byte 284 @ Masquerain
- .2byte 265 @ Wurmple
- .2byte 211 @ Qwilfish
- .2byte 151 @ Mew
- .2byte 90 @ Shellder
- .2byte 273 @ Seedot
- .2byte 132 @ Ditto
- .2byte 69 @ Bellsprout
- .2byte 311 @ Plusle
- .2byte 52 @ Meowth
- .2byte 312 @ Minun
- .2byte 285 @ Shroomish
- .2byte 251 @ Celebi
- .2byte 222 @ Corsola
- .2byte 252 @ Treecko
- .2byte 327 @ Spinda
- .2byte 201 @ Unown
- .2byte 46 @ Paras
- .2byte 43 @ Oddish
- .2byte 39 @ Jigglypuff
- .2byte 290 @ Nincada
- .2byte 182 @ Bellossom
- .2byte 81 @ Magnemite
- .2byte 25 @ Pikachu
- .2byte 238 @ Smoochum
- .2byte 161 @ Sentret
- .2byte 70 @ Weepinbell
- .2byte 152 @ Chikorita
- .2byte 220 @ Swinub
- .2byte 133 @ Eevee
- .2byte 98 @ Krabby
- .2byte 104 @ Cubone
- .2byte 280 @ Ralts
- .2byte 1 @ Bulbasaur
- .2byte 23 @ Ekans
- .2byte 29 @ Nidoran♀
- .2byte 204 @ Pineco
- .2byte 349 @ Feebas
- .2byte 138 @ Omanyte
- .2byte 41 @ Zubat
- .2byte 35 @ Clefairy
- .2byte 258 @ Mudkip
- .2byte 209 @ Snubbull
- .2byte 179 @ Mareep
- .2byte 155 @ Cyndaquil
- .2byte 116 @ Horsea
- .2byte 4 @ Charmander
- .2byte 192 @ Sunflora
- .2byte 183 @ Marill
- .2byte 194 @ Wooper
- .2byte 167 @ Spinarak
- .2byte 44 @ Gloom
- .2byte 370 @ Luvdisc
- .2byte 216 @ Teddiursa
- .2byte 32 @ Nidoran♂
- .2byte 7 @ Squirtle
- .2byte 278 @ Wingull
- .2byte 158 @ Totodile
- .2byte 110 @ Weezing
- .2byte 37 @ Vulpix
- .2byte 11 @ Metapod
- .2byte 266 @ Silcoon
- .2byte 129 @ Magikarp
- .2byte 14 @ Kakuna
- .2byte 316 @ Gulpin
- .2byte 100 @ Voltorb
- .2byte 165 @ Ledyba
- .2byte 228 @ Houndour
- .2byte 300 @ Skitty
- .2byte 302 @ Sableye
- .2byte 307 @ Meditite
- .2byte 341 @ Corphish
- .2byte 190 @ Aipom
- .2byte 268 @ Cascoon
- .2byte 303 @ Mawile
- .2byte 140 @ Kabuto
- .2byte 40 @ Wigglytuff
- .2byte 27 @ Sandshrew
- .2byte 223 @ Remoraid
- .2byte 291 @ Ninjask
- .2byte 170 @ Chinchou
- .2byte 60 @ Poliwag
- .2byte 347 @ Anorith
- .2byte 49 @ Venomoth
- .2byte 354 @ Banette
- .2byte 2 @ Ivysaur
- .2byte 180 @ Flaaffy
- .2byte 261 @ Poochyena
- .2byte 360 @ Wynaut
- .2byte 206 @ Dunsparce
- .2byte 178 @ Xatu
- .2byte 355 @ Duskull
- .2byte 83 @ Farfetch’d
- .2byte 328 @ Trapinch
- .2byte 118 @ Goldeen
- .2byte 309 @ Electrike
- .2byte 329 @ Vibrava
- .2byte 71 @ Victreebel
- .2byte 153 @ Bayleef
- .2byte 225 @ Delibird
- .2byte 293 @ Whismur
- .2byte 148 @ Dragonair
- .2byte 361 @ Snorunt
- .2byte 263 @ Zigzagoon
- .2byte 314 @ Illumise
- .2byte 313 @ Volbeat
- .2byte 20 @ Raticate
- .2byte 45 @ Vileplume
- .2byte 156 @ Quilava
- .2byte 5 @ Charmeleon
- .2byte 58 @ Growlithe
- .2byte 256 @ Combusken
- .2byte 66 @ Machop
- .2byte 63 @ Abra
- .2byte 33 @ Nidorino
- .2byte 54 @ Psyduck
- .2byte 277 @ Swellow
- .2byte 38 @ Ninetales
- .2byte 30 @ Nidorina
- .2byte 61 @ Poliwhirl
- .2byte 74 @ Geodude
- .2byte 281 @ Kirlia
- .2byte 213 @ Shuckle
- .2byte 334 @ Altaria
- .2byte 318 @ Carvanha
- .2byte 236 @ Tyrogue
- .2byte 163 @ Hoothoot
- .2byte 240 @ Magby
- .2byte 343 @ Baltoy
- .2byte 253 @ Grovyle
- .2byte 352 @ Kecleon
- .2byte 171 @ Lanturn
- .2byte 8 @ Wartortle
- .2byte 368 @ Gorebyss
- .2byte 369 @ Relicanth
- .2byte 239 @ Elekid
- .2byte 340 @ Whiscash
- .2byte 345 @ Lileep
- .2byte 322 @ Numel
- .2byte 287 @ Slakoth
- .2byte 135 @ Jolteon
- .2byte 159 @ Croconaw
- .2byte 136 @ Flareon
- .2byte 117 @ Seadra
- .2byte 196 @ Espeon
- .2byte 367 @ Huntail
- .2byte 197 @ Umbreon
- .2byte 259 @ Marshtomp
- .2byte 274 @ Nuzleaf
- .2byte 215 @ Sneasel
- .2byte 56 @ Mankey
- .2byte 279 @ Pelipper
- .2byte 267 @ Beautifly
- .2byte 224 @ Octillery
- .2byte 184 @ Azumarill
- .2byte 202 @ Wobbuffet
- .2byte 134 @ Vaporeon
- .2byte 28 @ Sandslash
- .2byte 47 @ Parasect
- .2byte 15 @ Beedrill
- .2byte 89 @ Muk
- .2byte 17 @ Pidgeotto
- .2byte 88 @ Grimer
- .2byte 26 @ Raichu
- .2byte 77 @ Ponyta
- .2byte 125 @ Electabuzz
- .2byte 48 @ Venonat
- .2byte 325 @ Spoink
- .2byte 356 @ Dusclops
- .2byte 308 @ Medicham
- .2byte 269 @ Dustox
- .2byte 53 @ Persian
- .2byte 12 @ Butterfree
- .2byte 57 @ Primeape
- .2byte 96 @ Drowzee
- .2byte 162 @ Furret
- .2byte 233 @ Porygon2
- .2byte 271 @ Lombre
- .2byte 264 @ Linoone
- .2byte 301 @ Delcatty
- .2byte 342 @ Crawdaunt
- .2byte 51 @ Dugtrio
- .2byte 168 @ Ariados
- .2byte 231 @ Phanpy
- .2byte 186 @ Politoed
- .2byte 120 @ Staryu
- .2byte 113 @ Chansey
- .2byte 139 @ Omastar
- .2byte 114 @ Tangela
- .2byte 218 @ Slugma
- .2byte 229 @ Houndoom
- .2byte 166 @ Ledian
- .2byte 79 @ Slowpoke
- .2byte 137 @ Porygon
- .2byte 262 @ Mightyena
- .2byte 193 @ Yanma
- .2byte 22 @ Fearow
- .2byte 185 @ Sudowoodo
- .2byte 119 @ Seaking
- .2byte 286 @ Breloom
- .2byte 84 @ Doduo
- .2byte 18 @ Pidgeot
- .2byte 363 @ Spheal
- .2byte 36 @ Clefable
- .2byte 380 @ Latias
- .2byte 310 @ Manectric
- .2byte 335 @ Zangoose
- .2byte 141 @ Kabutops
- .2byte 94 @ Gengar
- .2byte 294 @ Loudred
- .2byte 124 @ Jynx
- .2byte 164 @ Noctowl
- .2byte 203 @ Girafarig
- .2byte 371 @ Bagon
- .2byte 126 @ Magmar
- .2byte 105 @ Marowak
- .2byte 72 @ Tentacool
- .2byte 288 @ Vigoroth
- .2byte 242 @ Blissey
- .2byte 359 @ Absol
- .2byte 65 @ Alakazam
- .2byte 237 @ Hitmontop
- .2byte 282 @ Gardevoir
- .2byte 210 @ Granbull
- .2byte 106 @ Hitmonlee
- .2byte 107 @ Hitmonchan
- .2byte 227 @ Skarmory
- .2byte 331 @ Cacnea
- .2byte 257 @ Blaziken
- .2byte 254 @ Sceptile
- .2byte 336 @ Seviper
- .2byte 366 @ Clamperl
- .2byte 145 @ Zapdos
- .2byte 214 @ Heracross
- .2byte 62 @ Poliwrath
- .2byte 122 @ Mr. mime
- .2byte 127 @ Pinsir
- .2byte 272 @ Ludicolo
- .2byte 73 @ Tentacruel
- .2byte 42 @ Golbat
- .2byte 219 @ Magcargo
- .2byte 144 @ Articuno
- .2byte 221 @ Piloswine
- .2byte 123 @ Scyther
- .2byte 64 @ Kadabra
- .2byte 235 @ Smeargle
- .2byte 142 @ Aerodactyl
- .2byte 275 @ Shiftry
- .2byte 99 @ Kingler
- .2byte 31 @ Nidoqueen
- .2byte 82 @ Magneton
- .2byte 304 @ Aron
- .2byte 381 @ Latios
- .2byte 146 @ Moltres
- .2byte 346 @ Cradily
- .2byte 386 @ Deoxys
- .2byte 181 @ Ampharos
- .2byte 34 @ Nidoking
- .2byte 207 @ Gligar
- .2byte 24 @ Arbok
- .2byte 108 @ Lickitung
- .2byte 101 @ Electrode
- .2byte 348 @ Armaldo
- .2byte 67 @ Machoke
- .2byte 234 @ Stantler
- .2byte 326 @ Grumpig
- .2byte 246 @ Larvitar
- .2byte 169 @ Crobat
- .2byte 195 @ Quagsire
- .2byte 241 @ Miltank
- .2byte 97 @ Hypno
- .2byte 55 @ Golduck
- .2byte 332 @ Cacturne
- .2byte 80 @ Slowbro
- .2byte 157 @ Typhlosion
- .2byte 199 @ Slowking
- .2byte 115 @ Kangaskhan
- .2byte 121 @ Starmie
- .2byte 317 @ Swalot
- .2byte 324 @ Torkoal
- .2byte 260 @ Swampert
- .2byte 330 @ Flygon
- .2byte 295 @ Exploud
- .2byte 85 @ Dodrio
- .2byte 9 @ Blastoise
- .2byte 296 @ Makuhita
- .2byte 364 @ Sealeo
- .2byte 128 @ Tauros
- .2byte 319 @ Sharpedo
- .2byte 160 @ Feraligatr
- .2byte 86 @ Seel
- .2byte 6 @ Charizard
- .2byte 78 @ Rapidash
- .2byte 374 @ Beldum
- .2byte 299 @ Nosepass
- .2byte 3 @ Venusaur
- .2byte 357 @ Tropius
- .2byte 154 @ Meganium
- .2byte 373 @ Salamence
- .2byte 75 @ Graveler
- .2byte 344 @ Claydol
- .2byte 372 @ Shelgon
- .2byte 111 @ Rhyhorn
- .2byte 212 @ Scizor
- .2byte 87 @ Dewgong
- .2byte 112 @ Rhydon
- .2byte 232 @ Donphan
- .2byte 103 @ Exeggutor
- .2byte 305 @ Lairon
- .2byte 150 @ Mewtwo
- .2byte 217 @ Ursaring
- .2byte 205 @ Forretress
- .2byte 68 @ Machamp
- .2byte 320 @ Wailmer
- .2byte 289 @ Slaking
- .2byte 91 @ Cloyster
- .2byte 365 @ Walrein
- .2byte 247 @ Pupitar
- .2byte 230 @ Kingdra
- .2byte 338 @ Solrock
- .2byte 59 @ Arcanine
- .2byte 350 @ Milotic
- .2byte 337 @ Lunatone
- .2byte 378 @ Regice
- .2byte 243 @ Raikou
- .2byte 245 @ Suicune
- .2byte 244 @ Entei
- .2byte 250 @ Ho-Oh
- .2byte 248 @ Tyranitar
- .2byte 375 @ Metang
- .2byte 379 @ Registeel
- .2byte 384 @ Rayquaza
- .2byte 95 @ Onix
- .2byte 149 @ Dragonite
- .2byte 249 @ Lugia
- .2byte 131 @ Lapras
- .2byte 323 @ Camerupt
- .2byte 226 @ Mantine
- .2byte 377 @ Regirock
- .2byte 130 @ Gyarados
- .2byte 297 @ Hariyama
- .2byte 362 @ Glalie
- .2byte 76 @ Golem
- .2byte 382 @ Kyogre
- .2byte 306 @ Aggron
- .2byte 321 @ Wailord
- .2byte 208 @ Steelix
- .2byte 143 @ Snorlax
- .2byte 376 @ Metagross
- .2byte 383 @ Groudon
-
- .align 1
-gPokedexOrder_Height:: @ 83A00FE
- .2byte 50 @ Diglett
- .2byte 298 @ Azurill
- .2byte 177 @ Natu
- .2byte 13 @ Weedle
- .2byte 172 @ Pichu
- .2byte 173 @ Cleffa
- .2byte 175 @ Togepi
- .2byte 351 @ Castform
- .2byte 174 @ Igglybuff
- .2byte 10 @ Caterpie
- .2byte 276 @ Taillow
- .2byte 132 @ Ditto
- .2byte 133 @ Eevee
- .2byte 315 @ Roselia
- .2byte 21 @ Spearow
- .2byte 16 @ Pidgey
- .2byte 191 @ Sunkern
- .2byte 90 @ Shellder
- .2byte 19 @ Rattata
- .2byte 81 @ Magnemite
- .2byte 46 @ Paras
- .2byte 265 @ Wurmple
- .2byte 385 @ Jirachi
- .2byte 104 @ Cubone
- .2byte 258 @ Mudkip
- .2byte 194 @ Wooper
- .2byte 116 @ Horsea
- .2byte 52 @ Meowth
- .2byte 29 @ Nidoran♀
- .2byte 220 @ Swinub
- .2byte 151 @ Mew
- .2byte 333 @ Swablu
- .2byte 304 @ Aron
- .2byte 311 @ Plusle
- .2byte 312 @ Minun
- .2byte 102 @ Exeggcute
- .2byte 25 @ Pikachu
- .2byte 182 @ Bellossom
- .2byte 316 @ Gulpin
- .2byte 263 @ Zigzagoon
- .2byte 285 @ Shroomish
- .2byte 138 @ Omanyte
- .2byte 331 @ Cacnea
- .2byte 98 @ Krabby
- .2byte 280 @ Ralts
- .2byte 187 @ Hoppip
- .2byte 255 @ Torchic
- .2byte 366 @ Clamperl
- .2byte 74 @ Geodude
- .2byte 183 @ Marill
- .2byte 339 @ Barboach
- .2byte 238 @ Smoochum
- .2byte 100 @ Voltorb
- .2byte 290 @ Nincada
- .2byte 302 @ Sableye
- .2byte 198 @ Murkrow
- .2byte 211 @ Qwilfish
- .2byte 7 @ Squirtle
- .2byte 252 @ Treecko
- .2byte 343 @ Baltoy
- .2byte 43 @ Oddish
- .2byte 270 @ Lotad
- .2byte 39 @ Jigglypuff
- .2byte 283 @ Surskit
- .2byte 155 @ Cyndaquil
- .2byte 140 @ Kabuto
- .2byte 264 @ Linoone
- .2byte 324 @ Torkoal
- .2byte 32 @ Nidoran♂
- .2byte 167 @ Spinarak
- .2byte 56 @ Mankey
- .2byte 273 @ Seedot
- .2byte 261 @ Poochyena
- .2byte 231 @ Phanpy
- .2byte 201 @ Unown
- .2byte 170 @ Chinchou
- .2byte 233 @ Porygon2
- .2byte 60 @ Poliwag
- .2byte 371 @ Bagon
- .2byte 349 @ Feebas
- .2byte 353 @ Shuppet
- .2byte 158 @ Totodile
- .2byte 251 @ Celebi
- .2byte 360 @ Wynaut
- .2byte 27 @ Sandshrew
- .2byte 358 @ Chimecho
- .2byte 370 @ Luvdisc
- .2byte 228 @ Houndour
- .2byte 266 @ Silcoon
- .2byte 309 @ Electrike
- .2byte 4 @ Charmander
- .2byte 307 @ Meditite
- .2byte 278 @ Wingull
- .2byte 223 @ Remoraid
- .2byte 341 @ Corphish
- .2byte 222 @ Corsola
- .2byte 314 @ Illumise
- .2byte 209 @ Snubbull
- .2byte 37 @ Vulpix
- .2byte 246 @ Larvitar
- .2byte 374 @ Beldum
- .2byte 293 @ Whismur
- .2byte 204 @ Pineco
- .2byte 239 @ Elekid
- .2byte 35 @ Clefairy
- .2byte 213 @ Shuckle
- .2byte 216 @ Teddiursa
- .2byte 14 @ Kakuna
- .2byte 300 @ Skitty
- .2byte 176 @ Togetic
- .2byte 118 @ Goldeen
- .2byte 303 @ Mawile
- .2byte 179 @ Mareep
- .2byte 188 @ Skiploom
- .2byte 109 @ Koffing
- .2byte 51 @ Dugtrio
- .2byte 268 @ Cascoon
- .2byte 322 @ Numel
- .2byte 347 @ Anorith
- .2byte 313 @ Volbeat
- .2byte 163 @ Hoothoot
- .2byte 328 @ Trapinch
- .2byte 325 @ Spoink
- .2byte 11 @ Metapod
- .2byte 69 @ Bellsprout
- .2byte 361 @ Snorunt
- .2byte 20 @ Raticate
- .2byte 259 @ Marshtomp
- .2byte 277 @ Swellow
- .2byte 240 @ Magby
- .2byte 58 @ Growlithe
- .2byte 200 @ Misdreavus
- .2byte 1 @ Bulbasaur
- .2byte 236 @ Tyrogue
- .2byte 218 @ Slugma
- .2byte 287 @ Slakoth
- .2byte 281 @ Kirlia
- .2byte 190 @ Aipom
- .2byte 135 @ Jolteon
- .2byte 30 @ Nidorina
- .2byte 184 @ Azumarill
- .2byte 292 @ Shedinja
- .2byte 66 @ Machop
- .2byte 291 @ Ninjask
- .2byte 284 @ Masquerain
- .2byte 355 @ Duskull
- .2byte 192 @ Sunflora
- .2byte 189 @ Jumpluff
- .2byte 120 @ Staryu
- .2byte 180 @ Flaaffy
- .2byte 363 @ Spheal
- .2byte 54 @ Psyduck
- .2byte 219 @ Magcargo
- .2byte 83 @ Farfetch’d
- .2byte 41 @ Zubat
- .2byte 137 @ Porygon
- .2byte 161 @ Sentret
- .2byte 318 @ Carvanha
- .2byte 44 @ Gloom
- .2byte 26 @ Raichu
- .2byte 129 @ Magikarp
- .2byte 215 @ Sneasel
- .2byte 305 @ Lairon
- .2byte 256 @ Combusken
- .2byte 224 @ Octillery
- .2byte 33 @ Nidorino
- .2byte 136 @ Flareon
- .2byte 225 @ Delibird
- .2byte 72 @ Tentacool
- .2byte 63 @ Abra
- .2byte 253 @ Grovyle
- .2byte 340 @ Whiscash
- .2byte 156 @ Quilava
- .2byte 196 @ Espeon
- .2byte 88 @ Grimer
- .2byte 152 @ Chikorita
- .2byte 326 @ Grumpig
- .2byte 299 @ Nosepass
- .2byte 53 @ Persian
- .2byte 262 @ Mightyena
- .2byte 48 @ Venonat
- .2byte 82 @ Magneton
- .2byte 77 @ Ponyta
- .2byte 296 @ Makuhita
- .2byte 337 @ Lunatone
- .2byte 28 @ Sandslash
- .2byte 96 @ Drowzee
- .2byte 114 @ Tangela
- .2byte 57 @ Primeape
- .2byte 165 @ Ledyba
- .2byte 40 @ Wigglytuff
- .2byte 47 @ Parasect
- .2byte 139 @ Omastar
- .2byte 294 @ Loudred
- .2byte 8 @ Wartortle
- .2byte 75 @ Graveler
- .2byte 197 @ Umbreon
- .2byte 345 @ Lileep
- .2byte 61 @ Poliwhirl
- .2byte 134 @ Vaporeon
- .2byte 15 @ Beedrill
- .2byte 105 @ Marowak
- .2byte 70 @ Weepinbell
- .2byte 369 @ Relicanth
- .2byte 111 @ Rhyhorn
- .2byte 2 @ Ivysaur
- .2byte 352 @ Kecleon
- .2byte 274 @ Nuzleaf
- .2byte 267 @ Beautifly
- .2byte 17 @ Pidgeotto
- .2byte 168 @ Ariados
- .2byte 86 @ Seel
- .2byte 186 @ Politoed
- .2byte 159 @ Croconaw
- .2byte 113 @ Chansey
- .2byte 354 @ Banette
- .2byte 232 @ Donphan
- .2byte 121 @ Starmie
- .2byte 5 @ Charmeleon
- .2byte 221 @ Piloswine
- .2byte 12 @ Butterfree
- .2byte 329 @ Vibrava
- .2byte 125 @ Electabuzz
- .2byte 342 @ Crawdaunt
- .2byte 301 @ Delcatty
- .2byte 334 @ Altaria
- .2byte 372 @ Shelgon
- .2byte 38 @ Ninetales
- .2byte 207 @ Gligar
- .2byte 364 @ Sealeo
- .2byte 327 @ Spinda
- .2byte 247 @ Pupitar
- .2byte 79 @ Slowpoke
- .2byte 338 @ Solrock
- .2byte 241 @ Miltank
- .2byte 22 @ Fearow
- .2byte 45 @ Vileplume
- .2byte 89 @ Muk
- .2byte 205 @ Forretress
- .2byte 185 @ Sudowoodo
- .2byte 359 @ Absol
- .2byte 193 @ Yanma
- .2byte 269 @ Dustox
- .2byte 108 @ Lickitung
- .2byte 235 @ Smeargle
- .2byte 171 @ Lanturn
- .2byte 101 @ Electrode
- .2byte 271 @ Lombre
- .2byte 286 @ Breloom
- .2byte 153 @ Bayleef
- .2byte 117 @ Seadra
- .2byte 110 @ Weezing
- .2byte 279 @ Pelipper
- .2byte 375 @ Metang
- .2byte 31 @ Nidoqueen
- .2byte 332 @ Cacturne
- .2byte 275 @ Shiftry
- .2byte 308 @ Medicham
- .2byte 335 @ Zangoose
- .2byte 141 @ Kabutops
- .2byte 99 @ Kingler
- .2byte 64 @ Kadabra
- .2byte 119 @ Seaking
- .2byte 36 @ Clefable
- .2byte 126 @ Magmar
- .2byte 202 @ Wobbuffet
- .2byte 92 @ Gastly
- .2byte 122 @ Mr. mime
- .2byte 62 @ Poliwrath
- .2byte 128 @ Tauros
- .2byte 380 @ Latias
- .2byte 181 @ Ampharos
- .2byte 288 @ Vigoroth
- .2byte 166 @ Ledian
- .2byte 76 @ Golem
- .2byte 365 @ Walrein
- .2byte 84 @ Doduo
- .2byte 229 @ Houndoom
- .2byte 34 @ Nidoking
- .2byte 124 @ Jynx
- .2byte 107 @ Hitmonchan
- .2byte 234 @ Stantler
- .2byte 210 @ Granbull
- .2byte 237 @ Hitmontop
- .2byte 195 @ Quagsire
- .2byte 344 @ Claydol
- .2byte 260 @ Swampert
- .2byte 242 @ Blissey
- .2byte 272 @ Ludicolo
- .2byte 295 @ Exploud
- .2byte 206 @ Dunsparce
- .2byte 127 @ Pinsir
- .2byte 91 @ Cloyster
- .2byte 67 @ Machoke
- .2byte 203 @ Girafarig
- .2byte 18 @ Pidgeot
- .2byte 178 @ Xatu
- .2byte 346 @ Cradily
- .2byte 106 @ Hitmonlee
- .2byte 49 @ Venomoth
- .2byte 94 @ Gengar
- .2byte 214 @ Heracross
- .2byte 362 @ Glalie
- .2byte 123 @ Scyther
- .2byte 373 @ Salamence
- .2byte 310 @ Manectric
- .2byte 348 @ Armaldo
- .2byte 65 @ Alakazam
- .2byte 97 @ Hypno
- .2byte 164 @ Noctowl
- .2byte 73 @ Tentacruel
- .2byte 356 @ Dusclops
- .2byte 145 @ Zapdos
- .2byte 42 @ Golbat
- .2byte 376 @ Metagross
- .2byte 282 @ Gardevoir
- .2byte 9 @ Blastoise
- .2byte 80 @ Slowbro
- .2byte 93 @ Haunter
- .2byte 68 @ Machamp
- .2byte 377 @ Regirock
- .2byte 317 @ Swalot
- .2byte 254 @ Sceptile
- .2byte 227 @ Skarmory
- .2byte 55 @ Golduck
- .2byte 386 @ Deoxys
- .2byte 71 @ Victreebel
- .2byte 78 @ Rapidash
- .2byte 6 @ Charizard
- .2byte 367 @ Huntail
- .2byte 87 @ Dewgong
- .2byte 144 @ Articuno
- .2byte 157 @ Typhlosion
- .2byte 142 @ Aerodactyl
- .2byte 368 @ Gorebyss
- .2byte 217 @ Ursaring
- .2byte 154 @ Meganium
- .2byte 378 @ Regice
- .2byte 212 @ Scizor
- .2byte 230 @ Kingdra
- .2byte 147 @ Dratini
- .2byte 85 @ Dodrio
- .2byte 319 @ Sharpedo
- .2byte 169 @ Crobat
- .2byte 162 @ Furret
- .2byte 59 @ Arcanine
- .2byte 243 @ Raikou
- .2byte 257 @ Blaziken
- .2byte 323 @ Camerupt
- .2byte 112 @ Rhydon
- .2byte 379 @ Registeel
- .2byte 23 @ Ekans
- .2byte 330 @ Flygon
- .2byte 357 @ Tropius
- .2byte 381 @ Latios
- .2byte 245 @ Suicune
- .2byte 146 @ Moltres
- .2byte 3 @ Venusaur
- .2byte 103 @ Exeggutor
- .2byte 199 @ Slowking
- .2byte 248 @ Tyranitar
- .2byte 289 @ Slaking
- .2byte 320 @ Wailmer
- .2byte 150 @ Mewtwo
- .2byte 306 @ Aggron
- .2byte 143 @ Snorlax
- .2byte 226 @ Mantine
- .2byte 244 @ Entei
- .2byte 149 @ Dragonite
- .2byte 115 @ Kangaskhan
- .2byte 297 @ Hariyama
- .2byte 160 @ Feraligatr
- .2byte 131 @ Lapras
- .2byte 336 @ Seviper
- .2byte 24 @ Arbok
- .2byte 383 @ Groudon
- .2byte 250 @ Ho-Oh
- .2byte 148 @ Dragonair
- .2byte 382 @ Kyogre
- .2byte 249 @ Lugia
- .2byte 350 @ Milotic
- .2byte 130 @ Gyarados
- .2byte 384 @ Rayquaza
- .2byte 95 @ Onix
- .2byte 208 @ Steelix
- .2byte 321 @ Wailord
diff --git a/data/scripts/maps/LittlerootTown_BrendansHouse_2F.inc b/data/scripts/maps/LittlerootTown_BrendansHouse_2F.inc
index 4f121118a..0c6ec79f7 100644
--- a/data/scripts/maps/LittlerootTown_BrendansHouse_2F.inc
+++ b/data/scripts/maps/LittlerootTown_BrendansHouse_2F.inc
@@ -67,7 +67,7 @@ LittlerootTown_BrendansHouse_2F_EventScript_152837:: @ 8152837
releaseall
end
-gUnknown_08152850:: @ 8152850
+gBrendanHouse_TurnPCOff:: @ 8152850
setvar 0x8004, 1
playsfx SE_PC_OFF
special 215
diff --git a/data/scripts/maps/LittlerootTown_MaysHouse_2F.inc b/data/scripts/maps/LittlerootTown_MaysHouse_2F.inc
index 7871940ca..1aca3f86e 100644
--- a/data/scripts/maps/LittlerootTown_MaysHouse_2F.inc
+++ b/data/scripts/maps/LittlerootTown_MaysHouse_2F.inc
@@ -215,7 +215,7 @@ LittlerootTown_MaysHouse_2F_EventScript_152C5C:: @ 8152C5C
releaseall
end
-gUnknown_08152C75:: @ 8152C75
+gMayHouse_TurnPCOff:: @ 8152C75
setvar 0x8004, 2
playsfx SE_PC_OFF
special 215
diff --git a/data/text/pokedex_rating.inc b/data/text/pokedex_rating.inc
index d816799b6..bcf57eb5b 100644
--- a/data/text/pokedex_rating.inc
+++ b/data/text/pokedex_rating.inc
@@ -12,111 +12,90 @@ Route101_Text_1C44DC:: @ 81C44DC
.string "So, you’ve seen {STR_VAR_1} POKéMON,\n"
.string "and you’ve caught {STR_VAR_2} POKéMON...$"
-gUnknown_081C4520:: @ 81C4520
-UnknownString_81C4520: @ 81C4520
+gBirchDexRatingText_LessThan10:: @ 81C4520
.string "You should go into grassy areas more\n"
.string "and look for POKéMON more carefully.$"
-gUnknown_081C456A:: @ 81C456A
-UnknownString_81C456A: @ 81C456A
+gBirchDexRatingText_LessThan20:: @ 81C456A
.string "I guess you’re getting the hang of it.\n"
.string "But, it gets harder from here.$"
-gUnknown_081C45B0:: @ 81C45B0
-UnknownString_81C45B0: @ 81C45B0
+gBirchDexRatingText_LessThan30:: @ 81C45B0
.string "Some POKéMON only appear in certain\n"
.string "areas. You’ll need to be persistent.$"
-gUnknown_081C45F9:: @ 81C45F9
-UnknownString_81C45F9: @ 81C45F9
+gBirchDexRatingText_LessThan40:: @ 81C45F9
.string "Well, it could use more quantity, but\n"
.string "this is looking more like a POKéDEX now.$"
-gUnknown_081C4648:: @ 81C4648
-UnknownString_81C4648: @ 81C4648
+gBirchDexRatingText_LessThan50:: @ 81C4648
.string "This is coming along pretty good.\n"
.string "Keep up the effort.$"
-gUnknown_081C467E:: @ 81C467E
-UnknownString_81C467E: @ 81C467E
+gBirchDexRatingText_LessThan60:: @ 81C467E
.string "Are you using any RODS?\n"
.string "There are many POKéMON in the sea.$"
-gUnknown_081C46B9:: @ 81C46B9
-UnknownString_81C46B9: @ 81C46B9
+gBirchDexRatingText_LessThan70:: @ 81C46B9
.string "Instead of just catching POKéMON,\n"
.string "how about making them evolve, too?$"
-gUnknown_081C46FE:: @ 81C46FE
-UnknownString_81C46FE: @ 81C46FE
+gBirchDexRatingText_LessThan80:: @ 81C46FE
.string "This is going to be a fantastic POKéDEX.\n"
.string "That’s the feeling I’m getting.$"
-gUnknown_081C4747:: @ 81C4747
-UnknownString_81C4747: @ 81C4747
+gBirchDexRatingText_LessThan90:: @ 81C4747
.string "You’ve collected this many...\n"
.string "Your talent is remarkable!$"
-gUnknown_081C4780:: @ 81C4780
-UnknownString_81C4780: @ 81C4780
+gBirchDexRatingText_LessThan100:: @ 81C4780
.string "Have you visited the SAFARI ZONE?\p"
.string "I hear there are some POKéMON that\n"
.string "can only be caught there.$"
-gUnknown_081C47DF:: @ 81C47DF
-UnknownString_81C47DF: @ 81C47DF
+gBirchDexRatingText_LessThan110:: @ 81C47DF
.string "You’ve finally reached the 100-kind\n"
.string "mark. This is an impressive POKéDEX!$"
-gUnknown_081C4828:: @ 81C4828
-UnknownString_81C4828: @ 81C4828
+gBirchDexRatingText_LessThan120:: @ 81C4828
.string "There might be POKéMON that can be\n"
.string "found using ROCK SMASH.$"
-gUnknown_081C4863:: @ 81C4863
-UnknownString_81C4863: @ 81C4863
+gBirchDexRatingText_LessThan130:: @ 81C4863
.string "You should get some more POKéMON by\n"
.string "trading with others.$"
-gUnknown_081C489C:: @ 81C489C
-UnknownString_81C489C: @ 81C489C
+gBirchDexRatingText_LessThan140:: @ 81C489C
.string "I’ve heard of POKéMON that evolve when\n"
.string "they come to fully love their TRAINERS.$"
-gUnknown_081C48EB:: @ 81C48EB
-UnknownString_81C48EB: @ 81C48EB
+gBirchDexRatingText_LessThan150:: @ 81C48EB
.string "I had no idea that there were so many\n"
.string "POKéMON species in the HOENN region.$"
-gUnknown_081C4936:: @ 81C4936
-UnknownString_81C4936: @ 81C4936
+gBirchDexRatingText_LessThan160:: @ 81C4936
.string "On occasion, some POKéMON appear in\n"
.string "large numbers like wild outbreaks.\l"
.string "Don’t miss opportunities like those.$"
-gUnknown_081C49A2:: @ 81C49A2
-UnknownString_81C49A2: @ 81C49A2
+gBirchDexRatingText_LessThan170:: @ 81C49A2
.string "One can get a very good idea about the\n"
.string "POKéMON of the HOENN region by looking\l"
.string "through your POKéDEX.$"
-gUnknown_081C4A06:: @ 81C4A06
-UnknownString_81C4A06: @ 81C4A06
+gBirchDexRatingText_LessThan180:: @ 81C4A06
.string "I’d say you already qualify as a POKéMON\n"
.string "PROFESSOR, and a good one, too!$"
-gUnknown_081C4A4F:: @ 81C4A4F
-UnknownString_81C4A4F: @ 81C4A4F
+gBirchDexRatingText_LessThan190:: @ 81C4A4F
.string "With a POKéDEX this complete, you’re\n"
.string "a real professional at this!$"
-gUnknown_081C4A91:: @ 81C4A91
-UnknownString_81C4A91: @ 81C4A91
+gBirchDexRatingText_LessThan200:: @ 81C4A91
.string "You’re very close to completing this\n"
.string "POKéDEX. I can feel it in my bones!$"
-gUnknown_081C4ADA:: @ 81C4ADA
-UnknownString_81C4ADA: @ 81C4ADA
+gBirchDexRatingText_DexCompleted:: @ 81C4ADA
.string "Congratulations!\n"
.string "Your POKéDEX is complete!$"
diff --git a/include/asm.h b/include/asm.h
deleted file mode 100644
index e72683e45..000000000
--- a/include/asm.h
+++ /dev/null
@@ -1,59 +0,0 @@
-#ifndef PROJECT_ASM_H
-#define PROJECT_ASM_H
-
-#include "asm_fieldmap.h"
-#include "main.h"
-#include "sprite.h"
-#include "task.h"
-
-struct FieldInput
-{
- u8 pressedAButton:1;
- u8 input_field_0_1:1;
- u8 pressedStartButton:1;
- u8 pressedSelectButton:1;
- u8 input_field_0_4:1;
- u8 input_field_0_5:1;
- u8 input_field_0_6:1;
- u8 pressedBButton:1;
- u8 input_field_1_0:1;
- u8 input_field_1_1:1;
- u8 input_field_1_2:1;
- u8 input_field_1_3:1;
- u8 input_field_1_4:1;
- u8 input_field_1_5:1;
- u8 input_field_1_6:1;
- u8 input_field_1_7:1;
- u8 dpadDirection;
- u8 input_field_3;
-};
-
-struct UnknownStruct_FPA
-{
- u8 unk0;
- u8 unk1;
- u8 unk2;
- s16 unk4;
- s16 unk6;
- u8 unk8;
- u8 unk9;
- u8 unkA_0:4;
- u8 unkA_4:4;
- u16 unkC;
- u16 unkE;
- u32 unk10;
- u16 unk14;
-};
-
-struct CryRelatedStruct
-{
- u16 unk0;
- u8 unk2;
- u8 paletteNo;
- u8 xPos;
- u8 yPos;
-};
-
-#include "asm.inc.h"
-
-#endif //PROJECT_ASM_H
diff --git a/include/asm.inc.h b/include/asm.inc.h
deleted file mode 100644
index e087acd28..000000000
--- a/include/asm.inc.h
+++ /dev/null
@@ -1,450 +0,0 @@
-// src/rom3.o
-void sub_800C35C(void);
-
-struct UnkStruct8060024 {
- u8 outsideMovementRect:1;
- u8 tileIsImpassable:1;
- u8 elevationMismatch:1;
- u8 pathBlockedByObject:1;
- u8 pad_04:4;
-};
-
-// asm/battle_2.o
-void sub_800E7C4(void);
-u8 b_first_side(u8, u8, u8);
-void sub_80157C4(u8 index);
-
-// asm/battle_3.o
-u8 sub_8015A98(u8, u8, u8);
-u8 sub_8018324(u8, u8, u8, u8, u16);
-
-// asm/battle_5.o
-void sub_802C098();
-void sub_802E3E4(u8, int);
-void nullsub_8(u8);
-
-// asm/battle_7.o
-void sub_8032AA8(u8 index, int i);
-
-// src/pokemon_3.o
-u16 SpeciesToNationalPokedexNum(u16);
-void DrawSpindaSpots(u16, u32, u8 *, u8);
-u8 sub_803FC58(u16);
-void AdjustFriendship(struct Pokemon *, u8);
-void sub_80408BC();
-void current_map_music_set__default_for_battle(u16);
-
-// src/util.o
-void StoreWordInTwoHalfwords(u16 *, u32);
-void LoadWordFromTwoHalfwords(u16 *, u32 *);
-
-// src/daycare.o
-u8 Daycare_CountPokemon(struct BoxPokemon *);
-
-// asm/daycare.o
-void sub_8041324(struct BoxPokemon *, void *);
-void sub_8041790(int i);
-u16 sub_8041870(u16);
-void sub_8041940(void);
-void sub_8041950(void);
-u8 daycare_relationship_score_from_savegame(void);
-
-// asm/pokeball.o
-void CreatePokeballSprite(u8 r0, u8 r1, u8 r2, u8 r3, u8 s1, u8 s2, u8 s3, u16 s4);
-
-// asm/berry_blender.o
-void sub_80516C4(u8, u16);
-
-// src/field_map_obj.o
-void sub_805AA98();
-u8 sub_805AB54(void);
-u8 GetFieldObjectIdByLocalIdAndMap(u8, u8, u8);
-bool8 TryGetFieldObjectIdByLocalIdAndMap(u8, u8, u8, u8 *);
-u8 GetFieldObjectIdByXY(s16, s16);
-void RemoveFieldObjectByLocalIdAndMap(u8, u8, u8);
-u8 SpawnSpecialFieldObject(struct MapObjectTemplate *);
-u8 show_sprite(u8, u8, u8);
-u8 AddPseudoFieldObject(u16 graphicsId, void (*callback)(struct Sprite *), s16 c, s16 d, u8 subpriority);
-u8 sub_805B410(u8, u8, s16, s16, u8, u8);
-void sub_805B55C(s16 a, s16 b);
-void sub_805B710(u16 i, u16 i1);
-void sub_805B980(struct MapObject *, u8);
-void FieldObjectTurn(struct MapObject *, u8);
-void FieldObjectTurnByLocalIdAndMap(u8, u8, u8, u8);
-const struct MapObjectGraphicsInfo *GetFieldObjectGraphicsInfo(u8);
-void npc_by_local_id_and_map_set_field_1_bit_x20(u8, u8, u8, u8);
-void FieldObjectGetLocalIdAndMap(struct MapObject *, u8 *, u8 *, u8 *);
-void sub_805BCF0(u8, u8, u8, u8);
-void sub_805BD48(u8, u8, u8);
-void sub_805BD90(u8 localId, u8 mapNum, u8 mapGroup, s16 x, s16 y);
-void gpu_pal_allocator_reset__manage_upper_four(void);
-void npc_coords_shift(struct MapObject *pObject, s16 x, s16 y);
-void sub_805C0F8(u8, u8, u8, s16, s16);
-void npc_coords_shift_still(struct MapObject *pObject);
-u8 GetFieldObjectIdByXYZ(u16, u16, u8);
-void UpdateFieldObjectsForCameraUpdate(s16, s16);
-u8 AddCameraObject(u8);
-u8 * GetFieldObjectScriptPointerByFieldObjectId(u8);
-u8 FieldObjectGetBerryTreeId(u8);
-void sub_805C754(struct MapObject *pObject);
-void sub_805C774(struct MapObject *, u8);
-void sub_805C78C(u8, u8, u8);
-void sub_805C7C4(u8 i);
-
-// asm/field_map_obj.o
-u8 FieldObjectDirectionToImageAnimId(u8);
-u8 get_go_image_anim_num(u8 unk_19);
-u8 sub_805FD98(u8);
-u8 sub_805FDE8(u8);
-u8 sub_805FDF8(u8);
-u8 sub_805FE08(u8);
-void npc_set_running_behaviour_etc(struct MapObject *, u8);
-u8 npc_running_behaviour_by_direction(u8);
-u8 npc_block_way(struct MapObject *, s16, s16, u8);
-u8 sub_8060024(struct MapObject *, s16, s16, u8);
-u8 sub_8060234(u8, u8, u8);
-void sub_8060288(u8, u8, u8);
-void sub_80603CC(s16 x, s16 y, s16 *pInt, s16 *pInt1);
-void FieldObjectMoveDestCoords(struct MapObject *pObject, u8 unk_19, s16 *pInt, s16 *pInt1);
-bool8 FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(struct MapObject *);
-bool8 FieldObjectSetSpecialAnim(struct MapObject *, u8);
-void FieldObjectForceSetSpecialAnim(struct MapObject *pObject, u8 a);
-void FieldObjectClearAnimIfSpecialAnimActive(struct MapObject *);
-void FieldObjectClearAnim(struct MapObject *);
-bool8 FieldObjectCheckIfSpecialAnimFinishedOrInactive(struct MapObject *);
-u8 FieldObjectClearAnimIfSpecialAnimFinished(struct MapObject *);
-u8 FieldObjectGetSpecialAnim(struct MapObject *);
-u8 GetFaceDirectionAnimId(u8);
-u8 GetSimpleGoAnimId(u8);
-u8 GetGoSpeed0AnimId(u8 a);
-u8 sub_8060744(u8 a);
-u8 d2s_08064034(u8 a);
-u8 sub_806079C(u8 a);
-u8 sub_80607F4(u8 a);
-u8 GetJumpLedgeAnimId(u8 a);
-u8 sub_806084C(u8);
-u8 sub_8060878(u8);
-u8 sub_80608D0(u8);
-u8 GetStepInPlaceDelay32AnimId(u8 a);
-u8 GetStepInPlaceDelay16AnimId(u8);
-u8 GetStepInPlaceDelay8AnimId(u8 a);
-u8 GetStepInPlaceDelay4AnimId(u8 a);
-u8 FieldObjectFaceOppositeDirection(struct MapObject *, u8);
-u8 sub_80609D8(u8);
-u8 sub_8060A04(u8);
-u8 sub_8060A30(u8);
-u8 sub_8060A5C(u8);
-u8 sub_8060A88(u8);
-u8 sub_8060AB4(u8);
-u8 sub_8060AE0(u8);
-u8 sub_8060B0C(u8);
-u8 sub_8060B38(u8);
-u8 sub_8060B64(u8);
-u8 GetOppositeDirection(u8);
-
-// asm/field_ground_effect.o
-u8 GetLedgeJumpDirection(s16, s16, u8);
-u8 ZCoordToPriority(u8);
-void FieldObjectUpdateZCoord(struct MapObject *pObject);
-void SetObjectSubpriorityByZCoord(u8, struct Sprite *, u8);
-
-// asm/field_tasks.o
-void SetUpFieldTasks();
-void ActivatePerStepCallback(u8);
-void ResetFieldTasksArgs(void);
-
-// asm/reset_rtc_screen.o
-void CB2_InitResetRtcScreen(void);
-
-// asm/party_menu.o
-void sub_806CB74(u8 taskId);
-void sub_806CCE4(void);
-void sub_806CD44(u8 taskId);
-void sub_806D538();
-void sub_806D5A4(void);
-void GetMonNickname(struct Pokemon *mon, u8 *nickname);
-bool8 pokemon_has_move(struct Pokemon *, u16);
-void sub_806FA18(u8 taskId);
-
-// src/party_menu.o
-u8 sub_806E834(const u8 *message, u8 arg1);
-
-// src/rom_8077ABC.o
-u8 battle_side_get_owner(u8);
-u8 battle_get_per_side_status(u8);
-u8 battle_get_side_with_given_state(u8);
-bool8 IsDoubleBattle();
-
-// asm/field_weather.o
-void SetWeather(u32);
-
-// src/field_fadetransition.o
-void pal_fill_black();
-void sub_8080990(void);
-void sub_80809B0(void);
-
-// asm/field_fadetransition.o
-void sub_8080A3C(void);
-void sub_8080AC4(void);
-void mapldr_default();
-void sub_8080B60(void);
-void atk17_seteffectuser(void);
-void sub_8080E44(void);
-void sub_8080E88(void);
-void sp13E_warp_to_last_warp(void);
-void sub_8080EF0(void);
-void sp13F_fall_to_last_warp(void);
-void sub_8080F68(void);
-void sub_8080F9C(void);
-
-// asm/rom_8080874.o
-void sub_8081594(u8);
-void sub_80815E0(u8 val);
-
-// asm/cable_club.o
-u8 sub_8083664(void);
-void sub_8083A84(TaskFunc);
-s32 sub_8083BF4(u8 id);
-
-// asm/field_effect.o
-u8 CreateTrainerSprite_BirchSpeech(u8, u16, u16, u8, void *);
-void LoadTrainerGfx_TrainerCard(u8 gender, int, void *);
-u8 CreateBirchSprite(u8, u8, u8);
-
-// asm/unknown_task.o
-void remove_some_task(void);
-void dp12_8087EA4(void);
-void sub_80895F8(u32 i, u32 i1, u32 i2);
-void sub_8089668(void);
-void sub_8089944(int i, int i1, int i2, int i3, int i4, int i5, int i6);
-
-// asm/pokemon_menu.o
-void sub_8089A70(void);
-void sub_808A004();
-void sub_808AB90(void);
-
-// asm/rom_8094928.o
-u8 pokemon_order_func(u8);
-
-// asm/pokemon_storage_system.o
-void ResetPokemonStorageSystem(void);
-
-// asm/pokemon_icon.o
-u8 sub_809D3A4(u16 arg0, void (*)(struct Sprite *), int, u8 arg3, u32 arg4);
-u16 sub_809D4A8(u16);
-void sub_809D510(struct Sprite *);
-void sub_809D580(u16);
-void sub_809D608(u16);
-
-// asm/pokemon_summary_screen.o
-u8 pokemon_ailments_get_primary(u32);
-
-// src/script_movement.o
-bool8 exec_movement(u8, u8, u8, u8 *);
-bool8 sub_80A212C(u8, u8, u8);
-void sub_80A2178(void);
-
-// asm/mail_data.o
-void ClearMailData(void);
-u16 MailSpeciesToSpecies(u16, u8 *);
-
-// src/map_name_popup.o
-void ShowMapNamePopup(void);
-void HideMapNamePopup();
-
-// asm/item_menu.o
-void sub_80A3684(void);
-void ClearBag(void);
-void sub_80A53F8(void);
-void sub_80A5B40(void);
-void sub_80A68CC();
-u8 sub_80A7D8C(u8 berry, int i, int i1);
-void sub_80A7DD4(void);
-u8 sub_80A7E5C(u8);
-
-// asm/contest.o
-void ResetLinkContestBoolean(void);
-void sub_80AE098(u8);
-void sub_80AE398(u8, u8);
-u32 sub_80AE770(u8, u8);
-void sub_80AE82C(u8);
-void sub_80AF668(void);
-void sub_80B0F28(u8);
-void sub_80B2D1C(void);
-
-// asm/shop.o
-void CreatePokemartMenu(void *);
-void CreateDecorationShop1Menu(void *);
-void CreateDecorationShop2Menu(void *);
-
-// asm/secret_base.o
-void ResetSecretBases(void);
-u8 sub_80BBB24(void);
-void sub_80BBCCC(u8);
-u8 *sub_80BCCE8(void);
-void sub_80BD674(void *, u32, u8);
-
-// asm/tv.o
-void ClearTVShowData(void);
-void UpdateTVScreensOnMap(int, int);
-void ResetGabbyAndTy(void);
-u8 sub_80BDEAC(u8 *);
-void sub_80BE160(TVShow *);
-void sub_80BE8EC(u16);
-void UpdateMassOutbreakTimeLeft(u16);
-void sub_80BE97C(u8);
-void sub_80BEA50(u16);
-void sub_80BEA5C(u16);
-bool8 GetPriceReduction(u8);
-void sub_80BEE84(u16);
-size_t sub_80BF0B8(int);
-void sub_80BF478(void);
-u16 sub_80BF674(u16 species);
-s8 sub_80BF720(TVShow *);
-bool8 sub_80BF77C(u16);
-void sub_80BFD44(u8 *, u32, u8);
-void sub_80C0514(void *, u32, u8);
-
-// src/tv.o
-void StartMassOutbreak(void);
-void TVShowDone(void);
-
-// asm/contest_link_80C2020.o
-void sub_80C2358(void);
-void sub_80C48C8(void);
-void sub_80C4940(void);
-void sub_80C4980(u8);
-u8 sub_80C4B34(u8 *);
-
-// asm/fldeff_80C5CD4.o
-void DoFieldPoisonEffect(void);
-bool32 FieldPoisonEffectIsRunning(void);
-void CreateRecordMixingSprite(void);
-void DestroyRecordMixingSprite(void);
-
-// asm/rotating_gate.o
-void RotatingGatePuzzleCameraUpdate(s16, s16);
-void sub_80C8080();
-u32 CheckForRotatingGatePuzzleCollision(u8, s16, s16);
-
-// asm/contest_link_80C857C.o
-void sub_80C8734(u8);
-void sub_80C88AC(u8);
-void sub_80C8E1C(u8);
-void sub_80C8EBC(u8);
-void sub_80C8F34(u8);
-
-// asm/easy_chat.o
-void InitEasyChatPhrases(void);
-u8* sub_80EB3FC(u8 *, u16);
-u8 *ConvertEasyChatWordsToString(u8 *dst, u16 *words, u16, u16);
-
-// asm/pokenav.o
-void sub_80EBA5C(void);
-
-// src/mauville_old_man.o
-void SetMauvilleOldMan(void);
-
-// asm/mauville_old_man.o
-void sub_80F7F30(void);
-
-// asm/menu_helpers.o
-bool8 sub_80F9344(void);
-void sub_80F9368(void);
-void sub_80F9438(void);
-
-// asm/region_map.o
-void sub_80FBFB4(u8 *str, u8 region, u8);
-void CopyMapName();
-u8 *CopyLocationName(u8 *dest, u8 location);
-
-// asm/slot_machine.o
-void PlaySlotMachine(u8, void *);
-
-// asm/pokeblock.o
-void ClearPokeblocks(void);
-void sub_810CA6C(s32);
-s16 sub_810CAE4(u8, struct Pokeblock *);
-
-// asm/fldeff_flash.o
-void sub_810CC80(void);
-
-// src/time_events.o
-u8 IsMirageIslandPresent(void);
-
-// asm/field_specials.o
-void ResetCyclingRoadChallengeData(void);
-bool32 CountSSTidalStep(u16);
-u8 GetSSTidalLocation(s8 *, s8 *, s16 *, s16 *);
-void ScriptAddElevatorMenuItem(u8, u8, u8, u8);
-void ScriptShowElevatorMenu(void);
-u8 GetLeadMonIndex(void);
-void ResetFanClub(void);
-
-// asm/battle_records.o
-void InitLinkBattleRecords(void);
-
-// asm/pokedex_cry_screen.o
-u8 sub_8119E3C(struct CryRelatedStruct *, u8);
-void sub_8119F88(u8 a);
-void sub_811A050(u16 species);
-u8 ShowPokedexCryScreen(struct CryRelatedStruct *, u8);
-void DestroyCryMeterNeedleSprite();
-
-// asm/battle_transition.o
-void sub_811AABC(u8);
-void sub_811AAD8(u8);
-u8 sub_811AAE8(void);
-
-// asm/battle_message.o
-void get_battle_strings_(u8 *);
-void sub_8120FFC(const u8 *, u8 *);
-
-// src/mystery_event_script.o
-u32 sub_812613C(u8 *);
-void sub_8126160(u8);
-
-// asm/mystery_event_script.o
-u16 sub_8126338(void);
-
-// asm/field_effect_helpers.o
-u8 sub_8126B54(void);
-void objid_set_invisible(u8);
-void sub_8126BC4(u8 unk_1B, u8 r6, s16 x, s16 y);
-void sub_8127ED0(u8, u8);
-void sub_8127F28(u8, u8, s16);
-u8 sub_8128124(u8 id);
-
-// asm/learn_move.o
-void sub_8132670(void);
-
-// asm/decoration_inventory.o
-void ClearDecorationInventories(void);
-u8 sub_8133FE4(u8);
-u8 IsThereStorageSpaceForDecoration(u8);
-u8 sub_8134074(u8);
-s8 sub_81340A8(u8);
-
-// asm/battle_tower.o
-void sub_8134AC0(void *);
-
-// src/player_pc.o
-void NewGameInitPCItems(void);
-
-// asm/hall_of_fame.o
-void sub_8143648(u16 paletteTag, u8 arg1);
-
-// src/diploma.o
-void sub_8145D88(void);
-
-// asm/intro_credits_graphics.o
-void load_intro_part2_graphics(/*TODO: arg types*/);
-void sub_8148C78(/*TODO: arg types*/);
-void sub_8148CB0(u8);
-void sub_8148E90(u8);
-u8 sub_8148EC0(/*TODO: arg types*/);
-void sub_8149020(/*TODO: arg types*/);
-u8 intro_create_brendan_sprite(/*TODO: arg types*/);
-u8 intro_create_may_sprite(/*TODO: arg types*/);
-u8 intro_create_latios_sprite(/*TODO: arg types*/);
-u8 intro_create_latias_sprite(/*TODO: arg types*/);
diff --git a/include/asm_fieldmap.h b/include/asm_fieldmap.h
deleted file mode 100644
index 10d8c8f6d..000000000
--- a/include/asm_fieldmap.h
+++ /dev/null
@@ -1,23 +0,0 @@
-#ifndef GUARD_FIELDMAP_H
-#define GUARD_FIELDMAP_H
-
-void not_trainer_hill_battle_pyramid(void);
-void sub_8055FC0(void);
-u8 MapGridGetZCoordAt();
-bool8 MapGridIsImpassableAt(s16, s16);
-int MapGridGetMetatileIdAt(int, int);
-u32 MapGridGetMetatileBehaviorAt(int x, int y); // return: (u8|u16|int) args: (int|s16|s32)
-u8 MapGridGetMetatileLayerTypeAt(/*TODO: arg types*/);
-void MapGridSetMetatileIdAt(u32, u32, u16);
-void save_serialize_map(void);
-int CameraMove(int, int);
-void sub_8056C50(u16, u16);
-void sav1_camera_get_focus_coords(s16 *x, s16 *y);
-void GetCameraCoords(s16*, s16*);
-void sub_8056D28(struct MapData *pData);
-void sub_8056D38(struct MapData *pData);
-void apply_map_tileset2_palette(struct MapData *pData);
-void copy_map_tileset1_tileset2_to_vram(/*TODO: arg types*/);
-void apply_map_tileset1_tileset2_palette(/*TODO: arg types*/);
-
-#endif // GUARD_FIELDMAP_H
diff --git a/include/battle.h b/include/battle.h
index 47ddef71d..255813ca3 100644
--- a/include/battle.h
+++ b/include/battle.h
@@ -1,6 +1,8 @@
#ifndef GUARD_BATTLE_H
#define GUARD_BATTLE_H
+#include "sprite.h"
+
#define BATTLE_TYPE_DOUBLE 0x0001
#define BATTLE_TYPE_LINK 0x0002
#define BATTLE_TYPE_WILD 0x0004
@@ -32,13 +34,6 @@
// needed to match the hack that is get_item, thanks cam, someone else clean this up later.
extern u8 unk_2000000[];
-// to do: maybe try to reduce the defines needed to match?
-#define BATTLE_STRUCT ((struct BattleStruct *)(unk_2000000))
-#define AI_THINKING_STRUCT ((struct AI_ThinkingStruct *)(unk_2000000 + 0x16800))
-#define UNK_2016A00_STRUCT ((struct UnkBattleStruct1 *)(unk_2000000 + 0x16A00))
-#define AI_STACK ((struct AI_Stack *)(unk_2000000 + 0x16C00))
-#define AI_ARRAY_160CC ((struct SmallItemStruct *)(unk_2000000 + 0x160CC))
-
enum
{
WEATHER_SUN,
@@ -142,11 +137,7 @@ struct UnkBattleStruct4
/*0x17*/ u8 filler17[0x4];
};
-extern struct UnknownStruct1 unk_2016A00;
-extern struct UnkBattleStruct4 gUnknown_02024CA8[];
-extern struct AI_ThinkingStruct gAIThinkingSpace;
-
-struct UnknownStruct11
+struct Struct30042E0
{
u8 unk0;
u8 unk1;
@@ -171,4 +162,159 @@ struct UnknownStruct11
u8 unk36[10];
};
+struct Struct2017800
+{
+ u8 unk0_0:1;
+ u8 unk0_1:1;
+ u8 unk0_2:1;
+ u8 unk0_3:1;
+ u8 unk0_4:1;
+ u16 unk2;
+};
+
+struct Struct2017810
+{
+ u8 unk0_0:1;
+ u8 unk0_1:1;
+ u8 unk0_2:1;
+ u8 unk0_3:1;
+ u8 unk0_4:1;
+ u8 unk0_5:1;
+ u8 unk0_6:1;
+ u8 unk0_7:1;
+ u8 unk1_0:1;
+ u8 unk2;
+ u8 unk3;
+ //u8 filler2[2];
+ u8 unk4;
+ u8 unk5;
+ u8 unk6;
+ u8 unk7;
+ u8 unk8;
+ u8 unk9;
+ u8 fillerA[2];
+};
+
+struct Struct2017840
+{
+ u16 unk0;
+ u8 filler2[7];
+ u8 unk9_0:1;
+};
+
+extern struct UnkBattleStruct1 unk_2016A00;
+extern struct UnkBattleStruct4 gUnknown_02024CA8[];
+extern struct AI_ThinkingStruct gAIThinkingSpace;
+
+// TODO: move ewram to global.h
+extern u8 ewram[];
+
+#define BATTLE_STRUCT ((struct BattleStruct *) (ewram + 0x00000))
+#define AI_THINKING_STRUCT ((struct AI_ThinkingStruct *)(ewram + 0x16800))
+#define UNK_2016A00_STRUCT ((struct UnkBattleStruct1 *) (ewram + 0x16A00))
+#define AI_STACK ((struct AI_Stack *) (ewram + 0x16C00))
+#define AI_ARRAY_160CC ((struct SmallItemStruct *) (ewram + 0x160CC))
+#define ewram17800 ((struct Struct2017800 *) (ewram + 0x17800))
+#define ewram17810 ((struct Struct2017810 *) (ewram + 0x17810))
+#define ewram17840 (*(struct Struct2017840 *) (ewram + 0x17840))
+
+// asm/battle_1.o
+void sub_800D6D4();
+void sub_800D74C();
+void sub_800D7B8(void);
+void sub_800DAB8();
+void sub_800DE30(u8);
+void sub_800E23C();
+
+// src/battle_2.o
+void sub_800E7C4(void);
+void InitBattle(void);
+void sub_800EC9C(void);
+void sub_800F104(void);
+void sub_800F298(void);
+void sub_800F808(void);
+void sub_800F838(struct Sprite *);
+u8 CreateNPCTrainerParty(struct Pokemon *, u16);
+void sub_800FCFC(void);
+void c2_8011A1C(void);
+void sub_80101B8(void);
+void c2_081284E0(void);
+void sub_8010278(struct Sprite *);
+void sub_80102AC(struct Sprite *);
+void nullsub_37(struct Sprite *);
+void sub_8010320(struct Sprite *);
+void sub_8010494(struct Sprite *);
+void sub_801053C(struct Sprite *);
+void oac_poke_ally_(struct Sprite *);
+void nullsub_86(struct Sprite *);
+void objc_dp11b_pingpong(struct Sprite *);
+void nullsub_41(void);
+void sub_8010800(void);
+void sub_8010824(void);
+void sub_8010874(void);
+void bc_8012FAC(void);
+void bc_load_battlefield(void);
+void sub_8011384(void);
+void bc_801333C(void);
+void bc_battle_begin_message(void);
+void bc_8013568(void);
+void sub_8011800(void);
+void sub_8011834(void);
+void bc_801362C(void);
+void sub_8011970(void);
+void sub_80119B4(void);
+void sub_8011B00(void);
+void sub_8011E8C(void);
+
+// asm/battle_2.o
+void sub_8012324(void);
+void sub_8012FBC(u8, u8);
+u8 b_first_side(u8, u8, u8);
+void sub_801365C(u8);
+void sub_801377C(void);
+void sub_80138F0(void);
+void dp01_battle_side_mark_buffer_for_execution();
+void sub_80155A4();
+void b_cancel_multi_turn_move_maybe(u8);
+void b_std_message();
+void sub_80156DC();
+void sub_80157C4(u8 index);
+
+// asm/battle_3.o
+u8 sub_8015A98(u8, u8, u8);
+u8 sub_8015DFC();
+u8 sub_8016558();
+u8 sub_80170DC();
+u8 sub_80173A4();
+u8 sub_8018324(u8, u8, u8, u8, u16);
+u8 sub_801A02C();
+
+// asm/battle_4.o
+void sub_801CAF8(u8, u8);
+void move_effectiveness_something(u16, u8, u8);
+
+// asm/battle_5.o
+void nullsub_91(void);
+void sub_802BF74(void);
+void sub_802C098();
+void c3_0802FDF4(u8);
+void sub_802E3E4(u8, int);
+void nullsub_8(u8);
+void sub_802E414(void);
+
+// asm/battle_7.o
+void move_anim_start_t4(u8 a, u8 b, u8 c, u8 d);
+void nullsub_9(u16);
+void nullsub_10(int);
+void load_gfxc_health_bar();
+u8 battle_load_something();
+void sub_8031F88(u8);
+void sub_80324F8(struct Pokemon *, u8);
+void sub_8032638();
+void sub_8032AA8(u8, u8);
+void sub_8032AE0(void);
+
+// asm/battle_9.o
+void sub_8037510(void);
+
#endif // GUARD_BATTLE_H
diff --git a/include/battle_811DA74.h b/include/battle_811DA74.h
new file mode 100644
index 000000000..8b7e2f090
--- /dev/null
+++ b/include/battle_811DA74.h
@@ -0,0 +1,11 @@
+#ifndef GUARD_BATTLE_811DA74_H
+#define GUARD_BATTLE_811DA74_H
+
+void sub_811DA78(void);
+void sub_811DA94(void);
+void sub_811E0A0(void);
+void dp01_tbl3_exec_completed(void);
+u32 dp01_getattr_by_ch1_for_player_pokemon(u8 a, u8 *b);
+void sub_811EC68(u8);
+
+#endif // GUARD_BATTLE_811DA74_H
diff --git a/include/battle_ai.h b/include/battle_ai.h
index a5fea3480..028da2c27 100644
--- a/include/battle_ai.h
+++ b/include/battle_ai.h
@@ -27,5 +27,6 @@ void BattleAI_DoAIProcessing(void);
void sub_810745C(void);
void AIStackPushVar(u8 *);
u8 AIStackPop(void);
+void BattleAI_HandleItemUseBeforeAISetup(void);
#endif
diff --git a/include/battle_anim.h b/include/battle_anim.h
index e75c71ec0..48ceece21 100644
--- a/include/battle_anim.h
+++ b/include/battle_anim.h
@@ -1,6 +1,8 @@
#ifndef GUARD_BATTLEANIM_H
#define GUARD_BATTLEANIM_H
+#include "sprite.h"
+
#define SCRIPT_READ_8(ptr) ((ptr)[0])
#define SCRIPT_READ_16(ptr) ((ptr)[0] | ((ptr)[1] << 8))
#define SCRIPT_READ_32(ptr) ((ptr)[0] + ((ptr)[1] << 8) + ((ptr)[2] << 16) + ((ptr)[3] << 24))
@@ -54,5 +56,12 @@ void DoMoveAnim(const u8 *const moveAnims[], u16 b, u8 c);
bool8 b_side_obj__get_some_boolean(u8 a);
void sub_8076034(u8, u8);
bool8 IsContest(void);
+void battle_anim_clear_some_data(void);
+void move_anim_8072740(struct Sprite *sprite);
+void DestroyAnimVisualTask(u8 task);
+void DestroyAnimVisualTask(u8 task);
+bool8 b_side_obj__get_some_boolean(u8);
+u8 IsContest();
+
#endif
diff --git a/include/battle_anim_80CA710.h b/include/battle_anim_80CA710.h
new file mode 100644
index 000000000..fbbe23b97
--- /dev/null
+++ b/include/battle_anim_80CA710.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_BATTLE_ANIM_80CA710_H
+#define GUARD_BATTLE_ANIM_80CA710_H
+
+void sub_80E4EF8(int, int, int, int, u16, u8, int);
+
+#endif // GUARD_BATTLE_ANIM_80CA710_H
diff --git a/include/battle_anim_81258BC.h b/include/battle_anim_81258BC.h
new file mode 100644
index 000000000..6bbf5dde2
--- /dev/null
+++ b/include/battle_anim_81258BC.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_BATTLE_ANIM_81258BC_H
+#define GUARD_BATTLE_ANIM_81258BC_H
+
+void sub_812B468(void);
+void bx_battle_menu_t6_2(void);
+
+#endif // GUARD_BATTLE_ANIM_81258BC_H
diff --git a/include/battle_anim_8137220.h b/include/battle_anim_8137220.h
new file mode 100644
index 000000000..c9708ac62
--- /dev/null
+++ b/include/battle_anim_8137220.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_BATTLE_ANIM_8137220_H
+#define GUARD_BATTLE_ANIM_8137220_H
+
+void sub_8137224(void);
+
+#endif // GUARD_BATTLE_ANIM_8137220_H
diff --git a/include/battle_anim_813F0F4.h b/include/battle_anim_813F0F4.h
new file mode 100644
index 000000000..230a04dbb
--- /dev/null
+++ b/include/battle_anim_813F0F4.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_BATTLE_ANIM_813F0F4_H
+#define GUARD_BATTLE_ANIM_813F0F4_H
+
+void sub_8141828();
+
+#endif // GUARD_BATTLE_ANIM_813F0F4_H
diff --git a/include/battle_interface.h b/include/battle_interface.h
index e85f87a30..8230c7502 100644
--- a/include/battle_interface.h
+++ b/include/battle_interface.h
@@ -31,6 +31,7 @@ void sub_8045A5C(u8, struct Pokemon *, u8);
s32 sub_8045C78(u8, u8, u8, u8);
s16 sub_80460C8(struct BattleInterfaceStruct1 *, int *, void *, int);
u8 GetScaledHPFraction(s16, s16, u8);
-int GetHPBarLevel(s16, s16);
+u8 GetHPBarLevel(s16, s16);
+void sub_80440EC(u8 a, s16 b, u8 c);
#endif // GUARD_BATTLE_INTERFACE_H
diff --git a/include/battle_message.h b/include/battle_message.h
new file mode 100644
index 000000000..04a7770a3
--- /dev/null
+++ b/include/battle_message.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_BATTLE_MESSAGE_H
+#define GUARD_BATTLE_MESSAGE_H
+
+void get_battle_strings_(u8 *);
+void sub_8120FFC(const u8 *, u8 *);
+
+#endif // GUARD_BATTLE_MESSAGE_H
diff --git a/include/battle_party_menu.h b/include/battle_party_menu.h
index b9c3ad707..5112c7b3c 100644
--- a/include/battle_party_menu.h
+++ b/include/battle_party_menu.h
@@ -3,7 +3,8 @@
#include "task.h"
-struct UnknownStruct1
+// TODO: Unify all of the 0x0201B000 structs
+struct Struct201B000
{
u8 filler0[0x259];
u8 unk259;
@@ -15,24 +16,11 @@ struct UnknownStruct1
s16 unk266;
};
-struct PartyMenuItem
-{
- const u8 *text;
- TaskFunc func;
-};
-
-struct PartyPopupMenu
-{
- u8 unk0;
- u8 unk1;
- const u8 *unk4;
-};
-
extern u8 unk_2000000[];
void SetUpBattlePokemonMenu(u8);
#define EWRAM_1609D unk_2000000[0x1609D]
-#define EWRAM_1B000 (*(struct UnknownStruct1 *)(unk_2000000 + 0x1B000))
+#define EWRAM_1B000 (*(struct Struct201B000 *)(unk_2000000 + 0x1B000))
#endif
diff --git a/include/battle_records.h b/include/battle_records.h
new file mode 100644
index 000000000..f0c1a101b
--- /dev/null
+++ b/include/battle_records.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_BATTLE_RECORDS_H
+#define GUARD_BATTLE_RECORDS_H
+
+void InitLinkBattleRecords(void);
+void PrintLinkBattleWinsLossesDraws(void *);
+void PrintLinkBattleRecord(void *, u8);
+
+#endif // GUARD_BATTLE_RECORDS_H
diff --git a/include/battle_tower.h b/include/battle_tower.h
new file mode 100644
index 000000000..193905b93
--- /dev/null
+++ b/include/battle_tower.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_BATTLE_TOWER_H
+#define GUARD_BATTLE_TOWER_H
+
+void sub_8134AC0(void *);
+u16 sub_8135D3C(u8);
+
+#endif // GUARD_BATTLE_TOWER_H
diff --git a/include/battle_transition.h b/include/battle_transition.h
new file mode 100644
index 000000000..b01378505
--- /dev/null
+++ b/include/battle_transition.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_BATTLE_TRANSITION_H
+#define GUARD_BATTLE_TRANSITION_H
+
+void sub_811AABC(u8);
+void sub_811AAD8(u8);
+u8 sub_811AAE8(void);
+
+#endif // GUARD_BATTLE_TRANSITION_H
diff --git a/include/berry_blender.h b/include/berry_blender.h
new file mode 100644
index 000000000..924b24b00
--- /dev/null
+++ b/include/berry_blender.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_BERRY_BLENDER_H
+#define GUARD_BERRY_BLENDER_H
+
+void sub_80516C4(u8, u16);
+
+#endif // GUARD_BERRY_BLENDER_H
diff --git a/include/cable_club.h b/include/cable_club.h
new file mode 100644
index 000000000..9e6a703e3
--- /dev/null
+++ b/include/cable_club.h
@@ -0,0 +1,22 @@
+#ifndef GUARD_CABLE_CLUB_H
+#define GUARD_CABLE_CLUB_H
+
+#include "task.h"
+
+void sub_8082D4C();
+void sub_8082D60(u8, u8);
+u16 sub_8082D9C(u8, u8);
+u32 sub_8082DF4(u8);
+u32 sub_8082E28(u8);
+u32 sub_8082EB8(u8);
+void sub_8082FEC(u8 taskId);
+void sub_80833C4(u8 taskId);
+void sub_8083418(u8 taskId);
+u8 sub_8083444(u8 taskId);
+u8 sub_8083664(void);
+void sub_8083A84(TaskFunc);
+s32 sub_8083BF4(u8 id);
+void sub_8083C50(u8);
+void sub_8083188(u8 taskId);
+
+#endif // GUARD_CABLE_CLUB_H
diff --git a/include/choose_party.h b/include/choose_party.h
new file mode 100644
index 000000000..1e575a355
--- /dev/null
+++ b/include/choose_party.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_CHOOSE_PARTY_H
+#define GUARD_CHOOSE_PARTY_H
+
+void sub_8121E10(void);
+void sub_8121E34(void);
+void sub_8123138(u8);
+
+#endif // GUARD_CHOOSE_PARTY_H
diff --git a/include/contest.h b/include/contest.h
index 82520717f..983f9bc6a 100644
--- a/include/contest.h
+++ b/include/contest.h
@@ -22,5 +22,19 @@ struct ContestPokemon
}; // wow
extern struct ContestPokemon gContestMons[];
+void ResetLinkContestBoolean(void);
+void sub_80AB2AC(void);
+void sub_80AB47C(void);
+void sub_80AE098(u8);
+void sub_80AE398(u8, u8);
+u8 sub_80AE47C(struct Pokemon *party);
+u32 sub_80AE770(u8, u8);
+void sub_80AE82C(u8);
+u8 sub_80AEB1C();
+void sub_80AF668(void);
+void sub_80B0F28(u8);
+int sub_80B2A7C(u8); //Don't know return type size
+u8 sub_80B2C4C(u8, u8);
+void sub_80B2D1C(void);
#endif // GUARD_CONTEST_H
diff --git a/include/contest_link_80C2020.h b/include/contest_link_80C2020.h
new file mode 100644
index 000000000..0b49d188c
--- /dev/null
+++ b/include/contest_link_80C2020.h
@@ -0,0 +1,13 @@
+#ifndef GUARD_CONTEST_LINK_80C2020_H
+#define GUARD_CONTEST_LINK_80C2020_H
+
+void sub_80C2358(void);
+void sub_80C46EC(void);
+void sub_80C4740(void);
+void sub_80C48C8(void);
+void sub_80C48F4(void);
+void sub_80C4940(void);
+void sub_80C4980(u8);
+u8 sub_80C4B34(u8 *);
+
+#endif // GUARD_CONTEST_LINK_80C2020_H
diff --git a/include/contest_link_80C857C.h b/include/contest_link_80C857C.h
new file mode 100644
index 000000000..9135ba2e7
--- /dev/null
+++ b/include/contest_link_80C857C.h
@@ -0,0 +1,10 @@
+#ifndef GUARD_CONTEST_LINK_80C857C_H
+#define GUARD_CONTEST_LINK_80C857C_H
+
+void sub_80C8734(u8);
+void sub_80C88AC(u8);
+void sub_80C8E1C(u8);
+void sub_80C8EBC(u8);
+void sub_80C8F34(u8);
+
+#endif // GUARD_CONTEST_LINK_80C857C_H
diff --git a/include/contest_painting.h b/include/contest_painting.h
index 5c1b065c2..ad1cecfed 100644
--- a/include/contest_painting.h
+++ b/include/contest_painting.h
@@ -60,26 +60,7 @@ struct LabelPair
const u8 *suffix;
};
-struct Unk03005E20
-{
- u8 var_0;
- u8 pad1[3];
- u16 (*var_4)[][32];
- u16 (*var_8)[];
- u8 pad0C[4];
- u32 var_10;
- u16 var_14;
- u16 var_16;
- u8 var_18;
- u8 var_19;
- u8 var_1A;
- u8 var_1B;
- u8 var_1C;
- u8 var_1D;
- u8 var_1E;
- u8 var_1F;
-};
-
void sub_8106630(u32);
+void CB2_ContestPainting(void);
#endif
diff --git a/include/coord_event_weather.h b/include/coord_event_weather.h
new file mode 100644
index 000000000..86fb48793
--- /dev/null
+++ b/include/coord_event_weather.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_COORD_EVENT_WEATHER_H
+#define GUARD_COORD_EVENT_WEATHER_H
+
+void DoCoordEventWeather(u8);
+
+#endif // GUARD_COORD_EVENT_WEATHER_H
diff --git a/include/cute_sketch.h b/include/cute_sketch.h
new file mode 100644
index 000000000..1fa3c90fb
--- /dev/null
+++ b/include/cute_sketch.h
@@ -0,0 +1,28 @@
+#ifndef GUARD_CUTE_SKETCH_H
+#define GUARD_CUTE_SKETCH_H
+
+struct Unk03005E20
+{
+ u8 var_0;
+ u8 pad1[3];
+ u16 (*var_4)[][32];
+ u16 (*var_8)[];
+ u8 pad0C[4];
+ u32 var_10;
+ u16 var_14;
+ u16 var_16;
+ u8 var_18;
+ u8 var_19;
+ u8 var_1A;
+ u8 var_1B;
+ u8 var_1C;
+ u8 var_1D;
+ u8 var_1E;
+ u8 var_1F;
+};
+
+void sub_80FC7A0(struct Unk03005E20 *);
+void sub_80FD8CC(struct Unk03005E20 *);
+void sub_80FDA18(struct Unk03005E20 *);
+
+#endif // GUARD_CUTE_SKETCH_H
diff --git a/include/data2.h b/include/data2.h
index 987c7cb2e..759efe3d3 100644
--- a/include/data2.h
+++ b/include/data2.h
@@ -29,7 +29,7 @@ extern const union AnimCmd *const *const gUnknown_081EC2A4[];
extern const union AnimCmd *const *const gUnknown_081ECACC[];
extern struct MonCoords gTrainerBackPicCoords[];
extern struct SpriteSheet gTrainerBackPicTable[];
-extern struct SpritePalette gTrainerBackPicPaletteTable[];
+extern const struct SpritePalette gTrainerBackPicPaletteTable[];
extern u8 gEnemyMonElevation[];
extern const u8 gTrainerClassNames[][13];
extern const struct Trainer gTrainers[];
@@ -40,7 +40,7 @@ extern const u8 gUnknown_081F96C8[];
extern struct SpriteSheet gUnknown_081FAEA4;
extern struct SpritePalette gUnknown_081FAEAC;
extern const struct SpriteTemplate gSpriteTemplate_81FAF0C;
-extern void *gUnknown_081FAF4C[];
+extern void *const gUnknown_081FAF4C[];
extern struct BattleMove gBattleMoves[];
#endif // GUARD_DATA2_H
diff --git a/include/daycare.h b/include/daycare.h
new file mode 100644
index 000000000..b90c50610
--- /dev/null
+++ b/include/daycare.h
@@ -0,0 +1,14 @@
+#ifndef GUARD_DAYCARE_H
+#define GUARD_DAYCARE_H
+
+u8 Daycare_CountPokemon(struct BoxPokemon *);
+void sub_8041324(struct BoxPokemon *, struct RecordMixing_UnknownStruct *);
+void sub_8041790(int i);
+u16 sub_8041870(u16);
+void sub_8041940(void);
+void sub_8041950(void);
+void sub_8042044(struct Pokemon *mon, u16, u8);
+u8 sub_80422A0(void);
+u8 daycare_relationship_score_from_savegame(void);
+
+#endif // GUARD_DAYCARE_H
diff --git a/include/debug.h b/include/debug.h
new file mode 100644
index 000000000..f3ad8c401
--- /dev/null
+++ b/include/debug.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_DEBUG_H
+#define GUARD_DEBUG_H
+
+// matsuda_debug_menu
+void sub_80AAF30(void);
+
+#endif // GUARD_DEBUG_H
diff --git a/include/decoration.h b/include/decoration.h
index 01a00ee91..2595d491a 100755..100644
--- a/include/decoration.h
+++ b/include/decoration.h
@@ -1,6 +1,8 @@
#ifndef GUARD_DECORATION_H
#define GUARD_DECORATION_H
+#include "task.h"
+
enum DecoId {
/*000*/ DECOR_NONE,
/*001*/ DECOR_SMALL_DESK,
@@ -262,7 +264,7 @@ extern u8 gUnknown_020391A8;
extern u8 gUnknown_020391A9;
extern u8 gUnknown_020391AA;
extern u8 gUnknown_02039234;
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern const struct YesNoFuncTable gUnknown_083EC96C[];
extern struct UnkStruct_020391B4 gUnknown_020391B4[16];
@@ -372,5 +374,6 @@ void sub_8100FB4(u8);
void sub_810153C(u8);
void sub_8101590(u8);
void sub_8101848(u8);
+void DoPlayerPCDecoration(u8);
#endif // GUARD_DECORATION_H
diff --git a/include/decoration_inventory.h b/include/decoration_inventory.h
new file mode 100644
index 000000000..afc354237
--- /dev/null
+++ b/include/decoration_inventory.h
@@ -0,0 +1,10 @@
+#ifndef GUARD_DECORATION_INVENTORY_H
+#define GUARD_DECORATION_INVENTORY_H
+
+void ClearDecorationInventories(void);
+u8 sub_8133FE4(u8);
+u8 IsThereStorageSpaceForDecoration(u8);
+u8 sub_8134074(u8);
+s8 sub_81340A8(u8);
+
+#endif // GUARD_DECORATION_INVENTORY_H
diff --git a/include/dewford_trend.h b/include/dewford_trend.h
index a37de3389..26075d633 100644
--- a/include/dewford_trend.h
+++ b/include/dewford_trend.h
@@ -6,5 +6,6 @@
void InitDewfordTrend(void);
void sub_80FA4E4(void *, u32, u8);
+void UpdateDewfordTrendPerDay(u16);
#endif
diff --git a/include/diploma.h b/include/diploma.h
new file mode 100644
index 000000000..81e9e3bb2
--- /dev/null
+++ b/include/diploma.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_DIPLOMA_H
+#define GUARD_DIPLOMA_H
+
+void sub_8145D88(void);
+
+#endif // GUARD_DIPLOMA_H
diff --git a/include/easy_chat.h b/include/easy_chat.h
index dca6b80c2..6b04f524b 100644
--- a/include/easy_chat.h
+++ b/include/easy_chat.h
@@ -29,5 +29,16 @@ enum {
u16 sub_80EB72C(u16 group);
void sub_80EB6FC(u16 *, u16);
+void InitEasyChatPhrases(void);
+u8 sub_80EAD7C(u8 group);
+u16 sub_80EAE88(u8);
+u8 sub_80EB37C(u16);
+u8* sub_80EB3FC(u8 *, u16);
+u8 *ConvertEasyChatWordsToString(u8 *dst, u16 *words, u16, u16);
+u16 sub_80EB784(u16 group);
+u8 sub_80EB868(u8);
+void sub_80EB890(u8);
+u8 sub_80EB8C0(void);
+u16 sub_80EB8EC(void);
#endif // GUARD_EASYCHAT_H
diff --git a/include/field_control_avatar.h b/include/field_control_avatar.h
index 0f8b74d59..a85e02132 100644
--- a/include/field_control_avatar.h
+++ b/include/field_control_avatar.h
@@ -1,7 +1,27 @@
#ifndef GUARD_FIELDCONTROLAVATAR_H
#define GUARD_FIELDCONTROLAVATAR_H
-#include "asm.h"
+struct FieldInput
+{
+ u8 pressedAButton:1;
+ u8 input_field_0_1:1;
+ u8 pressedStartButton:1;
+ u8 pressedSelectButton:1;
+ u8 input_field_0_4:1;
+ u8 input_field_0_5:1;
+ u8 input_field_0_6:1;
+ u8 pressedBButton:1;
+ u8 input_field_1_0:1;
+ u8 input_field_1_1:1;
+ u8 input_field_1_2:1;
+ u8 input_field_1_3:1;
+ u8 input_field_1_4:1;
+ u8 input_field_1_5:1;
+ u8 input_field_1_6:1;
+ u8 input_field_1_7:1;
+ u8 dpadDirection;
+ u8 input_field_3;
+};
void FieldClearPlayerInput(struct FieldInput *pStruct);
void FieldGetPlayerInput(struct FieldInput *pStruct, u16 keys, u16 heldKeys);
@@ -11,5 +31,10 @@ void overworld_poison_timer_set(void);
void prev_quest_postbuffer_cursor_backup_reset(void);
u8 *sub_8068E24(struct MapPosition *);
u8 *GetFieldObjectScriptPointerForComparison();
+bool8 mapheader_trigger_activate_at__run_now(struct MapPosition *);
+bool8 sub_8068870(u16 a);
+bool8 sub_8068894(void);
+bool8 sub_8068A64(struct MapPosition *, u16);
+u8 sub_8068F18(void);
#endif
diff --git a/include/field_effect.h b/include/field_effect.h
index a46c048cb..74b5fa34d 100644
--- a/include/field_effect.h
+++ b/include/field_effect.h
@@ -2,6 +2,86 @@
#define GUARD_FIELD_EFFECT_H
#include "sprite.h"
+#include "task.h"
+
+enum FieldEffectScriptIdx
+{
+ FLDEFF_EXCLAMATION_MARK_ICON_1,
+ FLDEFF_USE_CUT_ON_GRASS,
+ FLDEFF_USE_CUT_ON_TREE,
+ FLDEFF_SHADOW,
+ FLDEFF_TALL_GRASS,
+ FLDEFF_RIPPLE,
+ FLDEFF_FIELD_MOVE_SHOW_MON,
+ FLDEFF_ASH,
+ FLDEFF_SURF_BLOB,
+ FLDEFF_USE_SURF,
+ FLDEFF_DUST,
+ FLDEFF_USE_SECRET_POWER_CAVE,
+ FLDEFF_JUMP_TALL_GRASS,
+ FLDEFF_SAND_FOOTPRINTS,
+ FLDEFF_JUMP_BIG_SPLASH,
+ FLDEFF_SPLASH,
+ FLDEFF_JUMP_SMALL_SPLASH,
+ FLDEFF_LONG_GRASS,
+ FLDEFF_JUMP_LONG_GRASS,
+ FLDEFF_UNKNOWN_19,
+ FLDEFF_UNKNOWN_20,
+ FLDEFF_UNKNOWN_21,
+ FLDEFF_UNKNOWN_22,
+ FLDEFF_BERRY_TREE_GROWTH_SPARKLE,
+ FLDEFF_DEEP_SAND_FOOTPRINTS,
+ FLDEFF_POKECENTER_HEAL,
+ FLDEFF_USE_SECRET_POWER_TREE,
+ FLDEFF_USE_SECRET_POWER_SHRUB,
+ FLDEFF_TREE_DISGUISE,
+ FLDEFF_MOUNTAIN_DISGUISE,
+ FLDEFF_NPCFLY_OUT,
+ FLDEFF_USE_FLY,
+ FLDEFF_FLY_IN,
+ FLDEFF_EXCLAMATION_MARK_ICON_2,
+ FLDEFF_FEET_IN_FLOWING_WATER,
+ FLDEFF_BIKE_TIRE_TRACKS,
+ FLDEFF_SAND_DISGUISE,
+ FLDEFF_USE_ROCK_SMASH,
+ FLDEFF_USE_DIG,
+ FLDEFF_SAND_PILE,
+ FLDEFF_USE_STRENGTH,
+ FLDEFF_SHORT_GRASS,
+ FLDEFF_HOT_SPRINGS_WATER,
+ FLDEFF_USE_WATERFALL,
+ FLDEFF_USE_DIVE,
+ FLDEFF_POKEBALL,
+ FLDEFF_HEART_ICON,
+ FLDEFF_NOP_47,
+ FLDEFF_NOP_48,
+ FLDEFF_POP_OUT_OF_ASH,
+ FLDEFF_LAVARIDGE_GYM_WARP,
+ FLDEFF_SWEET_SCENT,
+ FLDEFF_SAND_PILLAR,
+ FLDEFF_BUBBLES,
+ FLDEFF_SPARKLE,
+ FLDEFF_SECRET_POWER_CAVE,
+ FLDEFF_SECRET_POWER_TREE,
+ FLDEFF_SECRET_POWER_SHRUB,
+ FLDEFF_CUT_GRASS,
+ FLDEFF_FIELD_MOVE_SHOW_MON_INIT,
+ FLDEFF_USE_FLY_ANCIENT_TOMB,
+ FLDEFF_PCTURN_ON,
+ FLDEFF_HALL_OF_FAME_RECORD,
+ FLDEFF_USE_TELEPORT
+};
+
+extern const struct SpritePalette gTrainerFrontPicPaletteTable[2];
+extern const struct SpritePalette gUnknown_0839F114;
+extern const struct SpriteSheet gTrainerFrontPicTable[2];
+extern const struct SpriteTemplate gSpriteTemplate_839F128;
+extern const struct OamData gOamData_839F0F4;
+extern struct SpriteTemplate gUnknown_02024E8C;
+
+extern const struct SpritePalette *sub_80409C8(u16, u32, u32);
+
+extern u8 gLastFieldPokeMenuOpened;
u32 FieldEffectStart(u8 id);
bool8 FieldEffectCmd_loadtiles(u8 **script, u32 *val);
@@ -25,5 +105,144 @@ void FieldEffectActiveListClear(void);
void FieldEffectActiveListAdd(u8 id);
void FieldEffectActiveListRemove(u8 id);
bool8 FieldEffectActiveListContains(u8 id);
+void sub_807DE38(u8 index);
+
+void SpriteCB_PokeballGlow(struct Sprite *);
+void SpriteCB_PokecenterMonitor(struct Sprite *);
+void SpriteCB_HallOfFameMonitor(struct Sprite *);
+
+void PokecenterHealEffect_0(struct Task *);
+void PokecenterHealEffect_1(struct Task *);
+void PokecenterHealEffect_2(struct Task *);
+void PokecenterHealEffect_3(struct Task *);
+
+void HallOfFameRecordEffect_0(struct Task *);
+void HallOfFameRecordEffect_1(struct Task *);
+void HallOfFameRecordEffect_2(struct Task *);
+void HallOfFameRecordEffect_3(struct Task *);
+
+void PokeballGlowEffect_0(struct Sprite *);
+void PokeballGlowEffect_1(struct Sprite *);
+void PokeballGlowEffect_2(struct Sprite *);
+void PokeballGlowEffect_3(struct Sprite *);
+void PokeballGlowEffect_4(struct Sprite *);
+void PokeballGlowEffect_5(struct Sprite *);
+void PokeballGlowEffect_6(struct Sprite *);
+void PokeballGlowEffect_7(struct Sprite *);
+
+bool8 sub_80867AC(struct Task *);
+bool8 sub_8086854(struct Task *);
+bool8 sub_8086870(struct Task *);
+bool8 sub_80868E4(struct Task *);
+bool8 sub_808699C(struct Task *);
+bool8 sub_80869B8(struct Task *);
+bool8 sub_80869F8(struct Task *);
+
+bool8 sub_8086AA0(struct Task *);
+bool8 sub_8086AC0(struct Task *);
+bool8 sub_8086B30(struct Task *);
+bool8 sub_8086B54(struct Task *);
+bool8 sub_8086B64(struct Task *);
+bool8 sub_8086B88(struct Task *);
+
+bool8 sub_8086CF4(struct Task *);
+bool8 sub_8086D70(struct Task *);
+bool8 sub_8086DB0(struct Task *);
+bool8 sub_8086E10(struct Task *);
+bool8 sub_8086E50(struct Task *);
+bool8 sub_8086EB0(struct Task *);
+bool8 sub_8086ED4(struct Task *);
+
+bool8 sub_8086FB0(struct Task *, struct MapObject *);
+bool8 waterfall_1_do_anim_probably(struct Task *, struct MapObject *);
+bool8 waterfall_2_wait_anim_finish_probably(struct Task *, struct MapObject *);
+bool8 sub_8087030(struct Task *, struct MapObject *);
+bool8 sub_8087058(struct Task *, struct MapObject *);
+
+bool8 sub_8087124(struct Task *);
+bool8 dive_2_unknown(struct Task *);
+bool8 dive_3_unknown(struct Task *);
+
+bool8 sub_808722C(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_8087264(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_8087298(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80872E4(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80873D8(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80873F4(struct Task *, struct MapObject *, struct Sprite *);
+
+bool8 sub_80874CC(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80874FC(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_8087548(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_808759C(struct Task *, struct MapObject *, struct Sprite *);
+
+bool8 sub_80876C8(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80876F8(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_8087774(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80877AC(struct Task *, struct MapObject *, struct Sprite *);
+bool8 sub_80877D4(struct Task *, struct MapObject *, struct Sprite *);
+
+void sub_80878F4(struct Task *);
+void sub_8087914(struct Task *);
+
+void sub_8087AA4(struct Task *);
+void sub_8087AC8(struct Task *);
+
+void sub_8087BEC(struct Task *);
+void sub_8087C14(struct Task *);
+void sub_8087CA4(struct Task *);
+void sub_8087D78(struct Task *);
+
+void sub_8087E4C(struct Task *);
+void sub_8087ED8(struct Task *);
+void sub_8087FDC(struct Task *);
+
+void sub_8088150(struct Task *);
+void sub_80881C0(struct Task *);
+void sub_8088228(struct Task *);
+void sub_80882B4(struct Task *);
+void sub_80882E4(struct Task *);
+void sub_8088338(struct Task *);
+void sub_8088380(struct Task *);
+
+void sub_80884AC(struct Task *);
+void sub_80884E8(struct Task *);
+void sub_8088554(struct Task *);
+void sub_80885A8(struct Task *);
+void sub_80885D8(struct Task *);
+void sub_808860C(struct Task *);
+void sub_808862C(struct Task *);
+
+void sub_8088984(struct Task *);
+void sub_80889E4(struct Task *);
+void sub_8088A30(struct Task *);
+void sub_8088A78(struct Task *);
+void sub_8088AF4(struct Task *);
+
+void sub_8088CA0(struct Task *);
+void sub_8088CF8(struct Task *);
+void sub_8088D3C(struct Task *);
+void sub_8088D94(struct Task *);
+void sub_8088DD8(struct Task *);
+void sub_8088E2C(struct Task *);
+void sub_8088EB4(struct Task *);
+void sub_8088F10(struct Task *);
+void sub_8088F30(struct Task *);
+
+void sub_80892A0(struct Task *);
+void sub_8089354(struct Task *);
+void sub_80893C0(struct Task *);
+void sub_8089414(struct Task *);
+void sub_808948C(struct Task *);
+void sub_80894C4(struct Task *);
+void fishE(struct Task *);
+
+u8 CreateTrainerSprite_BirchSpeech(u8 gender, s16 x, s16 y, u8 subpriority, u8 *buffer);
+void LoadTrainerGfx_TrainerCard(u8 gender, u16 palOffset, u8 *dest);
+u8 CreateBirchSprite(s16 x, s16 y, u8 subpriority);
+u8 CreateMonSprite_PicBox(u16, s16, s16, u8);
+void FreeResourcesAndDestroySprite(struct Sprite *sprite);
+void MultiplyInvertedPaletteRGBComponents(u16, u8, u8, u8);
+void sub_80878A8(void);
+void sub_8087BA8(void);
#endif // GUARD_FIELD_EFFECT_H
diff --git a/include/field_effect_helpers.h b/include/field_effect_helpers.h
index 62f492bdc..56838fc3a 100644
--- a/include/field_effect_helpers.h
+++ b/include/field_effect_helpers.h
@@ -1,11 +1,13 @@
-//
-// Created by scott on 5/25/2017.
-//
-
-#ifndef POKERUBY_FIELD_EFFECT_HELPERS_H
-#define POKERUBY_FIELD_EFFECT_HELPERS_H
+#ifndef GUARD_FIELD_EFFECT_HELPERS_H
+#define GUARD_FIELD_EFFECT_HELPERS_H
void sub_812869C(struct MapObject *);
bool8 sub_81286C4(struct MapObject *);
+u8 sub_8126B54(void);
+void objid_set_invisible(u8);
+void sub_8126BC4(u8 unk_1B, u8 r6, s16 x, s16 y);
+void sub_8127ED0(u8, u8);
+void sub_8127F28(u8, u8, s16);
+u8 sub_8128124(u8 id);
-#endif //POKERUBY_FIELD_EFFECT_HELPERS_H
+#endif // GUARD_FIELD_EFFECT_HELPERS_H
diff --git a/include/field_fadetransition.h b/include/field_fadetransition.h
new file mode 100644
index 000000000..764adfc9a
--- /dev/null
+++ b/include/field_fadetransition.h
@@ -0,0 +1,31 @@
+#ifndef GUARD_FIELD_FADETRANSITION_H
+#define GUARD_FIELD_FADETRANSITION_H
+
+void palette_bg_fill_white(void);
+void palette_bg_fill_black(void);
+void pal_fill_black(void);
+void pal_fill_black();
+void pal_fill_black(void);
+void task0A_asap_script_env_2_enable_and_set_ctx_running(u8);
+void sub_8080990(void);
+void sub_80809B0(void);
+void sub_8080A3C(void);
+void sub_8080AC4(void);
+void mapldr_default();
+void sub_8080B60(void);
+void atk17_seteffectuser(void);
+void sub_8080E28(void);
+void sub_8080E44(void);
+int sub_8080E70(void);
+void sub_8080E88(void);
+void sub_8080E88();
+void sp13E_warp_to_last_warp(void);
+void sub_8080EF0(void);
+void sp13F_fall_to_last_warp(void);
+void sub_8080F2C(u8);
+void sub_8080F48(void);
+void sub_8080F58(void);
+void sub_8080F68(void);
+void sub_8080F9C(void);
+
+#endif // GUARD_FIELD_FADETRANSITION_H
diff --git a/include/field_ground_effect.h b/include/field_ground_effect.h
index 8a69426b3..19d43c916 100644
--- a/include/field_ground_effect.h
+++ b/include/field_ground_effect.h
@@ -1,11 +1,27 @@
-//
-// Created by Scott Norton on 5/22/17.
-//
-
-#ifndef POKERUBY_FIELD_GROUND_EFFECT_H
-#define POKERUBY_FIELD_GROUND_EFFECT_H
+#ifndef GUARD_FIELD_GROUND_EFFECT_H
+#define GUARD_FIELD_GROUND_EFFECT_H
bool8 IsZCoordMismatchAt(u8 z, s16 x, s16 y);
bool8 AreZCoordsCompatible(u8 z1, u8 z2);
+void FieldObjectUpdateMetatileBehaviors(struct MapObject *);
+void GetGroundEffectFlags_Reflection(struct MapObject *, u32 *);
+void GetGroundEffectFlags_TallGrassOnSpawn(struct MapObject *, u32 *);
+void GetGroundEffectFlags_TallGrassOnBeginStep(struct MapObject *, u32 *);
+void GetGroundEffectFlags_LongGrassOnSpawn(struct MapObject *, u32 *);
+void GetGroundEffectFlags_LongGrassOnBeginStep(struct MapObject *, u32 *);
+void GetGroundEffectFlags_Tracks(struct MapObject *, u32 *);
+void GetGroundEffectFlags_SandPile(struct MapObject *, u32 *);
+void GetGroundEffectFlags_ShallowFlowingWater(struct MapObject *, u32 *);
+void GetGroundEffectFlags_Puddle(struct MapObject *, u32 *);
+void GetGroundEffectFlags_Ripple(struct MapObject *, u32 *);
+void GetGroundEffectFlags_ShortGrass(struct MapObject *, u32 *);
+void GetGroundEffectFlags_HotSprings(struct MapObject *, u32 *);
+void GetGroundEffectFlags_Seaweed(struct MapObject *, u32 *);
+void GetGroundEffectFlags_JumpLanding(struct MapObject *, u32 *);
+u8 FieldObjectCheckForReflectiveSurface(struct MapObject *);
+u8 GetLedgeJumpDirection(s16, s16, u8);
+u8 ZCoordToPriority(u8);
+void FieldObjectUpdateZCoord(struct MapObject *pObject);
+void SetObjectSubpriorityByZCoord(u8, struct Sprite *, u8);
-#endif //POKERUBY_FIELD_GROUND_EFFECT_H
+#endif // GUARD_FIELD_GROUND_EFFECT_H
diff --git a/include/field_map_obj.h b/include/field_map_obj.h
index 0347b90d4..e4999dee6 100644
--- a/include/field_map_obj.h
+++ b/include/field_map_obj.h
@@ -92,4 +92,110 @@ extern u16 gUnknown_0300489C;
extern u32 gUnknown_0202FF84[];
int state_to_direction(u8, u8, u8);
+
+void sub_805AA98();
+void sub_805AAB0(void);
+u8 sub_805AB54(void);
+u8 GetFieldObjectIdByLocalIdAndMap(u8, u8, u8);
+bool8 TryGetFieldObjectIdByLocalIdAndMap(u8, u8, u8, u8 *);
+u8 GetFieldObjectIdByXY(s16, s16);
+u8 GetFieldObjectIdByLocalIdAndMapInternal(u8, u8, u8);
+u8 GetFieldObjectIdByLocalId(u8);
+u8 GetAvailableFieldObjectSlot(u16, u8, u8, u8 *);
+void RemoveFieldObjectByLocalIdAndMap(u8, u8, u8);
+void RemoveFieldObjectInternal(struct MapObject *);
+u8 SpawnSpecialFieldObject(struct MapObjectTemplate *);
+u8 show_sprite(u8, u8, u8);
+void MakeObjectTemplateFromFieldObjectTemplate(struct MapObjectTemplate *mapObjTemplate, struct SpriteTemplate *sprTemplate, struct SubspriteTable **subspriteTables);
+u8 AddPseudoFieldObject(u16 graphicsId, void (*callback)(struct Sprite *), s16 c, s16 d, u8 subpriority);
+u8 sub_805B410(u8, u8, s16, s16, u8, u8);
+void sub_805B55C(s16 a, s16 b);
+void sub_805B710(u16 i, u16 i1);
+void sub_805B980(struct MapObject *, u8);
+void FieldObjectTurn(struct MapObject *, u8);
+void FieldObjectTurnByLocalIdAndMap(u8, u8, u8, u8);
+const struct MapObjectGraphicsInfo *GetFieldObjectGraphicsInfo(u8);
+void FieldObjectHandleDynamicGraphicsId(struct MapObject *);
+void npc_by_local_id_and_map_set_field_1_bit_x20(u8, u8, u8, u8);
+void FieldObjectGetLocalIdAndMap(struct MapObject *, u8 *, u8 *, u8 *);
+void sub_805BCC0(s16 x, s16 y);
+void sub_805BCF0(u8, u8, u8, u8);
+void sub_805BD48(u8, u8, u8);
+void sub_805BD90(u8 localId, u8 mapNum, u8 mapGroup, s16 x, s16 y);
+void gpu_pal_allocator_reset__manage_upper_four(void);
+void sub_805BDF8(u16);
+u8 sub_805BE58(const struct SpritePalette *);
+void pal_patch_for_npc(u16, u16);
+u8 FindFieldObjectPaletteIndexByTag(u16);
+void npc_load_two_palettes__no_record(u16, u8);
+void npc_load_two_palettes__and_record(u16, u8);
+void npc_coords_shift(struct MapObject *pObject, s16 x, s16 y);
+void sub_805C0F8(u8, u8, u8, s16, s16);
+void npc_coords_shift_still(struct MapObject *pObject);
+u8 GetFieldObjectIdByXYZ(u16, u16, u8);
+void UpdateFieldObjectsForCameraUpdate(s16, s16);
+u8 AddCameraObject(u8);
+void CameraObjectReset1(void);
+u8 * GetFieldObjectScriptPointerByFieldObjectId(u8);
+u16 GetFieldObjectFlagIdByFieldObjectId(u8);
+u8 FieldObjectGetBerryTreeId(u8);
+struct MapObjectTemplate *GetFieldObjectTemplateByLocalIdAndMap(u8, u8, u8);
+void sub_805C754(struct MapObject *pObject);
+void sub_805C774(struct MapObject *, u8);
+void sub_805C78C(u8, u8, u8);
+void sub_805C7C4(u8 i);
+u8 FieldObjectDirectionToImageAnimId(u8);
+u8 get_go_image_anim_num(u8 unk_19);
+u8 sub_805FD98(u8);
+u8 sub_805FDE8(u8);
+u8 sub_805FDF8(u8);
+u8 sub_805FE08(u8);
+void npc_set_running_behaviour_etc(struct MapObject *, u8);
+u8 npc_running_behaviour_by_direction(u8);
+u8 npc_block_way(struct MapObject *, s16, s16, u8);
+u8 sub_8060024(struct MapObject *, s16, s16, u8);
+u8 sub_8060234(u8, u8, u8);
+void sub_8060288(u8, u8, u8);
+void sub_8060388(s16, s16, s16 *, s16 *);
+void sub_80603CC(s16 x, s16 y, s16 *pInt, s16 *pInt1);
+void GetFieldObjectMovingCameraOffset(s16 *, s16 *);
+void FieldObjectMoveDestCoords(struct MapObject *pObject, u8 unk_19, s16 *pInt, s16 *pInt1);
+bool8 FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(struct MapObject *);
+bool8 FieldObjectIsSpecialAnimActive(struct MapObject *);
+bool8 FieldObjectSetSpecialAnim(struct MapObject *, u8);
+void FieldObjectForceSetSpecialAnim(struct MapObject *pObject, u8 a);
+void FieldObjectClearAnimIfSpecialAnimActive(struct MapObject *);
+void FieldObjectClearAnim(struct MapObject *);
+bool8 FieldObjectCheckIfSpecialAnimFinishedOrInactive(struct MapObject *);
+u8 FieldObjectClearAnimIfSpecialAnimFinished(struct MapObject *);
+u8 FieldObjectGetSpecialAnim(struct MapObject *);
+u8 GetFaceDirectionAnimId(u8);
+u8 GetSimpleGoAnimId(u8);
+u8 GetGoSpeed0AnimId(u8 a);
+u8 sub_8060744(u8 a);
+u8 d2s_08064034(u8 a);
+u8 sub_806079C(u8 a);
+u8 sub_80607F4(u8 a);
+u8 GetJumpLedgeAnimId(u8 a);
+u8 sub_806084C(u8);
+u8 sub_8060878(u8);
+u8 sub_80608D0(u8);
+u8 GetStepInPlaceDelay32AnimId(u8 a);
+u8 GetStepInPlaceDelay16AnimId(u8);
+u8 GetStepInPlaceDelay8AnimId(u8 a);
+u8 GetStepInPlaceDelay4AnimId(u8 a);
+u8 FieldObjectFaceOppositeDirection(struct MapObject *, u8);
+u8 sub_80609D8(u8);
+u8 sub_8060A04(u8);
+u8 sub_8060A30(u8);
+u8 sub_8060A5C(u8);
+u8 sub_8060A88(u8);
+u8 sub_8060AB4(u8);
+u8 sub_8060AE0(u8);
+u8 sub_8060B0C(u8);
+u8 sub_8060B38(u8);
+u8 sub_8060B64(u8);
+u8 GetOppositeDirection(u8);
+void sub_80634D0(struct MapObject *, struct Sprite *);
+
#endif // GUARD_FIELD_MAP_OBJ_H
diff --git a/include/field_map_obj_helpers.h b/include/field_map_obj_helpers.h
index 5dceec595..fd29a9a7f 100644
--- a/include/field_map_obj_helpers.h
+++ b/include/field_map_obj_helpers.h
@@ -1,6 +1,8 @@
#ifndef GUARD_FIELDMAPOBJHELP_H
#define GUARD_FIELDMAPOBJHELP_H
+#include "sprite.h"
+
bool8 FreezeMapObject(struct MapObject *);
void FreezeMapObjects(void);
void FreezeMapObjectsExceptOne(u8);
diff --git a/include/field_player_avatar.h b/include/field_player_avatar.h
index fc21c4e3c..86b1af3fb 100644
--- a/include/field_player_avatar.h
+++ b/include/field_player_avatar.h
@@ -1,37 +1,39 @@
#ifndef GUARD_FIELD_PLAYER_AVATAR_H
#define GUARD_FIELD_PLAYER_AVATAR_H
+#include "task.h"
+
// sub_80587B4
void player_step(u8 a, u16 b, u16 c);
-// ForcedMovement_None
-// ForcedMovement_Slip
-// sub_8058AAC
-// sub_8058AC4
-// sub_8058ADC
-// sub_8058AF4
-// sub_8058B0C
-// sub_8058B24
-// sub_8058B3C
-// sub_8058B54
-// ForcedMovement_SlideSouth
-// ForcedMovement_SlideNorth
-// ForcedMovement_SlideWest
-// ForcedMovement_SlideEast
-// sub_8058C04
-// sub_8058C10
-// ForcedMovement_MuddySlope
-// PlayerNotOnBikeNotMoving
-// PlayerNotOnBikeTurningInPlace
-// sub_8058D0C
+u8 ForcedMovement_None(void);
+u8 ForcedMovement_Slip(void);
+u8 sub_8058AAC(void);
+u8 sub_8058AC4(void);
+u8 sub_8058ADC(void);
+u8 sub_8058AF4(void);
+u8 sub_8058B0C(void);
+u8 sub_8058B24(void);
+u8 sub_8058B3C(void);
+u8 sub_8058B54(void);
+u8 ForcedMovement_SlideSouth(void);
+u8 ForcedMovement_SlideNorth(void);
+u8 ForcedMovement_SlideWest(void);
+u8 ForcedMovement_SlideEast(void);
+u8 sub_8058C04(void);
+u8 sub_8058C10(void);
+u8 ForcedMovement_MuddySlope(void);
+void PlayerNotOnBikeNotMoving(u8 direction, u16 heldKeys);
+void PlayerNotOnBikeTurningInPlace(u8 direction, u16 heldKeys);
+void sub_8058D0C(u8 direction, u16 heldKeys);
u8 CheckForFieldObjectCollision(struct MapObject *a, s16 b, s16 c, u8 d, u8 e);
void SetPlayerAvatarTransitionFlags(u16 a);
-// nullsub_49
-// PlayerAvatarTransition_Normal
-// PlayerAvatarTransition_MachBike
-// PlayerAvatarTransition_AcroBike
-// PlayerAvatarTransition_Surfing
-// PlayerAvatarTransition_Underwater
-// sub_80591F4
+void nullsub_49(struct MapObject *a);
+void PlayerAvatarTransition_Normal(struct MapObject *a);
+void PlayerAvatarTransition_MachBike(struct MapObject *a);
+void PlayerAvatarTransition_AcroBike(struct MapObject *a);
+void PlayerAvatarTransition_Surfing(struct MapObject *a);
+void PlayerAvatarTransition_Underwater(struct MapObject *a);
+void sub_80591F4(struct MapObject *a);
void sub_8059204(void);
u8 player_get_x22(void);
void PlayerSetAnimId(u8 a, u8 b);
@@ -72,41 +74,41 @@ u8 GetPlayerAvatarGenderByGraphicsId(u8 gfxId);
bool8 PartyHasMonWithSurf(void);
bool8 IsPlayerSurfingNorth(void);
bool8 IsPlayerFacingSurfableFishableWater(void);
-// ClearPlayerAvatarInfo
+void ClearPlayerAvatarInfo(void);
void SetPlayerAvatarStateMask(u8 a);
u8 GetPlayerAvatarGraphicsIdByCurrentState(void);
void SetPlayerAvatarExtraStateTransition(u8 a, u8 b);
void InitPlayerAvatar(s16 a, s16 b, u8 c, u8 d);
-// sub_8059B88
+void sub_8059B88(u8);
void sub_8059BF4(void);
// sub_8059C3C
void sub_8059C94(u8);
// sub_8059D08
-// sub_8059E84
-// sub_8059EA4
-// sub_8059F40
-// sub_805A000
-// sub_805A0D8
-// sub_805A100
-// sub_805A178
-// sub_805A1B8
+u8 sub_8059E84(struct Task *task, struct MapObject *b, struct MapObject *c);
+u8 sub_8059EA4(struct Task *task, struct MapObject *b, struct MapObject *c);
+u8 sub_8059F40(struct Task *task, struct MapObject *b, struct MapObject *c);
+u8 sub_805A000(struct Task *task, struct MapObject *mapObject);
+u8 sub_805A0D8(struct Task *task, struct MapObject *mapObject);
+u8 sub_805A100(struct Task *task, struct MapObject *mapObject);
+u8 sub_805A178(struct Task *task, struct MapObject *mapObject);
+u8 sub_805A1B8(struct Task *task, struct MapObject *mapObject);
void sub_805A20C(u8 a);
void StartFishing(u8 a);
-// Fishing1
-// Fishing2
-// Fishing3
-// Fishing4
-// Fishing5
-// Fishing6
-// Fishing7
-// Fishing8
-// Fishing9
-// Fishing10
-// Fishing11
-// Fishing12
-// Fishing13
-// Fishing14
-// Fishing15
-// Fishing16
+u8 Fishing1(struct Task *task);
+u8 Fishing2(struct Task *task);
+u8 Fishing3(struct Task *task);
+u8 Fishing4(struct Task *task);
+u8 Fishing5(struct Task *task);
+u8 Fishing6(struct Task *task);
+u8 Fishing7(struct Task *task);
+u8 Fishing8(struct Task *task);
+u8 Fishing9(struct Task *task);
+u8 Fishing10(struct Task *task);
+u8 Fishing11(struct Task *task);
+u8 Fishing12(struct Task *task);
+u8 Fishing13(struct Task *task);
+u8 Fishing14(struct Task *task);
+u8 Fishing15(struct Task *task);
+u8 Fishing16(struct Task *task);
#endif
diff --git a/include/field_poison.h b/include/field_poison.h
new file mode 100644
index 000000000..8e8e2746f
--- /dev/null
+++ b/include/field_poison.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_FIELD_POISON_H
+#define GUARD_FIELD_POISON_H
+
+s32 overworld_poison(void);
+
+#endif // GUARD_FIELD_POISON_H
diff --git a/include/field_region_map.h b/include/field_region_map.h
new file mode 100644
index 000000000..93b8c6d68
--- /dev/null
+++ b/include/field_region_map.h
@@ -0,0 +1,10 @@
+#ifndef GUARD_FIELD_REGION_MAP_H
+#define GUARD_FIELD_REGION_MAP_H
+
+void CB2_FieldInitRegionMap(void);
+void VBlankCB_FieldRegionMap(void);
+void CB2_FieldRegionMap(void);
+void sub_813EFDC(void);
+void sub_813F0C8(void);
+
+#endif // GUARD_FIELD_REGION_MAP_H
diff --git a/include/field_screen_effect.h b/include/field_screen_effect.h
new file mode 100644
index 000000000..d86109282
--- /dev/null
+++ b/include/field_screen_effect.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_FIELD_SCREEN_EFFECT_H
+#define GUARD_FIELD_SCREEN_EFFECT_H
+
+void sub_8081594(u8);
+void sub_80815E0(u8 val);
+
+#endif // GUARD_FIELD_SCREEN_EFFECT_H
diff --git a/include/field_specials.h b/include/field_specials.h
new file mode 100644
index 000000000..d0eb12065
--- /dev/null
+++ b/include/field_specials.h
@@ -0,0 +1,13 @@
+#ifndef GUARD_FIELD_SPECIALS_H
+#define GUARD_FIELD_SPECIALS_H
+
+void ResetCyclingRoadChallengeData(void);
+bool32 CountSSTidalStep(u16);
+u8 GetSSTidalLocation(s8 *, s8 *, s16 *, s16 *);
+void ScriptAddElevatorMenuItem(u8, u8, u8, u8);
+void ScriptShowElevatorMenu(void);
+void SetShoalItemFlag(u16);
+u8 GetLeadMonIndex(void);
+void ResetFanClub(void);
+
+#endif // GUARD_FIELD_SPECIALS_H
diff --git a/include/field_tasks.h b/include/field_tasks.h
new file mode 100644
index 000000000..53e704395
--- /dev/null
+++ b/include/field_tasks.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_FIELD_TASKS_H
+#define GUARD_FIELD_TASKS_H
+
+void SetUpFieldTasks();
+void ActivatePerStepCallback(u8);
+void ResetFieldTasksArgs(void);
+
+#endif // GUARD_FIELD_TASKS_H
diff --git a/include/field_weather.h b/include/field_weather.h
index af07c970d..409f76028 100644
--- a/include/field_weather.h
+++ b/include/field_weather.h
@@ -31,6 +31,8 @@ void sub_807D874(u8);
// ...
void sub_807DB64(u8, u8);
// ...
+void sub_807DE68(void);
+// ...
void PlayRainSoundEffect(void);
// ...
void SetSav1Weather(u32);
@@ -40,4 +42,9 @@ void sub_80806E4(void);
void DoCurrentWeather(void);
void sub_8080750();
+u8 sub_807D770(void);
+bool8 sub_807DDFC(void);
+void SetWeather(u32);
+void UpdateWeatherPerDay(u16);
+
#endif // GUARD_WEATHER_H
diff --git a/include/fieldmap.h b/include/fieldmap.h
index d08627ddc..67b85fa62 100644
--- a/include/fieldmap.h
+++ b/include/fieldmap.h
@@ -10,4 +10,36 @@ int CanCameraMoveInDirection(int direction);
u32 GetBehaviorByMetatileId(u16 metatile);
void MapGridSetMetatileEntryAt(int, int, u16);
+void not_trainer_hill_battle_pyramid(void);
+void sub_8055FC0(void);
+void mapheader_copy_mapdata_with_padding(struct MapHeader *mapHeader);
+void map_copy_with_padding(u16 *map, u16 width, u16 height);
+void sub_80560AC(struct MapHeader *);
+void fillSouthConnection(struct MapHeader *, struct MapHeader *, s32);
+void fillNorthConnection(struct MapHeader *, struct MapHeader *, s32);
+void fillWestConnection(struct MapHeader *, struct MapHeader *, s32);
+void fillEastConnection(struct MapHeader *, struct MapHeader *, s32);
+u8 MapGridGetZCoordAt(int s, int y);
+u8 MapGridIsImpassableAt(int, int);
+u32 MapGridGetMetatileIdAt(int, int);
+u32 MapGridGetMetatileBehaviorAt(int x, int y); // return: (u8|u16|int) args: (int|s16|s32)
+u8 MapGridGetMetatileLayerTypeAt(int, int);
+void MapGridSetMetatileIdAt(int, int, u16);
+u32 GetBehaviorByMetatileId(u16 metatile);
+void save_serialize_map(void);
+void sub_8056670();
+bool8 CameraMove(int, int);
+struct MapConnection *sub_8056A64(u8 direction, int x, int y);
+bool8 sub_8056ABC(u8 direction, int x, int y, struct MapConnection *connection);
+bool8 sub_8056B20(int x, int src_width, int dest_width, int offset);
+struct MapConnection *sub_8056BA0(s16 x, s16 y); // fieldmap.c
+void sub_8056C50(u16, u16);
+void sav1_camera_get_focus_coords(u16 *x, u16 *y);
+void GetCameraCoords(u16*, u16*);
+void sub_8056D28(struct MapData *pData);
+void sub_8056D38(struct MapData *pData);
+void apply_map_tileset2_palette(struct MapData *pData);
+void copy_map_tileset1_tileset2_to_vram(/*TODO: arg types*/);
+void apply_map_tileset1_tileset2_palette(/*TODO: arg types*/);
+
#endif
diff --git a/include/fldeff_80C5CD4.h b/include/fldeff_80C5CD4.h
new file mode 100644
index 000000000..413e8ad96
--- /dev/null
+++ b/include/fldeff_80C5CD4.h
@@ -0,0 +1,9 @@
+#ifndef GUARD_FLDEFF_80C5CD4_H
+#define GUARD_FLDEFF_80C5CD4_H
+
+void DoFieldPoisonEffect(void);
+bool32 FieldPoisonEffectIsRunning(void);
+void CreateRecordMixingSprite(void);
+void DestroyRecordMixingSprite(void);
+
+#endif // GUARD_FLDEFF_80C5CD4_H
diff --git a/include/fldeff_cut.h b/include/fldeff_cut.h
new file mode 100644
index 000000000..0a5261468
--- /dev/null
+++ b/include/fldeff_cut.h
@@ -0,0 +1,13 @@
+#ifndef GUARD_FLDEFF_CUT_H
+#define GUARD_FLDEFF_CUT_H
+
+void sub_80A25E8(void);
+void sub_80A2634(void);
+void sub_80A2684(void);
+void sub_80A27A8(s16, s16);
+void sub_80A28F4(s16, s16);
+void objc_8097BBC(struct Sprite *sprite);
+void sub_80A2AB8(void);
+void sub_80A2B00(void); // unknown args
+
+#endif // GUARD_FLDEFF_CUT_H
diff --git a/include/fldeff_flash.h b/include/fldeff_flash.h
new file mode 100644
index 000000000..546a7f5dc
--- /dev/null
+++ b/include/fldeff_flash.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_FLDEFF_FLASH_H
+#define GUARD_FLDEFF_FLASH_H
+
+void sub_810CC80(void);
+u8 sub_810CDB8(u8, u8);
+u8 fade_type_for_given_maplight_pair(u8, u8);
+
+#endif // GUARD_FLDEFF_FLASH_H
diff --git a/include/fldeff_softboiled.h b/include/fldeff_softboiled.h
new file mode 100644
index 000000000..97c65be08
--- /dev/null
+++ b/include/fldeff_softboiled.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_FLDEFF_SOFTBOILED_H
+#define GUARD_FLDEFF_SOFTBOILED_H
+
+bool8 SetUpFieldMove_SoftBoiled(void);
+void sub_8133D28(u8 taskid);
+
+#endif // GUARD_FLDEFF_SOFTBOILED_H
diff --git a/include/fldeff_teleport.h b/include/fldeff_teleport.h
new file mode 100644
index 000000000..e447f5132
--- /dev/null
+++ b/include/fldeff_teleport.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_FLDEFF_TELEPORT_H
+#define GUARD_FLDEFF_TELEPORT_H
+
+void hm_teleport_run_dp02scr(void);
+void sub_814A404(void);
+
+#endif // GUARD_FLDEFF_TELEPORT_H
diff --git a/include/gba/defines.h b/include/gba/defines.h
index 0f7f06755..0f7f06755 100644..100755
--- a/include/gba/defines.h
+++ b/include/gba/defines.h
diff --git a/include/gba/types.h b/include/gba/types.h
index fd8a20a4c..96e057ab7 100644
--- a/include/gba/types.h
+++ b/include/gba/types.h
@@ -34,7 +34,7 @@ struct PlttData
u16 g:5; // green
u16 b:5; // blue
u16 unused_15:1;
-};
+} /*__attribute__((packed))*/;
struct OamData
{
diff --git a/include/global.h b/include/global.h
index c4c78e65d..9da4bd57c 100644..100755
--- a/include/global.h
+++ b/include/global.h
@@ -4,17 +4,45 @@
#include "gba/gba.h"
#include "config.h"
+// IDE support
+#ifdef __APPLE__
+#define _(x) x
+#define __(x) x
+#define INCBIN_U8 {0}
+#define INCBIN_U16 {0}
+#define INCBIN_U32 {0}
+#define INCBIN_S8 {0}
+#define INCBIN_S16 {0}
+#define INCBIN_S32 {0}
+void * memcpy (void *, const void *, size_t);
+void * memset (void *, int, size_t);
+int strcmp (const char *, const char *);
+#endif
+
// Prevent cross-jump optimization.
#define BLOCK_CROSS_JUMP asm("");
// to help in decompiling
#define asm_comment(x) asm volatile("@ -- " x " -- ")
+#define asm_unified(x) asm(".syntax unified\n" x "\n.syntax divided\n")
+
+#define nonmatching(fndec, x) {\
+__attribute__((naked))\
+fndec\
+{\
+ asm_unified(x);\
+}\
+}
+
#define ARRAY_COUNT(array) (sizeof(array) / sizeof((array)[0]))
#define POKEMON_NAME_LENGTH 10
#define OT_NAME_LENGTH 7
+#define min(a, b) (a >= b ? a : b)
+#define max(a, b) (a <= b ? a : b)
+
enum
{
VERSION_SAPPHIRE = 1,
@@ -472,10 +500,16 @@ struct GabbyAndTyData {
/*2b1b*/ u8 valB_5:3;
};
-struct RecordMixing_UnknownStruct {
+struct RecordMixing_UnknownStructSub {
u8 data[0x38];
};
+struct RecordMixing_UnknownStruct {
+ struct RecordMixing_UnknownStructSub data[2];
+ u32 unk70;
+ u16 unk74[0x2];
+};
+
struct SaveBlock1 /* 0x02025734 */
{
/*0x00*/ struct Coords16 pos;
@@ -551,8 +585,8 @@ struct SaveBlock1 /* 0x02025734 */
/*0x2DFC*/ u8 filler_2DFC[0x8];
/*0x2E04*/ SB_Struct sbStruct;
/*0x2F9C*/ struct BoxPokemon daycareData[2];
- /*0x303C*/ struct RecordMixing_UnknownStruct filler_303C[2];
- /*0x30AC*/ u8 filler_30AC[0xA];
+ /*0x303C*/ struct RecordMixing_UnknownStruct filler_303C;
+ /*0x30AC*/ u8 filler_30B4[0x2];
/*0x30B6*/ u8 filler_30B6;
/*0x30B7*/ u8 filler_30B7[1];
/*0x30B8*/ u8 linkBattleRecords[5][16];
diff --git a/include/graphics.h b/include/graphics.h
new file mode 100644
index 000000000..096a1982c
--- /dev/null
+++ b/include/graphics.h
@@ -0,0 +1,2412 @@
+#ifndef GUARD_GRAPHICS_H
+#define GUARD_GRAPHICS_H
+
+// data/graphics.s
+extern const u8 gMonFootprint_QuestionMark[];
+
+// data/graphics/pokemon/graphics.inc
+extern const u8 gMonFrontPic_Bulbasaur[];
+extern const u8 gMonPalette_Bulbasaur[];
+extern const u8 gMonBackPic_Bulbasaur[];
+extern const u8 gMonShinyPalette_Bulbasaur[];
+extern const u8 gMonIcon_Bulbasaur[];
+extern const u8 gMonFootprint_Bulbasaur[];
+extern const u8 gMonFrontPic_Ivysaur[];
+extern const u8 gMonPalette_Ivysaur[];
+extern const u8 gMonBackPic_Ivysaur[];
+extern const u8 gMonShinyPalette_Ivysaur[];
+extern const u8 gMonIcon_Ivysaur[];
+extern const u8 gMonFootprint_Ivysaur[];
+extern const u8 gMonFrontPic_Venusaur[];
+extern const u8 gMonPalette_Venusaur[];
+extern const u8 gMonBackPic_Venusaur[];
+extern const u8 gMonShinyPalette_Venusaur[];
+extern const u8 gMonIcon_Venusaur[];
+extern const u8 gMonFootprint_Venusaur[];
+extern const u8 gMonFrontPic_Charmander[];
+extern const u8 gMonPalette_Charmander[];
+extern const u8 gMonBackPic_Charmander[];
+extern const u8 gMonShinyPalette_Charmander[];
+extern const u8 gMonIcon_Charmander[];
+extern const u8 gMonFootprint_Charmander[];
+extern const u8 gMonFrontPic_Charmeleon[];
+extern const u8 gMonPalette_Charmeleon[];
+extern const u8 gMonBackPic_Charmeleon[];
+extern const u8 gMonShinyPalette_Charmeleon[];
+extern const u8 gMonIcon_Charmeleon[];
+extern const u8 gMonFootprint_Charmeleon[];
+extern const u8 gMonFrontPic_Charizard[];
+extern const u8 gMonPalette_Charizard[];
+extern const u8 gMonBackPic_Charizard[];
+extern const u8 gMonShinyPalette_Charizard[];
+extern const u8 gMonIcon_Charizard[];
+extern const u8 gMonFootprint_Charizard[];
+extern const u8 gMonFrontPic_Squirtle[];
+extern const u8 gMonPalette_Squirtle[];
+extern const u8 gMonBackPic_Squirtle[];
+extern const u8 gMonShinyPalette_Squirtle[];
+extern const u8 gMonIcon_Squirtle[];
+extern const u8 gMonFootprint_Squirtle[];
+extern const u8 gMonFrontPic_Wartortle[];
+extern const u8 gMonPalette_Wartortle[];
+extern const u8 gMonBackPic_Wartortle[];
+extern const u8 gMonShinyPalette_Wartortle[];
+extern const u8 gMonIcon_Wartortle[];
+extern const u8 gMonFootprint_Wartortle[];
+extern const u8 gMonFrontPic_Blastoise[];
+extern const u8 gMonPalette_Blastoise[];
+extern const u8 gMonBackPic_Blastoise[];
+extern const u8 gMonShinyPalette_Blastoise[];
+extern const u8 gMonIcon_Blastoise[];
+extern const u8 gMonFootprint_Blastoise[];
+extern const u8 gMonFrontPic_Caterpie[];
+extern const u8 gMonPalette_Caterpie[];
+extern const u8 gMonBackPic_Caterpie[];
+extern const u8 gMonShinyPalette_Caterpie[];
+extern const u8 gMonIcon_Caterpie[];
+extern const u8 gMonFootprint_Caterpie[];
+extern const u8 gMonFrontPic_Metapod[];
+extern const u8 gMonPalette_Metapod[];
+extern const u8 gMonBackPic_Metapod[];
+extern const u8 gMonShinyPalette_Metapod[];
+extern const u8 gMonIcon_Metapod[];
+extern const u8 gMonFootprint_Metapod[];
+extern const u8 gMonFrontPic_Butterfree[];
+extern const u8 gMonPalette_Butterfree[];
+extern const u8 gMonBackPic_Butterfree[];
+extern const u8 gMonShinyPalette_Butterfree[];
+extern const u8 gMonIcon_Butterfree[];
+extern const u8 gMonFootprint_Butterfree[];
+extern const u8 gMonFrontPic_Weedle[];
+extern const u8 gMonPalette_Weedle[];
+extern const u8 gMonBackPic_Weedle[];
+extern const u8 gMonShinyPalette_Weedle[];
+extern const u8 gMonIcon_Weedle[];
+extern const u8 gMonFootprint_Weedle[];
+extern const u8 gMonFrontPic_Kakuna[];
+extern const u8 gMonPalette_Kakuna[];
+extern const u8 gMonBackPic_Kakuna[];
+extern const u8 gMonShinyPalette_Kakuna[];
+extern const u8 gMonIcon_Kakuna[];
+extern const u8 gMonFootprint_Kakuna[];
+extern const u8 gMonFrontPic_Beedrill[];
+extern const u8 gMonPalette_Beedrill[];
+extern const u8 gMonBackPic_Beedrill[];
+extern const u8 gMonShinyPalette_Beedrill[];
+extern const u8 gMonIcon_Beedrill[];
+extern const u8 gMonFootprint_Beedrill[];
+extern const u8 gMonFrontPic_Pidgey[];
+extern const u8 gMonPalette_Pidgey[];
+extern const u8 gMonBackPic_Pidgey[];
+extern const u8 gMonShinyPalette_Pidgey[];
+extern const u8 gMonIcon_Pidgey[];
+extern const u8 gMonFootprint_Pidgey[];
+extern const u8 gMonFrontPic_Pidgeotto[];
+extern const u8 gMonPalette_Pidgeotto[];
+extern const u8 gMonBackPic_Pidgeotto[];
+extern const u8 gMonShinyPalette_Pidgeotto[];
+extern const u8 gMonIcon_Pidgeotto[];
+extern const u8 gMonFootprint_Pidgeotto[];
+extern const u8 gMonFrontPic_Pidgeot[];
+extern const u8 gMonPalette_Pidgeot[];
+extern const u8 gMonBackPic_Pidgeot[];
+extern const u8 gMonShinyPalette_Pidgeot[];
+extern const u8 gMonIcon_Pidgeot[];
+extern const u8 gMonFootprint_Pidgeot[];
+extern const u8 gMonFrontPic_Rattata[];
+extern const u8 gMonPalette_Rattata[];
+extern const u8 gMonBackPic_Rattata[];
+extern const u8 gMonShinyPalette_Rattata[];
+extern const u8 gMonIcon_Rattata[];
+extern const u8 gMonFootprint_Rattata[];
+extern const u8 gMonFrontPic_Raticate[];
+extern const u8 gMonPalette_Raticate[];
+extern const u8 gMonBackPic_Raticate[];
+extern const u8 gMonShinyPalette_Raticate[];
+extern const u8 gMonIcon_Raticate[];
+extern const u8 gMonFootprint_Raticate[];
+extern const u8 gMonFrontPic_Spearow[];
+extern const u8 gMonPalette_Spearow[];
+extern const u8 gMonBackPic_Spearow[];
+extern const u8 gMonShinyPalette_Spearow[];
+extern const u8 gMonIcon_Spearow[];
+extern const u8 gMonFootprint_Spearow[];
+extern const u8 gMonFrontPic_Fearow[];
+extern const u8 gMonPalette_Fearow[];
+extern const u8 gMonBackPic_Fearow[];
+extern const u8 gMonShinyPalette_Fearow[];
+extern const u8 gMonIcon_Fearow[];
+extern const u8 gMonFootprint_Fearow[];
+extern const u8 gMonFrontPic_Ekans[];
+extern const u8 gMonPalette_Ekans[];
+extern const u8 gMonBackPic_Ekans[];
+extern const u8 gMonShinyPalette_Ekans[];
+extern const u8 gMonIcon_Ekans[];
+extern const u8 gMonFootprint_Ekans[];
+extern const u8 gMonFrontPic_Arbok[];
+extern const u8 gMonPalette_Arbok[];
+extern const u8 gMonBackPic_Arbok[];
+extern const u8 gMonShinyPalette_Arbok[];
+extern const u8 gMonIcon_Arbok[];
+extern const u8 gMonFootprint_Arbok[];
+extern const u8 gMonFrontPic_Pikachu[];
+extern const u8 gMonPalette_Pikachu[];
+extern const u8 gMonBackPic_Pikachu[];
+extern const u8 gMonShinyPalette_Pikachu[];
+extern const u8 gMonIcon_Pikachu[];
+extern const u8 gMonFootprint_Pikachu[];
+extern const u8 gMonFrontPic_Raichu[];
+extern const u8 gMonPalette_Raichu[];
+extern const u8 gMonBackPic_Raichu[];
+extern const u8 gMonShinyPalette_Raichu[];
+extern const u8 gMonIcon_Raichu[];
+extern const u8 gMonFootprint_Raichu[];
+extern const u8 gMonFrontPic_Sandshrew[];
+extern const u8 gMonPalette_Sandshrew[];
+extern const u8 gMonBackPic_Sandshrew[];
+extern const u8 gMonShinyPalette_Sandshrew[];
+extern const u8 gMonIcon_Sandshrew[];
+extern const u8 gMonFootprint_Sandshrew[];
+extern const u8 gMonFrontPic_Sandslash[];
+extern const u8 gMonPalette_Sandslash[];
+extern const u8 gMonBackPic_Sandslash[];
+extern const u8 gMonShinyPalette_Sandslash[];
+extern const u8 gMonIcon_Sandslash[];
+extern const u8 gMonFootprint_Sandslash[];
+extern const u8 gMonFrontPic_NidoranF[];
+extern const u8 gMonPalette_NidoranF[];
+extern const u8 gMonBackPic_NidoranF[];
+extern const u8 gMonShinyPalette_NidoranF[];
+extern const u8 gMonIcon_NidoranF[];
+extern const u8 gMonFootprint_NidoranF[];
+extern const u8 gMonFrontPic_Nidorina[];
+extern const u8 gMonPalette_Nidorina[];
+extern const u8 gMonBackPic_Nidorina[];
+extern const u8 gMonShinyPalette_Nidorina[];
+extern const u8 gMonIcon_Nidorina[];
+extern const u8 gMonFootprint_Nidorina[];
+extern const u8 gMonFrontPic_Nidoqueen[];
+extern const u8 gMonPalette_Nidoqueen[];
+extern const u8 gMonBackPic_Nidoqueen[];
+extern const u8 gMonShinyPalette_Nidoqueen[];
+extern const u8 gMonIcon_Nidoqueen[];
+extern const u8 gMonFootprint_Nidoqueen[];
+extern const u8 gMonFrontPic_NidoranM[];
+extern const u8 gMonPalette_NidoranM[];
+extern const u8 gMonBackPic_NidoranM[];
+extern const u8 gMonShinyPalette_NidoranM[];
+extern const u8 gMonIcon_NidoranM[];
+extern const u8 gMonFootprint_NidoranM[];
+extern const u8 gMonFrontPic_Nidorino[];
+extern const u8 gMonPalette_Nidorino[];
+extern const u8 gMonBackPic_Nidorino[];
+extern const u8 gMonShinyPalette_Nidorino[];
+extern const u8 gMonIcon_Nidorino[];
+extern const u8 gMonFootprint_Nidorino[];
+extern const u8 gMonFrontPic_Nidoking[];
+extern const u8 gMonPalette_Nidoking[];
+extern const u8 gMonBackPic_Nidoking[];
+extern const u8 gMonShinyPalette_Nidoking[];
+extern const u8 gMonIcon_Nidoking[];
+extern const u8 gMonFootprint_Nidoking[];
+extern const u8 gMonFrontPic_Clefairy[];
+extern const u8 gMonPalette_Clefairy[];
+extern const u8 gMonBackPic_Clefairy[];
+extern const u8 gMonShinyPalette_Clefairy[];
+extern const u8 gMonIcon_Clefairy[];
+extern const u8 gMonFootprint_Clefairy[];
+extern const u8 gMonFrontPic_Clefable[];
+extern const u8 gMonPalette_Clefable[];
+extern const u8 gMonBackPic_Clefable[];
+extern const u8 gMonShinyPalette_Clefable[];
+extern const u8 gMonIcon_Clefable[];
+extern const u8 gMonFootprint_Clefable[];
+extern const u8 gMonFrontPic_Vulpix[];
+extern const u8 gMonPalette_Vulpix[];
+extern const u8 gMonBackPic_Vulpix[];
+extern const u8 gMonShinyPalette_Vulpix[];
+extern const u8 gMonIcon_Vulpix[];
+extern const u8 gMonFootprint_Vulpix[];
+extern const u8 gMonFrontPic_Ninetales[];
+extern const u8 gMonPalette_Ninetales[];
+extern const u8 gMonBackPic_Ninetales[];
+extern const u8 gMonShinyPalette_Ninetales[];
+extern const u8 gMonIcon_Ninetales[];
+extern const u8 gMonFootprint_Ninetales[];
+extern const u8 gMonFrontPic_Jigglypuff[];
+extern const u8 gMonPalette_Jigglypuff[];
+extern const u8 gMonBackPic_Jigglypuff[];
+extern const u8 gMonShinyPalette_Jigglypuff[];
+extern const u8 gMonIcon_Jigglypuff[];
+extern const u8 gMonFootprint_Jigglypuff[];
+extern const u8 gMonFrontPic_Wigglytuff[];
+extern const u8 gMonPalette_Wigglytuff[];
+extern const u8 gMonBackPic_Wigglytuff[];
+extern const u8 gMonShinyPalette_Wigglytuff[];
+extern const u8 gMonIcon_Wigglytuff[];
+extern const u8 gMonFootprint_Wigglytuff[];
+extern const u8 gMonFrontPic_Zubat[];
+extern const u8 gMonPalette_Zubat[];
+extern const u8 gMonBackPic_Zubat[];
+extern const u8 gMonShinyPalette_Zubat[];
+extern const u8 gMonIcon_Zubat[];
+extern const u8 gMonFootprint_Zubat[];
+extern const u8 gMonFrontPic_Golbat[];
+extern const u8 gMonPalette_Golbat[];
+extern const u8 gMonBackPic_Golbat[];
+extern const u8 gMonShinyPalette_Golbat[];
+extern const u8 gMonIcon_Golbat[];
+extern const u8 gMonFootprint_Golbat[];
+extern const u8 gMonFrontPic_Oddish[];
+extern const u8 gMonPalette_Oddish[];
+extern const u8 gMonBackPic_Oddish[];
+extern const u8 gMonShinyPalette_Oddish[];
+extern const u8 gMonIcon_Oddish[];
+extern const u8 gMonFootprint_Oddish[];
+extern const u8 gMonFrontPic_Gloom[];
+extern const u8 gMonPalette_Gloom[];
+extern const u8 gMonBackPic_Gloom[];
+extern const u8 gMonShinyPalette_Gloom[];
+extern const u8 gMonIcon_Gloom[];
+extern const u8 gMonFootprint_Gloom[];
+extern const u8 gMonFrontPic_Vileplume[];
+extern const u8 gMonPalette_Vileplume[];
+extern const u8 gMonBackPic_Vileplume[];
+extern const u8 gMonShinyPalette_Vileplume[];
+extern const u8 gMonIcon_Vileplume[];
+extern const u8 gMonFootprint_Vileplume[];
+extern const u8 gMonFrontPic_Paras[];
+extern const u8 gMonPalette_Paras[];
+extern const u8 gMonBackPic_Paras[];
+extern const u8 gMonShinyPalette_Paras[];
+extern const u8 gMonIcon_Paras[];
+extern const u8 gMonFootprint_Paras[];
+extern const u8 gMonFrontPic_Parasect[];
+extern const u8 gMonPalette_Parasect[];
+extern const u8 gMonBackPic_Parasect[];
+extern const u8 gMonShinyPalette_Parasect[];
+extern const u8 gMonIcon_Parasect[];
+extern const u8 gMonFootprint_Parasect[];
+extern const u8 gMonFrontPic_Venonat[];
+extern const u8 gMonPalette_Venonat[];
+extern const u8 gMonBackPic_Venonat[];
+extern const u8 gMonShinyPalette_Venonat[];
+extern const u8 gMonIcon_Venonat[];
+extern const u8 gMonFootprint_Venonat[];
+extern const u8 gMonFrontPic_Venomoth[];
+extern const u8 gMonPalette_Venomoth[];
+extern const u8 gMonBackPic_Venomoth[];
+extern const u8 gMonShinyPalette_Venomoth[];
+extern const u8 gMonIcon_Venomoth[];
+extern const u8 gMonFootprint_Venomoth[];
+extern const u8 gMonFrontPic_Diglett[];
+extern const u8 gMonPalette_Diglett[];
+extern const u8 gMonBackPic_Diglett[];
+extern const u8 gMonShinyPalette_Diglett[];
+extern const u8 gMonIcon_Diglett[];
+extern const u8 gMonFootprint_Diglett[];
+extern const u8 gMonFrontPic_Dugtrio[];
+extern const u8 gMonPalette_Dugtrio[];
+extern const u8 gMonBackPic_Dugtrio[];
+extern const u8 gMonShinyPalette_Dugtrio[];
+extern const u8 gMonIcon_Dugtrio[];
+extern const u8 gMonFootprint_Dugtrio[];
+extern const u8 gMonFrontPic_Meowth[];
+extern const u8 gMonPalette_Meowth[];
+extern const u8 gMonBackPic_Meowth[];
+extern const u8 gMonShinyPalette_Meowth[];
+extern const u8 gMonIcon_Meowth[];
+extern const u8 gMonFootprint_Meowth[];
+extern const u8 gMonFrontPic_Persian[];
+extern const u8 gMonPalette_Persian[];
+extern const u8 gMonBackPic_Persian[];
+extern const u8 gMonShinyPalette_Persian[];
+extern const u8 gMonIcon_Persian[];
+extern const u8 gMonFootprint_Persian[];
+extern const u8 gMonFrontPic_Psyduck[];
+extern const u8 gMonPalette_Psyduck[];
+extern const u8 gMonBackPic_Psyduck[];
+extern const u8 gMonShinyPalette_Psyduck[];
+extern const u8 gMonIcon_Psyduck[];
+extern const u8 gMonFootprint_Psyduck[];
+extern const u8 gMonFrontPic_Golduck[];
+extern const u8 gMonPalette_Golduck[];
+extern const u8 gMonBackPic_Golduck[];
+extern const u8 gMonShinyPalette_Golduck[];
+extern const u8 gMonIcon_Golduck[];
+extern const u8 gMonFootprint_Golduck[];
+extern const u8 gMonFrontPic_Mankey[];
+extern const u8 gMonPalette_Mankey[];
+extern const u8 gMonBackPic_Mankey[];
+extern const u8 gMonShinyPalette_Mankey[];
+extern const u8 gMonIcon_Mankey[];
+extern const u8 gMonFootprint_Mankey[];
+extern const u8 gMonFrontPic_Primeape[];
+extern const u8 gMonPalette_Primeape[];
+extern const u8 gMonBackPic_Primeape[];
+extern const u8 gMonShinyPalette_Primeape[];
+extern const u8 gMonIcon_Primeape[];
+extern const u8 gMonFootprint_Primeape[];
+extern const u8 gMonFrontPic_Growlithe[];
+extern const u8 gMonPalette_Growlithe[];
+extern const u8 gMonBackPic_Growlithe[];
+extern const u8 gMonShinyPalette_Growlithe[];
+extern const u8 gMonIcon_Growlithe[];
+extern const u8 gMonFootprint_Growlithe[];
+extern const u8 gMonFrontPic_Arcanine[];
+extern const u8 gMonPalette_Arcanine[];
+extern const u8 gMonBackPic_Arcanine[];
+extern const u8 gMonShinyPalette_Arcanine[];
+extern const u8 gMonIcon_Arcanine[];
+extern const u8 gMonFootprint_Arcanine[];
+extern const u8 gMonFrontPic_Poliwag[];
+extern const u8 gMonPalette_Poliwag[];
+extern const u8 gMonBackPic_Poliwag[];
+extern const u8 gMonShinyPalette_Poliwag[];
+extern const u8 gMonIcon_Poliwag[];
+extern const u8 gMonFootprint_Poliwag[];
+extern const u8 gMonFrontPic_Poliwhirl[];
+extern const u8 gMonPalette_Poliwhirl[];
+extern const u8 gMonBackPic_Poliwhirl[];
+extern const u8 gMonShinyPalette_Poliwhirl[];
+extern const u8 gMonIcon_Poliwhirl[];
+extern const u8 gMonFootprint_Poliwhirl[];
+extern const u8 gMonFrontPic_Poliwrath[];
+extern const u8 gMonPalette_Poliwrath[];
+extern const u8 gMonBackPic_Poliwrath[];
+extern const u8 gMonShinyPalette_Poliwrath[];
+extern const u8 gMonIcon_Poliwrath[];
+extern const u8 gMonFootprint_Poliwrath[];
+extern const u8 gMonFrontPic_Abra[];
+extern const u8 gMonPalette_Abra[];
+extern const u8 gMonBackPic_Abra[];
+extern const u8 gMonShinyPalette_Abra[];
+extern const u8 gMonIcon_Abra[];
+extern const u8 gMonFootprint_Abra[];
+extern const u8 gMonFrontPic_Kadabra[];
+extern const u8 gMonPalette_Kadabra[];
+extern const u8 gMonBackPic_Kadabra[];
+extern const u8 gMonShinyPalette_Kadabra[];
+extern const u8 gMonIcon_Kadabra[];
+extern const u8 gMonFootprint_Kadabra[];
+extern const u8 gMonFrontPic_Alakazam[];
+extern const u8 gMonPalette_Alakazam[];
+extern const u8 gMonBackPic_Alakazam[];
+extern const u8 gMonShinyPalette_Alakazam[];
+extern const u8 gMonIcon_Alakazam[];
+extern const u8 gMonFootprint_Alakazam[];
+extern const u8 gMonFrontPic_Machop[];
+extern const u8 gMonPalette_Machop[];
+extern const u8 gMonBackPic_Machop[];
+extern const u8 gMonShinyPalette_Machop[];
+extern const u8 gMonIcon_Machop[];
+extern const u8 gMonFootprint_Machop[];
+extern const u8 gMonFrontPic_Machoke[];
+extern const u8 gMonPalette_Machoke[];
+extern const u8 gMonBackPic_Machoke[];
+extern const u8 gMonShinyPalette_Machoke[];
+extern const u8 gMonIcon_Machoke[];
+extern const u8 gMonFootprint_Machoke[];
+extern const u8 gMonFrontPic_Machamp[];
+extern const u8 gMonPalette_Machamp[];
+extern const u8 gMonBackPic_Machamp[];
+extern const u8 gMonShinyPalette_Machamp[];
+extern const u8 gMonIcon_Machamp[];
+extern const u8 gMonFootprint_Machamp[];
+extern const u8 gMonFrontPic_Bellsprout[];
+extern const u8 gMonPalette_Bellsprout[];
+extern const u8 gMonBackPic_Bellsprout[];
+extern const u8 gMonShinyPalette_Bellsprout[];
+extern const u8 gMonIcon_Bellsprout[];
+extern const u8 gMonFootprint_Bellsprout[];
+extern const u8 gMonFrontPic_Weepinbell[];
+extern const u8 gMonPalette_Weepinbell[];
+extern const u8 gMonBackPic_Weepinbell[];
+extern const u8 gMonShinyPalette_Weepinbell[];
+extern const u8 gMonIcon_Weepinbell[];
+extern const u8 gMonFootprint_Weepinbell[];
+extern const u8 gMonFrontPic_Victreebel[];
+extern const u8 gMonPalette_Victreebel[];
+extern const u8 gMonBackPic_Victreebel[];
+extern const u8 gMonShinyPalette_Victreebel[];
+extern const u8 gMonIcon_Victreebel[];
+extern const u8 gMonFootprint_Victreebel[];
+extern const u8 gMonFrontPic_Tentacool[];
+extern const u8 gMonPalette_Tentacool[];
+extern const u8 gMonBackPic_Tentacool[];
+extern const u8 gMonShinyPalette_Tentacool[];
+extern const u8 gMonIcon_Tentacool[];
+extern const u8 gMonFootprint_Tentacool[];
+extern const u8 gMonFrontPic_Tentacruel[];
+extern const u8 gMonPalette_Tentacruel[];
+extern const u8 gMonBackPic_Tentacruel[];
+extern const u8 gMonShinyPalette_Tentacruel[];
+extern const u8 gMonIcon_Tentacruel[];
+extern const u8 gMonFootprint_Tentacruel[];
+extern const u8 gMonFrontPic_Geodude[];
+extern const u8 gMonPalette_Geodude[];
+extern const u8 gMonBackPic_Geodude[];
+extern const u8 gMonShinyPalette_Geodude[];
+extern const u8 gMonIcon_Geodude[];
+extern const u8 gMonFootprint_Geodude[];
+extern const u8 gMonFrontPic_Graveler[];
+extern const u8 gMonPalette_Graveler[];
+extern const u8 gMonBackPic_Graveler[];
+extern const u8 gMonShinyPalette_Graveler[];
+extern const u8 gMonIcon_Graveler[];
+extern const u8 gMonFootprint_Graveler[];
+extern const u8 gMonFrontPic_Golem[];
+extern const u8 gMonPalette_Golem[];
+extern const u8 gMonBackPic_Golem[];
+extern const u8 gMonShinyPalette_Golem[];
+extern const u8 gMonIcon_Golem[];
+extern const u8 gMonFootprint_Golem[];
+extern const u8 gMonFrontPic_Ponyta[];
+extern const u8 gMonPalette_Ponyta[];
+extern const u8 gMonBackPic_Ponyta[];
+extern const u8 gMonShinyPalette_Ponyta[];
+extern const u8 gMonIcon_Ponyta[];
+extern const u8 gMonFootprint_Ponyta[];
+extern const u8 gMonFrontPic_Rapidash[];
+extern const u8 gMonPalette_Rapidash[];
+extern const u8 gMonBackPic_Rapidash[];
+extern const u8 gMonShinyPalette_Rapidash[];
+extern const u8 gMonIcon_Rapidash[];
+extern const u8 gMonFootprint_Rapidash[];
+extern const u8 gMonFrontPic_Slowpoke[];
+extern const u8 gMonPalette_Slowpoke[];
+extern const u8 gMonBackPic_Slowpoke[];
+extern const u8 gMonShinyPalette_Slowpoke[];
+extern const u8 gMonIcon_Slowpoke[];
+extern const u8 gMonFootprint_Slowpoke[];
+extern const u8 gMonFrontPic_Slowbro[];
+extern const u8 gMonPalette_Slowbro[];
+extern const u8 gMonBackPic_Slowbro[];
+extern const u8 gMonShinyPalette_Slowbro[];
+extern const u8 gMonIcon_Slowbro[];
+extern const u8 gMonFootprint_Slowbro[];
+extern const u8 gMonFrontPic_Magnemite[];
+extern const u8 gMonPalette_Magnemite[];
+extern const u8 gMonBackPic_Magnemite[];
+extern const u8 gMonShinyPalette_Magnemite[];
+extern const u8 gMonIcon_Magnemite[];
+extern const u8 gMonFootprint_Magnemite[];
+extern const u8 gMonFrontPic_Magneton[];
+extern const u8 gMonPalette_Magneton[];
+extern const u8 gMonBackPic_Magneton[];
+extern const u8 gMonShinyPalette_Magneton[];
+extern const u8 gMonIcon_Magneton[];
+extern const u8 gMonFootprint_Magneton[];
+extern const u8 gMonFrontPic_Farfetchd[];
+extern const u8 gMonPalette_Farfetchd[];
+extern const u8 gMonBackPic_Farfetchd[];
+extern const u8 gMonShinyPalette_Farfetchd[];
+extern const u8 gMonIcon_Farfetchd[];
+extern const u8 gMonFootprint_Farfetchd[];
+extern const u8 gMonFrontPic_Doduo[];
+extern const u8 gMonPalette_Doduo[];
+extern const u8 gMonBackPic_Doduo[];
+extern const u8 gMonShinyPalette_Doduo[];
+extern const u8 gMonIcon_Doduo[];
+extern const u8 gMonFootprint_Doduo[];
+extern const u8 gMonFrontPic_Dodrio[];
+extern const u8 gMonPalette_Dodrio[];
+extern const u8 gMonBackPic_Dodrio[];
+extern const u8 gMonShinyPalette_Dodrio[];
+extern const u8 gMonIcon_Dodrio[];
+extern const u8 gMonFootprint_Dodrio[];
+extern const u8 gMonFrontPic_Seel[];
+extern const u8 gMonPalette_Seel[];
+extern const u8 gMonBackPic_Seel[];
+extern const u8 gMonShinyPalette_Seel[];
+extern const u8 gMonIcon_Seel[];
+extern const u8 gMonFootprint_Seel[];
+extern const u8 gMonFrontPic_Dewgong[];
+extern const u8 gMonPalette_Dewgong[];
+extern const u8 gMonBackPic_Dewgong[];
+extern const u8 gMonShinyPalette_Dewgong[];
+extern const u8 gMonIcon_Dewgong[];
+extern const u8 gMonFootprint_Dewgong[];
+extern const u8 gMonFrontPic_Grimer[];
+extern const u8 gMonPalette_Grimer[];
+extern const u8 gMonBackPic_Grimer[];
+extern const u8 gMonShinyPalette_Grimer[];
+extern const u8 gMonIcon_Grimer[];
+extern const u8 gMonFootprint_Grimer[];
+extern const u8 gMonFrontPic_Muk[];
+extern const u8 gMonPalette_Muk[];
+extern const u8 gMonBackPic_Muk[];
+extern const u8 gMonShinyPalette_Muk[];
+extern const u8 gMonIcon_Muk[];
+extern const u8 gMonFootprint_Muk[];
+extern const u8 gMonFrontPic_Shellder[];
+extern const u8 gMonPalette_Shellder[];
+extern const u8 gMonBackPic_Shellder[];
+extern const u8 gMonShinyPalette_Shellder[];
+extern const u8 gMonIcon_Shellder[];
+extern const u8 gMonFootprint_Shellder[];
+extern const u8 gMonFrontPic_Cloyster[];
+extern const u8 gMonPalette_Cloyster[];
+extern const u8 gMonBackPic_Cloyster[];
+extern const u8 gMonShinyPalette_Cloyster[];
+extern const u8 gMonIcon_Cloyster[];
+extern const u8 gMonFootprint_Cloyster[];
+extern const u8 gMonFrontPic_Gastly[];
+extern const u8 gMonPalette_Gastly[];
+extern const u8 gMonBackPic_Gastly[];
+extern const u8 gMonShinyPalette_Gastly[];
+extern const u8 gMonIcon_Gastly[];
+extern const u8 gMonFootprint_Gastly[];
+extern const u8 gMonFrontPic_Haunter[];
+extern const u8 gMonPalette_Haunter[];
+extern const u8 gMonBackPic_Haunter[];
+extern const u8 gMonShinyPalette_Haunter[];
+extern const u8 gMonIcon_Haunter[];
+extern const u8 gMonFootprint_Haunter[];
+extern const u8 gMonFrontPic_Gengar[];
+extern const u8 gMonPalette_Gengar[];
+extern const u8 gMonBackPic_Gengar[];
+extern const u8 gMonShinyPalette_Gengar[];
+extern const u8 gMonIcon_Gengar[];
+extern const u8 gMonFootprint_Gengar[];
+extern const u8 gMonFrontPic_Onix[];
+extern const u8 gMonPalette_Onix[];
+extern const u8 gMonBackPic_Onix[];
+extern const u8 gMonShinyPalette_Onix[];
+extern const u8 gMonIcon_Onix[];
+extern const u8 gMonFootprint_Onix[];
+extern const u8 gMonFrontPic_Drowzee[];
+extern const u8 gMonPalette_Drowzee[];
+extern const u8 gMonBackPic_Drowzee[];
+extern const u8 gMonShinyPalette_Drowzee[];
+extern const u8 gMonIcon_Drowzee[];
+extern const u8 gMonFootprint_Drowzee[];
+extern const u8 gMonFrontPic_Hypno[];
+extern const u8 gMonPalette_Hypno[];
+extern const u8 gMonBackPic_Hypno[];
+extern const u8 gMonShinyPalette_Hypno[];
+extern const u8 gMonIcon_Hypno[];
+extern const u8 gMonFootprint_Hypno[];
+extern const u8 gMonFrontPic_Krabby[];
+extern const u8 gMonPalette_Krabby[];
+extern const u8 gMonBackPic_Krabby[];
+extern const u8 gMonShinyPalette_Krabby[];
+extern const u8 gMonIcon_Krabby[];
+extern const u8 gMonFootprint_Krabby[];
+extern const u8 gMonFrontPic_Kingler[];
+extern const u8 gMonPalette_Kingler[];
+extern const u8 gMonBackPic_Kingler[];
+extern const u8 gMonShinyPalette_Kingler[];
+extern const u8 gMonIcon_Kingler[];
+extern const u8 gMonFootprint_Kingler[];
+extern const u8 gMonFrontPic_Voltorb[];
+extern const u8 gMonPalette_Voltorb[];
+extern const u8 gMonBackPic_Voltorb[];
+extern const u8 gMonShinyPalette_Voltorb[];
+extern const u8 gMonIcon_Voltorb[];
+extern const u8 gMonFootprint_Voltorb[];
+extern const u8 gMonFrontPic_Electrode[];
+extern const u8 gMonPalette_Electrode[];
+extern const u8 gMonBackPic_Electrode[];
+extern const u8 gMonShinyPalette_Electrode[];
+extern const u8 gMonIcon_Electrode[];
+extern const u8 gMonFootprint_Electrode[];
+extern const u8 gMonFrontPic_Exeggcute[];
+extern const u8 gMonPalette_Exeggcute[];
+extern const u8 gMonBackPic_Exeggcute[];
+extern const u8 gMonShinyPalette_Exeggcute[];
+extern const u8 gMonIcon_Exeggcute[];
+extern const u8 gMonFootprint_Exeggcute[];
+extern const u8 gMonFrontPic_Exeggutor[];
+extern const u8 gMonPalette_Exeggutor[];
+extern const u8 gMonBackPic_Exeggutor[];
+extern const u8 gMonShinyPalette_Exeggutor[];
+extern const u8 gMonIcon_Exeggutor[];
+extern const u8 gMonFootprint_Exeggutor[];
+extern const u8 gMonFrontPic_Cubone[];
+extern const u8 gMonPalette_Cubone[];
+extern const u8 gMonBackPic_Cubone[];
+extern const u8 gMonShinyPalette_Cubone[];
+extern const u8 gMonIcon_Cubone[];
+extern const u8 gMonFootprint_Cubone[];
+extern const u8 gMonFrontPic_Marowak[];
+extern const u8 gMonPalette_Marowak[];
+extern const u8 gMonBackPic_Marowak[];
+extern const u8 gMonShinyPalette_Marowak[];
+extern const u8 gMonIcon_Marowak[];
+extern const u8 gMonFootprint_Marowak[];
+extern const u8 gMonFrontPic_Hitmonlee[];
+extern const u8 gMonPalette_Hitmonlee[];
+extern const u8 gMonBackPic_Hitmonlee[];
+extern const u8 gMonShinyPalette_Hitmonlee[];
+extern const u8 gMonIcon_Hitmonlee[];
+extern const u8 gMonFootprint_Hitmonlee[];
+extern const u8 gMonFrontPic_Hitmonchan[];
+extern const u8 gMonPalette_Hitmonchan[];
+extern const u8 gMonBackPic_Hitmonchan[];
+extern const u8 gMonShinyPalette_Hitmonchan[];
+extern const u8 gMonIcon_Hitmonchan[];
+extern const u8 gMonFootprint_Hitmonchan[];
+extern const u8 gMonFrontPic_Lickitung[];
+extern const u8 gMonPalette_Lickitung[];
+extern const u8 gMonBackPic_Lickitung[];
+extern const u8 gMonShinyPalette_Lickitung[];
+extern const u8 gMonIcon_Lickitung[];
+extern const u8 gMonFootprint_Lickitung[];
+extern const u8 gMonFrontPic_Koffing[];
+extern const u8 gMonPalette_Koffing[];
+extern const u8 gMonBackPic_Koffing[];
+extern const u8 gMonShinyPalette_Koffing[];
+extern const u8 gMonIcon_Koffing[];
+extern const u8 gMonFootprint_Koffing[];
+extern const u8 gMonFrontPic_Weezing[];
+extern const u8 gMonPalette_Weezing[];
+extern const u8 gMonBackPic_Weezing[];
+extern const u8 gMonShinyPalette_Weezing[];
+extern const u8 gMonIcon_Weezing[];
+extern const u8 gMonFootprint_Weezing[];
+extern const u8 gMonFrontPic_Rhyhorn[];
+extern const u8 gMonPalette_Rhyhorn[];
+extern const u8 gMonBackPic_Rhyhorn[];
+extern const u8 gMonShinyPalette_Rhyhorn[];
+extern const u8 gMonIcon_Rhyhorn[];
+extern const u8 gMonFootprint_Rhyhorn[];
+extern const u8 gMonFrontPic_Rhydon[];
+extern const u8 gMonPalette_Rhydon[];
+extern const u8 gMonBackPic_Rhydon[];
+extern const u8 gMonShinyPalette_Rhydon[];
+extern const u8 gMonIcon_Rhydon[];
+extern const u8 gMonFootprint_Rhydon[];
+extern const u8 gMonFrontPic_Chansey[];
+extern const u8 gMonPalette_Chansey[];
+extern const u8 gMonBackPic_Chansey[];
+extern const u8 gMonShinyPalette_Chansey[];
+extern const u8 gMonIcon_Chansey[];
+extern const u8 gMonFootprint_Chansey[];
+extern const u8 gMonFrontPic_Tangela[];
+extern const u8 gMonPalette_Tangela[];
+extern const u8 gMonBackPic_Tangela[];
+extern const u8 gMonShinyPalette_Tangela[];
+extern const u8 gMonIcon_Tangela[];
+extern const u8 gMonFootprint_Tangela[];
+extern const u8 gMonFrontPic_Kangaskhan[];
+extern const u8 gMonPalette_Kangaskhan[];
+extern const u8 gMonBackPic_Kangaskhan[];
+extern const u8 gMonShinyPalette_Kangaskhan[];
+extern const u8 gMonIcon_Kangaskhan[];
+extern const u8 gMonFootprint_Kangaskhan[];
+extern const u8 gMonFrontPic_Horsea[];
+extern const u8 gMonPalette_Horsea[];
+extern const u8 gMonBackPic_Horsea[];
+extern const u8 gMonShinyPalette_Horsea[];
+extern const u8 gMonIcon_Horsea[];
+extern const u8 gMonFootprint_Horsea[];
+extern const u8 gMonFrontPic_Seadra[];
+extern const u8 gMonPalette_Seadra[];
+extern const u8 gMonBackPic_Seadra[];
+extern const u8 gMonShinyPalette_Seadra[];
+extern const u8 gMonIcon_Seadra[];
+extern const u8 gMonFootprint_Seadra[];
+extern const u8 gMonFrontPic_Goldeen[];
+extern const u8 gMonPalette_Goldeen[];
+extern const u8 gMonBackPic_Goldeen[];
+extern const u8 gMonShinyPalette_Goldeen[];
+extern const u8 gMonIcon_Goldeen[];
+extern const u8 gMonFootprint_Goldeen[];
+extern const u8 gMonFrontPic_Seaking[];
+extern const u8 gMonPalette_Seaking[];
+extern const u8 gMonBackPic_Seaking[];
+extern const u8 gMonShinyPalette_Seaking[];
+extern const u8 gMonIcon_Seaking[];
+extern const u8 gMonFootprint_Seaking[];
+extern const u8 gMonFrontPic_Staryu[];
+extern const u8 gMonPalette_Staryu[];
+extern const u8 gMonBackPic_Staryu[];
+extern const u8 gMonShinyPalette_Staryu[];
+extern const u8 gMonIcon_Staryu[];
+extern const u8 gMonFootprint_Staryu[];
+extern const u8 gMonFrontPic_Starmie[];
+extern const u8 gMonPalette_Starmie[];
+extern const u8 gMonBackPic_Starmie[];
+extern const u8 gMonShinyPalette_Starmie[];
+extern const u8 gMonIcon_Starmie[];
+extern const u8 gMonFootprint_Starmie[];
+extern const u8 gMonFrontPic_Mrmime[];
+extern const u8 gMonPalette_Mrmime[];
+extern const u8 gMonBackPic_Mrmime[];
+extern const u8 gMonShinyPalette_Mrmime[];
+extern const u8 gMonIcon_Mrmime[];
+extern const u8 gMonFootprint_Mrmime[];
+extern const u8 gMonFrontPic_Scyther[];
+extern const u8 gMonPalette_Scyther[];
+extern const u8 gMonBackPic_Scyther[];
+extern const u8 gMonShinyPalette_Scyther[];
+extern const u8 gMonIcon_Scyther[];
+extern const u8 gMonFootprint_Scyther[];
+extern const u8 gMonFrontPic_Jynx[];
+extern const u8 gMonPalette_Jynx[];
+extern const u8 gMonBackPic_Jynx[];
+extern const u8 gMonShinyPalette_Jynx[];
+extern const u8 gMonIcon_Jynx[];
+extern const u8 gMonFootprint_Jynx[];
+extern const u8 gMonFrontPic_Electabuzz[];
+extern const u8 gMonPalette_Electabuzz[];
+extern const u8 gMonBackPic_Electabuzz[];
+extern const u8 gMonShinyPalette_Electabuzz[];
+extern const u8 gMonIcon_Electabuzz[];
+extern const u8 gMonFootprint_Electabuzz[];
+extern const u8 gMonFrontPic_Magmar[];
+extern const u8 gMonPalette_Magmar[];
+extern const u8 gMonBackPic_Magmar[];
+extern const u8 gMonShinyPalette_Magmar[];
+extern const u8 gMonIcon_Magmar[];
+extern const u8 gMonFootprint_Magmar[];
+extern const u8 gMonFrontPic_Pinsir[];
+extern const u8 gMonPalette_Pinsir[];
+extern const u8 gMonBackPic_Pinsir[];
+extern const u8 gMonShinyPalette_Pinsir[];
+extern const u8 gMonIcon_Pinsir[];
+extern const u8 gMonFootprint_Pinsir[];
+extern const u8 gMonFrontPic_Tauros[];
+extern const u8 gMonPalette_Tauros[];
+extern const u8 gMonBackPic_Tauros[];
+extern const u8 gMonShinyPalette_Tauros[];
+extern const u8 gMonIcon_Tauros[];
+extern const u8 gMonFootprint_Tauros[];
+extern const u8 gMonFrontPic_Magikarp[];
+extern const u8 gMonPalette_Magikarp[];
+extern const u8 gMonBackPic_Magikarp[];
+extern const u8 gMonShinyPalette_Magikarp[];
+extern const u8 gMonIcon_Magikarp[];
+extern const u8 gMonFootprint_Magikarp[];
+extern const u8 gMonFrontPic_Gyarados[];
+extern const u8 gMonPalette_Gyarados[];
+extern const u8 gMonBackPic_Gyarados[];
+extern const u8 gMonShinyPalette_Gyarados[];
+extern const u8 gMonIcon_Gyarados[];
+extern const u8 gMonFootprint_Gyarados[];
+extern const u8 gMonFrontPic_Lapras[];
+extern const u8 gMonPalette_Lapras[];
+extern const u8 gMonBackPic_Lapras[];
+extern const u8 gMonShinyPalette_Lapras[];
+extern const u8 gMonIcon_Lapras[];
+extern const u8 gMonFootprint_Lapras[];
+extern const u8 gMonFrontPic_Ditto[];
+extern const u8 gMonPalette_Ditto[];
+extern const u8 gMonBackPic_Ditto[];
+extern const u8 gMonShinyPalette_Ditto[];
+extern const u8 gMonIcon_Ditto[];
+extern const u8 gMonFootprint_Ditto[];
+extern const u8 gMonFrontPic_Eevee[];
+extern const u8 gMonPalette_Eevee[];
+extern const u8 gMonBackPic_Eevee[];
+extern const u8 gMonShinyPalette_Eevee[];
+extern const u8 gMonIcon_Eevee[];
+extern const u8 gMonFootprint_Eevee[];
+extern const u8 gMonFrontPic_Vaporeon[];
+extern const u8 gMonPalette_Vaporeon[];
+extern const u8 gMonBackPic_Vaporeon[];
+extern const u8 gMonShinyPalette_Vaporeon[];
+extern const u8 gMonIcon_Vaporeon[];
+extern const u8 gMonFootprint_Vaporeon[];
+extern const u8 gMonFrontPic_Jolteon[];
+extern const u8 gMonPalette_Jolteon[];
+extern const u8 gMonBackPic_Jolteon[];
+extern const u8 gMonShinyPalette_Jolteon[];
+extern const u8 gMonIcon_Jolteon[];
+extern const u8 gMonFootprint_Jolteon[];
+extern const u8 gMonFrontPic_Flareon[];
+extern const u8 gMonPalette_Flareon[];
+extern const u8 gMonBackPic_Flareon[];
+extern const u8 gMonShinyPalette_Flareon[];
+extern const u8 gMonIcon_Flareon[];
+extern const u8 gMonFootprint_Flareon[];
+extern const u8 gMonFrontPic_Porygon[];
+extern const u8 gMonPalette_Porygon[];
+extern const u8 gMonBackPic_Porygon[];
+extern const u8 gMonShinyPalette_Porygon[];
+extern const u8 gMonIcon_Porygon[];
+extern const u8 gMonFootprint_Porygon[];
+extern const u8 gMonFrontPic_Omanyte[];
+extern const u8 gMonPalette_Omanyte[];
+extern const u8 gMonBackPic_Omanyte[];
+extern const u8 gMonShinyPalette_Omanyte[];
+extern const u8 gMonIcon_Omanyte[];
+extern const u8 gMonFootprint_Omanyte[];
+extern const u8 gMonFrontPic_Omastar[];
+extern const u8 gMonPalette_Omastar[];
+extern const u8 gMonBackPic_Omastar[];
+extern const u8 gMonShinyPalette_Omastar[];
+extern const u8 gMonIcon_Omastar[];
+extern const u8 gMonFootprint_Omastar[];
+extern const u8 gMonFrontPic_Kabuto[];
+extern const u8 gMonPalette_Kabuto[];
+extern const u8 gMonBackPic_Kabuto[];
+extern const u8 gMonShinyPalette_Kabuto[];
+extern const u8 gMonIcon_Kabuto[];
+extern const u8 gMonFootprint_Kabuto[];
+extern const u8 gMonFrontPic_Kabutops[];
+extern const u8 gMonPalette_Kabutops[];
+extern const u8 gMonBackPic_Kabutops[];
+extern const u8 gMonShinyPalette_Kabutops[];
+extern const u8 gMonIcon_Kabutops[];
+extern const u8 gMonFootprint_Kabutops[];
+extern const u8 gMonFrontPic_Aerodactyl[];
+extern const u8 gMonPalette_Aerodactyl[];
+extern const u8 gMonBackPic_Aerodactyl[];
+extern const u8 gMonShinyPalette_Aerodactyl[];
+extern const u8 gMonIcon_Aerodactyl[];
+extern const u8 gMonFootprint_Aerodactyl[];
+extern const u8 gMonFrontPic_Snorlax[];
+extern const u8 gMonPalette_Snorlax[];
+extern const u8 gMonBackPic_Snorlax[];
+extern const u8 gMonShinyPalette_Snorlax[];
+extern const u8 gMonIcon_Snorlax[];
+extern const u8 gMonFootprint_Snorlax[];
+extern const u8 gMonFrontPic_Articuno[];
+extern const u8 gMonPalette_Articuno[];
+extern const u8 gMonBackPic_Articuno[];
+extern const u8 gMonShinyPalette_Articuno[];
+extern const u8 gMonIcon_Articuno[];
+extern const u8 gMonFootprint_Articuno[];
+extern const u8 gMonFrontPic_Zapdos[];
+extern const u8 gMonPalette_Zapdos[];
+extern const u8 gMonBackPic_Zapdos[];
+extern const u8 gMonShinyPalette_Zapdos[];
+extern const u8 gMonIcon_Zapdos[];
+extern const u8 gMonFootprint_Zapdos[];
+extern const u8 gMonFrontPic_Moltres[];
+extern const u8 gMonPalette_Moltres[];
+extern const u8 gMonBackPic_Moltres[];
+extern const u8 gMonShinyPalette_Moltres[];
+extern const u8 gMonIcon_Moltres[];
+extern const u8 gMonFootprint_Moltres[];
+extern const u8 gMonFrontPic_Dratini[];
+extern const u8 gMonPalette_Dratini[];
+extern const u8 gMonBackPic_Dratini[];
+extern const u8 gMonShinyPalette_Dratini[];
+extern const u8 gMonIcon_Dratini[];
+extern const u8 gMonFootprint_Dratini[];
+extern const u8 gMonFrontPic_Dragonair[];
+extern const u8 gMonPalette_Dragonair[];
+extern const u8 gMonBackPic_Dragonair[];
+extern const u8 gMonShinyPalette_Dragonair[];
+extern const u8 gMonIcon_Dragonair[];
+extern const u8 gMonFootprint_Dragonair[];
+extern const u8 gMonFrontPic_Dragonite[];
+extern const u8 gMonPalette_Dragonite[];
+extern const u8 gMonBackPic_Dragonite[];
+extern const u8 gMonShinyPalette_Dragonite[];
+extern const u8 gMonIcon_Dragonite[];
+extern const u8 gMonFootprint_Dragonite[];
+extern const u8 gMonFrontPic_Mewtwo[];
+extern const u8 gMonPalette_Mewtwo[];
+extern const u8 gMonBackPic_Mewtwo[];
+extern const u8 gMonShinyPalette_Mewtwo[];
+extern const u8 gMonIcon_Mewtwo[];
+extern const u8 gMonFootprint_Mewtwo[];
+extern const u8 gMonFrontPic_Mew[];
+extern const u8 gMonPalette_Mew[];
+extern const u8 gMonBackPic_Mew[];
+extern const u8 gMonShinyPalette_Mew[];
+extern const u8 gMonIcon_Mew[];
+extern const u8 gMonFootprint_Mew[];
+extern const u8 gMonFrontPic_Chikorita[];
+extern const u8 gMonPalette_Chikorita[];
+extern const u8 gMonBackPic_Chikorita[];
+extern const u8 gMonShinyPalette_Chikorita[];
+extern const u8 gMonIcon_Chikorita[];
+extern const u8 gMonFootprint_Chikorita[];
+extern const u8 gMonFrontPic_Bayleef[];
+extern const u8 gMonPalette_Bayleef[];
+extern const u8 gMonBackPic_Bayleef[];
+extern const u8 gMonShinyPalette_Bayleef[];
+extern const u8 gMonIcon_Bayleef[];
+extern const u8 gMonFootprint_Bayleef[];
+extern const u8 gMonFrontPic_Meganium[];
+extern const u8 gMonPalette_Meganium[];
+extern const u8 gMonBackPic_Meganium[];
+extern const u8 gMonShinyPalette_Meganium[];
+extern const u8 gMonIcon_Meganium[];
+extern const u8 gMonFootprint_Meganium[];
+extern const u8 gMonFrontPic_Cyndaquil[];
+extern const u8 gMonPalette_Cyndaquil[];
+extern const u8 gMonBackPic_Cyndaquil[];
+extern const u8 gMonShinyPalette_Cyndaquil[];
+extern const u8 gMonIcon_Cyndaquil[];
+extern const u8 gMonFootprint_Cyndaquil[];
+extern const u8 gMonFrontPic_Quilava[];
+extern const u8 gMonPalette_Quilava[];
+extern const u8 gMonBackPic_Quilava[];
+extern const u8 gMonShinyPalette_Quilava[];
+extern const u8 gMonIcon_Quilava[];
+extern const u8 gMonFootprint_Quilava[];
+extern const u8 gMonFrontPic_Typhlosion[];
+extern const u8 gMonPalette_Typhlosion[];
+extern const u8 gMonBackPic_Typhlosion[];
+extern const u8 gMonShinyPalette_Typhlosion[];
+extern const u8 gMonIcon_Typhlosion[];
+extern const u8 gMonFootprint_Typhlosion[];
+extern const u8 gMonFrontPic_Totodile[];
+extern const u8 gMonPalette_Totodile[];
+extern const u8 gMonBackPic_Totodile[];
+extern const u8 gMonShinyPalette_Totodile[];
+extern const u8 gMonIcon_Totodile[];
+extern const u8 gMonFootprint_Totodile[];
+extern const u8 gMonFrontPic_Croconaw[];
+extern const u8 gMonPalette_Croconaw[];
+extern const u8 gMonBackPic_Croconaw[];
+extern const u8 gMonShinyPalette_Croconaw[];
+extern const u8 gMonIcon_Croconaw[];
+extern const u8 gMonFootprint_Croconaw[];
+extern const u8 gMonFrontPic_Feraligatr[];
+extern const u8 gMonPalette_Feraligatr[];
+extern const u8 gMonBackPic_Feraligatr[];
+extern const u8 gMonShinyPalette_Feraligatr[];
+extern const u8 gMonIcon_Feraligatr[];
+extern const u8 gMonFootprint_Feraligatr[];
+extern const u8 gMonFrontPic_Sentret[];
+extern const u8 gMonPalette_Sentret[];
+extern const u8 gMonBackPic_Sentret[];
+extern const u8 gMonShinyPalette_Sentret[];
+extern const u8 gMonIcon_Sentret[];
+extern const u8 gMonFootprint_Sentret[];
+extern const u8 gMonFrontPic_Furret[];
+extern const u8 gMonPalette_Furret[];
+extern const u8 gMonBackPic_Furret[];
+extern const u8 gMonShinyPalette_Furret[];
+extern const u8 gMonIcon_Furret[];
+extern const u8 gMonFootprint_Furret[];
+extern const u8 gMonFrontPic_Hoothoot[];
+extern const u8 gMonPalette_Hoothoot[];
+extern const u8 gMonBackPic_Hoothoot[];
+extern const u8 gMonShinyPalette_Hoothoot[];
+extern const u8 gMonIcon_Hoothoot[];
+extern const u8 gMonFootprint_Hoothoot[];
+extern const u8 gMonFrontPic_Noctowl[];
+extern const u8 gMonPalette_Noctowl[];
+extern const u8 gMonBackPic_Noctowl[];
+extern const u8 gMonShinyPalette_Noctowl[];
+extern const u8 gMonIcon_Noctowl[];
+extern const u8 gMonFootprint_Noctowl[];
+extern const u8 gMonFrontPic_Ledyba[];
+extern const u8 gMonPalette_Ledyba[];
+extern const u8 gMonBackPic_Ledyba[];
+extern const u8 gMonShinyPalette_Ledyba[];
+extern const u8 gMonIcon_Ledyba[];
+extern const u8 gMonFootprint_Ledyba[];
+extern const u8 gMonFrontPic_Ledian[];
+extern const u8 gMonPalette_Ledian[];
+extern const u8 gMonBackPic_Ledian[];
+extern const u8 gMonShinyPalette_Ledian[];
+extern const u8 gMonIcon_Ledian[];
+extern const u8 gMonFootprint_Ledian[];
+extern const u8 gMonFrontPic_Spinarak[];
+extern const u8 gMonPalette_Spinarak[];
+extern const u8 gMonBackPic_Spinarak[];
+extern const u8 gMonShinyPalette_Spinarak[];
+extern const u8 gMonIcon_Spinarak[];
+extern const u8 gMonFootprint_Spinarak[];
+extern const u8 gMonFrontPic_Ariados[];
+extern const u8 gMonPalette_Ariados[];
+extern const u8 gMonBackPic_Ariados[];
+extern const u8 gMonShinyPalette_Ariados[];
+extern const u8 gMonIcon_Ariados[];
+extern const u8 gMonFootprint_Ariados[];
+extern const u8 gMonFrontPic_Crobat[];
+extern const u8 gMonPalette_Crobat[];
+extern const u8 gMonBackPic_Crobat[];
+extern const u8 gMonShinyPalette_Crobat[];
+extern const u8 gMonIcon_Crobat[];
+extern const u8 gMonFootprint_Crobat[];
+extern const u8 gMonFrontPic_Chinchou[];
+extern const u8 gMonPalette_Chinchou[];
+extern const u8 gMonBackPic_Chinchou[];
+extern const u8 gMonShinyPalette_Chinchou[];
+extern const u8 gMonIcon_Chinchou[];
+extern const u8 gMonFootprint_Chinchou[];
+extern const u8 gMonFrontPic_Lanturn[];
+extern const u8 gMonPalette_Lanturn[];
+extern const u8 gMonBackPic_Lanturn[];
+extern const u8 gMonShinyPalette_Lanturn[];
+extern const u8 gMonIcon_Lanturn[];
+extern const u8 gMonFootprint_Lanturn[];
+extern const u8 gMonFrontPic_Pichu[];
+extern const u8 gMonPalette_Pichu[];
+extern const u8 gMonBackPic_Pichu[];
+extern const u8 gMonShinyPalette_Pichu[];
+extern const u8 gMonIcon_Pichu[];
+extern const u8 gMonFootprint_Pichu[];
+extern const u8 gMonFrontPic_Cleffa[];
+extern const u8 gMonPalette_Cleffa[];
+extern const u8 gMonBackPic_Cleffa[];
+extern const u8 gMonShinyPalette_Cleffa[];
+extern const u8 gMonIcon_Cleffa[];
+extern const u8 gMonFootprint_Cleffa[];
+extern const u8 gMonFrontPic_Igglybuff[];
+extern const u8 gMonPalette_Igglybuff[];
+extern const u8 gMonBackPic_Igglybuff[];
+extern const u8 gMonShinyPalette_Igglybuff[];
+extern const u8 gMonIcon_Igglybuff[];
+extern const u8 gMonFootprint_Igglybuff[];
+extern const u8 gMonFrontPic_Togepi[];
+extern const u8 gMonPalette_Togepi[];
+extern const u8 gMonBackPic_Togepi[];
+extern const u8 gMonShinyPalette_Togepi[];
+extern const u8 gMonIcon_Togepi[];
+extern const u8 gMonFootprint_Togepi[];
+extern const u8 gMonFrontPic_Togetic[];
+extern const u8 gMonPalette_Togetic[];
+extern const u8 gMonBackPic_Togetic[];
+extern const u8 gMonShinyPalette_Togetic[];
+extern const u8 gMonIcon_Togetic[];
+extern const u8 gMonFootprint_Togetic[];
+extern const u8 gMonFrontPic_Natu[];
+extern const u8 gMonPalette_Natu[];
+extern const u8 gMonBackPic_Natu[];
+extern const u8 gMonShinyPalette_Natu[];
+extern const u8 gMonIcon_Natu[];
+extern const u8 gMonFootprint_Natu[];
+extern const u8 gMonFrontPic_Xatu[];
+extern const u8 gMonPalette_Xatu[];
+extern const u8 gMonBackPic_Xatu[];
+extern const u8 gMonShinyPalette_Xatu[];
+extern const u8 gMonIcon_Xatu[];
+extern const u8 gMonFootprint_Xatu[];
+extern const u8 gMonFrontPic_Mareep[];
+extern const u8 gMonPalette_Mareep[];
+extern const u8 gMonBackPic_Mareep[];
+extern const u8 gMonShinyPalette_Mareep[];
+extern const u8 gMonIcon_Mareep[];
+extern const u8 gMonFootprint_Mareep[];
+extern const u8 gMonFrontPic_Flaaffy[];
+extern const u8 gMonPalette_Flaaffy[];
+extern const u8 gMonBackPic_Flaaffy[];
+extern const u8 gMonShinyPalette_Flaaffy[];
+extern const u8 gMonIcon_Flaaffy[];
+extern const u8 gMonFootprint_Flaaffy[];
+extern const u8 gMonFrontPic_Ampharos[];
+extern const u8 gMonPalette_Ampharos[];
+extern const u8 gMonBackPic_Ampharos[];
+extern const u8 gMonShinyPalette_Ampharos[];
+extern const u8 gMonIcon_Ampharos[];
+extern const u8 gMonFootprint_Ampharos[];
+extern const u8 gMonFrontPic_Bellossom[];
+extern const u8 gMonPalette_Bellossom[];
+extern const u8 gMonBackPic_Bellossom[];
+extern const u8 gMonShinyPalette_Bellossom[];
+extern const u8 gMonIcon_Bellossom[];
+extern const u8 gMonFootprint_Bellossom[];
+extern const u8 gMonFrontPic_Marill[];
+extern const u8 gMonPalette_Marill[];
+extern const u8 gMonBackPic_Marill[];
+extern const u8 gMonShinyPalette_Marill[];
+extern const u8 gMonIcon_Marill[];
+extern const u8 gMonFootprint_Marill[];
+extern const u8 gMonFrontPic_Azumarill[];
+extern const u8 gMonPalette_Azumarill[];
+extern const u8 gMonBackPic_Azumarill[];
+extern const u8 gMonShinyPalette_Azumarill[];
+extern const u8 gMonIcon_Azumarill[];
+extern const u8 gMonFootprint_Azumarill[];
+extern const u8 gMonFrontPic_Sudowoodo[];
+extern const u8 gMonPalette_Sudowoodo[];
+extern const u8 gMonBackPic_Sudowoodo[];
+extern const u8 gMonShinyPalette_Sudowoodo[];
+extern const u8 gMonIcon_Sudowoodo[];
+extern const u8 gMonFootprint_Sudowoodo[];
+extern const u8 gMonFrontPic_Politoed[];
+extern const u8 gMonPalette_Politoed[];
+extern const u8 gMonBackPic_Politoed[];
+extern const u8 gMonShinyPalette_Politoed[];
+extern const u8 gMonIcon_Politoed[];
+extern const u8 gMonFootprint_Politoed[];
+extern const u8 gMonFrontPic_Hoppip[];
+extern const u8 gMonPalette_Hoppip[];
+extern const u8 gMonBackPic_Hoppip[];
+extern const u8 gMonShinyPalette_Hoppip[];
+extern const u8 gMonIcon_Hoppip[];
+extern const u8 gMonFootprint_Hoppip[];
+extern const u8 gMonFrontPic_Skiploom[];
+extern const u8 gMonPalette_Skiploom[];
+extern const u8 gMonBackPic_Skiploom[];
+extern const u8 gMonShinyPalette_Skiploom[];
+extern const u8 gMonIcon_Skiploom[];
+extern const u8 gMonFootprint_Skiploom[];
+extern const u8 gMonFrontPic_Jumpluff[];
+extern const u8 gMonPalette_Jumpluff[];
+extern const u8 gMonBackPic_Jumpluff[];
+extern const u8 gMonShinyPalette_Jumpluff[];
+extern const u8 gMonIcon_Jumpluff[];
+extern const u8 gMonFootprint_Jumpluff[];
+extern const u8 gMonFrontPic_Aipom[];
+extern const u8 gMonPalette_Aipom[];
+extern const u8 gMonBackPic_Aipom[];
+extern const u8 gMonShinyPalette_Aipom[];
+extern const u8 gMonIcon_Aipom[];
+extern const u8 gMonFootprint_Aipom[];
+extern const u8 gMonFrontPic_Sunkern[];
+extern const u8 gMonPalette_Sunkern[];
+extern const u8 gMonBackPic_Sunkern[];
+extern const u8 gMonShinyPalette_Sunkern[];
+extern const u8 gMonIcon_Sunkern[];
+extern const u8 gMonFootprint_Sunkern[];
+extern const u8 gMonFrontPic_Sunflora[];
+extern const u8 gMonPalette_Sunflora[];
+extern const u8 gMonBackPic_Sunflora[];
+extern const u8 gMonShinyPalette_Sunflora[];
+extern const u8 gMonIcon_Sunflora[];
+extern const u8 gMonFootprint_Sunflora[];
+extern const u8 gMonFrontPic_Yanma[];
+extern const u8 gMonPalette_Yanma[];
+extern const u8 gMonBackPic_Yanma[];
+extern const u8 gMonShinyPalette_Yanma[];
+extern const u8 gMonIcon_Yanma[];
+extern const u8 gMonFootprint_Yanma[];
+extern const u8 gMonFrontPic_Wooper[];
+extern const u8 gMonPalette_Wooper[];
+extern const u8 gMonBackPic_Wooper[];
+extern const u8 gMonShinyPalette_Wooper[];
+extern const u8 gMonIcon_Wooper[];
+extern const u8 gMonFootprint_Wooper[];
+extern const u8 gMonFrontPic_Quagsire[];
+extern const u8 gMonPalette_Quagsire[];
+extern const u8 gMonBackPic_Quagsire[];
+extern const u8 gMonShinyPalette_Quagsire[];
+extern const u8 gMonIcon_Quagsire[];
+extern const u8 gMonFootprint_Quagsire[];
+extern const u8 gMonFrontPic_Espeon[];
+extern const u8 gMonPalette_Espeon[];
+extern const u8 gMonBackPic_Espeon[];
+extern const u8 gMonShinyPalette_Espeon[];
+extern const u8 gMonIcon_Espeon[];
+extern const u8 gMonFootprint_Espeon[];
+extern const u8 gMonFrontPic_Umbreon[];
+extern const u8 gMonPalette_Umbreon[];
+extern const u8 gMonBackPic_Umbreon[];
+extern const u8 gMonShinyPalette_Umbreon[];
+extern const u8 gMonIcon_Umbreon[];
+extern const u8 gMonFootprint_Umbreon[];
+extern const u8 gMonFrontPic_Murkrow[];
+extern const u8 gMonPalette_Murkrow[];
+extern const u8 gMonBackPic_Murkrow[];
+extern const u8 gMonShinyPalette_Murkrow[];
+extern const u8 gMonIcon_Murkrow[];
+extern const u8 gMonFootprint_Murkrow[];
+extern const u8 gMonFrontPic_Slowking[];
+extern const u8 gMonPalette_Slowking[];
+extern const u8 gMonBackPic_Slowking[];
+extern const u8 gMonShinyPalette_Slowking[];
+extern const u8 gMonIcon_Slowking[];
+extern const u8 gMonFootprint_Slowking[];
+extern const u8 gMonFrontPic_Misdreavus[];
+extern const u8 gMonPalette_Misdreavus[];
+extern const u8 gMonBackPic_Misdreavus[];
+extern const u8 gMonShinyPalette_Misdreavus[];
+extern const u8 gMonIcon_Misdreavus[];
+extern const u8 gMonFootprint_Misdreavus[];
+extern const u8 gMonFrontPic_UnownA[];
+extern const u8 gMonPalette_Unown[];
+extern const u8 gMonBackPic_UnownA[];
+extern const u8 gMonShinyPalette_Unown[];
+extern const u8 gMonIcon_UnownA[];
+extern const u8 gMonFootprint_Unown[];
+extern const u8 gMonFrontPic_Wobbuffet[];
+extern const u8 gMonPalette_Wobbuffet[];
+extern const u8 gMonBackPic_Wobbuffet[];
+extern const u8 gMonShinyPalette_Wobbuffet[];
+extern const u8 gMonIcon_Wobbuffet[];
+extern const u8 gMonFootprint_Wobbuffet[];
+extern const u8 gMonFrontPic_Girafarig[];
+extern const u8 gMonPalette_Girafarig[];
+extern const u8 gMonBackPic_Girafarig[];
+extern const u8 gMonShinyPalette_Girafarig[];
+extern const u8 gMonIcon_Girafarig[];
+extern const u8 gMonFootprint_Girafarig[];
+extern const u8 gMonFrontPic_Pineco[];
+extern const u8 gMonPalette_Pineco[];
+extern const u8 gMonBackPic_Pineco[];
+extern const u8 gMonShinyPalette_Pineco[];
+extern const u8 gMonIcon_Pineco[];
+extern const u8 gMonFootprint_Pineco[];
+extern const u8 gMonFrontPic_Forretress[];
+extern const u8 gMonPalette_Forretress[];
+extern const u8 gMonBackPic_Forretress[];
+extern const u8 gMonShinyPalette_Forretress[];
+extern const u8 gMonIcon_Forretress[];
+extern const u8 gMonFootprint_Forretress[];
+extern const u8 gMonFrontPic_Dunsparce[];
+extern const u8 gMonPalette_Dunsparce[];
+extern const u8 gMonBackPic_Dunsparce[];
+extern const u8 gMonShinyPalette_Dunsparce[];
+extern const u8 gMonIcon_Dunsparce[];
+extern const u8 gMonFootprint_Dunsparce[];
+extern const u8 gMonFrontPic_Gligar[];
+extern const u8 gMonPalette_Gligar[];
+extern const u8 gMonBackPic_Gligar[];
+extern const u8 gMonShinyPalette_Gligar[];
+extern const u8 gMonIcon_Gligar[];
+extern const u8 gMonFootprint_Gligar[];
+extern const u8 gMonFrontPic_Steelix[];
+extern const u8 gMonPalette_Steelix[];
+extern const u8 gMonBackPic_Steelix[];
+extern const u8 gMonShinyPalette_Steelix[];
+extern const u8 gMonIcon_Steelix[];
+extern const u8 gMonFootprint_Steelix[];
+extern const u8 gMonFrontPic_Snubbull[];
+extern const u8 gMonPalette_Snubbull[];
+extern const u8 gMonBackPic_Snubbull[];
+extern const u8 gMonShinyPalette_Snubbull[];
+extern const u8 gMonIcon_Snubbull[];
+extern const u8 gMonFootprint_Snubbull[];
+extern const u8 gMonFrontPic_Granbull[];
+extern const u8 gMonPalette_Granbull[];
+extern const u8 gMonBackPic_Granbull[];
+extern const u8 gMonShinyPalette_Granbull[];
+extern const u8 gMonIcon_Granbull[];
+extern const u8 gMonFootprint_Granbull[];
+extern const u8 gMonFrontPic_Qwilfish[];
+extern const u8 gMonPalette_Qwilfish[];
+extern const u8 gMonBackPic_Qwilfish[];
+extern const u8 gMonShinyPalette_Qwilfish[];
+extern const u8 gMonIcon_Qwilfish[];
+extern const u8 gMonFootprint_Qwilfish[];
+extern const u8 gMonFrontPic_Scizor[];
+extern const u8 gMonPalette_Scizor[];
+extern const u8 gMonBackPic_Scizor[];
+extern const u8 gMonShinyPalette_Scizor[];
+extern const u8 gMonIcon_Scizor[];
+extern const u8 gMonFootprint_Scizor[];
+extern const u8 gMonFrontPic_Shuckle[];
+extern const u8 gMonPalette_Shuckle[];
+extern const u8 gMonBackPic_Shuckle[];
+extern const u8 gMonShinyPalette_Shuckle[];
+extern const u8 gMonIcon_Shuckle[];
+extern const u8 gMonFootprint_Shuckle[];
+extern const u8 gMonFrontPic_Heracross[];
+extern const u8 gMonPalette_Heracross[];
+extern const u8 gMonBackPic_Heracross[];
+extern const u8 gMonShinyPalette_Heracross[];
+extern const u8 gMonIcon_Heracross[];
+extern const u8 gMonFootprint_Heracross[];
+extern const u8 gMonFrontPic_Sneasel[];
+extern const u8 gMonPalette_Sneasel[];
+extern const u8 gMonBackPic_Sneasel[];
+extern const u8 gMonShinyPalette_Sneasel[];
+extern const u8 gMonIcon_Sneasel[];
+extern const u8 gMonFootprint_Sneasel[];
+extern const u8 gMonFrontPic_Teddiursa[];
+extern const u8 gMonPalette_Teddiursa[];
+extern const u8 gMonBackPic_Teddiursa[];
+extern const u8 gMonShinyPalette_Teddiursa[];
+extern const u8 gMonIcon_Teddiursa[];
+extern const u8 gMonFootprint_Teddiursa[];
+extern const u8 gMonFrontPic_Ursaring[];
+extern const u8 gMonPalette_Ursaring[];
+extern const u8 gMonBackPic_Ursaring[];
+extern const u8 gMonShinyPalette_Ursaring[];
+extern const u8 gMonIcon_Ursaring[];
+extern const u8 gMonFootprint_Ursaring[];
+extern const u8 gMonFrontPic_Slugma[];
+extern const u8 gMonPalette_Slugma[];
+extern const u8 gMonBackPic_Slugma[];
+extern const u8 gMonShinyPalette_Slugma[];
+extern const u8 gMonIcon_Slugma[];
+extern const u8 gMonFootprint_Slugma[];
+extern const u8 gMonFrontPic_Magcargo[];
+extern const u8 gMonPalette_Magcargo[];
+extern const u8 gMonBackPic_Magcargo[];
+extern const u8 gMonShinyPalette_Magcargo[];
+extern const u8 gMonIcon_Magcargo[];
+extern const u8 gMonFootprint_Magcargo[];
+extern const u8 gMonFrontPic_Swinub[];
+extern const u8 gMonPalette_Swinub[];
+extern const u8 gMonBackPic_Swinub[];
+extern const u8 gMonShinyPalette_Swinub[];
+extern const u8 gMonIcon_Swinub[];
+extern const u8 gMonFootprint_Swinub[];
+extern const u8 gMonFrontPic_Piloswine[];
+extern const u8 gMonPalette_Piloswine[];
+extern const u8 gMonBackPic_Piloswine[];
+extern const u8 gMonShinyPalette_Piloswine[];
+extern const u8 gMonIcon_Piloswine[];
+extern const u8 gMonFootprint_Piloswine[];
+extern const u8 gMonFrontPic_Corsola[];
+extern const u8 gMonPalette_Corsola[];
+extern const u8 gMonBackPic_Corsola[];
+extern const u8 gMonShinyPalette_Corsola[];
+extern const u8 gMonIcon_Corsola[];
+extern const u8 gMonFootprint_Corsola[];
+extern const u8 gMonFrontPic_Remoraid[];
+extern const u8 gMonPalette_Remoraid[];
+extern const u8 gMonBackPic_Remoraid[];
+extern const u8 gMonShinyPalette_Remoraid[];
+extern const u8 gMonIcon_Remoraid[];
+extern const u8 gMonFootprint_Remoraid[];
+extern const u8 gMonFrontPic_Octillery[];
+extern const u8 gMonPalette_Octillery[];
+extern const u8 gMonBackPic_Octillery[];
+extern const u8 gMonShinyPalette_Octillery[];
+extern const u8 gMonIcon_Octillery[];
+extern const u8 gMonFootprint_Octillery[];
+extern const u8 gMonFrontPic_Delibird[];
+extern const u8 gMonPalette_Delibird[];
+extern const u8 gMonBackPic_Delibird[];
+extern const u8 gMonShinyPalette_Delibird[];
+extern const u8 gMonIcon_Delibird[];
+extern const u8 gMonFootprint_Delibird[];
+extern const u8 gMonFrontPic_Mantine[];
+extern const u8 gMonPalette_Mantine[];
+extern const u8 gMonBackPic_Mantine[];
+extern const u8 gMonShinyPalette_Mantine[];
+extern const u8 gMonIcon_Mantine[];
+extern const u8 gMonFootprint_Mantine[];
+extern const u8 gMonFrontPic_Skarmory[];
+extern const u8 gMonPalette_Skarmory[];
+extern const u8 gMonBackPic_Skarmory[];
+extern const u8 gMonShinyPalette_Skarmory[];
+extern const u8 gMonIcon_Skarmory[];
+extern const u8 gMonFootprint_Skarmory[];
+extern const u8 gMonFrontPic_Houndour[];
+extern const u8 gMonPalette_Houndour[];
+extern const u8 gMonBackPic_Houndour[];
+extern const u8 gMonShinyPalette_Houndour[];
+extern const u8 gMonIcon_Houndour[];
+extern const u8 gMonFootprint_Houndour[];
+extern const u8 gMonFrontPic_Houndoom[];
+extern const u8 gMonPalette_Houndoom[];
+extern const u8 gMonBackPic_Houndoom[];
+extern const u8 gMonShinyPalette_Houndoom[];
+extern const u8 gMonIcon_Houndoom[];
+extern const u8 gMonFootprint_Houndoom[];
+extern const u8 gMonFrontPic_Kingdra[];
+extern const u8 gMonPalette_Kingdra[];
+extern const u8 gMonBackPic_Kingdra[];
+extern const u8 gMonShinyPalette_Kingdra[];
+extern const u8 gMonIcon_Kingdra[];
+extern const u8 gMonFootprint_Kingdra[];
+extern const u8 gMonFrontPic_Phanpy[];
+extern const u8 gMonPalette_Phanpy[];
+extern const u8 gMonBackPic_Phanpy[];
+extern const u8 gMonShinyPalette_Phanpy[];
+extern const u8 gMonIcon_Phanpy[];
+extern const u8 gMonFootprint_Phanpy[];
+extern const u8 gMonFrontPic_Donphan[];
+extern const u8 gMonPalette_Donphan[];
+extern const u8 gMonBackPic_Donphan[];
+extern const u8 gMonShinyPalette_Donphan[];
+extern const u8 gMonIcon_Donphan[];
+extern const u8 gMonFootprint_Donphan[];
+extern const u8 gMonFrontPic_Porygon2[];
+extern const u8 gMonPalette_Porygon2[];
+extern const u8 gMonBackPic_Porygon2[];
+extern const u8 gMonShinyPalette_Porygon2[];
+extern const u8 gMonIcon_Porygon2[];
+extern const u8 gMonFootprint_Porygon2[];
+extern const u8 gMonFrontPic_Stantler[];
+extern const u8 gMonPalette_Stantler[];
+extern const u8 gMonBackPic_Stantler[];
+extern const u8 gMonShinyPalette_Stantler[];
+extern const u8 gMonIcon_Stantler[];
+extern const u8 gMonFootprint_Stantler[];
+extern const u8 gMonFrontPic_Smeargle[];
+extern const u8 gMonPalette_Smeargle[];
+extern const u8 gMonBackPic_Smeargle[];
+extern const u8 gMonShinyPalette_Smeargle[];
+extern const u8 gMonIcon_Smeargle[];
+extern const u8 gMonFootprint_Smeargle[];
+extern const u8 gMonFrontPic_Tyrogue[];
+extern const u8 gMonPalette_Tyrogue[];
+extern const u8 gMonBackPic_Tyrogue[];
+extern const u8 gMonShinyPalette_Tyrogue[];
+extern const u8 gMonIcon_Tyrogue[];
+extern const u8 gMonFootprint_Tyrogue[];
+extern const u8 gMonFrontPic_Hitmontop[];
+extern const u8 gMonPalette_Hitmontop[];
+extern const u8 gMonBackPic_Hitmontop[];
+extern const u8 gMonShinyPalette_Hitmontop[];
+extern const u8 gMonIcon_Hitmontop[];
+extern const u8 gMonFootprint_Hitmontop[];
+extern const u8 gMonFrontPic_Smoochum[];
+extern const u8 gMonPalette_Smoochum[];
+extern const u8 gMonBackPic_Smoochum[];
+extern const u8 gMonShinyPalette_Smoochum[];
+extern const u8 gMonIcon_Smoochum[];
+extern const u8 gMonFootprint_Smoochum[];
+extern const u8 gMonFrontPic_Elekid[];
+extern const u8 gMonPalette_Elekid[];
+extern const u8 gMonBackPic_Elekid[];
+extern const u8 gMonShinyPalette_Elekid[];
+extern const u8 gMonIcon_Elekid[];
+extern const u8 gMonFootprint_Elekid[];
+extern const u8 gMonFrontPic_Magby[];
+extern const u8 gMonPalette_Magby[];
+extern const u8 gMonBackPic_Magby[];
+extern const u8 gMonShinyPalette_Magby[];
+extern const u8 gMonIcon_Magby[];
+extern const u8 gMonFootprint_Magby[];
+extern const u8 gMonFrontPic_Miltank[];
+extern const u8 gMonPalette_Miltank[];
+extern const u8 gMonBackPic_Miltank[];
+extern const u8 gMonShinyPalette_Miltank[];
+extern const u8 gMonIcon_Miltank[];
+extern const u8 gMonFootprint_Miltank[];
+extern const u8 gMonFrontPic_Blissey[];
+extern const u8 gMonPalette_Blissey[];
+extern const u8 gMonBackPic_Blissey[];
+extern const u8 gMonShinyPalette_Blissey[];
+extern const u8 gMonIcon_Blissey[];
+extern const u8 gMonFootprint_Blissey[];
+extern const u8 gMonFrontPic_Raikou[];
+extern const u8 gMonPalette_Raikou[];
+extern const u8 gMonBackPic_Raikou[];
+extern const u8 gMonShinyPalette_Raikou[];
+extern const u8 gMonIcon_Raikou[];
+extern const u8 gMonFootprint_Raikou[];
+extern const u8 gMonFrontPic_Entei[];
+extern const u8 gMonPalette_Entei[];
+extern const u8 gMonBackPic_Entei[];
+extern const u8 gMonShinyPalette_Entei[];
+extern const u8 gMonIcon_Entei[];
+extern const u8 gMonFootprint_Entei[];
+extern const u8 gMonFrontPic_Suicune[];
+extern const u8 gMonPalette_Suicune[];
+extern const u8 gMonBackPic_Suicune[];
+extern const u8 gMonShinyPalette_Suicune[];
+extern const u8 gMonIcon_Suicune[];
+extern const u8 gMonFootprint_Suicune[];
+extern const u8 gMonFrontPic_Larvitar[];
+extern const u8 gMonPalette_Larvitar[];
+extern const u8 gMonBackPic_Larvitar[];
+extern const u8 gMonShinyPalette_Larvitar[];
+extern const u8 gMonIcon_Larvitar[];
+extern const u8 gMonFootprint_Larvitar[];
+extern const u8 gMonFrontPic_Pupitar[];
+extern const u8 gMonPalette_Pupitar[];
+extern const u8 gMonBackPic_Pupitar[];
+extern const u8 gMonShinyPalette_Pupitar[];
+extern const u8 gMonIcon_Pupitar[];
+extern const u8 gMonFootprint_Pupitar[];
+extern const u8 gMonFrontPic_Tyranitar[];
+extern const u8 gMonPalette_Tyranitar[];
+extern const u8 gMonBackPic_Tyranitar[];
+extern const u8 gMonShinyPalette_Tyranitar[];
+extern const u8 gMonIcon_Tyranitar[];
+extern const u8 gMonFootprint_Tyranitar[];
+extern const u8 gMonFrontPic_Lugia[];
+extern const u8 gMonPalette_Lugia[];
+extern const u8 gMonBackPic_Lugia[];
+extern const u8 gMonShinyPalette_Lugia[];
+extern const u8 gMonIcon_Lugia[];
+extern const u8 gMonFootprint_Lugia[];
+extern const u8 gMonFrontPic_HoOh[];
+extern const u8 gMonPalette_HoOh[];
+extern const u8 gMonBackPic_HoOh[];
+extern const u8 gMonShinyPalette_HoOh[];
+extern const u8 gMonIcon_HoOh[];
+extern const u8 gMonFootprint_HoOh[];
+extern const u8 gMonFrontPic_Celebi[];
+extern const u8 gMonPalette_Celebi[];
+extern const u8 gMonBackPic_Celebi[];
+extern const u8 gMonShinyPalette_Celebi[];
+extern const u8 gMonIcon_Celebi[];
+extern const u8 gMonFootprint_Celebi[];
+extern const u8 gMonFrontPic_QuestionMark[];
+extern const u8 gMonPalette_QuestionMark[];
+extern const u8 gMonBackPic_QuestionMark[];
+extern const u8 gMonShinyPalette_QuestionMark[];
+extern const u8 gMonFrontPic_Treecko[];
+extern const u8 gMonPalette_Treecko[];
+extern const u8 gMonBackPic_Treecko[];
+extern const u8 gMonShinyPalette_Treecko[];
+extern const u8 gMonIcon_Treecko[];
+extern const u8 gMonFootprint_Treecko[];
+extern const u8 gMonFrontPic_Grovyle[];
+extern const u8 gMonPalette_Grovyle[];
+extern const u8 gMonBackPic_Grovyle[];
+extern const u8 gMonShinyPalette_Grovyle[];
+extern const u8 gMonIcon_Grovyle[];
+extern const u8 gMonFootprint_Grovyle[];
+extern const u8 gMonFrontPic_Sceptile[];
+extern const u8 gMonPalette_Sceptile[];
+extern const u8 gMonBackPic_Sceptile[];
+extern const u8 gMonShinyPalette_Sceptile[];
+extern const u8 gMonIcon_Sceptile[];
+extern const u8 gMonFootprint_Sceptile[];
+extern const u8 gMonFrontPic_Torchic[];
+extern const u8 gMonPalette_Torchic[];
+extern const u8 gMonBackPic_Torchic[];
+extern const u8 gMonShinyPalette_Torchic[];
+extern const u8 gMonIcon_Torchic[];
+extern const u8 gMonFootprint_Torchic[];
+extern const u8 gMonFrontPic_Combusken[];
+extern const u8 gMonPalette_Combusken[];
+extern const u8 gMonBackPic_Combusken[];
+extern const u8 gMonShinyPalette_Combusken[];
+extern const u8 gMonIcon_Combusken[];
+extern const u8 gMonFootprint_Combusken[];
+extern const u8 gMonFrontPic_Blaziken[];
+extern const u8 gMonPalette_Blaziken[];
+extern const u8 gMonBackPic_Blaziken[];
+extern const u8 gMonShinyPalette_Blaziken[];
+extern const u8 gMonIcon_Blaziken[];
+extern const u8 gMonFootprint_Blaziken[];
+extern const u8 gMonFrontPic_Mudkip[];
+extern const u8 gMonPalette_Mudkip[];
+extern const u8 gMonBackPic_Mudkip[];
+extern const u8 gMonShinyPalette_Mudkip[];
+extern const u8 gMonIcon_Mudkip[];
+extern const u8 gMonFootprint_Mudkip[];
+extern const u8 gMonFrontPic_Marshtomp[];
+extern const u8 gMonPalette_Marshtomp[];
+extern const u8 gMonBackPic_Marshtomp[];
+extern const u8 gMonShinyPalette_Marshtomp[];
+extern const u8 gMonIcon_Marshtomp[];
+extern const u8 gMonFootprint_Marshtomp[];
+extern const u8 gMonFrontPic_Swampert[];
+extern const u8 gMonPalette_Swampert[];
+extern const u8 gMonBackPic_Swampert[];
+extern const u8 gMonShinyPalette_Swampert[];
+extern const u8 gMonIcon_Swampert[];
+extern const u8 gMonFootprint_Swampert[];
+extern const u8 gMonFrontPic_Poochyena[];
+extern const u8 gMonPalette_Poochyena[];
+extern const u8 gMonBackPic_Poochyena[];
+extern const u8 gMonShinyPalette_Poochyena[];
+extern const u8 gMonIcon_Poochyena[];
+extern const u8 gMonFootprint_Poochyena[];
+extern const u8 gMonFrontPic_Mightyena[];
+extern const u8 gMonPalette_Mightyena[];
+extern const u8 gMonBackPic_Mightyena[];
+extern const u8 gMonShinyPalette_Mightyena[];
+extern const u8 gMonIcon_Mightyena[];
+extern const u8 gMonFootprint_Mightyena[];
+extern const u8 gMonFrontPic_Zigzagoon[];
+extern const u8 gMonPalette_Zigzagoon[];
+extern const u8 gMonBackPic_Zigzagoon[];
+extern const u8 gMonShinyPalette_Zigzagoon[];
+extern const u8 gMonIcon_Zigzagoon[];
+extern const u8 gMonFootprint_Zigzagoon[];
+extern const u8 gMonFrontPic_Linoone[];
+extern const u8 gMonPalette_Linoone[];
+extern const u8 gMonBackPic_Linoone[];
+extern const u8 gMonShinyPalette_Linoone[];
+extern const u8 gMonIcon_Linoone[];
+extern const u8 gMonFootprint_Linoone[];
+extern const u8 gMonFrontPic_Wurmple[];
+extern const u8 gMonPalette_Wurmple[];
+extern const u8 gMonBackPic_Wurmple[];
+extern const u8 gMonShinyPalette_Wurmple[];
+extern const u8 gMonIcon_Wurmple[];
+extern const u8 gMonFootprint_Wurmple[];
+extern const u8 gMonFrontPic_Silcoon[];
+extern const u8 gMonPalette_Silcoon[];
+extern const u8 gMonBackPic_Silcoon[];
+extern const u8 gMonShinyPalette_Silcoon[];
+extern const u8 gMonIcon_Silcoon[];
+extern const u8 gMonFootprint_Silcoon[];
+extern const u8 gMonFrontPic_Beautifly[];
+extern const u8 gMonPalette_Beautifly[];
+extern const u8 gMonBackPic_Beautifly[];
+extern const u8 gMonShinyPalette_Beautifly[];
+extern const u8 gMonIcon_Beautifly[];
+extern const u8 gMonFootprint_Beautifly[];
+extern const u8 gMonFrontPic_Cascoon[];
+extern const u8 gMonPalette_Cascoon[];
+extern const u8 gMonBackPic_Cascoon[];
+extern const u8 gMonShinyPalette_Cascoon[];
+extern const u8 gMonIcon_Cascoon[];
+extern const u8 gMonFootprint_Cascoon[];
+extern const u8 gMonFrontPic_Dustox[];
+extern const u8 gMonPalette_Dustox[];
+extern const u8 gMonBackPic_Dustox[];
+extern const u8 gMonShinyPalette_Dustox[];
+extern const u8 gMonIcon_Dustox[];
+extern const u8 gMonFootprint_Dustox[];
+extern const u8 gMonFrontPic_Lotad[];
+extern const u8 gMonPalette_Lotad[];
+extern const u8 gMonBackPic_Lotad[];
+extern const u8 gMonShinyPalette_Lotad[];
+extern const u8 gMonIcon_Lotad[];
+extern const u8 gMonFootprint_Lotad[];
+extern const u8 gMonFrontPic_Lombre[];
+extern const u8 gMonPalette_Lombre[];
+extern const u8 gMonBackPic_Lombre[];
+extern const u8 gMonShinyPalette_Lombre[];
+extern const u8 gMonIcon_Lombre[];
+extern const u8 gMonFootprint_Lombre[];
+extern const u8 gMonFrontPic_Ludicolo[];
+extern const u8 gMonPalette_Ludicolo[];
+extern const u8 gMonBackPic_Ludicolo[];
+extern const u8 gMonShinyPalette_Ludicolo[];
+extern const u8 gMonIcon_Ludicolo[];
+extern const u8 gMonFootprint_Ludicolo[];
+extern const u8 gMonFrontPic_Seedot[];
+extern const u8 gMonPalette_Seedot[];
+extern const u8 gMonBackPic_Seedot[];
+extern const u8 gMonShinyPalette_Seedot[];
+extern const u8 gMonIcon_Seedot[];
+extern const u8 gMonFootprint_Seedot[];
+extern const u8 gMonFrontPic_Nuzleaf[];
+extern const u8 gMonPalette_Nuzleaf[];
+extern const u8 gMonBackPic_Nuzleaf[];
+extern const u8 gMonShinyPalette_Nuzleaf[];
+extern const u8 gMonIcon_Nuzleaf[];
+extern const u8 gMonFootprint_Nuzleaf[];
+extern const u8 gMonFrontPic_Shiftry[];
+extern const u8 gMonPalette_Shiftry[];
+extern const u8 gMonBackPic_Shiftry[];
+extern const u8 gMonShinyPalette_Shiftry[];
+extern const u8 gMonIcon_Shiftry[];
+extern const u8 gMonFootprint_Shiftry[];
+extern const u8 gMonFrontPic_Nincada[];
+extern const u8 gMonPalette_Nincada[];
+extern const u8 gMonBackPic_Nincada[];
+extern const u8 gMonShinyPalette_Nincada[];
+extern const u8 gMonIcon_Nincada[];
+extern const u8 gMonFootprint_Nincada[];
+extern const u8 gMonFrontPic_Ninjask[];
+extern const u8 gMonPalette_Ninjask[];
+extern const u8 gMonBackPic_Ninjask[];
+extern const u8 gMonShinyPalette_Ninjask[];
+extern const u8 gMonIcon_Ninjask[];
+extern const u8 gMonFootprint_Ninjask[];
+extern const u8 gMonFrontPic_Shedinja[];
+extern const u8 gMonPalette_Shedinja[];
+extern const u8 gMonBackPic_Shedinja[];
+extern const u8 gMonShinyPalette_Shedinja[];
+extern const u8 gMonIcon_Shedinja[];
+extern const u8 gMonFootprint_Shedinja[];
+extern const u8 gMonFrontPic_Taillow[];
+extern const u8 gMonPalette_Taillow[];
+extern const u8 gMonBackPic_Taillow[];
+extern const u8 gMonShinyPalette_Taillow[];
+extern const u8 gMonIcon_Taillow[];
+extern const u8 gMonFootprint_Taillow[];
+extern const u8 gMonFrontPic_Swellow[];
+extern const u8 gMonPalette_Swellow[];
+extern const u8 gMonBackPic_Swellow[];
+extern const u8 gMonShinyPalette_Swellow[];
+extern const u8 gMonIcon_Swellow[];
+extern const u8 gMonFootprint_Swellow[];
+extern const u8 gMonFrontPic_Shroomish[];
+extern const u8 gMonPalette_Shroomish[];
+extern const u8 gMonBackPic_Shroomish[];
+extern const u8 gMonShinyPalette_Shroomish[];
+extern const u8 gMonIcon_Shroomish[];
+extern const u8 gMonFootprint_Shroomish[];
+extern const u8 gMonFrontPic_Breloom[];
+extern const u8 gMonPalette_Breloom[];
+extern const u8 gMonBackPic_Breloom[];
+extern const u8 gMonShinyPalette_Breloom[];
+extern const u8 gMonIcon_Breloom[];
+extern const u8 gMonFootprint_Breloom[];
+extern const u8 gMonFrontPic_Spinda[];
+extern const u8 gMonPalette_Spinda[];
+extern const u8 gMonBackPic_Spinda[];
+extern const u8 gMonShinyPalette_Spinda[];
+extern const u8 gMonIcon_Spinda[];
+extern const u8 gMonFootprint_Spinda[];
+extern const u8 gMonFrontPic_Wingull[];
+extern const u8 gMonPalette_Wingull[];
+extern const u8 gMonBackPic_Wingull[];
+extern const u8 gMonShinyPalette_Wingull[];
+extern const u8 gMonIcon_Wingull[];
+extern const u8 gMonFootprint_Wingull[];
+extern const u8 gMonFrontPic_Pelipper[];
+extern const u8 gMonPalette_Pelipper[];
+extern const u8 gMonBackPic_Pelipper[];
+extern const u8 gMonShinyPalette_Pelipper[];
+extern const u8 gMonIcon_Pelipper[];
+extern const u8 gMonFootprint_Pelipper[];
+extern const u8 gMonFrontPic_Surskit[];
+extern const u8 gMonPalette_Surskit[];
+extern const u8 gMonBackPic_Surskit[];
+extern const u8 gMonShinyPalette_Surskit[];
+extern const u8 gMonIcon_Surskit[];
+extern const u8 gMonFootprint_Surskit[];
+extern const u8 gMonFrontPic_Masquerain[];
+extern const u8 gMonPalette_Masquerain[];
+extern const u8 gMonBackPic_Masquerain[];
+extern const u8 gMonShinyPalette_Masquerain[];
+extern const u8 gMonIcon_Masquerain[];
+extern const u8 gMonFootprint_Masquerain[];
+extern const u8 gMonFrontPic_Wailmer[];
+extern const u8 gMonPalette_Wailmer[];
+extern const u8 gMonBackPic_Wailmer[];
+extern const u8 gMonShinyPalette_Wailmer[];
+extern const u8 gMonIcon_Wailmer[];
+extern const u8 gMonFootprint_Wailmer[];
+extern const u8 gMonFrontPic_Wailord[];
+extern const u8 gMonPalette_Wailord[];
+extern const u8 gMonBackPic_Wailord[];
+extern const u8 gMonShinyPalette_Wailord[];
+extern const u8 gMonIcon_Wailord[];
+extern const u8 gMonFootprint_Wailord[];
+extern const u8 gMonFrontPic_Skitty[];
+extern const u8 gMonPalette_Skitty[];
+extern const u8 gMonBackPic_Skitty[];
+extern const u8 gMonShinyPalette_Skitty[];
+extern const u8 gMonIcon_Skitty[];
+extern const u8 gMonFootprint_Skitty[];
+extern const u8 gMonFrontPic_Delcatty[];
+extern const u8 gMonPalette_Delcatty[];
+extern const u8 gMonBackPic_Delcatty[];
+extern const u8 gMonShinyPalette_Delcatty[];
+extern const u8 gMonIcon_Delcatty[];
+extern const u8 gMonFootprint_Delcatty[];
+extern const u8 gMonFrontPic_Kecleon[];
+extern const u8 gMonPalette_Kecleon[];
+extern const u8 gMonBackPic_Kecleon[];
+extern const u8 gMonShinyPalette_Kecleon[];
+extern const u8 gMonIcon_Kecleon[];
+extern const u8 gMonFootprint_Kecleon[];
+extern const u8 gMonFrontPic_Baltoy[];
+extern const u8 gMonPalette_Baltoy[];
+extern const u8 gMonBackPic_Baltoy[];
+extern const u8 gMonShinyPalette_Baltoy[];
+extern const u8 gMonIcon_Baltoy[];
+extern const u8 gMonFootprint_Baltoy[];
+extern const u8 gMonFrontPic_Claydol[];
+extern const u8 gMonPalette_Claydol[];
+extern const u8 gMonBackPic_Claydol[];
+extern const u8 gMonShinyPalette_Claydol[];
+extern const u8 gMonIcon_Claydol[];
+extern const u8 gMonFootprint_Claydol[];
+extern const u8 gMonFrontPic_Nosepass[];
+extern const u8 gMonPalette_Nosepass[];
+extern const u8 gMonBackPic_Nosepass[];
+extern const u8 gMonShinyPalette_Nosepass[];
+extern const u8 gMonIcon_Nosepass[];
+extern const u8 gMonFootprint_Nosepass[];
+extern const u8 gMonFrontPic_Torkoal[];
+extern const u8 gMonPalette_Torkoal[];
+extern const u8 gMonBackPic_Torkoal[];
+extern const u8 gMonShinyPalette_Torkoal[];
+extern const u8 gMonIcon_Torkoal[];
+extern const u8 gMonFootprint_Torkoal[];
+extern const u8 gMonFrontPic_Sableye[];
+extern const u8 gMonPalette_Sableye[];
+extern const u8 gMonBackPic_Sableye[];
+extern const u8 gMonShinyPalette_Sableye[];
+extern const u8 gMonIcon_Sableye[];
+extern const u8 gMonFootprint_Sableye[];
+extern const u8 gMonFrontPic_Barboach[];
+extern const u8 gMonPalette_Barboach[];
+extern const u8 gMonBackPic_Barboach[];
+extern const u8 gMonShinyPalette_Barboach[];
+extern const u8 gMonIcon_Barboach[];
+extern const u8 gMonFootprint_Barboach[];
+extern const u8 gMonFrontPic_Whiscash[];
+extern const u8 gMonPalette_Whiscash[];
+extern const u8 gMonBackPic_Whiscash[];
+extern const u8 gMonShinyPalette_Whiscash[];
+extern const u8 gMonIcon_Whiscash[];
+extern const u8 gMonFootprint_Whiscash[];
+extern const u8 gMonFrontPic_Luvdisc[];
+extern const u8 gMonPalette_Luvdisc[];
+extern const u8 gMonBackPic_Luvdisc[];
+extern const u8 gMonShinyPalette_Luvdisc[];
+extern const u8 gMonIcon_Luvdisc[];
+extern const u8 gMonFootprint_Luvdisc[];
+extern const u8 gMonFrontPic_Corphish[];
+extern const u8 gMonPalette_Corphish[];
+extern const u8 gMonBackPic_Corphish[];
+extern const u8 gMonShinyPalette_Corphish[];
+extern const u8 gMonIcon_Corphish[];
+extern const u8 gMonFootprint_Corphish[];
+extern const u8 gMonFrontPic_Crawdaunt[];
+extern const u8 gMonPalette_Crawdaunt[];
+extern const u8 gMonBackPic_Crawdaunt[];
+extern const u8 gMonShinyPalette_Crawdaunt[];
+extern const u8 gMonIcon_Crawdaunt[];
+extern const u8 gMonFootprint_Crawdaunt[];
+extern const u8 gMonFrontPic_Feebas[];
+extern const u8 gMonPalette_Feebas[];
+extern const u8 gMonBackPic_Feebas[];
+extern const u8 gMonShinyPalette_Feebas[];
+extern const u8 gMonIcon_Feebas[];
+extern const u8 gMonFootprint_Feebas[];
+extern const u8 gMonFrontPic_Milotic[];
+extern const u8 gMonPalette_Milotic[];
+extern const u8 gMonBackPic_Milotic[];
+extern const u8 gMonShinyPalette_Milotic[];
+extern const u8 gMonIcon_Milotic[];
+extern const u8 gMonFootprint_Milotic[];
+extern const u8 gMonFrontPic_Carvanha[];
+extern const u8 gMonPalette_Carvanha[];
+extern const u8 gMonBackPic_Carvanha[];
+extern const u8 gMonShinyPalette_Carvanha[];
+extern const u8 gMonIcon_Carvanha[];
+extern const u8 gMonFootprint_Carvanha[];
+extern const u8 gMonFrontPic_Sharpedo[];
+extern const u8 gMonPalette_Sharpedo[];
+extern const u8 gMonBackPic_Sharpedo[];
+extern const u8 gMonShinyPalette_Sharpedo[];
+extern const u8 gMonIcon_Sharpedo[];
+extern const u8 gMonFootprint_Sharpedo[];
+extern const u8 gMonFrontPic_Trapinch[];
+extern const u8 gMonPalette_Trapinch[];
+extern const u8 gMonBackPic_Trapinch[];
+extern const u8 gMonShinyPalette_Trapinch[];
+extern const u8 gMonIcon_Trapinch[];
+extern const u8 gMonFootprint_Trapinch[];
+extern const u8 gMonFrontPic_Vibrava[];
+extern const u8 gMonPalette_Vibrava[];
+extern const u8 gMonBackPic_Vibrava[];
+extern const u8 gMonShinyPalette_Vibrava[];
+extern const u8 gMonIcon_Vibrava[];
+extern const u8 gMonFootprint_Vibrava[];
+extern const u8 gMonFrontPic_Flygon[];
+extern const u8 gMonPalette_Flygon[];
+extern const u8 gMonBackPic_Flygon[];
+extern const u8 gMonShinyPalette_Flygon[];
+extern const u8 gMonIcon_Flygon[];
+extern const u8 gMonFootprint_Flygon[];
+extern const u8 gMonFrontPic_Makuhita[];
+extern const u8 gMonPalette_Makuhita[];
+extern const u8 gMonBackPic_Makuhita[];
+extern const u8 gMonShinyPalette_Makuhita[];
+extern const u8 gMonIcon_Makuhita[];
+extern const u8 gMonFootprint_Makuhita[];
+extern const u8 gMonFrontPic_Hariyama[];
+extern const u8 gMonPalette_Hariyama[];
+extern const u8 gMonBackPic_Hariyama[];
+extern const u8 gMonShinyPalette_Hariyama[];
+extern const u8 gMonIcon_Hariyama[];
+extern const u8 gMonFootprint_Hariyama[];
+extern const u8 gMonFrontPic_Electrike[];
+extern const u8 gMonPalette_Electrike[];
+extern const u8 gMonBackPic_Electrike[];
+extern const u8 gMonShinyPalette_Electrike[];
+extern const u8 gMonIcon_Electrike[];
+extern const u8 gMonFootprint_Electrike[];
+extern const u8 gMonFrontPic_Manectric[];
+extern const u8 gMonPalette_Manectric[];
+extern const u8 gMonBackPic_Manectric[];
+extern const u8 gMonShinyPalette_Manectric[];
+extern const u8 gMonIcon_Manectric[];
+extern const u8 gMonFootprint_Manectric[];
+extern const u8 gMonFrontPic_Numel[];
+extern const u8 gMonPalette_Numel[];
+extern const u8 gMonBackPic_Numel[];
+extern const u8 gMonShinyPalette_Numel[];
+extern const u8 gMonIcon_Numel[];
+extern const u8 gMonFootprint_Numel[];
+extern const u8 gMonFrontPic_Camerupt[];
+extern const u8 gMonPalette_Camerupt[];
+extern const u8 gMonBackPic_Camerupt[];
+extern const u8 gMonShinyPalette_Camerupt[];
+extern const u8 gMonIcon_Camerupt[];
+extern const u8 gMonFootprint_Camerupt[];
+extern const u8 gMonFrontPic_Spheal[];
+extern const u8 gMonPalette_Spheal[];
+extern const u8 gMonBackPic_Spheal[];
+extern const u8 gMonShinyPalette_Spheal[];
+extern const u8 gMonIcon_Spheal[];
+extern const u8 gMonFootprint_Spheal[];
+extern const u8 gMonFrontPic_Sealeo[];
+extern const u8 gMonPalette_Sealeo[];
+extern const u8 gMonBackPic_Sealeo[];
+extern const u8 gMonShinyPalette_Sealeo[];
+extern const u8 gMonIcon_Sealeo[];
+extern const u8 gMonFootprint_Sealeo[];
+extern const u8 gMonFrontPic_Walrein[];
+extern const u8 gMonPalette_Walrein[];
+extern const u8 gMonBackPic_Walrein[];
+extern const u8 gMonShinyPalette_Walrein[];
+extern const u8 gMonIcon_Walrein[];
+extern const u8 gMonFootprint_Walrein[];
+extern const u8 gMonFrontPic_Cacnea[];
+extern const u8 gMonPalette_Cacnea[];
+extern const u8 gMonBackPic_Cacnea[];
+extern const u8 gMonShinyPalette_Cacnea[];
+extern const u8 gMonIcon_Cacnea[];
+extern const u8 gMonFootprint_Cacnea[];
+extern const u8 gMonFrontPic_Cacturne[];
+extern const u8 gMonPalette_Cacturne[];
+extern const u8 gMonBackPic_Cacturne[];
+extern const u8 gMonShinyPalette_Cacturne[];
+extern const u8 gMonIcon_Cacturne[];
+extern const u8 gMonFootprint_Cacturne[];
+extern const u8 gMonFrontPic_Snorunt[];
+extern const u8 gMonPalette_Snorunt[];
+extern const u8 gMonBackPic_Snorunt[];
+extern const u8 gMonShinyPalette_Snorunt[];
+extern const u8 gMonIcon_Snorunt[];
+extern const u8 gMonFootprint_Snorunt[];
+extern const u8 gMonFrontPic_Glalie[];
+extern const u8 gMonPalette_Glalie[];
+extern const u8 gMonBackPic_Glalie[];
+extern const u8 gMonShinyPalette_Glalie[];
+extern const u8 gMonIcon_Glalie[];
+extern const u8 gMonFootprint_Glalie[];
+extern const u8 gMonFrontPic_Lunatone[];
+extern const u8 gMonPalette_Lunatone[];
+extern const u8 gMonBackPic_Lunatone[];
+extern const u8 gMonShinyPalette_Lunatone[];
+extern const u8 gMonIcon_Lunatone[];
+extern const u8 gMonFootprint_Lunatone[];
+extern const u8 gMonFrontPic_Solrock[];
+extern const u8 gMonPalette_Solrock[];
+extern const u8 gMonBackPic_Solrock[];
+extern const u8 gMonShinyPalette_Solrock[];
+extern const u8 gMonIcon_Solrock[];
+extern const u8 gMonFootprint_Solrock[];
+extern const u8 gMonFrontPic_Azurill[];
+extern const u8 gMonPalette_Azurill[];
+extern const u8 gMonBackPic_Azurill[];
+extern const u8 gMonShinyPalette_Azurill[];
+extern const u8 gMonIcon_Azurill[];
+extern const u8 gMonFootprint_Azurill[];
+extern const u8 gMonFrontPic_Spoink[];
+extern const u8 gMonPalette_Spoink[];
+extern const u8 gMonBackPic_Spoink[];
+extern const u8 gMonShinyPalette_Spoink[];
+extern const u8 gMonIcon_Spoink[];
+extern const u8 gMonFootprint_Spoink[];
+extern const u8 gMonFrontPic_Grumpig[];
+extern const u8 gMonPalette_Grumpig[];
+extern const u8 gMonBackPic_Grumpig[];
+extern const u8 gMonShinyPalette_Grumpig[];
+extern const u8 gMonIcon_Grumpig[];
+extern const u8 gMonFootprint_Grumpig[];
+extern const u8 gMonFrontPic_Plusle[];
+extern const u8 gMonPalette_Plusle[];
+extern const u8 gMonBackPic_Plusle[];
+extern const u8 gMonShinyPalette_Plusle[];
+extern const u8 gMonIcon_Plusle[];
+extern const u8 gMonFootprint_Plusle[];
+extern const u8 gMonFrontPic_Minun[];
+extern const u8 gMonPalette_Minun[];
+extern const u8 gMonBackPic_Minun[];
+extern const u8 gMonShinyPalette_Minun[];
+extern const u8 gMonIcon_Minun[];
+extern const u8 gMonFootprint_Minun[];
+extern const u8 gMonFrontPic_Mawile[];
+extern const u8 gMonPalette_Mawile[];
+extern const u8 gMonBackPic_Mawile[];
+extern const u8 gMonShinyPalette_Mawile[];
+extern const u8 gMonIcon_Mawile[];
+extern const u8 gMonFootprint_Mawile[];
+extern const u8 gMonFrontPic_Meditite[];
+extern const u8 gMonPalette_Meditite[];
+extern const u8 gMonBackPic_Meditite[];
+extern const u8 gMonShinyPalette_Meditite[];
+extern const u8 gMonIcon_Meditite[];
+extern const u8 gMonFootprint_Meditite[];
+extern const u8 gMonFrontPic_Medicham[];
+extern const u8 gMonPalette_Medicham[];
+extern const u8 gMonBackPic_Medicham[];
+extern const u8 gMonShinyPalette_Medicham[];
+extern const u8 gMonIcon_Medicham[];
+extern const u8 gMonFootprint_Medicham[];
+extern const u8 gMonFrontPic_Swablu[];
+extern const u8 gMonPalette_Swablu[];
+extern const u8 gMonBackPic_Swablu[];
+extern const u8 gMonShinyPalette_Swablu[];
+extern const u8 gMonIcon_Swablu[];
+extern const u8 gMonFootprint_Swablu[];
+extern const u8 gMonFrontPic_Altaria[];
+extern const u8 gMonPalette_Altaria[];
+extern const u8 gMonBackPic_Altaria[];
+extern const u8 gMonShinyPalette_Altaria[];
+extern const u8 gMonIcon_Altaria[];
+extern const u8 gMonFootprint_Altaria[];
+extern const u8 gMonFrontPic_Wynaut[];
+extern const u8 gMonPalette_Wynaut[];
+extern const u8 gMonBackPic_Wynaut[];
+extern const u8 gMonShinyPalette_Wynaut[];
+extern const u8 gMonIcon_Wynaut[];
+extern const u8 gMonFootprint_Wynaut[];
+extern const u8 gMonFrontPic_Duskull[];
+extern const u8 gMonPalette_Duskull[];
+extern const u8 gMonBackPic_Duskull[];
+extern const u8 gMonShinyPalette_Duskull[];
+extern const u8 gMonIcon_Duskull[];
+extern const u8 gMonFootprint_Duskull[];
+extern const u8 gMonFrontPic_Dusclops[];
+extern const u8 gMonPalette_Dusclops[];
+extern const u8 gMonBackPic_Dusclops[];
+extern const u8 gMonShinyPalette_Dusclops[];
+extern const u8 gMonIcon_Dusclops[];
+extern const u8 gMonFootprint_Dusclops[];
+extern const u8 gMonFrontPic_Roselia[];
+extern const u8 gMonPalette_Roselia[];
+extern const u8 gMonBackPic_Roselia[];
+extern const u8 gMonShinyPalette_Roselia[];
+extern const u8 gMonIcon_Roselia[];
+extern const u8 gMonFootprint_Roselia[];
+extern const u8 gMonFrontPic_Slakoth[];
+extern const u8 gMonPalette_Slakoth[];
+extern const u8 gMonBackPic_Slakoth[];
+extern const u8 gMonShinyPalette_Slakoth[];
+extern const u8 gMonIcon_Slakoth[];
+extern const u8 gMonFootprint_Slakoth[];
+extern const u8 gMonFrontPic_Vigoroth[];
+extern const u8 gMonPalette_Vigoroth[];
+extern const u8 gMonBackPic_Vigoroth[];
+extern const u8 gMonShinyPalette_Vigoroth[];
+extern const u8 gMonIcon_Vigoroth[];
+extern const u8 gMonFootprint_Vigoroth[];
+extern const u8 gMonFrontPic_Slaking[];
+extern const u8 gMonPalette_Slaking[];
+extern const u8 gMonBackPic_Slaking[];
+extern const u8 gMonShinyPalette_Slaking[];
+extern const u8 gMonIcon_Slaking[];
+extern const u8 gMonFootprint_Slaking[];
+extern const u8 gMonFrontPic_Gulpin[];
+extern const u8 gMonPalette_Gulpin[];
+extern const u8 gMonBackPic_Gulpin[];
+extern const u8 gMonShinyPalette_Gulpin[];
+extern const u8 gMonIcon_Gulpin[];
+extern const u8 gMonFootprint_Gulpin[];
+extern const u8 gMonFrontPic_Swalot[];
+extern const u8 gMonPalette_Swalot[];
+extern const u8 gMonBackPic_Swalot[];
+extern const u8 gMonShinyPalette_Swalot[];
+extern const u8 gMonIcon_Swalot[];
+extern const u8 gMonFootprint_Swalot[];
+extern const u8 gMonFrontPic_Tropius[];
+extern const u8 gMonPalette_Tropius[];
+extern const u8 gMonBackPic_Tropius[];
+extern const u8 gMonShinyPalette_Tropius[];
+extern const u8 gMonIcon_Tropius[];
+extern const u8 gMonFootprint_Tropius[];
+extern const u8 gMonFrontPic_Whismur[];
+extern const u8 gMonPalette_Whismur[];
+extern const u8 gMonBackPic_Whismur[];
+extern const u8 gMonShinyPalette_Whismur[];
+extern const u8 gMonIcon_Whismur[];
+extern const u8 gMonFootprint_Whismur[];
+extern const u8 gMonFrontPic_Loudred[];
+extern const u8 gMonPalette_Loudred[];
+extern const u8 gMonBackPic_Loudred[];
+extern const u8 gMonShinyPalette_Loudred[];
+extern const u8 gMonIcon_Loudred[];
+extern const u8 gMonFootprint_Loudred[];
+extern const u8 gMonFrontPic_Exploud[];
+extern const u8 gMonPalette_Exploud[];
+extern const u8 gMonBackPic_Exploud[];
+extern const u8 gMonShinyPalette_Exploud[];
+extern const u8 gMonIcon_Exploud[];
+extern const u8 gMonFootprint_Exploud[];
+extern const u8 gMonFrontPic_Clamperl[];
+extern const u8 gMonPalette_Clamperl[];
+extern const u8 gMonBackPic_Clamperl[];
+extern const u8 gMonShinyPalette_Clamperl[];
+extern const u8 gMonIcon_Clamperl[];
+extern const u8 gMonFootprint_Clamperl[];
+extern const u8 gMonFrontPic_Huntail[];
+extern const u8 gMonPalette_Huntail[];
+extern const u8 gMonBackPic_Huntail[];
+extern const u8 gMonShinyPalette_Huntail[];
+extern const u8 gMonIcon_Huntail[];
+extern const u8 gMonFootprint_Huntail[];
+extern const u8 gMonFrontPic_Gorebyss[];
+extern const u8 gMonPalette_Gorebyss[];
+extern const u8 gMonBackPic_Gorebyss[];
+extern const u8 gMonShinyPalette_Gorebyss[];
+extern const u8 gMonIcon_Gorebyss[];
+extern const u8 gMonFootprint_Gorebyss[];
+extern const u8 gMonFrontPic_Absol[];
+extern const u8 gMonPalette_Absol[];
+extern const u8 gMonBackPic_Absol[];
+extern const u8 gMonShinyPalette_Absol[];
+extern const u8 gMonIcon_Absol[];
+extern const u8 gMonFootprint_Absol[];
+extern const u8 gMonFrontPic_Shuppet[];
+extern const u8 gMonPalette_Shuppet[];
+extern const u8 gMonBackPic_Shuppet[];
+extern const u8 gMonShinyPalette_Shuppet[];
+extern const u8 gMonIcon_Shuppet[];
+extern const u8 gMonFootprint_Shuppet[];
+extern const u8 gMonFrontPic_Banette[];
+extern const u8 gMonPalette_Banette[];
+extern const u8 gMonBackPic_Banette[];
+extern const u8 gMonShinyPalette_Banette[];
+extern const u8 gMonIcon_Banette[];
+extern const u8 gMonFootprint_Banette[];
+extern const u8 gMonFrontPic_Seviper[];
+extern const u8 gMonPalette_Seviper[];
+extern const u8 gMonBackPic_Seviper[];
+extern const u8 gMonShinyPalette_Seviper[];
+extern const u8 gMonIcon_Seviper[];
+extern const u8 gMonFootprint_Seviper[];
+extern const u8 gMonFrontPic_Zangoose[];
+extern const u8 gMonPalette_Zangoose[];
+extern const u8 gMonBackPic_Zangoose[];
+extern const u8 gMonShinyPalette_Zangoose[];
+extern const u8 gMonIcon_Zangoose[];
+extern const u8 gMonFootprint_Zangoose[];
+extern const u8 gMonFrontPic_Relicanth[];
+extern const u8 gMonPalette_Relicanth[];
+extern const u8 gMonBackPic_Relicanth[];
+extern const u8 gMonShinyPalette_Relicanth[];
+extern const u8 gMonIcon_Relicanth[];
+extern const u8 gMonFootprint_Relicanth[];
+extern const u8 gMonFrontPic_Aron[];
+extern const u8 gMonPalette_Aron[];
+extern const u8 gMonBackPic_Aron[];
+extern const u8 gMonShinyPalette_Aron[];
+extern const u8 gMonIcon_Aron[];
+extern const u8 gMonFootprint_Aron[];
+extern const u8 gMonFrontPic_Lairon[];
+extern const u8 gMonPalette_Lairon[];
+extern const u8 gMonBackPic_Lairon[];
+extern const u8 gMonShinyPalette_Lairon[];
+extern const u8 gMonIcon_Lairon[];
+extern const u8 gMonFootprint_Lairon[];
+extern const u8 gMonFrontPic_Aggron[];
+extern const u8 gMonPalette_Aggron[];
+extern const u8 gMonBackPic_Aggron[];
+extern const u8 gMonShinyPalette_Aggron[];
+extern const u8 gMonIcon_Aggron[];
+extern const u8 gMonFootprint_Aggron[];
+extern const u8 gMonFrontPic_Castform[];
+extern const u8 gMonPalette_Castform[];
+extern const u8 gMonBackPic_Castform[];
+extern const u8 gMonShinyPalette_Castform[];
+extern const u8 gMonIcon_Castform[];
+extern const u8 gMonFootprint_Castform[];
+extern const u8 gMonFrontPic_Volbeat[];
+extern const u8 gMonPalette_Volbeat[];
+extern const u8 gMonBackPic_Volbeat[];
+extern const u8 gMonShinyPalette_Volbeat[];
+extern const u8 gMonIcon_Volbeat[];
+extern const u8 gMonFootprint_Volbeat[];
+extern const u8 gMonFrontPic_Illumise[];
+extern const u8 gMonPalette_Illumise[];
+extern const u8 gMonBackPic_Illumise[];
+extern const u8 gMonShinyPalette_Illumise[];
+extern const u8 gMonIcon_Illumise[];
+extern const u8 gMonFootprint_Illumise[];
+extern const u8 gMonFrontPic_Lileep[];
+extern const u8 gMonPalette_Lileep[];
+extern const u8 gMonBackPic_Lileep[];
+extern const u8 gMonShinyPalette_Lileep[];
+extern const u8 gMonIcon_Lileep[];
+extern const u8 gMonFootprint_Lileep[];
+extern const u8 gMonFrontPic_Cradily[];
+extern const u8 gMonPalette_Cradily[];
+extern const u8 gMonBackPic_Cradily[];
+extern const u8 gMonShinyPalette_Cradily[];
+extern const u8 gMonIcon_Cradily[];
+extern const u8 gMonFootprint_Cradily[];
+extern const u8 gMonFrontPic_Anorith[];
+extern const u8 gMonPalette_Anorith[];
+extern const u8 gMonBackPic_Anorith[];
+extern const u8 gMonShinyPalette_Anorith[];
+extern const u8 gMonIcon_Anorith[];
+extern const u8 gMonFootprint_Anorith[];
+extern const u8 gMonFrontPic_Armaldo[];
+extern const u8 gMonPalette_Armaldo[];
+extern const u8 gMonBackPic_Armaldo[];
+extern const u8 gMonShinyPalette_Armaldo[];
+extern const u8 gMonIcon_Armaldo[];
+extern const u8 gMonFootprint_Armaldo[];
+extern const u8 gMonFrontPic_Ralts[];
+extern const u8 gMonPalette_Ralts[];
+extern const u8 gMonBackPic_Ralts[];
+extern const u8 gMonShinyPalette_Ralts[];
+extern const u8 gMonIcon_Ralts[];
+extern const u8 gMonFootprint_Ralts[];
+extern const u8 gMonFrontPic_Kirlia[];
+extern const u8 gMonPalette_Kirlia[];
+extern const u8 gMonBackPic_Kirlia[];
+extern const u8 gMonShinyPalette_Kirlia[];
+extern const u8 gMonIcon_Kirlia[];
+extern const u8 gMonFootprint_Kirlia[];
+extern const u8 gMonFrontPic_Gardevoir[];
+extern const u8 gMonPalette_Gardevoir[];
+extern const u8 gMonBackPic_Gardevoir[];
+extern const u8 gMonShinyPalette_Gardevoir[];
+extern const u8 gMonIcon_Gardevoir[];
+extern const u8 gMonFootprint_Gardevoir[];
+extern const u8 gMonFrontPic_Bagon[];
+extern const u8 gMonPalette_Bagon[];
+extern const u8 gMonBackPic_Bagon[];
+extern const u8 gMonShinyPalette_Bagon[];
+extern const u8 gMonIcon_Bagon[];
+extern const u8 gMonFootprint_Bagon[];
+extern const u8 gMonFrontPic_Shelgon[];
+extern const u8 gMonPalette_Shelgon[];
+extern const u8 gMonBackPic_Shelgon[];
+extern const u8 gMonShinyPalette_Shelgon[];
+extern const u8 gMonIcon_Shelgon[];
+extern const u8 gMonFootprint_Shelgon[];
+extern const u8 gMonFrontPic_Salamence[];
+extern const u8 gMonPalette_Salamence[];
+extern const u8 gMonBackPic_Salamence[];
+extern const u8 gMonShinyPalette_Salamence[];
+extern const u8 gMonIcon_Salamence[];
+extern const u8 gMonFootprint_Salamence[];
+extern const u8 gMonFrontPic_Beldum[];
+extern const u8 gMonPalette_Beldum[];
+extern const u8 gMonBackPic_Beldum[];
+extern const u8 gMonShinyPalette_Beldum[];
+extern const u8 gMonIcon_Beldum[];
+extern const u8 gMonFootprint_Beldum[];
+extern const u8 gMonFrontPic_Metang[];
+extern const u8 gMonPalette_Metang[];
+extern const u8 gMonBackPic_Metang[];
+extern const u8 gMonShinyPalette_Metang[];
+extern const u8 gMonIcon_Metang[];
+extern const u8 gMonFootprint_Metang[];
+extern const u8 gMonFrontPic_Metagross[];
+extern const u8 gMonPalette_Metagross[];
+extern const u8 gMonBackPic_Metagross[];
+extern const u8 gMonShinyPalette_Metagross[];
+extern const u8 gMonIcon_Metagross[];
+extern const u8 gMonFootprint_Metagross[];
+extern const u8 gMonFrontPic_Regirock[];
+extern const u8 gMonPalette_Regirock[];
+extern const u8 gMonBackPic_Regirock[];
+extern const u8 gMonShinyPalette_Regirock[];
+extern const u8 gMonIcon_Regirock[];
+extern const u8 gMonFootprint_Regirock[];
+extern const u8 gMonFrontPic_Regice[];
+extern const u8 gMonPalette_Regice[];
+extern const u8 gMonBackPic_Regice[];
+extern const u8 gMonShinyPalette_Regice[];
+extern const u8 gMonIcon_Regice[];
+extern const u8 gMonFootprint_Regice[];
+extern const u8 gMonFrontPic_Registeel[];
+extern const u8 gMonPalette_Registeel[];
+extern const u8 gMonBackPic_Registeel[];
+extern const u8 gMonShinyPalette_Registeel[];
+extern const u8 gMonIcon_Registeel[];
+extern const u8 gMonFootprint_Registeel[];
+extern const u8 gMonFrontPic_Kyogre[];
+extern const u8 gMonPalette_Kyogre[];
+extern const u8 gMonBackPic_Kyogre[];
+extern const u8 gMonShinyPalette_Kyogre[];
+extern const u8 gMonIcon_Kyogre[];
+extern const u8 gMonFootprint_Kyogre[];
+extern const u8 gMonFrontPic_Groudon[];
+extern const u8 gMonPalette_Groudon[];
+extern const u8 gMonBackPic_Groudon[];
+extern const u8 gMonShinyPalette_Groudon[];
+extern const u8 gMonIcon_Groudon[];
+extern const u8 gMonFootprint_Groudon[];
+extern const u8 gMonFrontPic_Rayquaza[];
+extern const u8 gMonPalette_Rayquaza[];
+extern const u8 gMonBackPic_Rayquaza[];
+extern const u8 gMonShinyPalette_Rayquaza[];
+extern const u8 gMonIcon_Rayquaza[];
+extern const u8 gMonFootprint_Rayquaza[];
+extern const u8 gMonFrontPic_Latias[];
+extern const u8 gMonPalette_Latias[];
+extern const u8 gMonBackPic_Latias[];
+extern const u8 gMonShinyPalette_Latias[];
+extern const u8 gMonIcon_Latias[];
+extern const u8 gMonFootprint_Latias[];
+extern const u8 gMonFrontPic_Latios[];
+extern const u8 gMonPalette_Latios[];
+extern const u8 gMonBackPic_Latios[];
+extern const u8 gMonShinyPalette_Latios[];
+extern const u8 gMonIcon_Latios[];
+extern const u8 gMonFootprint_Latios[];
+extern const u8 gMonFrontPic_Jirachi[];
+extern const u8 gMonPalette_Jirachi[];
+extern const u8 gMonBackPic_Jirachi[];
+extern const u8 gMonShinyPalette_Jirachi[];
+extern const u8 gMonIcon_Jirachi[];
+extern const u8 gMonFootprint_Jirachi[];
+extern const u8 gMonFrontPic_Deoxys[];
+extern const u8 gMonPalette_Deoxys[];
+extern const u8 gMonBackPic_Deoxys[];
+extern const u8 gMonShinyPalette_Deoxys[];
+extern const u8 gMonIcon_Deoxys[];
+extern const u8 gMonFootprint_Deoxys[];
+extern const u8 gMonFrontPic_Chimecho[];
+extern const u8 gMonPalette_Chimecho[];
+extern const u8 gMonBackPic_Chimecho[];
+extern const u8 gMonShinyPalette_Chimecho[];
+extern const u8 gMonIcon_Chimecho[];
+extern const u8 gMonFootprint_Chimecho[];
+extern const u8 gMonPic_Egg[];
+extern const u8 gMonPalette_Egg[];
+extern const u8 gMonFrontPic_UnownB[];
+extern const u8 gMonBackPic_UnownB[];
+extern const u8 gMonIcon_UnownB[];
+extern const u8 gMonFrontPic_UnownC[];
+extern const u8 gMonBackPic_UnownC[];
+extern const u8 gMonIcon_UnownC[];
+extern const u8 gMonFrontPic_UnownD[];
+extern const u8 gMonBackPic_UnownD[];
+extern const u8 gMonIcon_UnownD[];
+extern const u8 gMonFrontPic_UnownE[];
+extern const u8 gMonBackPic_UnownE[];
+extern const u8 gMonIcon_UnownE[];
+extern const u8 gMonFrontPic_UnownF[];
+extern const u8 gMonBackPic_UnownF[];
+extern const u8 gMonIcon_UnownF[];
+extern const u8 gMonFrontPic_UnownG[];
+extern const u8 gMonBackPic_UnownG[];
+extern const u8 gMonIcon_UnownG[];
+extern const u8 gMonFrontPic_UnownH[];
+extern const u8 gMonBackPic_UnownH[];
+extern const u8 gMonIcon_UnownH[];
+extern const u8 gMonFrontPic_UnownI[];
+extern const u8 gMonBackPic_UnownI[];
+extern const u8 gMonIcon_UnownI[];
+extern const u8 gMonFrontPic_UnownJ[];
+extern const u8 gMonBackPic_UnownJ[];
+extern const u8 gMonIcon_UnownJ[];
+extern const u8 gMonFrontPic_UnownK[];
+extern const u8 gMonBackPic_UnownK[];
+extern const u8 gMonIcon_UnownK[];
+extern const u8 gMonFrontPic_UnownL[];
+extern const u8 gMonBackPic_UnownL[];
+extern const u8 gMonIcon_UnownL[];
+extern const u8 gMonFrontPic_UnownM[];
+extern const u8 gMonBackPic_UnownM[];
+extern const u8 gMonIcon_UnownM[];
+extern const u8 gMonFrontPic_UnownN[];
+extern const u8 gMonBackPic_UnownN[];
+extern const u8 gMonIcon_UnownN[];
+extern const u8 gMonFrontPic_UnownO[];
+extern const u8 gMonBackPic_UnownO[];
+extern const u8 gMonIcon_UnownO[];
+extern const u8 gMonFrontPic_UnownP[];
+extern const u8 gMonBackPic_UnownP[];
+extern const u8 gMonIcon_UnownP[];
+extern const u8 gMonFrontPic_UnownQ[];
+extern const u8 gMonBackPic_UnownQ[];
+extern const u8 gMonIcon_UnownQ[];
+extern const u8 gMonFrontPic_UnownR[];
+extern const u8 gMonBackPic_UnownR[];
+extern const u8 gMonIcon_UnownR[];
+extern const u8 gMonFrontPic_UnownS[];
+extern const u8 gMonBackPic_UnownS[];
+extern const u8 gMonIcon_UnownS[];
+extern const u8 gMonFrontPic_UnownT[];
+extern const u8 gMonBackPic_UnownT[];
+extern const u8 gMonIcon_UnownT[];
+extern const u8 gMonFrontPic_UnownU[];
+extern const u8 gMonBackPic_UnownU[];
+extern const u8 gMonIcon_UnownU[];
+extern const u8 gMonFrontPic_UnownV[];
+extern const u8 gMonBackPic_UnownV[];
+extern const u8 gMonIcon_UnownV[];
+extern const u8 gMonFrontPic_UnownW[];
+extern const u8 gMonBackPic_UnownW[];
+extern const u8 gMonIcon_UnownW[];
+extern const u8 gMonFrontPic_UnownX[];
+extern const u8 gMonBackPic_UnownX[];
+extern const u8 gMonIcon_UnownX[];
+extern const u8 gMonFrontPic_UnownY[];
+extern const u8 gMonBackPic_UnownY[];
+extern const u8 gMonIcon_UnownY[];
+extern const u8 gMonFrontPic_UnownZ[];
+extern const u8 gMonBackPic_UnownZ[];
+extern const u8 gMonIcon_UnownZ[];
+extern const u8 gMonFrontPic_UnownExclamationMark[];
+extern const u8 gMonBackPic_UnownExclamationMark[];
+extern const u8 gMonIcon_UnownExclamationMark[];
+extern const u8 gMonFrontPic_UnownQuestionMark[];
+extern const u8 gMonBackPic_UnownQuestionMark[];
+extern const u8 gMonIcon_UnownQuestionMark[];
+
+#endif // GUARD_GRAPHICS_H
diff --git a/include/hall_of_fame.h b/include/hall_of_fame.h
new file mode 100644
index 000000000..62e84c39e
--- /dev/null
+++ b/include/hall_of_fame.h
@@ -0,0 +1,9 @@
+#ifndef GUARD_HALL_OF_FAME_H
+#define GUARD_HALL_OF_FAME_H
+
+void sub_8141F90(void);
+void sub_8143648(u16 paletteTag, u8 arg1);
+void sub_81428CC(void);
+void sub_8143680(int, u8);
+
+#endif // GUARD_HALL_OF_FAME_H
diff --git a/include/intro_credits_graphics.h b/include/intro_credits_graphics.h
new file mode 100644
index 000000000..85485a2c4
--- /dev/null
+++ b/include/intro_credits_graphics.h
@@ -0,0 +1,24 @@
+#ifndef GUARD_INTRO_CREDITS_GRAPHICS_H
+#define GUARD_INTRO_CREDITS_GRAPHICS_H
+
+extern const struct SpriteSheet gIntro2BrendanSpriteSheet;
+extern const struct SpriteSheet gIntro2MaySpriteSheet;
+extern const struct SpriteSheet gIntro2BicycleSpriteSheet;
+extern const struct SpriteSheet gIntro2LatiosSpriteSheet;
+extern const struct SpriteSheet gIntro2LatiasSpriteSheet;
+extern const struct SpritePalette gIntro2SpritePalettes[];
+extern const struct SpriteSheet gUnknown_08416E24;
+extern const struct SpriteSheet gUnknown_08416E34;
+
+void load_intro_part2_graphics(/*TODO: arg types*/);
+void sub_8148C78(/*TODO: arg types*/);
+void sub_8148CB0(u8);
+void sub_8148E90(u8);
+u8 sub_8148EC0(/*TODO: arg types*/);
+void sub_8149020(/*TODO: arg types*/);
+u8 intro_create_brendan_sprite(/*TODO: arg types*/);
+u8 intro_create_may_sprite(/*TODO: arg types*/);
+u8 intro_create_latios_sprite(/*TODO: arg types*/);
+u8 intro_create_latias_sprite(/*TODO: arg types*/);
+
+#endif // GUARD_INTRO_CREDITS_GRAPHICS_H
diff --git a/include/item_menu.h b/include/item_menu.h
new file mode 100644
index 000000000..301836ac8
--- /dev/null
+++ b/include/item_menu.h
@@ -0,0 +1,29 @@
+#ifndef GUARD_ITEM_MENU_H
+#define GUARD_ITEM_MENU_H
+
+#include "string_util.h"
+
+void sub_80A3684(void);
+void ClearBag(void);
+void sub_80A3E0C(void);
+void sub_80A3FA0(u16 *, u32, u32, u32, u32, u32);
+void sub_80A4164(u8 *, u16, enum StringConvertMode, u8);
+void sub_80A418C(u16, enum StringConvertMode, int, int, int);
+void sub_80A53F8(void);
+void HandleItemMenuPaletteFade(u8);
+void sub_80A5B40(void);
+void CleanUpItemMenuMessage(u8);
+void CleanUpOverworldMessage(u8);
+void ExecuteItemUseFromBlackPalette(void);
+void sub_80A5D04(void);
+void sub_80A6300(void);
+void sub_80A68CC();
+void sub_80A6A30(void);
+int sub_80A6D1C(void);
+void sub_80A6DCC(void);
+void sub_80A7094(u8);
+u8 sub_80A7D8C(u8 berry, int i, int i1);
+void sub_80A7DD4(void);
+u8 sub_80A7E5C(u8);
+
+#endif // GUARD_ITEM_MENU_H
diff --git a/include/item_use.h b/include/item_use.h
new file mode 100644
index 000000000..b35389ee8
--- /dev/null
+++ b/include/item_use.h
@@ -0,0 +1,28 @@
+#ifndef GUARD_ITEM_USE_H
+#define GUARD_ITEM_USE_H
+
+void ItemUseOnFieldCB_Bike(u8);
+void ItemUseOnFieldCB_Rod(u8);
+void ItemUseOnFieldCB_Itemfinder(u8);
+void RunItemfinderResults(u8);
+void ExitItemfinder(u8);
+bool8 ItemfinderCheckForHiddenItems(struct MapEvents *events, u8 taskId);
+void sub_80C9720(u8);
+void sub_80C9838(u8, s16, s16);
+u8 GetPlayerDirectionTowardsHiddenItem(s16, s16);
+void SetPlayerDirectionTowardsItem(u8);
+void DisplayItemRespondingMessageAndExitItemfinder(u8);
+void RotatePlayerAndExitItemfinder(u8);
+void sub_80C9D00(u8);
+void sub_80C9D74(u8);
+void ItemUseOutOfBattle_TMHM(u8);
+void sub_80C9EE4(u8);
+void sub_80C9F10(u8);
+void sub_80C9F80(u8);
+void sub_80C9FC0(u8);
+void task08_080A1C44(u8);
+u8 sub_80CA1C8(void);
+void ItemUseOutOfBattle_EvolutionStone(u8);
+void ItemUseOutOfBattle_CannotUse(u8);
+
+#endif // GUARD_ITEM_USE_H
diff --git a/include/learn_move.h b/include/learn_move.h
new file mode 100644
index 000000000..85fbf046e
--- /dev/null
+++ b/include/learn_move.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_LEARN_MOVE_H
+#define GUARD_LEARN_MOVE_H
+
+void sub_8132670(void);
+
+#endif // GUARD_LEARN_MOVE_H
diff --git a/include/mail_data.h b/include/mail_data.h
new file mode 100644
index 000000000..df4b385a1
--- /dev/null
+++ b/include/mail_data.h
@@ -0,0 +1,16 @@
+#ifndef GUARD_MAIL_DATA_H
+#define GUARD_MAIL_DATA_H
+
+void ClearMailData(void);
+void ClearMailStruct(struct MailStruct *);
+void ClearMailStruct(struct MailStruct *);
+u8 GiveMailToMon(struct Pokemon *, u16);
+u16 SpeciesToMailSpecies(u16, u32);
+u16 MailSpeciesToSpecies(u16, u16 *);
+u8 GiveMailToMon2(struct Pokemon *, struct MailStruct *);
+void TakeMailFromMon(struct Pokemon *);
+u8 TakeMailFromMon2(struct Pokemon *);
+bool8 ItemIsMail(u16);
+bool8 ItemIsMail(u16);
+
+#endif // GUARD_MAIL_DATA_H
diff --git a/include/map_name_popup.h b/include/map_name_popup.h
new file mode 100644
index 000000000..aeee7e029
--- /dev/null
+++ b/include/map_name_popup.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_MAP_NAME_POPUP_H
+#define GUARD_MAP_NAME_POPUP_H
+
+void ShowMapNamePopup(void);
+void HideMapNamePopup();
+
+#endif // GUARD_MAP_NAME_POPUP_H
diff --git a/include/mauville_old_man.h b/include/mauville_old_man.h
new file mode 100644
index 000000000..473fcf5c8
--- /dev/null
+++ b/include/mauville_old_man.h
@@ -0,0 +1,11 @@
+#ifndef GUARD_MAUVILLE_OLD_MAN_H
+#define GUARD_MAUVILLE_OLD_MAN_H
+
+void SetMauvilleOldMan(void);
+void sub_80F7DC0(void);
+void sub_80F7F30(void);
+void sub_80F7F80(u8);
+void sub_80F83D0(void);
+void sub_80F83F8(void);
+
+#endif // GUARD_MAUVILLE_OLD_MAN_H
diff --git a/include/menu.h b/include/menu.h
index 98d7afcc3..a6784a553 100644
--- a/include/menu.h
+++ b/include/menu.h
@@ -21,6 +21,14 @@ struct MenuAction3
void (*func2)(u8);
};
+extern const struct MenuAction gMenuYesNoItems[];
+
+extern struct Window gMenuWindow;
+extern struct Window *gMenuWindowPtr;
+extern u16 gMenuTextTileOffset;
+extern u16 gMenuTextWindowContentTileOffset;
+extern u16 gMenuMessageBoxContentTileOffset;
+
void CloseMenu(void);
void AppendToList(u8 *list, u8 *pindex, u32 value);
void InitMenuWindow(const struct WindowConfig *);
@@ -66,7 +74,7 @@ u8 sub_8072A18(const u8 *, u8, u16, u8, u32);
u8 unref_sub_8072A5C(u8 *, u8 *, u8, u16, u8, u32);
int sub_8072AB0(const u8 *, u8, u16, u8, u8, u32);
void MenuPrint_RightAligned(u8 *, u8, u8);
-void sub_8072B80(u8 *, u8, u8, u8 *);
+void sub_8072B80(const u8 *, u8, u8, const u8 *);
void sub_8072BD8(const u8 *, u8, u8, u16);
u8 *sub_8072C14(u8 *, s32, u8, u8);
u8 *sub_8072C44(u8 *, s32, u8, u8);
@@ -81,6 +89,6 @@ void RedrawMenuCursor(u8, u8);
void unref_sub_8072DC0(void);
void sub_8072DCC(u8);
void sub_8072DDC(u8);
-void sub_8072DEC(void);
+void HandleDestroyMenuCursors(void);
#endif // GUARD_MENU_H
diff --git a/include/menu_cursor.h b/include/menu_cursor.h
index cc6cc16bc..ca82ef244 100644
--- a/include/menu_cursor.h
+++ b/include/menu_cursor.h
@@ -7,7 +7,7 @@ void sub_814A590(void);
u8 sub_814A5C0(u8 a1, u16 a2, u8 a3, u16 a4, u8 a5);
u8 sub_814A758(u8 a1, u8 a2, u8 a3, u8 a4);
u8 unref_sub_814A7AC(u8 a1, u16 a2, u8 a3);
-void sub_814A7FC(void);
+void DestroyMenuCursor(void);
void sub_814A880(u8 a1, u8 a2);
void sub_814A904(void);
void sub_814A958(u8 a1);
diff --git a/include/menu_helpers.h b/include/menu_helpers.h
index f55a90615..0aa9f79f7 100644
--- a/include/menu_helpers.h
+++ b/include/menu_helpers.h
@@ -1,12 +1,27 @@
#ifndef GUARD_MENU_HELPERS_H
#define GUARD_MENU_HELPERS_H
+#include "task.h"
+
struct YesNoFuncTable
{
void (*yesFunc)(u8);
void (*noFunc)(u8);
};
+void DoYesNoFuncWithChoice(u8, const struct YesNoFuncTable *);
void sub_80F914C(u8, const struct YesNoFuncTable *);
+void DisplayItemMessageOnField(u8, const u8 *, TaskFunc, u16);
+bool8 sub_80F9344(void);
+u8 sub_80F9344(void);
+void sub_80F9368(void);
+void sub_80F9438(void);
+void sub_80F944C(void);
+void CreateVerticalScrollIndicators(u8, u8, u8); // include/decoration.h
+void sub_80F979C(u32, u32); // unknown args
+void DestroyVerticalScrollIndicator(u8);
+void BuyMenuFreeMemory(void);
+void sub_80F98DC(int);
+void sub_80F996C(u8);
#endif // GUARD_MENU_HELPERS_H
diff --git a/include/mystery_event_script.h b/include/mystery_event_script.h
new file mode 100644
index 000000000..766303588
--- /dev/null
+++ b/include/mystery_event_script.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_MYSTERY_EVENT_SCRIPT_H
+#define GUARD_MYSTERY_EVENT_SCRIPT_H
+
+u32 sub_812613C(u8 *);
+void sub_8126160(u32 val);
+u16 sub_8126338(void);
+
+#endif // GUARD_MYSTERY_EVENT_SCRIPT_H
diff --git a/include/party_menu.h b/include/party_menu.h
new file mode 100644
index 000000000..917d6a58c
--- /dev/null
+++ b/include/party_menu.h
@@ -0,0 +1,113 @@
+#ifndef GUARD_PARTY_MENU_H
+#define GUARD_PARTY_MENU_H
+
+#include "task.h"
+
+struct PartyMenuItem
+{
+ const u8 *text;
+ TaskFunc func;
+};
+
+struct PartyPopupMenu
+{
+ u8 unk0;
+ u8 unk1;
+ const u8 *unk4;
+};
+
+void sub_806AEDC(void);
+void sub_806AF4C();
+void OpenPartyMenu(u8, u8);
+void OpenPartyMenu();
+u8 sub_806B124(void);
+u8 IsLinkDoubleBattle(void);
+u8 sub_806B58C(u8);
+u8 sub_806B58C(u8);
+void sub_806BC3C(u8, u8);
+u8 sub_806BD58(u8, u8);
+u8 sub_806BD58(u8, u8);
+u16 sub_806BD80(); // undefined args in battle_party_menu.c
+void task_pc_turn_off();
+void sub_806BF74();
+void sub_806C994();
+u8 sub_806CA38(u8);
+void sub_806CB74(u8 taskId);
+void sub_806CCE4(void);
+void sub_806CD44(u8 taskId);
+void sub_806D538();
+void sub_806D538();
+void sub_806D538();
+void sub_806D5A4(void);
+void SetMonIconAnim();
+void TryCreatePartyMenuMonIcon(u8, u8, struct Pokemon *);
+void LoadHeldItemIconGraphics(void);
+void LoadHeldItemIconGraphics(void);
+void CreateHeldItemIcons_806DC34(); // undefined args
+void CreateHeldItemIcons_806DC34();
+u8 GetMonIconSpriteId_maybe();
+void SetHeldItemIconVisibility();
+void TryPrintPartyMenuMonNickname();
+void PrintPartyMenuMonNicknames(void);
+void PrintPartyMenuMonNicknames(void);
+void GetMonNickname(struct Pokemon *mon, u8 *nickname);
+void PartyMenuClearLevelStatusTilemap();
+void PartyMenuPrintMonLevelOrStatus();
+void PartyMenuPrintMonsLevelOrStatus(void);
+void PartyMenuPrintMonsLevelOrStatus(void);
+void PartyMenuDoPrintHP(u8, int, u16, u16);
+void PartyMenuTryPrintMonsHP(void);
+void nullsub_13(void);
+void PartyMenuDrawHPBars(void);
+void sub_806E6F0();
+void sub_806E750(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, int);
+void sub_806E7D0(u8, const struct PartyPopupMenu *);
+TaskFunc PartyMenuGetPopupMenuFunc(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, u8);
+void sub_8070968();
+void sub_8070A20();
+void Task_RareCandy3(u8);
+void sub_8070C54();
+void DoEvolutionStoneItemEffect(u8, u16, TaskFunc);
+u8 GetItemEffectType();
+u8 sub_806E834(const u8 *message, u8 arg1);
+void sub_806E8D0(u8 taskId, u16 b, TaskFunc c);
+void party_menu_link_mon_held_item_object(u8);
+void Task_ConfirmGiveHeldItem(u8);
+void DisplayGiveHeldItemMessage(u8, u16, u8);
+void DisplayTakeHeldItemMessage(u8, u16, u8);
+void Task_ConfirmTakeHeldMail(u8);
+u16 ItemIdToBattleMoveId(u16);
+bool8 pokemon_has_move(struct Pokemon *, u16);
+void TeachMonTMMove(u8, u16, TaskFunc);
+void Task_TeamMonTMMove(u8);
+void Task_TeamMonTMMove2(u8);
+void Task_TeamMonTMMove3(u8);
+void Task_TeamMonTMMove4(u8);
+void sub_806F358(u8);
+void sub_806F390(u8);
+void sub_806F44C(u8);
+void TMMoveUpdateMoveSlot(u8);
+void StopTryingToTeachMove_806F614(u8);
+void StopTryingToTeachMove_806F67C(u8);
+void StopTryingToTeachMove_806F6B4(u8);
+void sub_806F8AC(u8 taskId);
+void sub_806FA18(u8 taskId);
+void sub_806FB0C(u8 taskId);
+void sub_806FB44(u8);
+void PartyMenuUpdateLevelOrStatus(struct Pokemon *, u8);
+void GetMedicineItemEffectMessage(u16);
+bool8 ExecuteTableBasedItemEffect__(u8, u16, u8);
+void UseMedicine(u8, u16, TaskFunc);
+bool8 IsBlueYellowRedFlute(u16);
+void sub_8070048(u8, u16, TaskFunc);
+void sub_8070088(u8);
+void sub_80701DC(u8 taskId);
+void DoPPRecoveryItemEffect(u8, u16, TaskFunc);
+void DoRecoverPP(u8);
+void DoPPUpItemEffect(u8, u16, TaskFunc);
+void DoRareCandyItemEffect(u8, u16, TaskFunc);
+void Task_RareCandy1(u8);
+void Task_RareCandy2(u8);
+void sub_8070848(u8 taskId);
+
+#endif // GUARD_PARTY_MENU_H
diff --git a/include/player_pc.h b/include/player_pc.h
new file mode 100755
index 000000000..f2446ebdf
--- /dev/null
+++ b/include/player_pc.h
@@ -0,0 +1,107 @@
+#ifndef GUARD_PLAYER_PC_H
+#define GUARD_PLAYER_PC_H
+
+// general task defines
+#define TASK gTasks[taskId]
+#define FUNC func
+
+// local task defines
+#define PAGE_INDEX data[0]
+#define ITEMS_ABOVE_TOP data[1]
+#define NUM_ITEMS data[2]
+#define NUM_QUANTITY_ROLLER data[3]
+#define NUM_PAGE_ITEMS data[4]
+// not used
+#define CURRENT_ITEM_STORAGE_MENU data[6]
+// not used
+#define SWAP_ITEM_INDEX data[8]
+#define SWITCH_MODE_ACTIVE data[9]
+
+#define NEW_GAME_PC_ITEMS(i, type) ((u16)((u16 *)gNewGamePCItems + type)[i * 2])
+
+// defined and used in the above macro
+enum
+{
+ ITEM_ID,
+ QUANTITY
+};
+
+// player PC menu options
+enum
+{
+ PLAYERPC_MENU_ITEMSTORAGE,
+ PLAYERPC_MENU_MAILBOX,
+ PLAYERPC_MENU_DECORATION,
+ PLAYERPC_MENU_TURNOFF
+};
+
+// item storage menus
+enum
+{
+ ITEMPC_MENU_WITHDRAW,
+ ITEMPC_MENU_DEPOSIT,
+ ITEMPC_MENU_TOSS,
+ ITEMPC_MENU_EXIT
+};
+
+// mailbox mail options
+enum
+{
+ MAILBOX_READ,
+ MAILBOX_MOVE_TO_BAG,
+ MAILBOX_GIVE,
+ MAILBOX_CANCEL,
+};
+
+// special item description handlers
+enum
+{
+ ITEMPC_SWITCH_WHICH_ITEM = 0xFFF7,
+ ITEMPC_OKAY_TO_THROW_AWAY,
+ ITEMPC_TOO_IMPORTANT,
+ ITEMPC_NO_MORE_ROOM,
+ ITEMPC_THREW_AWAY_ITEM,
+ ITEMPC_HOW_MANY_TO_TOSS,
+ ITEMPC_WITHDREW_THING,
+ ITEMPC_HOW_MANY_TO_WITHDRAW,
+ ITEMPC_GO_BACK_TO_PREV
+};
+
+struct MailboxStruct
+{
+ /*0x00*/ u8 cursorPos;
+ /*0x01*/ u8 pageItems; // number of items (not including Cancel) on the current page.
+ /*0x02*/ u8 itemsAbove; // number of items above the top item on the page.
+ /*0x03*/ u8 count; // total number of items in mailbox storage.
+};
+
+extern struct MailboxStruct gMailboxInfo;
+
+void ReshowPlayerPC(u8 var);
+void NewGameInitPCItems(void);
+void BedroomPC(void);
+void PlayerPC(void);
+void ItemStorage_ReturnToMenuAfterDeposit(void);
+void Mailbox_ReturnToMailListAfterDeposit(void);
+
+void sub_813A240(u8);
+void sub_813A280(u8);
+void sub_813A468(u8);
+void sub_813A4B4(u8);
+void HandleQuantityRolling(u8);
+void sub_813A6FC(u8);
+void sub_813A794(u8);
+void sub_813A8F0(u8);
+void sub_813A984(u8);
+void sub_813A9EC(u8);
+void sub_813AA30(u8, u8);
+void sub_813ABE8(u8);
+void sub_813AD58(u16);
+void sub_813AE0C(u8);
+void sub_813AE6C(u8, u8);
+u8 sub_813AF3C(void);
+void sub_813AF78(void);
+void sub_813B108(u8);
+void sub_813B174(u8);
+
+#endif // GUARD_PLAYER_PC_H
diff --git a/include/pokeball.h b/include/pokeball.h
new file mode 100644
index 000000000..b6fbbcf77
--- /dev/null
+++ b/include/pokeball.h
@@ -0,0 +1,7 @@
+#ifndef GUARD_POKEBALL_H
+#define GUARD_POKEBALL_H
+
+void CreatePokeballSprite(u8 r0, u8 r1, u8 r2, u8 r3, u8 s1, u8 s2, u8 s3, u16 s4);
+void sub_804777C(u8);
+
+#endif // GUARD_POKEBALL_H
diff --git a/include/pokeblock.h b/include/pokeblock.h
new file mode 100644
index 000000000..257c83f1c
--- /dev/null
+++ b/include/pokeblock.h
@@ -0,0 +1,10 @@
+#ifndef GUARD_POKEBLOCK_H
+#define GUARD_POKEBLOCK_H
+
+void sub_810B96C(void);
+void sub_810BA7C(u8);
+void ClearPokeblocks(void);
+void sub_810CA6C(s32);
+s16 sub_810CAE4(u8, struct Pokeblock *);
+
+#endif // GUARD_POKEBLOCK_H
diff --git a/include/pokedex.h b/include/pokedex.h
index 61597981b..1bc63a4ff 100644
--- a/include/pokedex.h
+++ b/include/pokedex.h
@@ -3,156 +3,16 @@
#include "sprite.h"
-struct PokedexListItem
-{
- u16 dexNum;
- u16 seen:1;
- u16 owned:1;
-};
-
-struct PokedexView
-{
- struct PokedexListItem unk0[386];
- u16 unk608;
- u8 unk60A_1:1;
- u8 unk60A_2:1;
- u8 unk60B;
- u16 unk60C;
- u16 selectedPokemon;
- u16 unk610;
- u16 dexMode; //National or Hoenn
- u16 unk614;
- u16 dexOrder;
- u16 unk618;
- u16 unk61A;
- u16 unk61C;
- u16 unk61E[4];
- u16 unk626; //sprite id of selected Pokemon
- u16 unk628;
- u16 unk62A;
- u8 unk62C;
- u8 unk62D;
- u8 unk62E;
- u8 unk62F;
- s16 unk630;
- s16 unk632;
- u16 unk634;
- u16 unk636;
- u16 unk638;
- u16 unk63A[4];
- u8 filler642[8];
- u8 unk64A;
- u8 unk64B;
- u8 unk64C_1:1;
- u8 selectedScreen;
- u8 unk64E;
- u8 unk64F;
- u8 menuIsOpen; //menuIsOpen
- u8 unk651;
- u16 menuCursorPos; //Menu cursor position
- s16 menuY; //Menu Y position (inverted because we use REG_BG0VOFS for this)
- u8 unk656[8];
- u8 unk65E[8];
-};
-
void ResetPokedex(void);
void sub_808C0A0(void);
-void sub_808C0B8(void);
-void ClearPokedexView(struct PokedexView *pokedexView);
void CB2_InitPokedex(void);
-u8 unref_sub_808C540(void (*func)(u8));
-void MainCB(void);
-void Task_PokedexShowMainScreen(u8 taskId);
-void Task_PokedexMainScreen(u8 taskId);
-void sub_808C898(u8 taskId);
-void Task_PokedexMainScreenMenu(u8 taskId);
-void sub_808CA64(u8 taskId);
-void sub_808CAE4(u8 taskId);
-void sub_808CB8C(u8 taskId);
-void Task_ClosePokedex(u8 taskId);
-void sub_808CCC4(u8 taskId);
-void Task_PokedexResultsScreen(u8 taskId);
-void sub_808CEF8(u8 taskId);
-void Task_PokedexResultsScreenMenu(u8 taskId);
-void sub_808D118(u8 taskId);
-void sub_808D198(u8 taskId);
-void Task_PokedexResultsScreenReturnToMainScreen(u8 taskId);
-void Task_PokedexResultsScreenExitPokedex(u8 taskId);
-bool8 sub_808D344(u8 a);
-void sub_808D640(void);
-void SortPokedex(u8 dexMode, u8 sortMode);
-void sub_808DBE8(u8 a, u16 b, u16 c);
-void sub_808DEB0(u16 a, u8 b, u8 c, u16 d);
-void sub_808DF88(u16 a, u8 b, u8 c, u16 d);
-u8 sub_808DFE4(u16 a, u8 b, u8 c);
-void sub_808E090(u8 a, u8 b, u16 c);
-void sub_808E0CC(u16 a, u16 b);
-bool8 sub_808E208(u8 a, u8 b, u8 c);
-void sub_808E398(u8 a, u16 b);
-u16 sub_808E48C(u16 a, u16 b);
-void sub_808E6BC(void);
-u8 sub_808E71C(void);
-u8 sub_808E82C(void);
-u16 sub_808E888(u16 a1);
-u32 sub_808E8C8(u16 a, u16 b, u16 c);
-void sub_808E978(u8 a);
-void nullsub_58(struct Sprite *sprite);
-void sub_808ED94(struct Sprite *sprite);
-void sub_808EDB8(struct Sprite *sprite);
-void sub_808EE28(struct Sprite *sprite);
-void sub_808EF38(struct Sprite *sprite);
-void sub_808EF8C(struct Sprite *sprite);
-void sub_808F08C(struct Sprite *sprite);
-void sub_808F0B4(struct Sprite *sprite);
-void sub_808F168(struct Sprite *sprite);
-u8 sub_808F210(struct PokedexListItem *item, u8 b);
-bool8 sub_808F250(u8 taskId);
-u8 sub_808F284(struct PokedexListItem *item, u8 b);
-void Task_InitPageScreenMultistep(u8 taskId);
-void Task_PageScreenProcessInput(u8 taskId);
-void sub_808F888(u8 taskId);
-void Task_ClosePageScreen(u8 taskId);
-void Task_InitAreaScreenMultistep(u8 taskId);
-void Task_AreaScreenProcessInput(u8 taskId);
-void sub_808FA00(u8 taskId);
-void Task_InitCryScreenMultistep(u8 taskId);
-void Task_CryScreenProcessInput(u8 taskId);
-void sub_808FFBC(u8 taskId);
-void sub_8090040(u8 a);
-void Task_InitSizeScreenMultistep(u8 taskId);
-void Task_SizeScreenProcessInput(u8 taskId);
-void sub_8090498(u8 taskId);
-void sub_80904FC(u16 a);
-void sub_8090540(u16 a);
-void sub_8090584(u8 a, u16 b);
-void sub_8090644(u8 a, u16 b);
u8 sub_809070C(u16 dexNum, u32 b, u32 c);
-
-// ASM
-void sub_8090750(u8);
-void sub_8090A3C(u8);
-
-void sub_8090C68(void);
-u8 *GetPokemonCategory(u16);
-
-s8 sub_8090D90(u16, u8);
+const u8 *GetPokemonCategory(u16);
+u16 GetPokedexHeightWeight(u16 dexNum, u8 data);
+s8 GetNationalPokedexFlag(u16, u8);
u16 GetNationalPokedexCount(u8);
u16 GetHoennPokedexCount(u8);
bool8 sub_8090FC0(void);
u16 sub_8090FF4(void);
-void sub_8091060(u16);
-void sub_8091154(u16 order, int i, int i1);
-void sub_80911C8(u16 num, int i, int i1);
-void sub_8091260(u16 num, int i, int i1, int i2);
-void sub_8091304(u8 name[12], int i, int i1);
-
-void sub_8091458(u16 height, int i, int i1);
-void sub_8091564(u16 weight, int i, int i1);
-void sub_8091738(u16, u16, u16);
-void sub_80917CC(int i, int i1);
-u16 sub_8091818(u8, u16, u16, u16);
-
-u16 sub_80918EC(u16 a, s16 b, s16 c, u16 d); //Not sure of return type
-u8 sub_8091A4C(u8 gender, int i, int i1, int i2);
#endif // GUARD_POKEDEX_H
diff --git a/include/pokedex_area_screen.h b/include/pokedex_area_screen.h
new file mode 100644
index 000000000..35ea43854
--- /dev/null
+++ b/include/pokedex_area_screen.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_POKEDEX_AREA_SCREEN_H
+#define GUARD_POKEDEX_AREA_SCREEN_H
+
+void ShowPokedexAreaScreen(u16 species, u8 *string);
+
+#endif // GUARD_POKEDEX_AREA_SCREEN_H
diff --git a/include/pokedex_cry_screen.h b/include/pokedex_cry_screen.h
new file mode 100644
index 000000000..ee586a092
--- /dev/null
+++ b/include/pokedex_cry_screen.h
@@ -0,0 +1,19 @@
+#ifndef GUARD_POKEDEX_CRY_SCREEN_H
+#define GUARD_POKEDEX_CRY_SCREEN_H
+
+struct CryRelatedStruct
+{
+ u16 unk0;
+ u8 unk2;
+ u8 paletteNo;
+ u8 xPos;
+ u8 yPos;
+};
+
+u8 ShowPokedexCryScreen(struct CryRelatedStruct *, u8);
+u8 sub_8119E3C(struct CryRelatedStruct *, u8);
+void sub_8119F88(u8 a);
+void sub_811A050(u16 species);
+void DestroyCryMeterNeedleSprite();
+
+#endif // GUARD_POKEDEX_CRY_SCREEN_H
diff --git a/include/pokemon.h b/include/pokemon.h
index 15a028d6e..273e7d26e 100644
--- a/include/pokemon.h
+++ b/include/pokemon.h
@@ -1,6 +1,8 @@
#ifndef GUARD_POKEMON_H
#define GUARD_POKEMON_H
+#include "sprite.h"
+
#define MON_DATA_PERSONALITY 0
#define MON_DATA_OT_ID 1
#define MON_DATA_NICKNAME 2
@@ -357,7 +359,8 @@ struct BaseStats
/* 0x16 */ u8 ability1;
/* 0x17 */ u8 ability2;
/* 0x18 */ u8 safariZoneFleeRate;
- /* 0x19 */ u8 bodyColor;
+ /* 0x19 */ u8 bodyColor:7;
+ u8 unk19_7:1;
};
struct BattleMove
@@ -381,6 +384,29 @@ struct PokemonStorage
u8 unkArray[14];
};
+struct Evolution
+{
+ u16 method;
+ u16 param;
+ u16 targetSpecies;
+};
+
+struct EvolutionData
+{
+ struct Evolution evolutions[5];
+};
+
+extern const u8 *const gItemEffectTable[];
+extern u8 gTrainerClassToPicIndex[];
+extern u8 gTrainerClassToNameIndex[];
+extern const u32 gExperienceTables[8][101];
+extern const struct BaseStats gBaseStats[];
+extern struct EvolutionData gEvolutionTable[];
+extern const u16 *gLevelUpLearnsets[];
+extern u8 gUnknown_08208238[];
+extern u8 gUnknown_0820823C[];
+extern u8 gStatStageRatios[][2];
+
extern struct Pokemon gPlayerParty[PARTY_SIZE];
extern struct Pokemon gEnemyParty[PARTY_SIZE];
@@ -463,4 +489,26 @@ void MonRestorePP(struct Pokemon *);
u8 *sub_803F378(u16 itemId);
u16 NationalPokedexNumToSpecies(u16 nationalNum);
+u16 NationalToHoennOrder(u16);
+u16 SpeciesToNationalPokedexNum(u16);
+u16 HoennToNationalOrder(u16);
+void DrawSpindaSpots(u16, u32, u8 *, u8);
+u8 sub_803FBBC(void);
+u8 sub_803FC58(u16);
+void AdjustFriendship(struct Pokemon *, u8);
+u8 CheckPartyHasHadPokerus(struct Pokemon *, u8);
+void UpdatePartyPokerusTime(u16);
+u32 CanMonLearnTMHM(struct Pokemon *, u8);
+u8 sub_8040574(struct Pokemon *party);
+void ClearBattleMonForms(void);
+void sub_80408BC();
+void current_map_music_set__default_for_battle(u16);
+const u16 *species_and_otid_get_pal(u16, u32, u32);
+const struct SpritePalette *sub_80409C8(u16, u32, u32);
+bool8 IsOtherTrainer(u32, u8 *);
+void sub_8040B8C(void);
+void SetWildMonHeldItem(void);
+u8 *sub_8040D08();
+bool32 sub_8040D3C(u16 species, u8 *name, u8 language);
+
#endif // GUARD_POKEMON_H
diff --git a/include/pokemon_icon.h b/include/pokemon_icon.h
new file mode 100644
index 000000000..98f984564
--- /dev/null
+++ b/include/pokemon_icon.h
@@ -0,0 +1,14 @@
+#ifndef GUARD_POKEMON_ICON_H
+#define GUARD_POKEMON_ICON_H
+
+u8 CreateMonIcon();
+u8 sub_809D3A4(u16 arg0, void (*)(struct Sprite *), int, u8 arg3, u32 arg4);
+u16 GetUnownLetterByPersonality(u32);
+u16 sub_809D4A8(u16);
+void sub_809D510(struct Sprite *);
+void sub_809D51C(void);
+void sub_809D580(u16);
+void sub_809D608(u16);
+void UpdateMonIconFrame(struct Sprite *sprite);
+
+#endif // GUARD_POKEMON_ICON_H
diff --git a/include/pokemon_item_effect.h b/include/pokemon_item_effect.h
new file mode 100644
index 000000000..c09649aff
--- /dev/null
+++ b/include/pokemon_item_effect.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_POKEMON_ITEM_EFFECT_H
+#define GUARD_POKEMON_ITEM_EFFECT_H
+
+bool8 ExecuteTableBasedItemEffect_(struct Pokemon *mon, u16, u8, u16);
+
+#endif // GUARD_POKEMON_ITEM_EFFECT_H
diff --git a/include/pokemon_menu.h b/include/pokemon_menu.h
new file mode 100644
index 000000000..d22dbb708
--- /dev/null
+++ b/include/pokemon_menu.h
@@ -0,0 +1,14 @@
+#ifndef GUARD_POKEMON_MENU_H
+#define GUARD_POKEMON_MENU_H
+
+void sub_8089A70(void);
+void sub_808A004();
+void sub_808AB90(void);
+void sub_808AB90(void); // unknown args
+void sub_808AB90(void);
+void sub_808B020(void);
+void sub_808B0C0(u8);
+void sub_808B508(u8);
+void sub_808B564();
+
+#endif // GUARD_POKEMON_MENU_H
diff --git a/include/pokemon_storage_system.h b/include/pokemon_storage_system.h
new file mode 100644
index 000000000..bd4e7915b
--- /dev/null
+++ b/include/pokemon_storage_system.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_POKEMON_STORAGE_SYSTEM_H
+#define GUARD_POKEMON_STORAGE_SYSTEM_H
+
+void ResetPokemonStorageSystem(void);
+
+#endif // GUARD_POKEMON_STORAGE_SYSTEM_H
diff --git a/include/pokemon_summary_screen.h b/include/pokemon_summary_screen.h
new file mode 100644
index 000000000..3f7ed8fad
--- /dev/null
+++ b/include/pokemon_summary_screen.h
@@ -0,0 +1,16 @@
+#ifndef GUARD_POKEMON_SUMMARY_SCREEN_H
+#define GUARD_POKEMON_SUMMARY_SCREEN_H
+
+extern const u8 *const gNatureNames[];
+
+void ShowPokemonSummaryScreen(struct Pokemon *, u8, u8, void (*)(u8), int);
+void sub_809D9F0(struct Pokemon *party, u8, u8, void *, u32);
+void sub_809D9F0(struct Pokemon *, u8, u8, void *, u32);
+u8 sub_809FA30(void);
+u8 pokemon_ailments_get_primary(u32);
+u8 GetMonStatusAndPokerus();
+u8 *sub_80A1E9C(u8 *dest, const u8 *src, u8);
+u8 *PokemonSummaryScreen_CopyPokemonLevel(u8 *dest, u8 level);
+u8 PokemonSummaryScreen_CheckOT(struct Pokemon *pokemon);
+
+#endif // GUARD_POKEMON_SUMMARY_SCREEN_H
diff --git a/include/pokenav.h b/include/pokenav.h
new file mode 100644
index 000000000..ccea77a57
--- /dev/null
+++ b/include/pokenav.h
@@ -0,0 +1,19 @@
+#ifndef GUARD_POKENAV_H
+#define GUARD_POKENAV_H
+
+struct UnkPokenavStruct_Sub {
+ /*0x0*/ u16 unk0;
+ /*0x2*/ u8 filler2[6];
+};
+
+struct UnkPokenavStruct {
+ /*0x0000*/ u8 filler0000[0xCEE8];
+ /*0xCEE8*/ struct UnkPokenavStruct_Sub unkCEE8[78];
+ /*0xD158*/ u16 unkD158;
+};
+
+extern struct UnkPokenavStruct *gUnknown_083DFEC4;
+
+void sub_80EBA5C(void);
+
+#endif // GUARD_POKENAV_H
diff --git a/include/record_mixing.h b/include/record_mixing.h
index 72a089ca1..103f5ad64 100644
--- a/include/record_mixing.h
+++ b/include/record_mixing.h
@@ -23,11 +23,11 @@ void sub_80B9A88(u8 *a);
void sub_80B9B1C(u8 *a, size_t size, u8 index);
void sub_80B9B70(u8 *a, size_t size, u8 index);
u8 sub_80B9BBC(u16 *a);
-void sub_80B9BC4(u32 a, u32 b, u32 c, u32 d);
+void sub_80B9BC4(struct RecordMixing_UnknownStruct *, size_t, u8 [][2], u8, u8);
u8 sub_80B9C4C(u8 *a);
// ASM
-void sub_80B9C6C(void *, u32, u8, void *);
+void sub_80B9C6C(struct RecordMixing_UnknownStruct *, u32, u8, void *);
void sub_80B9F3C(void *, u8);
void sub_80BA00C(u8);
diff --git a/include/region_map.h b/include/region_map.h
new file mode 100644
index 000000000..0cef566f6
--- /dev/null
+++ b/include/region_map.h
@@ -0,0 +1,13 @@
+#ifndef GUARD_REGION_MAP_H
+#define GUARD_REGION_MAP_H
+
+void sub_80FA8EC(u32, u8);
+void sub_80FAB10(void);
+u8 sub_80FAB60(void);
+void sub_80FBB3C(u16, u16);
+void sub_80FBCF0(u32, u8);
+void sub_80FBFB4(u8 *str, u8 region, u8);
+void CopyMapName();
+u8 *CopyLocationName(u8 *dest, u8 location);
+
+#endif // GUARD_REGION_MAP_H
diff --git a/include/reset_rtc_screen.h b/include/reset_rtc_screen.h
new file mode 100644
index 000000000..5807dec99
--- /dev/null
+++ b/include/reset_rtc_screen.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_RESET_RTC_SCREEN_H
+#define GUARD_RESET_RTC_SCREEN_H
+
+void CB2_InitResetRtcScreen(void);
+
+#endif // GUARD_RESET_RTC_SCREEN_H
diff --git a/include/rom3.h b/include/rom3.h
new file mode 100644
index 000000000..a66162443
--- /dev/null
+++ b/include/rom3.h
@@ -0,0 +1,25 @@
+#ifndef GUARD_ROM3_H
+#define GUARD_ROM3_H
+
+void sub_800B858(void);
+void setup_poochyena_battle();
+void sub_800B950(void);
+void sub_800B9A8(void);
+void sub_800BA78(void);
+void sub_800BD54(void);
+void sub_800BF28(void);
+void dp01_prepare_buffer_wireless_probably(u8 a, u16, u8 *c);
+void sub_800C1A8(u8);
+void sub_800C35C(void);
+void sub_800C47C(u8);
+void dp01_build_cmdbuf_x00_a_b_0(u8 a, u8 b, u8 c);
+void dp01_build_cmdbuf_x04_4_4_4(u8 a);
+void sub_800C704(u8, u8, u8);
+void dp01_build_cmdbuf_x07_7_7_7(u8 a);
+void dp01_build_cmdbuf_x12_a_bb(u8 a, u8 b, u16 c);
+void dp01_build_cmdbuf_x1D_1D_numargs_varargs(u8, u16, u8 *);
+void dp01_build_cmdbuf_x2E_a(u8 a, u8 b);
+void dp01_build_cmdbuf_x2F_2F_2F_2F(u8 a);
+void dp01_build_cmdbuf_x30_TODO(u8 a, u8 *b, u8 c);
+
+#endif // GUARD_ROM3_H
diff --git a/include/rom4.h b/include/rom4.h
index 476a0e103..eac4d29a2 100644
--- a/include/rom4.h
+++ b/include/rom4.h
@@ -17,8 +17,15 @@ struct LinkPlayerMapObject
u8 mode;
};
+struct UCoords32
+{
+ u32 x, y;
+};
+
+extern struct UCoords32 gUnknown_0821664C[];
+
// sub_8052F5C
-// flag_var_implications_of_teleport_
+void flag_var_implications_of_teleport_(void);
void new_game(void);
void sub_8053014(void);
void sub_8053050(void);
@@ -37,7 +44,7 @@ void update_saveblock1_field_object_movement_behavior(u8, u8);
// warp_set
// warp_data_is_not_neg_1
struct MapHeader * const get_mapheader_by_bank_and_number(u16 mapGroup, u16 mapNum);
-// warp1_get_mapheader
+struct MapHeader * const warp1_get_mapheader(void);
// set_current_map_header_from_sav1_save_old_name
// sub_805338C
// sub_80533CC
@@ -52,7 +59,7 @@ void sub_8053570(void);
void sub_8053588(u8);
void sub_80535C4(s16 a1, s16 a2);
void sub_805363C(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
-// sub_8053678
+void sub_8053678(void);
void sub_8053690(s8, s8, s8, s8, s8);
// warp1_set_to_warp2
void sub_80536E4(s8, s8, s8, s8, s8);
@@ -65,10 +72,10 @@ void gpu_sync_bg_hide();
// sub_8053850
bool8 sub_80538B0(u16 x, u16 y);
bool8 sub_80538D0(u16 x, u16 y);
-// sub_80538F0
+void sub_80538F0(u8 mapGroup, u8 mapNum);
// sub_8053994
void player_avatar_init_params_reset(void);
-// walkrun_find_lowest_active_bit_in_bitfield
+void walkrun_find_lowest_active_bit_in_bitfield(void);
// sub_8053AA8
u8 sub_8053B00(struct UnkPlayerStruct *playerStruct, u16 a2, u8 a3);
u8 sub_8053B60(struct UnkPlayerStruct *playerStruct, u8, u16, u8);
@@ -200,7 +207,7 @@ u32 sub_80558AC(void);
u32 sub_8055910(void);
u32 sub_8055940(void);
// ZeroLinkPlayerMapObject
-// strange_npc_table_clear
+void strange_npc_table_clear(void);
// ZeroMapObject
void SpawnLinkPlayerMapObject(u8, s16, s16, u8);
void InitLinkPlayerMapObjectPos(struct MapObject *, s16, s16);
diff --git a/include/rom_8077ABC.h b/include/rom_8077ABC.h
new file mode 100644
index 000000000..26c89d4cc
--- /dev/null
+++ b/include/rom_8077ABC.h
@@ -0,0 +1,59 @@
+#ifndef GUARD_ROM_8077ABC_H
+#define GUARD_ROM_8077ABC_H
+
+#include "sprite.h"
+#include "task.h"
+
+u8 sub_8077ABC(u8, u8);
+u8 sub_8077E44(u8 slot, u16 species, u8 a3);
+u8 obj_id_for_side_relative_to_move(u8 side);
+void oamt_set_x3A_32(struct Sprite *sprite, void(*callback)(struct Sprite *));
+void sub_8078314(struct Sprite *sprite);
+void sub_8078364(struct Sprite *sprite);
+void sub_8078458(struct Sprite *sprite);
+void sub_80784A8(struct Sprite *sprite);
+u8 battle_side_get_owner(u8);
+u8 battle_side_get_owner(u8);
+u8 battle_side_get_owner(u8 side);
+u8 battle_side_get_owner(u8 slot);
+u8 battle_side_get_owner(u8);
+u8 battle_get_per_side_status(u8);
+u8 battle_get_per_side_status(u8 slot);
+u8 battle_get_side_with_given_state(u8);
+u8 battle_get_side_with_given_state(u8);
+u8 battle_get_side_with_given_state(u8 state);
+u8 sub_8078874(u8);
+bool8 sub_8078874(u8);
+bool8 IsDoubleBattle();
+u8 IsDoubleBattle(void);
+bool8 IsDoubleBattle(void);
+void sub_8078914();
+u8 sub_80789BC();
+void sub_8078A5C(struct Sprite *sprite);
+void sub_8078A5C(struct Sprite *sprite);
+void obj_translate_based_on_private_1_2_3_4(struct Sprite *sprite);
+bool8 sub_8078B5C(struct Sprite *sprite);
+void sub_8078BB8(struct Sprite *sprite);
+void sub_8078D44(struct Sprite *sprite);
+void obj_id_set_rotscale(u8 sprite, s16, s16, u16);
+bool8 sub_8078E38();
+void sub_8078E70(u8 sprite, u8);
+void sub_8078F40(u8 sprite);
+void sub_8078F9C(u8 sprite);
+void sub_8079518(struct Sprite *sprite);
+void sub_80796F8(u8 task);
+void sub_80797EC(struct Task *task);
+void sub_8079814(u8 taskId);
+void sub_8079A64(u8 sprite);
+u16 sub_8079B10(u8 sprite);
+void sub_8079BF4(s16 *bottom, s16 *top, void *ptr);
+void *sub_8079BFC(s16 bottom, s16 top);
+void sub_8079E24();
+u8 sub_8079E90(u8 slot);
+u8 battle_get_per_side_status_permutated(u8 slot);
+void sub_807A784(u8 taskId);
+void sub_807A850(struct Task *task, u8 taskId);
+void sub_807A8D4(struct Sprite *sprite);
+void sub_807A960(struct Sprite *sprite);
+
+#endif // GUARD_ROM_8077ABC_H
diff --git a/include/rom_8094928.h b/include/rom_8094928.h
new file mode 100644
index 000000000..fd4e58847
--- /dev/null
+++ b/include/rom_8094928.h
@@ -0,0 +1,10 @@
+#ifndef GUARD_ROM_8094928_H
+#define GUARD_ROM_8094928_H
+
+void sub_8094978(u8, u8);
+u8 sub_8094C20(u8);
+void sub_8094C98(u8, u8);
+u8 pokemon_order_func(u8);
+void sub_8094E4C(void);
+
+#endif // GUARD_ROM_8094928_H
diff --git a/include/rotating_gate.h b/include/rotating_gate.h
new file mode 100644
index 000000000..6f4f38a9a
--- /dev/null
+++ b/include/rotating_gate.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_ROTATING_GATE_H
+#define GUARD_ROTATING_GATE_H
+
+void RotatingGatePuzzleCameraUpdate(s16, s16);
+void sub_80C8080();
+u32 CheckForRotatingGatePuzzleCollision(u8, s16, s16);
+
+#endif // GUARD_ROTATING_GATE_H
diff --git a/include/safari_zone.h b/include/safari_zone.h
index f491be2f1..0bee08a95 100644
--- a/include/safari_zone.h
+++ b/include/safari_zone.h
@@ -1,6 +1,8 @@
#ifndef GUARD_SAFARI_ZONE_H
#define GUARD_SAFARI_ZONE_H
+extern u8 gNumSafariBalls;
+
bool32 GetSafariZoneFlag(void);
void SetSafariZoneFlag(void);
void ResetSafariZoneFlag(void);
diff --git a/include/script_menu.h b/include/script_menu.h
index 7a504556e..458aad13d 100644
--- a/include/script_menu.h
+++ b/include/script_menu.h
@@ -7,6 +7,8 @@ struct MultichoiceListStruct
u8 count;
};
+extern const struct TextStruct gUnknown_083CE048[];
+
bool8 sub_80B5054(u8 left, u8 top, u8 var3, u8 var4);
bool8 sub_80B50B0(u8 left, u8 top, u8 var3, u8 var4, u8 var5);
u16 GetStringWidthInTilesForScriptMenu(const u8 *str);
diff --git a/include/script_movement.h b/include/script_movement.h
new file mode 100644
index 000000000..e3cdc25b3
--- /dev/null
+++ b/include/script_movement.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_SCRIPT_MOVEMENT_H
+#define GUARD_SCRIPT_MOVEMENT_H
+
+bool8 exec_movement(u8, u8, u8, u8 *);
+bool8 sub_80A212C(u8, u8, u8);
+void sub_80A2178(void);
+
+#endif // GUARD_SCRIPT_MOVEMENT_H
diff --git a/include/secret_base.h b/include/secret_base.h
new file mode 100644
index 000000000..3ca5ab182
--- /dev/null
+++ b/include/secret_base.h
@@ -0,0 +1,15 @@
+#ifndef GUARD_SECRET_BASE_H
+#define GUARD_SECRET_BASE_H
+
+void ResetSecretBases(void);
+void sub_80BB970(struct MapEvents *);
+u8 sub_80BBB24(void);
+void sub_80BBCCC(u8);
+void sub_80BC038();
+u8 sub_80BC050();
+void sub_80BC300();
+const u8 sub_80BCCA4(u8);
+u8 *sub_80BCCE8(void);
+void sub_80BD674(void *, u32, u8);
+
+#endif // GUARD_SECRET_BASE_H
diff --git a/include/shop.h b/include/shop.h
new file mode 100644
index 000000000..cca6091c9
--- /dev/null
+++ b/include/shop.h
@@ -0,0 +1,18 @@
+#ifndef GUARD_SHOP_H
+#define GUARD_SHOP_H
+
+void sub_80B2E38(u8);
+void HandleShopMenuQuit(u8);
+void sub_80B2FA0(u8);
+void BuyMenuDrawGraphics(void);
+void sub_80B3240(void);
+void sub_80B3270(void);
+void BuyMenuDrawMapGraphics(void);
+void sub_80B3764(int, int);
+void sub_80B37EC(void);
+void sub_80B40E8(u8);
+void CreatePokemartMenu(void *);
+void CreateDecorationShop1Menu(void *);
+void CreateDecorationShop2Menu(void *);
+
+#endif // GUARD_SHOP_H
diff --git a/include/slot_machine.h b/include/slot_machine.h
new file mode 100644
index 000000000..c39aa7ca8
--- /dev/null
+++ b/include/slot_machine.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_SLOT_MACHINE_H
+#define GUARD_SLOT_MACHINE_H
+
+void PlaySlotMachine(u8, void *);
+void sub_8104DA4(void);
+u8 sub_8105BB4(u8, u8, s16);
+
+#endif // GUARD_SLOT_MACHINE_H
diff --git a/include/songs.h b/include/songs.h
index d7829479f..72d28a355 100644
--- a/include/songs.h
+++ b/include/songs.h
@@ -20,22 +20,22 @@ enum
/*0x0E*/ SE_KOUKA_H,
/*0x0F*/ SE_BOWA2,
/*0x10*/ SE_POKE_DEAD,
- SE_NIGERU,
- SE_JIDO_DOA,
- SE_NAMINORI,
- SE_BAN,
- SE_PIN,
- SE_BOO,
- SE_BOWA,
- SE_JYUNI,
- SE_A,
- SE_I,
- SE_U,
- SE_E,
- SE_O,
- SE_N,
- SE_SEIKAI,
- SE_HAZURE,
+ /*0x11*/ SE_NIGERU,
+ /*0x12*/ SE_JIDO_DOA,
+ /*0x13*/ SE_NAMINORI,
+ /*0x14*/ SE_BAN,
+ /*0x15*/ SE_PIN,
+ /*0x16*/ SE_BOO,
+ /*0x17*/ SE_BOWA,
+ /*0x18*/ SE_JYUNI,
+ /*0x19*/ SE_A,
+ /*0x1A*/ SE_I,
+ /*0x1B*/ SE_U,
+ /*0x1C*/ SE_E,
+ /*0x1D*/ SE_O,
+ /*0x1E*/ SE_N,
+ /*0x1F*/ SE_SEIKAI,
+ /*0x20*/ SE_HAZURE,
SE_EXP,
SE_JITE_PYOKO,
SE_MU_PACHI,
@@ -93,7 +93,7 @@ enum
SE_T_KAMI,
SE_T_KAMI2,
SE_ELEBETA,
- SE_HINSI,
+ /*0x5A*/ SE_HINSI,
SE_EXPMAX,
SE_TAMAKORO,
SE_TAMAKORO_E,
@@ -112,11 +112,11 @@ enum
SE_JIHANKI,
SE_TAMA,
SE_Z_SCROLL,
- SE_Z_PAGE,
- SE_PN_ON,
- SE_PN_OFF,
- SE_Z_SEARCH,
- SE_TAMAGO,
+ /*0x6D*/ SE_Z_PAGE,
+ /*0x6E*/ SE_PN_ON,
+ /*0x6F*/ SE_PN_OFF,
+ /*0x70*/ SE_Z_SEARCH,
+ /*0x71*/ SE_TAMAGO,
/*0x72*/ SE_TB_START,
/*0x73*/ SE_TB_KON,
/*0x74*/ SE_TB_KARA,
diff --git a/include/sprite.h b/include/sprite.h
index 13c03ab51..dd9d5efb7 100644
--- a/include/sprite.h
+++ b/include/sprite.h
@@ -133,7 +133,7 @@ struct Subsprite
struct SubspriteTable
{
u8 subspriteCount;
- struct Subsprite *subsprites;
+ const struct Subsprite *subsprites;
};
struct Sprite;
diff --git a/include/starter_choose.h b/include/starter_choose.h
index 008d1b14e..44ca8c34c 100644
--- a/include/starter_choose.h
+++ b/include/starter_choose.h
@@ -3,6 +3,11 @@
#include "sprite.h"
+extern const u16 gBirchBagGrassPal[2][16];
+extern const u8 gBirchBagTilemap[];
+extern const u8 gBirchGrassTilemap[];
+extern const u8 gBirchHelpGfx[];
+
u16 GetStarterPokemon(u16);
void CB2_ChooseStarter(void);
diff --git a/include/string_util.h b/include/string_util.h
index f45c2741f..7a4bfa4c1 100644
--- a/include/string_util.h
+++ b/include/string_util.h
@@ -8,6 +8,8 @@ enum StringConvertMode
STR_CONV_MODE_LEADING_ZEROS
};
+extern const u8 gEmptyString_81E72B0[];
+
u8 *StringCopy10(u8 *dest, const u8 *src);
u8 *StringGetEnd10(u8 *str);
u8 *StringCopy8(u8 *dest, const u8 *src);
diff --git a/include/text.h b/include/text.h
index ba4ccb4b2..6e32de6dd 100644
--- a/include/text.h
+++ b/include/text.h
@@ -2,6 +2,7 @@
#define GUARD_TEXT_H
#define CHAR_SPACE 0x00
+#define CHAR_0 0xA1
#define CHAR_QUESTION_MARK 0xAC
#define CHAR_PERIOD 0xAD
#define CHAR_HYPHEN 0xAE
@@ -10,6 +11,58 @@
#define CHAR_COMMA 0xB8
#define CHAR_CURRENCY 0xB7
#define CHAR_SLASH 0xBA
+#define CHAR_A 0xBB
+#define CHAR_B 0xBC
+#define CHAR_C 0xBD
+#define CHAR_D 0xBE
+#define CHAR_E 0xBF
+#define CHAR_F 0xC0
+#define CHAR_G 0xC1
+#define CHAR_H 0xC2
+#define CHAR_I 0xC3
+#define CHAR_J 0xC4
+#define CHAR_K 0xC5
+#define CHAR_L 0xC6
+#define CHAR_M 0xC7
+#define CHAR_N 0xC8
+#define CHAR_O 0xC9
+#define CHAR_P 0xCA
+#define CHAR_Q 0xCB
+#define CHAR_R 0xCC
+#define CHAR_S 0xCD
+#define CHAR_T 0xCE
+#define CHAR_U 0xCF
+#define CHAR_V 0xD0
+#define CHAR_W 0xD1
+#define CHAR_X 0xD2
+#define CHAR_Y 0xD3
+#define CHAR_Z 0xD4
+#define CHAR_a 0xD5
+#define CHAR_b 0xD6
+#define CHAR_c 0xD7
+#define CHAR_d 0xD8
+#define CHAR_e 0xD9
+#define CHAR_f 0xDA
+#define CHAR_g 0xDB
+#define CHAR_h 0xDC
+#define CHAR_i 0xDD
+#define CHAR_j 0xDE
+#define CHAR_k 0xDF
+#define CHAR_l 0xE0
+#define CHAR_m 0xE1
+#define CHAR_n 0xE2
+#define CHAR_o 0xE3
+#define CHAR_p 0xE4
+#define CHAR_q 0xE5
+#define CHAR_r 0xE6
+#define CHAR_s 0xE7
+#define CHAR_t 0xE8
+#define CHAR_u 0xE9
+#define CHAR_v 0xEA
+#define CHAR_w 0xEB
+#define CHAR_x 0xEC
+#define CHAR_y 0xED
+#define CHAR_z 0xEE
#define CHAR_COLON 0xF0
#define EXT_CTRL_CODE_BEGIN 0xFC // extended control code
#define PLACEHOLDER_BEGIN 0xFD // string placeholder
diff --git a/include/time_events.h b/include/time_events.h
new file mode 100644
index 000000000..fd6d29f39
--- /dev/null
+++ b/include/time_events.h
@@ -0,0 +1,8 @@
+#ifndef GUARD_TIME_EVENTS_H
+#define GUARD_TIME_EVENTS_H
+
+void UpdateMirageRnd(u16);
+u8 IsMirageIslandPresent(void);
+void UpdateBirchState(u16);
+
+#endif // GUARD_TIME_EVENTS_H
diff --git a/include/title_screen.h b/include/title_screen.h
index 304ec0540..91da38018 100644
--- a/include/title_screen.h
+++ b/include/title_screen.h
@@ -3,6 +3,8 @@
#include "sprite.h"
+extern const u16 gUnknown_08393E64[];
+
void SpriteCallback_VersionBannerLeft(struct Sprite *sprite);
void SpriteCallback_VersionBannerRight(struct Sprite *sprite);
void SpriteCallback_PressStartCopyrightBanner(struct Sprite *sprite);
diff --git a/include/trader.h b/include/trader.h
new file mode 100644
index 000000000..24a9f2a07
--- /dev/null
+++ b/include/trader.h
@@ -0,0 +1,6 @@
+#ifndef GUARD_TRADER_H
+#define GUARD_TRADER_H
+
+void sub_81099CC(void);
+
+#endif // GUARD_TRADER_H
diff --git a/include/tv.h b/include/tv.h
index b1ed61a82..277d29750 100644
--- a/include/tv.h
+++ b/include/tv.h
@@ -1,9 +1,6 @@
-//
-// Created by Scott Norton on 5/18/17.
-//
+#ifndef GUARD_TV_H
+#define GUARD_TV_H
-#ifndef POKERUBY_TV_H
-#define POKERUBY_TV_H
enum
{
TVSHOW_FAN_CLUB_LETTER = 1,
@@ -20,4 +17,94 @@ enum
TVSHOW_WORLD_OF_MASTERS,
TVSHOW_MASS_OUTBREAK = 41,
};
-#endif //POKERUBY_TV_H
+
+extern u8 *gUnknown_083D1464[3];
+
+void ClearTVShowData(void);
+u8 sub_80BDEAC(u8 *);
+void sub_80BE028(void);
+void sub_80BE074(void);
+void sub_80BE138(TVShow *show);
+void sub_80BE160(TVShow *show);
+void sub_80BE160(TVShow *);
+void sub_80BE188(void);
+void sub_80BE320(void);
+void StartMassOutbreak(void);
+void sub_80BE5FC(void);
+void sub_80BE65C(void);
+void sub_80BE6A0(void);
+void nullsub_21(void);
+void sub_80BE778(void);
+void sub_80BE8EC(u16);
+void UpdateMassOutbreakTimeLeft(u16);
+void sub_80BE97C(u8);
+void sub_80BE9D4();
+void sub_80BEA50(u16);
+void sub_80BEA5C(u16);
+void sub_80BEA88(void);
+void sub_80BEA88(void);
+void sub_80BEB20(void);
+int sub_80BEBC8(struct UnknownSaveStruct2ABC *arg0);
+extern void sub_80BEBF4(void);
+void sub_80BEC10(u8);
+bool8 GetPriceReduction(u8);
+bool8 IsPriceDiscounted(u8);
+bool8 sub_80BEE48(u8);
+void sub_80BEE84(u16);
+size_t sub_80BF0B8(int);
+bool8 sub_80BF1B4(u8);
+void sub_80BF20C(void);
+void sub_80BF334(void);
+void sub_80BF3A4(void);
+void sub_80BF3DC(void);
+void sub_80BF46C(void);
+void sub_80BF478(void);
+void sub_80BF478(void);
+void sub_80BF484(void);
+void sub_80BF4BC(void);
+void sub_80BF55C(TVShow tvShow[], u8 showidx);
+void sub_80BF55C(TVShow tvShow[], u8 showidx);
+void sub_80BF588(TVShow tvShows[]);
+u16 sub_80BF674(u16 species);
+void sub_80BF6D8(void);
+s8 sub_80BF720(TVShow *);
+s8 sub_80BF74C(TVShow tvShow[]);
+bool8 sub_80BF77C(u16);
+bool8 sub_80BF77C(u16);
+u32 GetPlayerTrainerId(void);
+void sub_80BFD44(u8 *, u32, u8);
+u8 sub_80C004C(TVShow *tv1, TVShow *tv2, u8 idx);
+u8 sub_80C00B4(TVShow *tv1, TVShow *tv2, u8 idx);
+u8 sub_80C0134(TVShow *tv1, TVShow *tv2, u8 idx);
+s8 sub_80C019C(TVShow tvShows[]);
+void sub_80C01D4(void);
+void sub_80C03A8(u8 showidx);
+void sub_80C03C8(u16 species, u8 showidx);
+void sub_80C0408(void);
+bool8 sub_80C06E8(struct UnknownSaveStruct2ABC *arg0, struct UnknownSaveStruct2ABC *arg1, s8 arg2);
+void TVShowConvertInternationalString(u8 *, u8 *, u8);
+void DoTVShowTheNameRaterShow(void);
+void DoTVShowPokemonTodaySuccessfulCapture(void);
+void DoTVShowPokemonTodayFailedCapture(void);
+void DoTVShowPokemonFanClubLetter(void);
+void DoTVShowRecentHappenings(void);
+void DoTVShowPokemonFanClubOpinions(void);
+void nullsub_22(void);
+void DoTVShowPokemonNewsMassOutbreak(void);
+void DoTVShowPokemonAngler(void);
+void DoTVShowTheWorldOfMasters(void);
+void TVShowDone(void);
+void UpdateTVScreensOnMap(int, int);
+void ResetGabbyAndTy(void);
+void TakeTVShowInSearchOfTrainersOffTheAir(void);
+extern u8 GabbyAndTyGetBattleNum(void);
+void sub_80C04A0(void);
+void sub_80C0514(void *, u32, u8);
+void DoTVShowBravoTrainerPokemonProfile(void);
+void DoTVShowBravoTrainerBattleTowerProfile(void);
+void DoTVShowTodaysSmartShopper(void);
+void sub_80BE3BC(void);
+void UpdateTVShowsPerDay(u16);
+void sub_80C045C();
+
+#endif // GUARD_TV_H
diff --git a/include/unknown_task.h b/include/unknown_task.h
new file mode 100644
index 000000000..dc07767d6
--- /dev/null
+++ b/include/unknown_task.h
@@ -0,0 +1,14 @@
+#ifndef GUARD_UNKNOWN_TASK_H
+#define GUARD_UNKNOWN_TASK_H
+
+void remove_some_task(void);
+void remove_some_task(void);
+void dp12_8087EA4(void);
+void dp12_8087EA4(void);
+void sub_80895F8(u32 i, u32 i1, u32 i2);
+void sub_80895F8();
+void sub_8089668(void);
+void sub_8089668();
+void sub_8089944(int i, int i1, int i2, int i3, int i4, int i5, int i6);
+
+#endif // GUARD_UNKNOWN_TASK_H
diff --git a/include/util.h b/include/util.h
new file mode 100644
index 000000000..1851c2e82
--- /dev/null
+++ b/include/util.h
@@ -0,0 +1,13 @@
+#ifndef GUARD_UTIL_H
+#define GUARD_UTIL_H
+
+#include "sprite.h"
+
+extern const u8 gMiscBlank_Gfx[];
+extern const u32 gBitTable[];
+
+u8 CreateInvisibleSpriteWithCallback(void (*)(struct Sprite *));
+void StoreWordInTwoHalfwords(u16 *, u32);
+void LoadWordFromTwoHalfwords(u16 *, u32 *);
+
+#endif // GUARD_UTIL_H
diff --git a/include/wild_encounter.h b/include/wild_encounter.h
index 33b7df7b9..a4485b08d 100644
--- a/include/wild_encounter.h
+++ b/include/wild_encounter.h
@@ -1,6 +1,31 @@
#ifndef GUARD_WILD_ENCOUNTER_H
#define GUARD_WILD_ENCOUNTER_H
+struct WildPokemon
+{
+ u8 minLevel;
+ u8 maxLevel;
+ u16 species;
+};
+
+struct WildPokemonInfo
+{
+ u8 encounterRate;
+ const struct WildPokemon *wildPokemon;
+};
+
+struct WildPokemonHeader
+{
+ u8 mapGroup;
+ u8 mapNum;
+ struct WildPokemonInfo *landMonsInfo;
+ struct WildPokemonInfo *waterMonsInfo;
+ struct WildPokemonInfo *rockSmashMonsInfo;
+ struct WildPokemonInfo *fishingMonsInfo;
+};
+
+extern struct WildPokemonHeader gWildMonHeaders[];
+
void DisableWildEncounters(bool8 disabled);
bool8 StandardWildEncounter(u16 a, u16 b);
void RockSmashWildEncounter(void);
diff --git a/ld_script.txt b/ld_script.txt
index 7c2214347..b20e05223 100644..100755
--- a/ld_script.txt
+++ b/ld_script.txt
@@ -59,7 +59,7 @@ SECTIONS {
asm/battle_6.o(.text);
src/battle_6.o(.text);
asm/battle_6.o(.text_8030464);
- asm/battle_7.o(.text);
+ src/battle_7.o(.text);
asm/battle_8.o(.text);
asm/battle_9.o(.text);
asm/battle_10.o(.text);
@@ -134,16 +134,12 @@ SECTIONS {
src/trainer_see.o(.text);
src/wild_encounter.o(.text);
src/field_effect.o(.text);
- asm/field_effect.o(.text);
asm/unknown_task.o(.text);
asm/pokemon_menu.o(.text);
src/option_menu.o(.text);
src/pokedex.o(.text);
- asm/pokedex.o(.text);
src/trainer_card.o(.text);
src/save_menu_util.o(.text);
- src/rom_8094928.o(.text);
- asm/rom_8094928.o(.text);
src/battle_party_menu.o(.text);
asm/pokemon_storage_system.o(.text);
src/pokemon_storage_system.o(.text);
@@ -252,13 +248,12 @@ SECTIONS {
asm/battle_anim_812C144.o(.text);
asm/learn_move.o(.text);
src/fldeff_softboiled.o(.text);
- asm/decoration_inventory.o(.text);
+ src/decoration_inventory.o(.text);
src/roamer.o(.text);
asm/battle_tower.o(.text);
asm/use_pokeblock.o(.text);
asm/battle_anim_8137220.o(.text);
src/player_pc.o(.text);
- asm/player_pc.o(.text);
src/intro.o(.text);
src/field_region_map.o(.text);
asm/battle_anim_813F0F4.o(.text);
@@ -389,10 +384,10 @@ SECTIONS {
data/trainer_see.o(.rodata);
src/wild_encounter.o(.rodata);
data/wild_encounter.o(.rodata);
- data/field_effect.o(.rodata);
+ src/field_effect.o(.rodata);
data/pokemon_menu.o(.rodata);
data/option_menu.o(.rodata);
- data/pokedex.o(.rodata);
+ src/pokedex.o(.rodata);
data/trainer_card.o(.rodata);
src/battle_party_menu.o(.rodata);
data/pokemon_storage_system.o(.rodata);
@@ -460,12 +455,12 @@ SECTIONS {
data/battle_anim_81258BC.o(.rodata);
data/battle_anim_812C144.o(.rodata);
data/learn_move.o(.rodata);
- data/decoration_inventory.o(.rodata);
+ src/decoration_inventory.o(.rodata);
src/roamer.o(.rodata);
data/battle_tower.o(.rodata);
data/use_pokeblock.o(.rodata);
data/battle_anim_8137220.o(.rodata);
- data/player_pc.o(.rodata);
+ src/player_pc.o(.rodata);
src/intro.o(.rodata);
data/battle_anim_813F0F4.o(.rodata);
data/hall_of_fame.o(.rodata);
diff --git a/shared_syms.txt b/shared_syms.txt
index 16d4138e5..884f0e89d 100644
--- a/shared_syms.txt
+++ b/shared_syms.txt
@@ -22,7 +22,7 @@ unk_2016C00 = 0x2016C00;
gTransformStatuses = 0x2017800;
unk_2017810 = 0x2017810;
-unk_201FE00 = 0x201FE00;
+gMailboxInfo = 0x201FE00;
gSecretBaseRecord = 0x2017000;
diff --git a/src/bard_music.c b/src/bard_music.c
index 43c2923d2..a5514e3f7 100644
--- a/src/bard_music.c
+++ b/src/bard_music.c
@@ -1,5 +1,4 @@
#include "global.h"
-#include "asm.h"
struct BardSound
{
diff --git a/src/battle_2.c b/src/battle_2.c
index 17a583441..451c4f108 100644
--- a/src/battle_2.c
+++ b/src/battle_2.c
@@ -1,22 +1,31 @@
#include "global.h"
-#include "asm.h"
+#include "abilities.h"
#include "battle.h"
+#include "battle_interface.h"
+#include "battle_setup.h"
#include "data2.h"
+#include "item.h"
+#include "link.h"
#include "main.h"
-#include "text.h"
+#include "name_string_util.h"
#include "palette.h"
-#include "sprite.h"
-#include "task.h"
+#include "party_menu.h"
+#include "pokeball.h"
+#include "pokedex.h"
#include "pokemon.h"
-#include "species.h"
-#include "link.h"
-#include "name_string_util.h"
-#include "battle_setup.h"
#include "rng.h"
-#include "sound.h"
+#include "rom3.h"
+#include "rom_8077ABC.h"
+#include "rom_8094928.h"
#include "songs.h"
+#include "sound.h"
+#include "species.h"
+#include "sprite.h"
+#include "task.h"
+#include "text.h"
#include "trig.h"
-#include "abilities.h"
+#include "unknown_task.h"
+#include "util.h"
struct UnknownStruct6
{
@@ -55,23 +64,6 @@ struct UnknownPokemonStruct2
/*0x1D*/ u8 language;
};
-struct UnknownStruct9
-{
- u8 unk0;
- u16 unk2;
-};
-
-struct UnknownStruct10
-{
- u8 unk0_0:1;
- u8 unk0_1:1;
- u8 unk0_2:1;
- u8 filler1[1];
- u8 unk2;
- u8 unk3;
- u8 filler4[8];
-};
-
struct UnknownStruct12
{
u32 unk0;
@@ -104,8 +96,6 @@ struct UnknownStruct13
extern const u16 gUnknown_08D004E0[];
extern const struct MonCoords gCastformFrontSpriteCoords[];
-extern const struct BaseStats gBaseStats[];
-extern const u32 gBitTable[];
extern u8 ewram[];
#define ewram0 (*(struct UnknownStruct7 *)(ewram + 0x0))
@@ -147,8 +137,6 @@ extern u8 ewram[];
#define ewram17100 ((u32 *)(ewram + 0x17100))
#define ewram17130 (ewram[0x17130])
#define ewram17160 (ewram[0x17160])
-#define ewram17800 ((struct UnknownStruct9 *)(ewram + 0x17800))
-#define ewram17810 ((struct UnknownStruct10 *)(ewram + 0x17810))
#define ewram1D000 ((struct Pokemon *)(ewram + 0x1D000))
extern struct UnknownPokemonStruct2 gUnknown_02023A00[];
@@ -211,7 +199,7 @@ extern u16 gUnknown_030042C0;
extern u16 gUnknown_030042C4;
extern MainCallback gUnknown_030042D0;
extern void (*gUnknown_030042D4)(void);
-extern struct UnknownStruct11 gUnknown_030042E0;
+extern struct Struct30042E0 gUnknown_030042E0;
extern u8 gUnknown_03004324;
extern void (*gUnknown_03004330[])(void);
extern u8 gUnknown_03004340[];
@@ -231,86 +219,6 @@ extern u32 gBattleMoveDamage;
extern struct BattlePokemon gBattleMons[];
extern u8 gBattleMoveFlags;
-extern void sub_800B858(void);
-extern void dp12_8087EA4(void);
-extern void sub_80895F8();
-extern void sub_800D6D4();
-extern void sub_800DAB8();
-extern void sub_800E23C();
-extern void setup_poochyena_battle();
-extern void SetWildMonHeldItem(void);
-extern void AdjustFriendship(struct Pokemon *, u8);
-extern void sub_800DE30(u8);
-extern void sub_800B950(void);
-extern u8 battle_load_something();
-extern void OpenPartyMenu();
-extern void sub_8089668();
-extern void sub_800D74C();
-extern void sub_804777C(u8);
-extern void sub_8043DFC();
-extern u8 CreateInvisibleSpriteWithCallback(void (*)(struct Sprite *));
-extern void dp01_build_cmdbuf_x00_a_b_0(u8 a, u8 b, u8 c);
-extern void dp01_build_cmdbuf_x04_4_4_4(u8 a);
-extern void dp01_build_cmdbuf_x07_7_7_7(u8 a);
-extern void dp01_build_cmdbuf_x12_a_bb(u8 a, u8 b, u16 c);
-extern void dp01_build_cmdbuf_x2E_a(u8 a, u8 b);
-extern void dp01_build_cmdbuf_x2F_2F_2F_2F(u8 a);
-extern void dp01_build_cmdbuf_x30_TODO(u8 a, u8 *b, u8 c);
-extern void dp01_battle_side_mark_buffer_for_execution();
-extern u8 sub_8090D90();
-extern void sub_800C704(u8, u8, u8);
-extern u8 sub_8018324();
-extern u8 sub_801A02C();
-extern u8 sub_8015DFC();
-extern u8 sub_8016558();
-extern u8 sub_80173A4();
-extern u8 sub_80170DC();
-extern u8 ItemId_GetHoldEffect(u16);
-extern void sub_8094C98();
-
-void InitBattle(void);
-void sub_800EC9C(void);
-void sub_800F104(void);
-void sub_800F298(void);
-void sub_800F808(void);
-void sub_800F838(struct Sprite *);
-u8 CreateNPCTrainerParty(struct Pokemon *, u16);
-void sub_800FCFC(void);
-void sub_8010824(void);
-void sub_80101B8(void);
-void c2_081284E0(void);
-void sub_8010278(struct Sprite *);
-void sub_80102AC(struct Sprite *);
-void nullsub_37(struct Sprite *);
-void sub_8010320(struct Sprite *);
-void sub_8010494(struct Sprite *);
-void sub_801053C(struct Sprite *);
-void oac_poke_ally_(struct Sprite *);
-void nullsub_86(struct Sprite *);
-void objc_dp11b_pingpong(struct Sprite *);
-void sub_8010874(void);
-void bc_8012FAC(void);
-void bc_load_battlefield(void);
-void sub_8011384(void);
-void bc_801333C(void);
-void bc_battle_begin_message(void);
-void bc_8013568(void);
-void sub_8011800(void);
-void sub_8011834(void);
-void bc_801362C(void);
-void sub_8011970(void);
-void sub_80119B4(void);
-void sub_8011B00(void);
-void sub_8011E8C(void);
-void sub_8012324(void);
-void sub_8012FBC(u8, u8);
-u8 b_first_side();
-void sub_801365C(u8);
-void sub_801377C(void);
-void sub_80138F0(void);
-void b_cancel_multi_turn_move_maybe(u8);
-void b_std_message();
-void sub_80156DC();
void sub_800E7C4(void)
{
@@ -2040,14 +1948,14 @@ void sub_8011384(void)
}
if (battle_side_get_owner(gUnknown_02024A60) == 1
&& !(gBattleTypeFlags & (BATTLE_TYPE_EREADER_TRAINER | BATTLE_TYPE_BATTLE_TOWER | BATTLE_TYPE_LINK)))
- sub_8090D90(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
+ GetNationalPokedexFlag(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
}
else
{
if (battle_side_get_owner(gUnknown_02024A60) == 1
&& !(gBattleTypeFlags & (BATTLE_TYPE_EREADER_TRAINER | BATTLE_TYPE_BATTLE_TOWER | BATTLE_TYPE_LINK)))
{
- sub_8090D90(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
+ GetNationalPokedexFlag(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
dp01_build_cmdbuf_x04_4_4_4(0);
dp01_battle_side_mark_buffer_for_execution(gUnknown_02024A60);
}
@@ -2202,7 +2110,7 @@ void bc_801362C(void)
{
if (battle_side_get_owner(gUnknown_02024A60) == 1
&& !(gBattleTypeFlags & (BATTLE_TYPE_EREADER_TRAINER | BATTLE_TYPE_BATTLE_TOWER | BATTLE_TYPE_LINK)))
- sub_8090D90(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
+ GetNationalPokedexFlag(SpeciesToNationalPokedexNum(gBattleMons[gUnknown_02024A60].species), 2);
}
gUnknown_030042D4 = sub_8011970;
}
diff --git a/src/battle_6.c b/src/battle_6.c
index bc540ce72..866a66ae3 100644
--- a/src/battle_6.c
+++ b/src/battle_6.c
@@ -1,5 +1,6 @@
#include "global.h"
-#include "asm.h"
+#include "battle.h"
+#include "battle_message.h"
#include "menu_cursor.h"
#include "text.h"
diff --git a/src/battle_7.c b/src/battle_7.c
new file mode 100644
index 000000000..9c8b86fb4
--- /dev/null
+++ b/src/battle_7.c
@@ -0,0 +1,1237 @@
+#include "global.h"
+#include "battle.h"
+#include "battle_anim.h"
+#include "battle_interface.h"
+#include "blend_palette.h"
+#include "data2.h"
+#include "decompress.h"
+#include "main.h"
+#include "m4a.h"
+#include "palette.h"
+#include "pokemon.h"
+#include "rom_8077ABC.h"
+#include "rom_8094928.h"
+#include "songs.h"
+#include "sound.h"
+#include "species.h"
+#include "sprite.h"
+#include "task.h"
+#include "text.h"
+#include "gba/m4a_internal.h"
+
+struct Struct2019348
+{
+ u8 filler0[2];
+ u16 unk2;
+ u8 filler4[4];
+ u32 unk8;
+ u32 unkC;
+ u32 unk10;
+};
+
+extern u8 gUnknown_02023A60[][0x200];
+extern u8 gUnknown_02024A60;
+extern u32 gUnknown_02024A64;
+extern u8 gUnknown_02024A68;
+extern u16 gUnknown_02024A6A[];
+extern u8 gUnknown_02024A72[];
+extern u8 gUnknown_02024BE0[];
+extern u16 gUnknown_02024DE8;
+extern u8 gUnknown_02024E6D;
+extern u32 gUnknown_02024E70[];
+extern struct Window gUnknown_03004210;
+extern void (*gUnknown_03004330[])(void);
+extern u8 gUnknown_03004340[];
+extern u8 gUnknown_0300434C[];
+extern struct MusicPlayerInfo gMPlay_SE1;
+extern struct MusicPlayerInfo gMPlay_SE2;
+extern struct MusicPlayerInfo gMPlay_BGM;
+extern u32 gBitTable[];
+extern u16 gBattleTypeFlags;
+extern u8 gBattleMonForms[];
+extern u8 gBattleAnimPlayerMonIndex;
+extern u8 gBattleAnimEnemyMonIndex;
+extern void (*gAnimScriptCallback)(void);
+extern u8 gAnimScriptActive;
+extern const u8 *const gBattleAnims_Unknown1[];
+extern const u8 *const gBattleAnims_Unknown2[];
+extern const struct SpriteSheet gTrainerFrontPicTable[];
+extern const struct MonCoords gTrainerFrontPicCoords[];
+extern const struct SpritePalette gTrainerFrontPicPaletteTable[];
+extern const u8 gSubstituteDollTilemap[];
+extern const u8 gSubstituteDollGfx[];
+extern const u8 gSubstituteDollPal[];
+extern const struct SpriteSheet gUnknown_081FAF24;
+extern const struct SpriteTemplate gSpriteTemplate_81FAF34;
+extern void (*const gUnknown_081FAF5C[])(void);
+extern const struct SpriteSheet gUnknown_0820A47C;
+extern const struct SpriteSheet gUnknown_0820A484;
+extern const struct SpriteSheet gUnknown_0820A48C[];
+extern const struct SpriteSheet gUnknown_0820A49C[];
+extern const struct SpriteSheet gUnknown_0820A4AC;
+extern const struct SpriteSheet gUnknown_0820A4B4[];
+extern const struct SpritePalette gUnknown_0820A4D4[];
+extern const u8 gUnknown_08D09C48[];
+
+#define ewram19348 (*(struct Struct2019348 *)(ewram + 0x19348))
+
+extern void c3_0802FDF4(u8);
+extern void sub_80440EC();
+extern void sub_804777C();
+extern void sub_8141828();
+extern u8 sub_8077ABC();
+extern u8 sub_8078874(u8);
+extern u8 sub_8077F68(u8);
+extern u8 sub_8077F7C(u8);
+extern void sub_8094958(void);
+extern const u16 *pokemon_get_pal(struct Pokemon *);
+extern void sub_80105DC(struct Sprite *);
+extern void move_anim_start_t2();
+extern const u16 *species_and_otid_get_pal();
+
+void sub_80315E8(u8);
+u8 sub_803163C(u8);
+void sub_80316CC(u8);
+void sub_8031F0C(void);
+void refresh_graphics_maybe(u8, u8, u8);
+void sub_80324E0(u8 a);
+void sub_80327CC(void);
+void sub_8032978(struct Sprite *);
+void sub_80328A4(struct Sprite *);
+void sub_8032AFC(void);
+void sub_80332D0(void);
+void sub_80334EC(void);
+
+void sub_80312F0(struct Sprite *sprite)
+{
+ u8 spriteId = sprite->data1;
+
+ if (gSprites[spriteId].affineAnimEnded && !gSprites[spriteId].invisible)
+ {
+ if (gSprites[spriteId].animPaused)
+ gSprites[spriteId].animPaused = FALSE;
+ else if (gSprites[spriteId].animEnded)
+ {
+ gSprites[spriteId].callback = sub_80105DC;
+ StartSpriteAffineAnim(&gSprites[spriteId], 0);
+ sprite->callback = SpriteCallbackDummy;
+ }
+ }
+}
+
+void unref_sub_8031364(struct Sprite *sprite, bool8 stupid)
+{
+ sprite->animPaused = TRUE;
+ sprite->callback = SpriteCallbackDummy;
+ if (!stupid)
+ StartSpriteAffineAnim(sprite, 1);
+ else
+ StartSpriteAffineAnim(sprite, 1);
+ AnimateSprite(sprite);
+}
+
+void sub_80313A0(struct Sprite *sprite)
+{
+ if (!(gUnknown_02024DE8 & 1))
+ {
+ sprite->pos2.x += sprite->data0;
+ if (sprite->pos2.x == 0)
+ sprite->callback = SpriteCallbackDummy;
+ }
+}
+
+void move_anim_start_t2_for_situation(u8 a, u32 b)
+{
+ ewram17810[gUnknown_02024A60].unk0_4 = 1;
+ if (a == 0)
+ {
+ if (b == 0x20)
+ move_anim_start_t2(gUnknown_02024A60, 6);
+ else if (b == 8 || (b & 0x80))
+ move_anim_start_t2(gUnknown_02024A60, 0);
+ else if (b == 0x10)
+ move_anim_start_t2(gUnknown_02024A60, 2);
+ else if (b & 7)
+ move_anim_start_t2(gUnknown_02024A60, 4);
+ else if (b == 0x40)
+ move_anim_start_t2(gUnknown_02024A60, 5);
+ else
+ ewram17810[gUnknown_02024A60].unk0_4 = 0;
+ }
+ else
+ {
+ if (b & 0x000F0000)
+ move_anim_start_t2(gUnknown_02024A60, 3);
+ else if (b & 7)
+ move_anim_start_t2(gUnknown_02024A60, 1);
+ else if (b & 0x10000000)
+ move_anim_start_t2(gUnknown_02024A60, 7);
+ else if (b & 0x08000000)
+ move_anim_start_t2(gUnknown_02024A60, 8);
+ else if (b & 0x0000E000)
+ move_anim_start_t2(gUnknown_02024A60, 9);
+ else
+ ewram17810[gUnknown_02024A60].unk0_4 = 0;
+ }
+}
+
+bool8 move_anim_start_t3(u8 a, u8 b, u8 c, u8 d, u16 e)
+{
+ u8 taskId;
+
+ if (d == 0 && (e & 0x80))
+ {
+ gBattleMonForms[a] = e & 0x7F;
+ return TRUE;
+ }
+ if (ewram17800[a].unk0_2 && sub_803163C(d) == 0)
+ return TRUE;
+ if (ewram17800[a].unk0_2 && d == 2 && gSprites[gUnknown_02024BE0[a]].invisible)
+ {
+ refresh_graphics_maybe(a, 1, gUnknown_02024BE0[a]);
+ sub_80324E0(a);
+ return TRUE;
+ }
+ gBattleAnimPlayerMonIndex = b;
+ gBattleAnimEnemyMonIndex = c;
+ ewram17840.unk0 = e;
+ DoMoveAnim(gBattleAnims_Unknown1, d, 0);
+ taskId = CreateTask(sub_80315E8, 10);
+ gTasks[taskId].data[0] = a;
+ ewram17810[gTasks[taskId].data[0]].unk0_5 = 1;
+ return FALSE;
+}
+
+void sub_80315E8(u8 taskId)
+{
+ gAnimScriptCallback();
+ if (!gAnimScriptActive)
+ {
+ ewram17810[gTasks[taskId].data[0]].unk0_5 = 0;
+ DestroyTask(taskId);
+ }
+}
+
+u8 sub_803163C(u8 a)
+{
+ switch (a)
+ {
+ case 2:
+ case 10:
+ case 11:
+ case 12:
+ case 13:
+ case 17:
+ return 1;
+ default:
+ return 0;
+ }
+}
+
+void move_anim_start_t4(u8 a, u8 b, u8 c, u8 d)
+{
+ u8 taskId;
+
+ gBattleAnimPlayerMonIndex = b;
+ gBattleAnimEnemyMonIndex = c;
+ DoMoveAnim(gBattleAnims_Unknown2, d, 0);
+ taskId = CreateTask(sub_80316CC, 10);
+ gTasks[taskId].data[0] = a;
+ ewram17810[gTasks[taskId].data[0]].unk0_6 = 1;
+}
+
+void sub_80316CC(u8 taskId)
+{
+ gAnimScriptCallback();
+ if (!gAnimScriptActive)
+ {
+ ewram17810[gTasks[taskId].data[0]].unk0_6 = 0;
+ DestroyTask(taskId);
+ }
+}
+
+u8 sub_8031720(int unused1, int unused2)
+{
+ return 0;
+}
+
+bool8 mplay_80342A4(u8 a)
+{
+ u8 zero = 0;
+
+ if (IsSEPlaying())
+ {
+ ewram17810[a].unk8++;
+ if (ewram17810[gUnknown_02024A60].unk8 < 30)
+ return TRUE;
+ m4aMPlayStop(&gMPlay_SE1);
+ m4aMPlayStop(&gMPlay_SE2);
+ }
+ if (zero == 0)
+ {
+ ewram17810[a].unk8 = 0;
+ return FALSE;
+ }
+ return TRUE;
+}
+
+void sub_8031794(struct Pokemon *pkmn, u8 b)
+{
+ u32 personalityValue;
+ u16 species;
+ u32 r7;
+ u32 otId;
+ u8 var;
+ u16 paletteOffset;
+ const u16 *palette;
+
+ personalityValue = GetMonData(pkmn, MON_DATA_PERSONALITY);
+ if (ewram17800[b].unk2 == 0)
+ {
+ species = GetMonData(pkmn, MON_DATA_SPECIES);
+ r7 = personalityValue;
+ }
+ else
+ {
+ species = ewram17800[b].unk2;
+ r7 = gUnknown_02024E70[b];
+ }
+ otId = GetMonData(pkmn, MON_DATA_OT_ID);
+ var = battle_get_per_side_status(b);
+ HandleLoadSpecialPokePic(
+ &gMonFrontPicTable[species],
+ gMonFrontPicCoords[species].coords,
+ gMonFrontPicCoords[species].y_offset,
+ 0x02000000,
+ gUnknown_081FAF4C[var],
+ species,
+ r7);
+ paletteOffset = 0x100 + b * 16;
+ if (ewram17800[b].unk2 == 0)
+ palette = pokemon_get_pal(pkmn);
+ else
+ palette = species_and_otid_get_pal(species, otId, personalityValue);
+ sub_800D238(palette, ewram);
+ LoadPalette(ewram, paletteOffset, 0x20);
+ LoadPalette(ewram, 0x80 + b * 16, 0x20);
+ if (species == SPECIES_CASTFORM)
+ {
+ paletteOffset = 0x100 + b * 16;
+ sub_800D238(palette, ewram + 0x16400);
+ LoadPalette(ewram + 0x16400 + gBattleMonForms[b] * 32, paletteOffset, 0x20);
+ }
+ if (ewram17800[b].unk2 != 0)
+ {
+ BlendPalette(paletteOffset, 16, 6, 0x7FFF);
+ CpuCopy32(gPlttBufferFaded + paletteOffset, gPlttBufferUnfaded + paletteOffset, 32);
+ }
+}
+
+void sub_80318FC(struct Pokemon *pkmn, u8 b)
+{
+ u32 personalityValue;
+ u16 species;
+ u32 r7;
+ u32 otId;
+ u8 var;
+ u16 paletteOffset;
+ const u16 *palette;
+
+ personalityValue = GetMonData(pkmn, MON_DATA_PERSONALITY);
+ if (ewram17800[b].unk2 == 0)
+ {
+ species = GetMonData(pkmn, MON_DATA_SPECIES);
+ r7 = personalityValue;
+ }
+ else
+ {
+ species = ewram17800[b].unk2;
+ r7 = gUnknown_02024E70[b];
+ }
+ otId = GetMonData(pkmn, MON_DATA_OT_ID);
+ var = battle_get_per_side_status(b);
+ HandleLoadSpecialPokePic(
+ &gMonBackPicTable[species],
+ gMonBackPicCoords[species].coords,
+ gMonBackPicCoords[species].y_offset,
+ 0x02000000,
+ gUnknown_081FAF4C[var],
+ species,
+ r7);
+ paletteOffset = 0x100 + b * 16;
+ if (ewram17800[b].unk2 == 0)
+ palette = pokemon_get_pal(pkmn);
+ else
+ palette = species_and_otid_get_pal(species, otId, personalityValue);
+ sub_800D238(palette, ewram);
+ LoadPalette(ewram, paletteOffset, 0x20);
+ LoadPalette(ewram, 0x80 + b * 16, 0x20);
+ if (species == SPECIES_CASTFORM)
+ {
+ paletteOffset = 0x100 + b * 16;
+ sub_800D238(palette, ewram + 0x16400);
+ LoadPalette(ewram + 0x16400 + gBattleMonForms[b] * 32, paletteOffset, 0x20);
+ }
+ if (ewram17800[b].unk2 != 0)
+ {
+ BlendPalette(paletteOffset, 16, 6, 0x7FFF);
+ CpuCopy32(gPlttBufferFaded + paletteOffset, gPlttBufferUnfaded + paletteOffset, 32);
+ }
+}
+
+void unref_sub_8031A64(void)
+{
+}
+
+void nullsub_9(u16 unused)
+{
+}
+
+void sub_8031A6C(u16 a, u8 b)
+{
+ u8 status;
+ struct SpriteSheet spriteSheet;
+
+ status = battle_get_per_side_status(b);
+ DecompressPicFromTable_2(
+ &gTrainerFrontPicTable[a],
+ gTrainerFrontPicCoords[a].coords,
+ gTrainerFrontPicCoords[a].y_offset,
+ (void *)0x02000000,
+ gUnknown_081FAF4C[status],
+ 0);
+ spriteSheet.data = gUnknown_081FAF4C[status];
+ spriteSheet.size = gTrainerFrontPicTable[a].size;
+ spriteSheet.tag = gTrainerFrontPicTable[a].tag;
+ LoadCompressedObjectPic(&spriteSheet);
+ LoadCompressedObjectPalette(&gTrainerFrontPicPaletteTable[a]);
+}
+
+void sub_8031AF4(u16 a, u8 b)
+{
+ u8 status;
+
+ status = battle_get_per_side_status(b);
+ DecompressPicFromTable_2(
+ &gTrainerBackPicTable[a],
+ gTrainerBackPicCoords[a].coords,
+ gTrainerBackPicCoords[a].y_offset,
+ (void *)0x02000000,
+ gUnknown_081FAF4C[status],
+ 0);
+ LoadCompressedPalette(gTrainerBackPicPaletteTable[a].data, 0x100 + b * 16, 32);
+}
+
+void nullsub_10(int unused)
+{
+}
+
+void sub_8031B74(u16 a)
+{
+ FreeSpritePaletteByTag(gTrainerFrontPicPaletteTable[a].tag);
+ FreeSpriteTilesByTag(gTrainerFrontPicTable[a].tag);
+}
+
+void unref_sub_8031BA0(void)
+{
+ u8 count;
+ u8 i;
+
+ LoadSpritePalette(&gUnknown_0820A4D4[0]);
+ LoadSpritePalette(&gUnknown_0820A4D4[1]);
+ if (!IsDoubleBattle())
+ {
+ LoadCompressedObjectPic(&gUnknown_0820A47C);
+ LoadCompressedObjectPic(&gUnknown_0820A484);
+ count = 2;
+ }
+ else
+ {
+ LoadCompressedObjectPic(&gUnknown_0820A48C[0]);
+ LoadCompressedObjectPic(&gUnknown_0820A48C[1]);
+ LoadCompressedObjectPic(&gUnknown_0820A49C[0]);
+ LoadCompressedObjectPic(&gUnknown_0820A49C[1]);
+ count = 4;
+ }
+ for (i = 0; i < count; i++)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[i]]);
+}
+
+bool8 sub_8031C30(u8 a)
+{
+ bool8 retVal = FALSE;
+
+ if (a != 0)
+ {
+ if (a == 1)
+ {
+ LoadSpritePalette(&gUnknown_0820A4D4[0]);
+ LoadSpritePalette(&gUnknown_0820A4D4[1]);
+ }
+ else if (!IsDoubleBattle())
+ {
+ if (a == 2)
+ {
+ if (gBattleTypeFlags & 0x80)
+ LoadCompressedObjectPic(&gUnknown_0820A4AC);
+ else
+ LoadCompressedObjectPic(&gUnknown_0820A47C);
+ }
+ else if (a == 3)
+ LoadCompressedObjectPic(&gUnknown_0820A484);
+ else if (a == 4)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[0]]);
+ else if (a == 5)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[1]]);
+ else
+ retVal = TRUE;
+ }
+ else
+ {
+ if (a == 2)
+ LoadCompressedObjectPic(&gUnknown_0820A48C[0]);
+ else if (a == 3)
+ LoadCompressedObjectPic(&gUnknown_0820A48C[1]);
+ else if (a == 4)
+ LoadCompressedObjectPic(&gUnknown_0820A49C[0]);
+ else if (a == 5)
+ LoadCompressedObjectPic(&gUnknown_0820A49C[1]);
+ else if (a == 6)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[0]]);
+ else if (a == 7)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[1]]);
+ else if (a == 8)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[2]]);
+ else if (a == 9)
+ LoadCompressedObjectPic(&gUnknown_0820A4B4[gUnknown_02024A72[3]]);
+ else
+ retVal = TRUE;
+ }
+ }
+ return retVal;
+}
+
+void load_gfxc_health_bar(void)
+{
+ sub_800D238(gUnknown_08D09C48, (void *)0x02000000);
+}
+
+u8 battle_load_something(u8 *pState, u8 *b)
+{
+ bool8 retVal = FALSE;
+
+ switch (*pState)
+ {
+ case 0:
+ sub_8031F0C();
+ (*pState)++;
+ break;
+ case 1:
+ if (sub_8031C30(*b) == 0)
+ {
+ (*b)++;
+ }
+ else
+ {
+ *b = 0;
+ (*pState)++;
+ }
+ break;
+ case 2:
+ (*pState)++;
+ break;
+ case 3:
+ if ((gBattleTypeFlags & 0x80) && *b == 0)
+ gUnknown_03004340[*b] = battle_make_oam_safari_battle();
+ else
+ gUnknown_03004340[*b] = battle_make_oam_normal_battle(*b);
+ (*b)++;
+ if (*b == gUnknown_02024A68)
+ {
+ *b = 0;
+ (*pState)++;
+ }
+ break;
+ case 4:
+ sub_8043F44(*b);
+ if (gUnknown_02024A72[*b] <= 1)
+ nullsub_11(gUnknown_03004340[*b], 0);
+ else
+ nullsub_11(gUnknown_03004340[*b], 1);
+ (*b)++;
+ if (*b == gUnknown_02024A68)
+ {
+ *b = 0;
+ (*pState)++;
+ }
+ break;
+ case 5:
+ if (battle_side_get_owner(*b) == 0)
+ {
+ if (!(gBattleTypeFlags & 0x80))
+ sub_8045A5C(gUnknown_03004340[*b], &gPlayerParty[gUnknown_02024A6A[*b]], 0);
+ }
+ else
+ {
+ sub_8045A5C(gUnknown_03004340[*b], &gEnemyParty[gUnknown_02024A6A[*b]], 0);
+ }
+ sub_8043DB0(gUnknown_03004340[*b]);
+ (*b)++;
+ if (*b == gUnknown_02024A68)
+ {
+ *b = 0;
+ (*pState)++;
+ }
+ break;
+ case 6:
+ sub_80327CC();
+ sub_8094958();
+ retVal = TRUE;
+ break;
+ }
+ return retVal;
+}
+
+void sub_8031EE8(void)
+{
+ memset(ewram17810, 0, 0x30);
+ memset(&ewram17840, 0, 0x10);
+}
+
+void sub_8031F0C(void)
+{
+ sub_8031EE8();
+ memset(ewram17800, 0, 0x10);
+}
+
+void sub_8031F24(void)
+{
+ s32 i;
+
+ for (i = 0; i < gUnknown_02024A68; i++)
+ ewram17800[i].unk0_0 = gSprites[gUnknown_02024BE0[i]].invisible;
+}
+
+void sub_8031F88(u8 a)
+{
+ ewram17800[a].unk0_0 = gSprites[gUnknown_02024BE0[a]].invisible;
+}
+
+void sub_8031FC4(u8 a, u8 b, bool8 c)
+{
+ u16 paletteOffset;
+ u16 species;
+ u32 personalityValue;
+ u32 otId;
+ u8 r10;
+ const u16 *palette;
+
+ if (c)
+ {
+ StartSpriteAnim(&gSprites[gUnknown_02024BE0[a]], ewram17840.unk0);
+ paletteOffset = 0x100 + a * 16;
+ LoadPalette(ewram + 0x16400 + ewram17840.unk0 * 32, paletteOffset, 32);
+ gBattleMonForms[a] = ewram17840.unk0;
+ if (ewram17800[a].unk2 != 0)
+ {
+ BlendPalette(paletteOffset, 16, 6, 0x7FFF);
+ CpuCopy32(gPlttBufferFaded + paletteOffset, gPlttBufferUnfaded + paletteOffset, 32);
+ }
+ gSprites[gUnknown_02024BE0[a]].pos1.y = sub_8077F68(a);
+ }
+ else
+ {
+ const void *src;
+ void *dst;
+
+ if (IsContest())
+ {
+ r10 = 0;
+ species = ewram19348.unk2;
+ personalityValue = ewram19348.unk8;
+ otId = ewram19348.unkC;
+ HandleLoadSpecialPokePic(
+ &gMonBackPicTable[species],
+ gMonBackPicCoords[species].coords,
+ gMonBackPicCoords[species].y_offset,
+ 0x02000000,
+ gUnknown_081FAF4C[0],
+ species,
+ ewram19348.unk10);
+ }
+ else
+ {
+ r10 = battle_get_per_side_status(a);
+ if (battle_side_get_owner(b) == 1)
+ species = GetMonData(&gEnemyParty[gUnknown_02024A6A[b]], MON_DATA_SPECIES);
+ else
+ species = GetMonData(&gPlayerParty[gUnknown_02024A6A[b]], MON_DATA_SPECIES);
+ if (battle_side_get_owner(a) == 0)
+ {
+ personalityValue = GetMonData(&gPlayerParty[gUnknown_02024A6A[a]], MON_DATA_PERSONALITY);
+ otId = GetMonData(&gPlayerParty[gUnknown_02024A6A[a]], MON_DATA_OT_ID);
+ HandleLoadSpecialPokePic(
+ &gMonBackPicTable[species],
+ gMonBackPicCoords[species].coords,
+ gMonBackPicCoords[species].y_offset,
+ 0x02000000,
+ gUnknown_081FAF4C[r10],
+ species,
+ gUnknown_02024E70[a]);
+ }
+ else
+ {
+ personalityValue = GetMonData(&gEnemyParty[gUnknown_02024A6A[a]], MON_DATA_PERSONALITY);
+ otId = GetMonData(&gEnemyParty[gUnknown_02024A6A[a]], MON_DATA_OT_ID);
+ HandleLoadSpecialPokePic(
+ &gMonFrontPicTable[species],
+ gMonFrontPicCoords[species].coords,
+ gMonFrontPicCoords[species].y_offset,
+ 0x02000000,
+ gUnknown_081FAF4C[r10],
+ species,
+ gUnknown_02024E70[a]);
+ }
+ }
+ src = gUnknown_081FAF4C[r10];
+ dst = (void *)(VRAM + 0x10000 + gSprites[gUnknown_02024BE0[a]].oam.tileNum * 32);
+ DmaCopy32(3, src, dst, 0x800);
+ paletteOffset = 0x100 + a * 16;
+ palette = species_and_otid_get_pal(species, otId, personalityValue);
+ sub_800D238(palette, ewram);
+ LoadPalette(ewram, paletteOffset, 32);
+ if (species == SPECIES_CASTFORM)
+ {
+ u16 *paletteSrc = (u16 *)(ewram + 0x16400);
+
+ sub_800D238(palette, paletteSrc);
+ LoadPalette(paletteSrc + gBattleMonForms[b] * 16, paletteOffset, 32);
+ }
+ BlendPalette(paletteOffset, 16, 6, 0x7FFF);
+ CpuCopy32(gPlttBufferFaded + paletteOffset, gPlttBufferUnfaded + paletteOffset, 32);
+ if (!IsContest())
+ {
+ ewram17800[a].unk2 = species;
+ gBattleMonForms[a] = gBattleMonForms[b];
+ }
+ gSprites[gUnknown_02024BE0[a]].pos1.y = sub_8077F68(a);
+ StartSpriteAnim(&gSprites[gUnknown_02024BE0[a]], gBattleMonForms[a]);
+ }
+}
+
+void sub_8032350(u8 a, u8 b)
+{
+ u8 r4;
+ u16 foo;
+ const u8 *gSubstituteDollPal_;
+ void *src;
+ s32 i;
+
+ if (b == 0)
+ {
+ if (IsContest())
+ r4 = 0;
+ else
+ r4 = battle_get_per_side_status(a);
+ if (IsContest())
+ LZDecompressVram(gSubstituteDollTilemap, gUnknown_081FAF4C[r4]);
+ else if (battle_side_get_owner(a) != 0)
+ LZDecompressVram(gSubstituteDollGfx, gUnknown_081FAF4C[r4]);
+ else
+ LZDecompressVram(gSubstituteDollTilemap, gUnknown_081FAF4C[r4]);
+ // There is probably a way to do this without all the temp variables, but I couldn't figure it out.
+ foo = a * 16;
+ gSubstituteDollPal_ = gSubstituteDollPal;
+ src = gUnknown_081FAF4C[r4];
+ for (i = 0; i < 3; i++)
+ DmaCopy32(3, src, src + i * 0x800 + 0x800, 0x800);
+ LoadCompressedPalette(gSubstituteDollPal_, 0x100 + foo, 32);
+ }
+ else
+ {
+ if (!IsContest())
+ {
+ if (battle_side_get_owner(a) != 0)
+ sub_8031794(&gEnemyParty[gUnknown_02024A6A[a]], a);
+ else
+ sub_80318FC(&gPlayerParty[gUnknown_02024A6A[a]], a);
+ }
+ }
+}
+
+void refresh_graphics_maybe(u8 a, u8 b, u8 spriteId)
+{
+ sub_8032350(a, b);
+ StartSpriteAnim(&gSprites[spriteId], gBattleMonForms[a]);
+ if (b == 0)
+ gSprites[spriteId].pos1.y = sub_8077F7C(a);
+ else
+ gSprites[spriteId].pos1.y = sub_8077F68(a);
+}
+
+void sub_80324BC(u8 a, u16 b)
+{
+ if (b == 0xA4)
+ ewram17800[a].unk0_2 = 1;
+}
+
+void sub_80324E0(u8 a)
+{
+ ewram17800[a].unk0_2 = 0;
+}
+
+void sub_80324F8(struct Pokemon *pkmn, u8 b)
+{
+ u16 hp = GetMonData(pkmn, MON_DATA_HP);
+ u16 maxHP = GetMonData(pkmn, MON_DATA_MAX_HP);
+
+ if (GetHPBarLevel(hp, maxHP) == 1)
+ {
+ if (!ewram17800[b].unk0_1)
+ {
+ if (!ewram17800[b ^ 2].unk0_1)
+ PlaySE(SE_HINSI);
+ ewram17800[b].unk0_1 = 1;
+ }
+ }
+ else
+ {
+ ewram17800[b].unk0_1 = 0;
+ if (!IsDoubleBattle())
+ {
+ m4aSongNumStop(SE_HINSI);
+ return;
+ }
+ if (IsDoubleBattle() && !ewram17800[b ^ 2].unk0_1)
+ {
+ m4aSongNumStop(SE_HINSI);
+ return;
+ }
+ }
+}
+
+void sub_80325B8(void)
+{
+ u8 r4 = battle_get_side_with_given_state(0);
+
+ ewram17800[r4].unk0_1 = 0;
+ if (IsDoubleBattle())
+ ewram17800[r4 ^ 2].unk0_1 = 0;
+ m4aSongNumStop(SE_HINSI);
+}
+
+u8 unref_sub_8032604(struct Pokemon *pkmn)
+{
+ u16 hp = GetMonData(pkmn, MON_DATA_HP);
+ u16 maxHP = GetMonData(pkmn, MON_DATA_MAX_HP);
+
+ return GetHPBarLevel(hp, maxHP);
+}
+
+void sub_8032638(void)
+{
+ if (gMain.inBattle)
+ {
+ u8 r8 = battle_get_side_with_given_state(0);
+ u8 r9 = battle_get_side_with_given_state(2);
+ u8 r4 = pokemon_order_func(gUnknown_02024A6A[r8]);
+ u8 r5 = pokemon_order_func(gUnknown_02024A6A[r9]);
+
+ if (GetMonData(&gPlayerParty[r4], MON_DATA_HP) != 0)
+ sub_80324F8(&gPlayerParty[r4], r8);
+ if (IsDoubleBattle())
+ {
+ if (GetMonData(&gPlayerParty[r5], MON_DATA_HP) != 0)
+ sub_80324F8(&gPlayerParty[r5], r9);
+ }
+ }
+}
+
+void sub_80326EC(u8 a)
+{
+ s32 i;
+
+ for (i = 0; i < gUnknown_02024A68; i++)
+ {
+ if (sub_8078874(i) != 0)
+ {
+ gSprites[gUnknown_02024BE0[i]].oam.affineMode = a;
+ if (a == 0)
+ {
+ ewram17810[i].unk6 = gSprites[gUnknown_02024BE0[i]].oam.matrixNum;
+ gSprites[gUnknown_02024BE0[i]].oam.matrixNum = 0;
+ }
+ else
+ {
+ gSprites[gUnknown_02024BE0[i]].oam.matrixNum = ewram17810[i].unk6;
+ }
+ }
+ }
+}
+
+void sub_80327CC(void)
+{
+ u8 r5;
+
+ LoadCompressedObjectPic(&gUnknown_081FAF24);
+ r5 = battle_get_side_with_given_state(1);
+ ewram17810[r5].unk7 = CreateSprite(&gSpriteTemplate_81FAF34, sub_8077ABC(r5, 0), sub_8077ABC(r5, 1) + 32, 0xC8);
+ gSprites[ewram17810[r5].unk7].data0 = r5;
+ if (IsDoubleBattle())
+ {
+ r5 = battle_get_side_with_given_state(3);
+ ewram17810[r5].unk7 = CreateSprite(&gSpriteTemplate_81FAF34, sub_8077ABC(r5, 0), sub_8077ABC(r5, 1) + 32, 0xC8);
+ gSprites[ewram17810[r5].unk7].data0 = r5;
+ }
+}
+
+void sub_80328A4(struct Sprite *sprite)
+{
+ bool8 invisible = FALSE;
+ u8 r4 = sprite->data0;
+ struct Sprite *r7 = &gSprites[gUnknown_02024BE0[r4]];
+
+ if (!r7->inUse || sub_8078874(r4) == 0)
+ {
+ sprite->callback = sub_8032978;
+ return;
+ }
+ if (gAnimScriptActive || r7->invisible)
+ invisible = TRUE;
+ else if (ewram17800[r4].unk2 != 0 && gEnemyMonElevation[ewram17800[r4].unk2] == 0)
+ invisible = TRUE;
+ if (ewram17800[r4].unk0_2)
+ invisible = TRUE;
+ sprite->pos1.x = r7->pos1.x;
+ sprite->pos2.x = r7->pos2.x;
+ sprite->invisible = invisible;
+}
+
+void sub_8032978(struct Sprite *sprite)
+{
+ sprite->invisible = TRUE;
+}
+
+void sub_8032984(u8 a, u16 b)
+{
+ if (battle_side_get_owner(a) != 0)
+ {
+ if (ewram17800[a].unk2 != 0)
+ b = ewram17800[a].unk2;
+ if (gEnemyMonElevation[b] != 0)
+ gSprites[ewram17810[a].unk7].callback = sub_80328A4;
+ else
+ gSprites[ewram17810[a].unk7].callback = sub_8032978;
+ }
+}
+
+void sub_8032A08(u8 a)
+{
+ gSprites[ewram17810[a].unk7].callback = sub_8032978;
+}
+
+void sub_8032A38(void)
+{
+ u16 *ptr = (u16 *)(VRAM + 0x240);
+ s32 i;
+ s32 j;
+
+ for (i = 0; i < 9; i++)
+ {
+ for (j = 0; j < 16; j++)
+ {
+ if (!(*ptr & 0xF000))
+ *ptr |= 0xF000;
+ if (!(*ptr & 0x0F00))
+ *ptr |= 0x0F00;
+ if (!(*ptr & 0x00F0))
+ *ptr |= 0x00F0;
+ if (!(*ptr & 0x000F))
+ *ptr |= 0x000F;
+ ptr++;
+ }
+ }
+}
+
+void sub_8032AA8(u8 a, u8 b)
+{
+ ewram17800[a].unk2 = 0;
+ gBattleMonForms[a] = 0;
+ if (b == 0)
+ sub_80324E0(a);
+}
+
+void nullsub_45(void)
+{
+}
+
+void sub_8032AE0(void)
+{
+ gUnknown_03004330[gUnknown_02024A60] = sub_8032AFC;
+}
+
+void sub_8032AFC(void)
+{
+ if (gUnknown_02024A64 & gBitTable[gUnknown_02024A60])
+ {
+ if (gUnknown_02023A60[gUnknown_02024A60][0] <= 0x38)
+ gUnknown_081FAF5C[gUnknown_02023A60[gUnknown_02024A60][0]]();
+ else
+ sub_80334EC();
+ }
+}
+
+void sub_8032B4C(void)
+{
+ if (gSprites[gUnknown_02024BE0[gUnknown_02024A60]].callback == SpriteCallbackDummy)
+ sub_80334EC();
+}
+
+// Duplicate of sub_8032B4C
+void sub_8032B84(void)
+{
+ if (gSprites[gUnknown_02024BE0[gUnknown_02024A60]].callback == SpriteCallbackDummy)
+ sub_80334EC();
+}
+
+void sub_8032BBC(void)
+{
+ if (gSprites[gUnknown_02024BE0[gUnknown_02024A60]].callback == SpriteCallbackDummy)
+ {
+ sub_8031B74(gSprites[gUnknown_02024BE0[gUnknown_02024A60]].oam.affineParam);
+ gSprites[gUnknown_02024BE0[gUnknown_02024A60]].oam.tileNum = gSprites[gUnknown_02024BE0[gUnknown_02024A60]].data5;
+ FreeSpriteOamMatrix(&gSprites[gUnknown_02024BE0[gUnknown_02024A60]]);
+ DestroySprite(&gSprites[gUnknown_02024BE0[gUnknown_02024A60]]);
+ sub_80334EC();
+ }
+}
+
+void sub_8032C4C(void)
+{
+ if ((--ewram17810[gUnknown_02024A60].unk9) == 0xFF)
+ {
+ ewram17810[gUnknown_02024A60].unk9 = 0;
+ sub_80334EC();
+ }
+}
+
+void sub_8032C88(void)
+{
+ bool8 r6 = FALSE;
+
+ if (!IsDoubleBattle() || (IsDoubleBattle() && (gBattleTypeFlags & BATTLE_TYPE_MULTI)))
+ {
+ if (gSprites[gUnknown_03004340[gUnknown_02024A60]].callback == SpriteCallbackDummy)
+ r6 = TRUE;
+ }
+ else
+ {
+ if (gSprites[gUnknown_03004340[gUnknown_02024A60]].callback == SpriteCallbackDummy
+ && gSprites[gUnknown_03004340[gUnknown_02024A60 ^ 2]].callback == SpriteCallbackDummy)
+ r6 = TRUE;
+ }
+ if (IsCryPlayingOrClearCrySongs())
+ r6 = FALSE;
+
+ if (r6 && ewram17810[gUnknown_02024A60].unk1_0 && ewram17810[gUnknown_02024A60 ^ 2].unk1_0)
+ {
+ ewram17810[gUnknown_02024A60].unk0_7 = 0;
+ ewram17810[gUnknown_02024A60].unk1_0 = 0;
+ ewram17810[gUnknown_02024A60 ^ 2].unk0_7 = 0;
+ ewram17810[gUnknown_02024A60 ^ 2].unk1_0 = 0;
+ FreeSpriteTilesByTag(0x27F9);
+ FreeSpritePaletteByTag(0x27F9);
+ if (gBattleTypeFlags & BATTLE_TYPE_MULTI)
+ m4aMPlayContinue(&gMPlay_BGM);
+ else
+ m4aMPlayVolumeControl(&gMPlay_BGM, 0xFFFF, 256);
+ ewram17810[gUnknown_02024A60].unk9 = 3;
+ gUnknown_03004330[gUnknown_02024A60] = sub_8032C4C;
+ }
+}
+
+void sub_8032E2C(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_3 && !ewram17810[gUnknown_02024A60].unk0_7)
+ sub_8141828(gUnknown_02024A60, &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]]);
+ if (!ewram17810[gUnknown_02024A60 ^ 2].unk0_3 && !ewram17810[gUnknown_02024A60 ^ 2].unk0_7)
+ sub_8141828(gUnknown_02024A60 ^ 2, &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60 ^ 2]]);
+ if (!ewram17810[gUnknown_02024A60].unk0_3 && !ewram17810[gUnknown_02024A60 ^ 2].unk0_3)
+ {
+ if (IsDoubleBattle() && !(gBattleTypeFlags & BATTLE_TYPE_MULTI))
+ {
+ DestroySprite(&gSprites[gUnknown_0300434C[gUnknown_02024A60 ^ 2]]);
+ sub_8045A5C(
+ gUnknown_03004340[gUnknown_02024A60 ^ 2],
+ &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60 ^ 2]],
+ 0);
+ sub_804777C(gUnknown_02024A60 ^ 2);
+ sub_8043DFC(gUnknown_03004340[gUnknown_02024A60 ^ 2]);
+ sub_8032984(
+ gUnknown_02024A60 ^ 2,
+ GetMonData(&gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60 ^ 2]], MON_DATA_SPECIES));
+ }
+ DestroySprite(&gSprites[gUnknown_0300434C[gUnknown_02024A60]]);
+ sub_8045A5C(
+ gUnknown_03004340[gUnknown_02024A60],
+ &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]],
+ 0);
+ sub_804777C(gUnknown_02024A60);
+ sub_8043DFC(gUnknown_03004340[gUnknown_02024A60]);
+ sub_8032984(
+ gUnknown_02024A60,
+ GetMonData(&gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]], MON_DATA_SPECIES));
+
+ ewram17840.unk9_0 = 0;
+ gUnknown_03004330[gUnknown_02024A60] = sub_8032C88;
+ }
+}
+
+void sub_8033018(void)
+{
+ if (gSprites[gUnknown_02024BE0[gUnknown_02024A60]].animEnded == TRUE
+ && gSprites[gUnknown_02024BE0[gUnknown_02024A60]].pos2.x == 0)
+ {
+ if (!ewram17810[gUnknown_02024A60].unk0_7)
+ {
+ sub_8141828(gUnknown_02024A60, &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]]);
+ return;
+ }
+ if (ewram17810[gUnknown_02024A60].unk1_0)
+ {
+ ewram17810[gUnknown_02024A60].unk0_7 = 0;
+ ewram17810[gUnknown_02024A60].unk1_0 = 0;
+ FreeSpriteTilesByTag(0x27F9);
+ FreeSpritePaletteByTag(0x27F9);
+ sub_80334EC();
+ return;
+ }
+ }
+}
+
+void sub_80330C8(void)
+{
+ s16 r4 = sub_8045C78(gUnknown_02024A60, gUnknown_03004340[gUnknown_02024A60], 0, 0);
+
+ sub_8043DFC(gUnknown_03004340[gUnknown_02024A60]);
+ if (r4 != -1)
+ sub_80440EC(gUnknown_03004340[gUnknown_02024A60], r4, 0);
+ else
+ sub_80334EC();
+}
+
+void sub_803311C(void)
+{
+ if (!gSprites[gUnknown_02024BE0[gUnknown_02024A60]].inUse)
+ {
+ sub_8043DB0(gUnknown_03004340[gUnknown_02024A60]);
+ sub_80334EC();
+ }
+}
+
+void sub_8033160(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_6)
+ {
+ FreeSpriteOamMatrix(&gSprites[gUnknown_02024BE0[gUnknown_02024A60]]);
+ DestroySprite(&gSprites[gUnknown_02024BE0[gUnknown_02024A60]]);
+ sub_8032A08(gUnknown_02024A60);
+ sub_8043DB0(gUnknown_03004340[gUnknown_02024A60]);
+ sub_80334EC();
+ }
+}
+
+void sub_80331D0(void)
+{
+ if (gUnknown_03004210.state == 0)
+ sub_80334EC();
+}
+
+void bx_blink_t7(void)
+{
+ u8 spriteId = gUnknown_02024BE0[gUnknown_02024A60];
+
+ if (gSprites[spriteId].data1 == 32)
+ {
+ gSprites[spriteId].data1 = 0;
+ gSprites[spriteId].invisible = FALSE;
+ gUnknown_02024E6D = 0;
+ sub_80334EC();
+ }
+ else
+ {
+ if (((u16)gSprites[spriteId].data1 % 4) == 0)
+ gSprites[spriteId].invisible ^= 1;
+ gSprites[spriteId].data1++;
+ }
+}
+
+void sub_8033264(void)
+{
+ if (gSprites[gUnknown_03004340[gUnknown_02024A60]].callback == SpriteCallbackDummy)
+ {
+ if (ewram17800[gUnknown_02024A60].unk0_2)
+ move_anim_start_t4(gUnknown_02024A60, gUnknown_02024A60, gUnknown_02024A60, 6);
+ gUnknown_03004330[gUnknown_02024A60] = sub_80332D0;
+ }
+}
+
+void sub_80332D0(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_6)
+ {
+ CreateTask(c3_0802FDF4, 10);
+ sub_80334EC();
+ }
+}
+
+void sub_8033308(void)
+{
+ if (ewram17810[gUnknown_02024A60].unk1_0)
+ {
+ ewram17810[gUnknown_02024A60].unk0_7 = 0;
+ ewram17810[gUnknown_02024A60].unk1_0 = 0;
+ FreeSpriteTilesByTag(0x27F9);
+ FreeSpritePaletteByTag(0x27F9);
+ StartSpriteAnim(&gSprites[gUnknown_02024BE0[gUnknown_02024A60]], 0);
+ sub_8045A5C(
+ gUnknown_03004340[gUnknown_02024A60],
+ &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]],
+ 0);
+ sub_804777C(gUnknown_02024A60);
+ sub_8043DFC(gUnknown_03004340[gUnknown_02024A60]);
+ sub_8031F88(gUnknown_02024A60);
+ gUnknown_03004330[gUnknown_02024A60] = sub_8033264;
+ }
+}
+
+void sub_80333D4(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_3 && !ewram17810[gUnknown_02024A60].unk0_7)
+ sub_8141828(gUnknown_02024A60, &gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]]);
+ if (gSprites[gUnknown_0300434C[gUnknown_02024A60]].callback == SpriteCallbackDummy
+ && !ewram17810[gUnknown_02024A60].unk0_3)
+ {
+ DestroySprite(&gSprites[gUnknown_0300434C[gUnknown_02024A60]]);
+ sub_8032984(gUnknown_02024A60, GetMonData(&gEnemyParty[gUnknown_02024A6A[gUnknown_02024A60]], MON_DATA_SPECIES));
+ gUnknown_03004330[gUnknown_02024A60] = sub_8033308;
+ }
+}
+
+void sub_8033494(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_4)
+ sub_80334EC();
+}
+
+void sub_80334C0(void)
+{
+ if (!ewram17810[gUnknown_02024A60].unk0_5)
+ sub_80334EC();
+}
+
+void sub_80334EC(void)
+{
+ gUnknown_03004330[gUnknown_02024A60] = sub_8032AFC;
+ gUnknown_02024A64 &= ~gBitTable[gUnknown_02024A60];
+}
diff --git a/src/battle_811DA74.c b/src/battle_811DA74.c
index 56a4bd0c4..b855f1535 100644
--- a/src/battle_811DA74.c
+++ b/src/battle_811DA74.c
@@ -1,18 +1,24 @@
#include "global.h"
-#include "asm.h"
#include "battle.h"
#include "battle_interface.h"
#include "data2.h"
+#include "battle_811DA74.h"
+#include "battle_anim_813F0F4.h"
#include "link.h"
#include "m4a.h"
#include "main.h"
#include "palette.h"
+#include "pokeball.h"
#include "pokemon.h"
+#include "rom3.h"
+#include "rom_8077ABC.h"
#include "sound.h"
#include "songs.h"
#include "sprite.h"
#include "string_util.h"
+#include "task.h"
#include "text.h"
+#include "util.h"
struct UnknownStruct1
{
@@ -21,24 +27,6 @@ struct UnknownStruct1
u8 unk2[0x1FE];
};
-struct UnknownStruct2
-{
- u8 unk0_0:1;
- u8 unk0_1:2;
- u8 unk0_3:1;
- u8 unk0_4:1;
- u8 unk0_5:1;
- u8 unk0_6:1;
- u8 unk0_7:1;
- u8 unk1_0:1;
- u8 filler2[2];
- u8 unk4;
- u8 unk5;
- u8 filler6[3];
- u8 unk9;
- u8 fillerA[2];
-};
-
//Possibly PokemonSubstruct1
struct UnknownStruct3
{
@@ -47,26 +35,12 @@ struct UnknownStruct3
u8 ppBonuses;
};
-struct UnknownStruct4
-{
- u8 unk0_0:2;
- u8 unk0_2:1;
- u8 unk0_3:1;
-};
-
struct UnknownStruct5
{
u8 unk0_0:7;
u8 unk0_7:1;
};
-struct UnknownStruct6
-{
- u8 filler0[9];
- u8 unk9;
-};
-
-extern u32 gBitTable[];
extern u16 gBattleTypeFlags;
extern struct UnknownStruct5 gUnknown_020238C8;
@@ -100,12 +74,6 @@ extern u8 gAnimScriptActive;
extern void (*gAnimScriptCallback)(void);
extern void (*const gUnknown_083FE4F4[])(void);
-extern u8 ewram[];
-
-#define ewram17800 ((struct UnknownStruct4 *)(ewram + 0x17800))
-#define ewram17810 ((struct UnknownStruct2 *)(ewram + 0x17810))
-#define ewram17840 (*(struct UnknownStruct6 *)(ewram + 0x17840))
-
extern u8 move_anim_start_t3();
extern u8 sub_8078874();
extern void sub_8044CA0(u8);
@@ -150,8 +118,6 @@ extern void c3_0802FDF4(u8);
extern void sub_8031F88();
extern void sub_8141828();
extern void c2_8011A1C(void);
-extern void dp01_prepare_buffer_wireless_probably();
-extern void dp01_build_cmdbuf_x1D_1D_numargs_varargs(int, u16, void *);
void sub_811DA94(void);
void sub_811E0A0(void);
@@ -164,6 +130,7 @@ void sub_811FF30(void);
void sub_812071C(u8);
void sub_81208E0(void);
+
void nullsub_74(void)
{
}
@@ -1518,7 +1485,7 @@ void sub_8120588(void)
gTasks[taskId].data[0] = gUnknown_02024A60;
if (ewram17810[gUnknown_02024A60].unk0_0)
gTasks[gUnknown_02024E68[gUnknown_02024A60]].func = sub_8044CA0;
- ewram17840.unk9 |= 1;
+ ewram17840.unk9_0 = 1;
gUnknown_03004330[gUnknown_02024A60] = nullsub_74;
}
diff --git a/src/battle_ai.c b/src/battle_ai.c
index dbd926000..cb8023251 100644
--- a/src/battle_ai.c
+++ b/src/battle_ai.c
@@ -1,7 +1,6 @@
#include "global.h"
#include "battle_ai.h"
#include "abilities.h"
-#include "asm.h"
#include "battle.h"
#include "battle_move_effects.h"
#include "data2.h"
@@ -9,11 +8,9 @@
#include "moves.h"
#include "pokemon.h"
#include "rng.h"
+#include "rom_8077ABC.h"
#include "species.h"
-
-extern void sub_801CAF8(u8, u8);
-
-extern void move_effectiveness_something(u16, u8, u8);
+#include "util.h"
extern u16 gBattleTypeFlags;
extern u16 gBattleWeather;
@@ -35,9 +32,7 @@ extern struct BattlePokemon gUnknown_02024A8C[];
extern u8 gUnknown_030042E0[];
extern u8 gCritMultiplier;
extern u16 gTrainerBattleOpponent;
-extern u32 gBitTable[];
extern u8 *BattleAIs[];
-extern struct BaseStats gBaseStats[];
/*
gAIScriptPtr is a pointer to the next battle AI cmd command to read.
@@ -1998,7 +1993,7 @@ static void BattleAICmd_get_item(void)
index = gEnemyMonIndex;
// this hack and a half matches. whatever. i dont care. someone else fix this mess later. PS: still cant fix this.
- AI_THINKING_STRUCT->funcResult = unk_2000000[0x160CC + (index * 2)];
+ AI_THINKING_STRUCT->funcResult = ewram[0x160CC + (index * 2)];
gAIScriptPtr += 2;
}
diff --git a/src/battle_anim.c b/src/battle_anim.c
index bdb34365f..90e5c97c3 100644
--- a/src/battle_anim.c
+++ b/src/battle_anim.c
@@ -1,9 +1,14 @@
#include "global.h"
#include "battle_anim.h"
-#include "asm.h"
+#include "battle.h"
+#include "battle_anim_80CA710.h"
+#include "battle_interface.h"
+#include "contest.h"
#include "decompress.h"
#include "m4a.h"
+#include "main.h"
#include "palette.h"
+#include "rom_8077ABC.h"
#include "sound.h"
#include "sprite.h"
#include "task.h"
@@ -57,20 +62,6 @@ extern const struct SpriteSheet gBattleAnimPicTable[];
extern const struct SpritePalette gBattleAnimPaletteTable[];
extern const struct BattleAnimBackground gBattleAnimBackgroundTable[];
-extern void sub_8079E24();
-extern void sub_8043EB4();
-extern u8 sub_8079E90();
-extern u8 sub_8077ABC();
-extern u8 sub_8078874(u8);
-extern void sub_8078914();
-extern u8 sub_80AEB1C();
-extern void sub_80E4EF8(int, int, int, int, u16, u8, int);
-extern u8 sub_80789BC();
-extern void sub_80AB2AC(void);
-extern void sub_800D7B8(void);
-extern u8 obj_id_for_side_relative_to_move();
-extern u8 battle_get_per_side_status_permutated();
-
static void RunAnimScriptCommand(void);
static void ScriptCmd_loadsprite(void);
static void ScriptCmd_unloadsprite(void);
diff --git a/src/battle_anim_80A7E7C.c b/src/battle_anim_80A7E7C.c
index 285a782f3..12b53d7d9 100644
--- a/src/battle_anim_80A7E7C.c
+++ b/src/battle_anim_80A7E7C.c
@@ -1,5 +1,6 @@
#include "global.h"
#include "battle_anim.h"
+#include "rom_8077ABC.h"
#include "sprite.h"
#include "task.h"
#include "trig.h"
@@ -15,20 +16,6 @@ extern u16 gUnknown_0202F7BC;
extern u8 gBattleAnimPlayerMonIndex;
extern u8 gBattleAnimEnemyMonIndex;
-extern u8 obj_id_for_side_relative_to_move(u8 side);
-extern void DestroyAnimVisualTask(u8 task);
-extern u8 battle_get_side_with_given_state(u8 state);
-extern u8 battle_side_get_owner(u8 side);
-extern void oamt_set_x3A_32(struct Sprite *sprite, void(*callback)(struct Sprite*));
-extern void sub_8078458(struct Sprite *sprite);
-extern void move_anim_8072740(struct Sprite *sprite);
-extern void sub_8078A5C(struct Sprite *sprite);
-extern void sub_80784A8(struct Sprite *sprite);
-extern void sub_8078E70(u8 sprite, u8);
-extern void obj_id_set_rotscale(u8 sprite, int, int, u16);
-extern void sub_8078F40(u8 sprite);
-extern void sub_8078F9C(u8 sprite);
-
static void sub_80A7EF0(u8 task);
static void sub_80A808C(u8 task);
static void sub_80A81D8(u8 task);
diff --git a/src/battle_anim_81258BC.c b/src/battle_anim_81258BC.c
index 42a685f4a..fe4e9bd38 100644
--- a/src/battle_anim_81258BC.c
+++ b/src/battle_anim_81258BC.c
@@ -1,7 +1,9 @@
#include "global.h"
-#include "asm.h"
-#include "text.h"
+#include "battle_anim_81258BC.h"
+#include "battle.h"
+#include "battle_message.h"
#include "menu_cursor.h"
+#include "text.h"
extern struct Window gUnknown_03004210;
extern u8 gUnknown_020238CC[];
@@ -11,12 +13,10 @@ extern const u8 gUnknown_08400CBB[];
extern u8 gUnknown_02024A60;
extern const u8 gUnknown_08400D15[];
-extern void* gUnknown_03004330[];
+extern void *gUnknown_03004330[];
extern u16 gUnknown_030042A0;
extern u16 gUnknown_030042A4;
-void bx_battle_menu_t6_2(void);
-
#if ENGLISH
#define SUB_812BB10_TILE_DATA_OFFSET 440
#elif GERMAN
diff --git a/src/battle_interface.c b/src/battle_interface.c
index 61a6a5853..042861c22 100644
--- a/src/battle_interface.c
+++ b/src/battle_interface.c
@@ -1,14 +1,18 @@
#include "global.h"
-#include "asm.h"
+#include "battle.h"
+#include "battle_interface.h"
+#include "decompress.h"
+#include "palette.h"
+#include "pokedex.h"
+#include "pokemon.h"
+#include "rom_8077ABC.h"
+#include "safari_zone.h"
+#include "songs.h"
+#include "sound.h"
#include "sprite.h"
#include "string_util.h"
+#include "task.h"
#include "text.h"
-#include "decompress.h"
-#include "sound.h"
-#include "songs.h"
-#include "battle.h"
-#include "palette.h"
-#include "battle_interface.h"
struct UnknownStruct5
{
@@ -19,18 +23,6 @@ struct UnknownStruct5
u32 unk10;
};
-struct UnknownStruct6
-{
- u8 bit_0:1;
- u8 bit_1:1;
- u8 bit_2:1;
- u8 bit_3:1;
- u8 bit_4:1;
- u8 bit_5:1;
- u8 bit_6:1;
- u8 bit_7:1;
-};
-
struct UnknownStruct7
{
u8 filler0[0x180];
@@ -40,7 +32,6 @@ extern u8 ewram[];
#define ewram520 ((struct UnknownStruct7 *)(ewram + 0x00520))
#define ewram16088 (*(u8 *) (ewram + 0x16088))
#define ewram16089 (*(u8 *) (ewram + 0x16089))
-#define ewram17800 ((struct UnknownStruct6 *)(ewram + 0x17800))
#define ewram17850 ((struct UnknownStruct5 *)(ewram + 0x17850))
extern u8 gUnknown_020238CC[];
@@ -50,9 +41,7 @@ extern u8 gUnknown_02024A72[];
extern u8 gUnknown_03004340[];
extern u16 gBattleTypeFlags;
-extern u8 gNumSafariBalls;
-extern u32 gExperienceTables[8][101];
extern const struct SpriteTemplate gSpriteTemplate_820A4EC[];
extern const struct SpriteTemplate gSpriteTemplate_820A51C[];
extern const struct SpriteTemplate gSpriteTemplate_820A54C;
@@ -82,23 +71,17 @@ extern const u8 gUnknown_0820A81C[];
extern const u8 gUnknown_0820A864[];
extern const u8 gUnknown_0820A89C[];
extern const u8 gUnknown_0820A8B0[];
-extern const struct BaseStats gBaseStats[];
extern const u8 BattleText_SafariBalls[];
extern const u8 BattleText_SafariBallsLeft[];
extern const u8 BattleText_HighlightRed[];
extern const u8 gUnknown_08D1216C[][32];
-extern const u8 *const gNatureNames[];
extern const u16 gBattleInterfaceStatusIcons_DynPal[];
#define ABS(n) ((n) >= 0 ? (n) : -(n))
// Used for computing copy destination addresses
#define MACRO1(n) ((n) - (n) / 8 * 8) + 64 * ((n) / 8)
-extern int sub_8040D3C();
-extern u8 sub_8090D90();
-extern void load_gfxc_health_bar();
-
static void sub_8043D5C(struct Sprite *);
static const void *sub_8043CDC(u8);
static void sub_8044210(u8, s16, u8);
@@ -939,7 +922,7 @@ static void sub_8044210(u8 a, s16 b, u8 c)
// TODO: make this a local variable
memcpy(str, gUnknown_0820A89C, sizeof(str));
r4 = gSprites[a].data6;
- if ((ewram17800[r4].bit_4) == 0)
+ if ((ewram17800[r4].unk0_4) == 0)
return;
ptr = str + 6;
if (c == 0)
@@ -1312,8 +1295,8 @@ void sub_804454C(void)
{
u8 r6;
- ewram17800[i].bit_4 ^= 1;
- r6 = ewram17800[i].bit_4;
+ ewram17800[i].unk0_4 ^= 1;
+ r6 = ewram17800[i].unk0_4;
if (battle_side_get_owner(i) == 0)
{
@@ -2518,7 +2501,7 @@ static void sub_8045458(u8 a, u8 b)
if (battle_side_get_owner(r4) != 0)
{
u16 species = GetMonData(&gEnemyParty[gUnknown_02024A6A[r4]], MON_DATA_SPECIES);
- if (sub_8090D90(SpeciesToNationalPokedexNum(species), 1) != 0)
+ if (GetNationalPokedexFlag(SpeciesToNationalPokedexNum(species), 1) != 0)
{
r4 = gSprites[a].data5;
if (b != 0)
@@ -2587,7 +2570,7 @@ static void draw_status_ailment_maybe(u8 a)
for (i = 0; i < 3; i++)
CpuCopy32(r6, (void *)(OBJ_VRAM0 + (gSprites[a].oam.tileNum + r8 + i) * 32), 32);
- if (!ewram17800[r7].bit_4)
+ if (!ewram17800[r7].unk0_4)
CpuCopy32(sub_8043CDC(1), (void *)(OBJ_VRAM0 + gSprites[r10].oam.tileNum * 32), 64);
sub_8045458(a, 1);
@@ -2602,7 +2585,7 @@ static void draw_status_ailment_maybe(u8 a)
CpuCopy32(r6, (void *)(OBJ_VRAM0 + (gSprites[a].oam.tileNum + r8) * 32), 96);
if (IsDoubleBattle() == TRUE || battle_side_get_owner(r7) == TRUE)
{
- if (!ewram17800[r7].bit_4)
+ if (!ewram17800[r7].unk0_4)
{
CpuCopy32(sub_8043CDC(0), (void *)(OBJ_VRAM0 + gSprites[r10].oam.tileNum * 32), 32);
CpuCopy32(sub_8043CDC(0x41), (void *)(OBJ_VRAM0 + (gSprites[r10].oam.tileNum + 1) * 32), 32);
@@ -2809,7 +2792,7 @@ s32 sub_8045C78(u8 a, u8 unused1, u8 c, u8 unused2)
r5 = ABS(r8 / r5);
r6 = sub_8045F58(ewram17850[a].unk4, ewram17850[a].unk8, r8, &ewram17850[a].unk10, 8, r5);
}
- if (c == 1 || (c == 0 && (!ewram17800[a].bit_4)))
+ if (c == 1 || (c == 0 && (!ewram17800[a].unk0_4)))
sub_8045D58(a, c);
if (r6 == -1)
ewram17850[a].unk10 = 0;
@@ -3044,7 +3027,7 @@ u8 GetScaledHPFraction(s16 hp, s16 maxhp, u8 scale)
return result;
}
-int GetHPBarLevel(s16 hp, s16 maxhp)
+u8 GetHPBarLevel(s16 hp, s16 maxhp)
{
int result;
diff --git a/src/battle_party_menu.c b/src/battle_party_menu.c
index 359517ecd..c02290e80 100644
--- a/src/battle_party_menu.c
+++ b/src/battle_party_menu.c
@@ -1,10 +1,16 @@
#include "global.h"
#include "battle_party_menu.h"
-#include "asm.h"
+#include "battle.h"
+#include "item_menu.h"
#include "main.h"
#include "menu.h"
+#include "menu_helpers.h"
#include "palette.h"
+#include "party_menu.h"
#include "pokemon.h"
+#include "pokemon_summary_screen.h"
+#include "rom_8077ABC.h"
+#include "rom_8094928.h"
#include "songs.h"
#include "sound.h"
#include "string_util.h"
@@ -12,41 +18,29 @@
#include "task.h"
#include "text.h"
-extern u8 IsLinkDoubleBattle(void);
-extern void TryCreatePartyMenuMonIcon(u8, u8, struct Pokemon *);
-extern void LoadHeldItemIconGraphics(void);
-extern void CreateHeldItemIcons_806DC34();
-extern u8 sub_806BD58(u8, u8);
-extern void PartyMenuPrintMonsLevelOrStatus(void);
-extern void PrintPartyMenuMonNicknames(void);
-extern void PartyMenuTryPrintMonsHP(void);
-extern void nullsub_13(void);
-extern void PartyMenuDrawHPBars(void);
-extern u8 sub_806B58C(u8);
-extern u8 GetItemEffectType();
-extern void sub_806E750(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, int);
-extern u16 sub_806BD80();
-extern u8 sub_806CA38();
-extern void sub_806D5A4(void);
-extern void sub_802E414(void);
-extern void sub_8094D60(void);
-extern void sub_80A6DCC(void);
-extern void sub_806AF4C();
-extern u8 sub_80F9344(void);
-extern u8 sub_806B124(void);
-extern void sub_806C994();
-extern void sub_806BF74();
-extern void sub_806AEDC(void);
-extern TaskFunc PartyMenuGetPopupMenuFunc(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, u8);
-extern void ShowPokemonSummaryScreen(struct Pokemon *, u8, u8, void (*)(u8), int);
-extern void sub_806E7D0(u8, const struct PartyPopupMenu *);
-extern u8 *sub_8040D08();
-extern u8 sub_8094C20();
-extern void sub_8040B8C(void);
-extern u8 pokemon_order_func(u8);
-extern void sub_8094C98(u8, u8);
-extern void sub_806E6F0();
-extern void sub_806D538();
+#define DATA_COUNT (6)
+
+extern u8 ewram[];
+
+struct Unk201B000
+{
+ //u8 filler0[0x260];
+ struct Pokemon unk0[6];
+ u8 filler258[1];
+ u8 unk259;
+ u8 filler25A[6];
+ u8 unk260;
+ u8 unk261;
+ u8 filler262[2];
+ s16 unk264[DATA_COUNT * 2]; // This may be a union
+ u8 filler27C[2];
+ s16 unk27E;
+ s16 unk280;
+ s16 unk282;
+};
+
+#define ewram1B000 (*(struct Unk201B000 *)(ewram + 0x1B000))
+#define UNK_201606C_ARRAY (ewram + 0x1606C) // lazy define but whatever.
extern u16 gScriptItemId;
extern u8 gPlayerPartyCount;
@@ -56,10 +50,19 @@ extern u8 gUnknown_02024E6C;
extern u8 gUnknown_0202E8F4;
extern u8 gUnknown_0202E8F5;
extern u8 gUnknown_0202E8F6;
+extern u8 gUnknown_02038470[3];
extern u8 gUnknown_02038473;
extern u8 gUnknown_020384F0;
extern void (*gUnknown_03004AE4)(); //don't know types yet
+extern struct PokemonStorage gPokemonStorage;
+extern void nullsub_14();
+void sub_8094C98(u8, u8);
+u8 pokemon_order_func(u8);
+
+static void sub_8094998(u8[3], u8);
+static void sub_8094A74(u8[3], u8, u32);
+static void sub_8094D60(void);
static void Task_809527C(u8);
static void Task_80952B4(u8);
static void Task_80952E4(u8);
@@ -87,11 +90,276 @@ static const struct PartyPopupMenu sBattlePartyPopupMenus[] =
{ARRAY_COUNT(Unknown_83B5FF2), 9, Unknown_83B5FF2},
};
-// rom_8094928 is part of this file, has yet to be decompiled.
+void unref_sub_8094928(struct PokemonStorage *ptr)
+{
+ *ptr = gPokemonStorage;
+}
+
+void unref_sub_8094940(struct PokemonStorage *ptr)
+{
+ gPokemonStorage = *ptr;
+}
+
+void sub_8094958(void)
+{
+ sub_8094998(gUnknown_02038470, sub_803FBBC());
+}
+
+void sub_8094978(u8 arg1, u8 arg2)
+{
+ sub_8094A74((UNK_201606C_ARRAY) + arg1 * 3, arg2, arg1);
+}
+
+static void sub_8094998(u8 arg[3], u8 player_number)
+{
+ int i;
+ u32 pos;
+ u8 temp[6];
+ if (IsLinkDoubleBattle() == TRUE)
+ {
+ if (player_number)
+ {
+ *arg = 0x30;
+ arg[1] = 0x45;
+ arg[2] = 0x12;
+ }
+ else
+ {
+ *arg = 0x03;
+ arg[1] = 0x12;
+ arg[2] = 0x45;
+ }
+ }
+ else
+ {
+ if (!IsDoubleBattle())
+ {
+ pos = 1;
+ *temp = gUnknown_02024A6A[battle_get_side_with_given_state(0)];
+ for (i = 0; i <= 5; i++)
+ if (i != *temp)
+ temp[pos++] = i;
+ }
+ else
+ {
+ pos = 2;
+ *temp = gUnknown_02024A6A[battle_get_side_with_given_state(0)];
+ temp[1] = gUnknown_02024A6A[battle_get_side_with_given_state(2)];
+ for (i = 0; i <= 5; i++)
+ if ((i != *temp) && (i != temp[1]))
+ temp[pos++] = i;
+ }
+ for (i = 0; i <= 2; i++)
+ arg[i] = (temp[i << 1] << 4) | temp[(i << 1) + 1];
+ }
+}
+
+static void sub_8094A74(u8 arg[3], u8 player_number, u32 arg3)
+{
+ int i, j;
+ u8 temp[6];
+ if (!battle_side_get_owner(arg3))
+ {
+ i = battle_get_side_with_given_state(0);
+ j = battle_get_side_with_given_state(2);
+ }
+ else
+ {
+ i = battle_get_side_with_given_state(1);
+ j = battle_get_side_with_given_state(3);
+ }
+ if (IsLinkDoubleBattle() == TRUE)
+ {
+ if (player_number)
+ {
+ *arg = 0x30;
+ arg[1] = 0x45;
+ arg[2] = 0x12;
+ }
+ else
+ {
+ *arg = 0x03;
+ arg[1] = 0x12;
+ arg[2] = 0x45;
+ }
+ }
+ else
+ {
+ if (!IsDoubleBattle())
+ {
+ int pos = 1;
+ *temp = gUnknown_02024A6A[i];
+ for (i = 0; i <= 5; i++)
+ if (i != *temp)
+ temp[pos++] = i;
+ }
+ else
+ {
+ int pos = 2;
+ *temp = gUnknown_02024A6A[i];
+ temp[1] = gUnknown_02024A6A[j];
+ for (i = 0; i <= 5; i++)
+ if ((i != *temp) && (i != temp[1]))
+ temp[pos++] = i;
+ }
+ for (i = 0; i <= 2; i++)
+ arg[i] = (temp[i << 1] << 4) | temp[(i << 1) + 1];
+ }
+}
+
+void sub_8094B6C(u8 a, u8 b, u8 c)
+{
+ s32 i;
+ s32 j;
+ u8 temp[6];
+ u8 r3;
+ u8 r7 = 0;
+
+ if (IsLinkDoubleBattle())
+ {
+ u8 *arr = ewram + 0x1606C + a * 3;
+
+ for (i = 0, j = 0; i < 3; i++)
+ {
+ temp[j++] = arr[i] >> 4;
+ temp[j++] = arr[i] & 0xF;
+ }
+ r3 = temp[c];
+ for (i = 0; i < 6; i++)
+ {
+ if (temp[i] == b)
+ {
+ r7 = temp[i];
+ temp[i] = r3;
+ break;
+ }
+ }
+ if (i != 6)
+ {
+ temp[c] = r7;
+
+ arr[0] = (temp[0] << 4) | temp[1];
+ arr[1] = (temp[2] << 4) | temp[3];
+ arr[2] = (temp[4] << 4) | temp[5];
+ }
+ }
+}
+
+u8 sub_8094C20(u8 a)
+{
+ u8 retVal;
+ u8 val = a & 1;
+
+ a /= 2;
+ if (val)
+ retVal = gUnknown_02038470[a] & 0xF;
+ else
+ retVal = gUnknown_02038470[a] >> 4;
+ return retVal;
+}
+
+void sub_8094C54(u8 a, u8 b)
+{
+ u8 val = a & 1;
+
+ a /= 2;
+ if (val)
+ gUnknown_02038470[a] = (gUnknown_02038470[a] & 0xF0) | b;
+ else
+ gUnknown_02038470[a] = (gUnknown_02038470[a] & 0xF) | (b << 4);
+}
+
+void sub_8094C98(u8 a, u8 b)
+{
+ u8 r4 = sub_8094C20(a);
+ u8 r1 = sub_8094C20(b);
+
+ sub_8094C54(a, r1);
+ sub_8094C54(b, r4);
+}
+
+u8 pokemon_order_func(u8 a)
+{
+ u8 i;
+ u8 r2;
+
+ for (i = 0, r2 = 0; i < 3; i++)
+ {
+ if ((gUnknown_02038470[i] >> 4) == a)
+ return r2;
+ r2++;
+ if ((gUnknown_02038470[i] & 0xF) == a)
+ return r2;
+ r2++;
+ }
+ return 0;
+}
+
+void pokemon_change_order(void)
+{
+ u8 i;
+
+ memcpy(ewram1B000.unk0, gPlayerParty, sizeof(gPlayerParty));
+ for (i = 0; i < 6; i++)
+ {
+ u8 n = pokemon_order_func(i);
+
+ memcpy(&gPlayerParty[n], &ewram1B000.unk0[i], sizeof(struct Pokemon));
+ }
+}
+
+static void sub_8094D60(void)
+{
+ struct Pokemon temp[6];
+ u8 i;
+
+ memcpy(temp, gPlayerParty, sizeof(gPlayerParty));
+ for (i = 0; i < 6; i++)
+ {
+ u8 n = sub_8094C20(i);
+
+ memcpy(&gPlayerParty[n], &temp[i], sizeof(struct Pokemon));
+ }
+}
+
+void unref_sub_8094DB0(void)
+{
+ u8 i;
+ u8 r4;
+
+ for (i = 1; i < 6; i++)
+ {
+ u8 n = sub_8094C20(i);
+
+ if (GetMonData(&gPlayerParty[n], MON_DATA_SPECIES) != 0
+ && GetMonData(&gPlayerParty[n], MON_DATA_HP) != 0)
+ {
+ r4 = sub_8094C20(0);
+ sub_8094C98(0, i);
+ sub_806E6F0(&gPlayerParty[r4], &gPlayerParty[n]);
+ break;
+ }
+ }
+}
+
+void sub_8094E20(u8 a)
+{
+ gPaletteFade.bufferTransferDisabled = TRUE;
+ gUnknown_02038473 = a;
+ nullsub_14();
+ pokemon_change_order();
+ OpenPartyMenu(1, 0xFF);
+}
+
+void sub_8094E4C(void)
+{
+ sub_8094E20(3);
+}
int SetUpBattlePartyMenu(void)
{
switch (EWRAM_1B000.unk264)
+ //switch (ewram1B000.unk264[0])
{
case 0:
//TODO: try to get rid of this duplicate code
@@ -172,9 +440,9 @@ int SetUpBattlePartyMenu(void)
if (gUnknown_02038473 == 3)
{
if (GetItemEffectType(gScriptItemId) == 10)
- EWRAM_1B000.unk259 = 0xFF;
+ ewram1B000.unk259 = 0xFF;
else
- EWRAM_1B000.unk259 = 3;
+ ewram1B000.unk259 = 3;
}
return TRUE;
}
@@ -467,7 +735,7 @@ static void Task_BattlePartyMenuShift(u8 taskId)
static void Task_BattlePartyMenuCancel(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
sub_806E7D0(gTasks[taskId].data[4], sBattlePartyPopupMenus);
gTasks[taskId].data[4] = gTasks[taskId].data[5];
sub_806D538(0, 0);
diff --git a/src/battle_records.c b/src/battle_records.c
index 35fd3284b..cf86787f0 100644
--- a/src/battle_records.c
+++ b/src/battle_records.c
@@ -1,11 +1,8 @@
#include "global.h"
+#include "battle_records.h"
#include "menu.h"
#include "strings2.h"
-void PrintLinkBattleWinsLossesDraws(void *);
-
-void PrintLinkBattleRecord(void *, u8);
-
void ShowLinkBattleRecords(void) {
s32 i;
MenuDrawTextWindow(1, 0, 28, 18);
diff --git a/src/battle_setup.c b/src/battle_setup.c
index a70157a43..e4e83dfa1 100644
--- a/src/battle_setup.c
+++ b/src/battle_setup.c
@@ -1,14 +1,17 @@
#include "global.h"
#include "battle_setup.h"
-#include "asm.h"
#include "battle.h"
+#include "battle_transition.h"
#include "data2.h"
#include "event_data.h"
#include "field_control_avatar.h"
+#include "field_fadetransition.h"
#include "field_map_obj_helpers.h"
#include "field_message_box.h"
#include "field_player_avatar.h"
#include "field_weather.h"
+#include "fieldmap.h"
+#include "fldeff_80C5CD4.h"
#include "main.h"
#include "map_constants.h"
#include "metatile_behavior.h"
@@ -19,6 +22,7 @@
#include "safari_zone.h"
#include "script.h"
#include "script_pokemon_80C4.h"
+#include "secret_base.h"
#include "songs.h"
#include "sound.h"
#include "species.h"
@@ -31,10 +35,7 @@
extern u16 gScriptResult;
-extern void (*gUnknown_0300485C)(void);
-
-extern struct Pokemon gEnemyParty[];
-extern struct Pokemon gPlayerParty[];
+extern void (*gFieldCallback)(void);
EWRAM_DATA u16 gTrainerBattleMode = 0;
EWRAM_DATA u16 gTrainerBattleOpponent = 0;
@@ -580,7 +581,7 @@ void HandleWildBattleEnd(void)
else
{
SetMainCallback2(c2_exit_to_overworld_2_switch);
- gUnknown_0300485C = sub_8080E44;
+ gFieldCallback = sub_8080E44;
}
}
diff --git a/src/berry.c b/src/berry.c
index 257248e5c..d6fbb955e 100644
--- a/src/berry.c
+++ b/src/berry.c
@@ -1,8 +1,10 @@
#include "global.h"
#include "berry.h"
-#include "asm.h"
#include "field_control_avatar.h"
+#include "field_map_obj.h"
+#include "fieldmap.h"
#include "item.h"
+#include "item_menu.h"
#include "items.h"
#include "main.h"
#include "rng.h"
diff --git a/src/berry_tag_screen.c b/src/berry_tag_screen.c
index 394a3691b..5647d4593 100644
--- a/src/berry_tag_screen.c
+++ b/src/berry_tag_screen.c
@@ -1,11 +1,13 @@
#include "global.h"
#include "berry_tag_screen.h"
-#include "asm.h"
#include "berry.h"
#include "decompress.h"
+#include "field_map_obj.h"
+#include "item_menu.h"
#include "items.h"
#include "main.h"
#include "menu.h"
+#include "menu_helpers.h"
#include "palette.h"
#include "rom4.h"
#include "songs.h"
diff --git a/src/bike.c b/src/bike.c
index d7175b5e0..f37eb2144 100644
--- a/src/bike.c
+++ b/src/bike.c
@@ -1,8 +1,8 @@
#include "global.h"
#include "bike.h"
-#include "asm.h"
#include "field_map_obj.h"
#include "field_player_avatar.h"
+#include "fieldmap.h"
#include "flags.h"
#include "global.fieldmap.h"
#include "metatile_behavior.h"
diff --git a/src/birch_pc.c b/src/birch_pc.c
index 89eafc0ce..5fb6427c3 100644
--- a/src/birch_pc.c
+++ b/src/birch_pc.c
@@ -1,5 +1,4 @@
#include "global.h"
-#include "asm.h"
#include "event_data.h"
#include "field_message_box.h"
#include "pokedex.h"
@@ -9,31 +8,31 @@ extern u16 gSpecialVar_0x8004;
extern u16 gSpecialVar_0x8005;
extern u16 gSpecialVar_0x8006;
-extern const u8 gUnknown_081C4520[];
-extern const u8 gUnknown_081C456A[];
-extern const u8 gUnknown_081C45B0[];
-extern const u8 gUnknown_081C45F9[];
-extern const u8 gUnknown_081C4648[];
-extern const u8 gUnknown_081C467E[];
-extern const u8 gUnknown_081C46B9[];
-extern const u8 gUnknown_081C46FE[];
-extern const u8 gUnknown_081C4747[];
-extern const u8 gUnknown_081C4780[];
-extern const u8 gUnknown_081C47DF[];
-extern const u8 gUnknown_081C4828[];
-extern const u8 gUnknown_081C4863[];
-extern const u8 gUnknown_081C489C[];
-extern const u8 gUnknown_081C48EB[];
-extern const u8 gUnknown_081C4936[];
-extern const u8 gUnknown_081C49A2[];
-extern const u8 gUnknown_081C4A06[];
-extern const u8 gUnknown_081C4A4F[];
-extern const u8 gUnknown_081C4A91[];
-extern const u8 gUnknown_081C4ADA[];
+extern const u8 gBirchDexRatingText_LessThan10[];
+extern const u8 gBirchDexRatingText_LessThan20[];
+extern const u8 gBirchDexRatingText_LessThan30[];
+extern const u8 gBirchDexRatingText_LessThan40[];
+extern const u8 gBirchDexRatingText_LessThan50[];
+extern const u8 gBirchDexRatingText_LessThan60[];
+extern const u8 gBirchDexRatingText_LessThan70[];
+extern const u8 gBirchDexRatingText_LessThan80[];
+extern const u8 gBirchDexRatingText_LessThan90[];
+extern const u8 gBirchDexRatingText_LessThan100[];
+extern const u8 gBirchDexRatingText_LessThan110[];
+extern const u8 gBirchDexRatingText_LessThan120[];
+extern const u8 gBirchDexRatingText_LessThan130[];
+extern const u8 gBirchDexRatingText_LessThan140[];
+extern const u8 gBirchDexRatingText_LessThan150[];
+extern const u8 gBirchDexRatingText_LessThan160[];
+extern const u8 gBirchDexRatingText_LessThan170[];
+extern const u8 gBirchDexRatingText_LessThan180[];
+extern const u8 gBirchDexRatingText_LessThan190[];
+extern const u8 gBirchDexRatingText_LessThan200[];
+extern const u8 gBirchDexRatingText_DexCompleted[];
bool16 ScriptGetPokedexInfo(void)
{
- if (!gSpecialVar_0x8004)
+ if (gSpecialVar_0x8004 == 0) // is national dex not present?
{
gSpecialVar_0x8005 = GetHoennPokedexCount(0);
gSpecialVar_0x8006 = GetHoennPokedexCount(1);
@@ -47,65 +46,66 @@ bool16 ScriptGetPokedexInfo(void)
return IsNationalPokedexEnabled();
}
+// This shows your Hoenn Pokedex rating and not your National Dex.
const u8 *GetPokedexRatingText(u16 count)
{
if (count < 10)
- return gUnknown_081C4520;
+ return gBirchDexRatingText_LessThan10;
if (count < 20)
- return gUnknown_081C456A;
+ return gBirchDexRatingText_LessThan20;
if (count < 30)
- return gUnknown_081C45B0;
+ return gBirchDexRatingText_LessThan30;
if (count < 40)
- return gUnknown_081C45F9;
+ return gBirchDexRatingText_LessThan40;
if (count < 50)
- return gUnknown_081C4648;
+ return gBirchDexRatingText_LessThan50;
if (count < 60)
- return gUnknown_081C467E;
+ return gBirchDexRatingText_LessThan60;
if (count < 70)
- return gUnknown_081C46B9;
+ return gBirchDexRatingText_LessThan70;
if (count < 80)
- return gUnknown_081C46FE;
+ return gBirchDexRatingText_LessThan80;
if (count < 90)
- return gUnknown_081C4747;
+ return gBirchDexRatingText_LessThan90;
if (count < 100)
- return gUnknown_081C4780;
+ return gBirchDexRatingText_LessThan100;
if (count < 110)
- return gUnknown_081C47DF;
+ return gBirchDexRatingText_LessThan110;
if (count < 120)
- return gUnknown_081C4828;
+ return gBirchDexRatingText_LessThan120;
if (count < 130)
- return gUnknown_081C4863;
+ return gBirchDexRatingText_LessThan130;
if (count < 140)
- return gUnknown_081C489C;
+ return gBirchDexRatingText_LessThan140;
if (count < 150)
- return gUnknown_081C48EB;
+ return gBirchDexRatingText_LessThan150;
if (count < 160)
- return gUnknown_081C4936;
+ return gBirchDexRatingText_LessThan160;
if (count < 170)
- return gUnknown_081C49A2;
+ return gBirchDexRatingText_LessThan170;
if (count < 180)
- return gUnknown_081C4A06;
+ return gBirchDexRatingText_LessThan180;
if (count < 190)
- return gUnknown_081C4A4F;
+ return gBirchDexRatingText_LessThan190;
if (count < 200)
- return gUnknown_081C4A91;
+ return gBirchDexRatingText_LessThan200;
if (count == 200)
{
- if (sub_8090D90(SpeciesToNationalPokedexNum(SPECIES_JIRACHI), 1)
- || sub_8090D90(SpeciesToNationalPokedexNum(SPECIES_DEOXYS), 1))
- return gUnknown_081C4A91;
- return gUnknown_081C4ADA;
+ if (GetNationalPokedexFlag(SpeciesToNationalPokedexNum(SPECIES_JIRACHI), 1)
+ || GetNationalPokedexFlag(SpeciesToNationalPokedexNum(SPECIES_DEOXYS), 1)) // Jirachi or Deoxys is not counted towards the dex completion. If either of these flags are enabled, it means the actual count is less than 200.
+ return gBirchDexRatingText_LessThan200;
+ return gBirchDexRatingText_DexCompleted;
}
if (count == 201)
{
- if (sub_8090D90(SpeciesToNationalPokedexNum(SPECIES_JIRACHI), 1)
- && sub_8090D90(SpeciesToNationalPokedexNum(SPECIES_DEOXYS), 1))
- return gUnknown_081C4A91;
- return gUnknown_081C4ADA;
+ if (GetNationalPokedexFlag(SpeciesToNationalPokedexNum(SPECIES_JIRACHI), 1)
+ && GetNationalPokedexFlag(SpeciesToNationalPokedexNum(SPECIES_DEOXYS), 1)) // If both of these flags are enabled, it means the actual count is less than 200.
+ return gBirchDexRatingText_LessThan200;
+ return gBirchDexRatingText_DexCompleted;
}
if (count == 202)
- return gUnknown_081C4ADA;
- return gUnknown_081C4520;
+ return gBirchDexRatingText_DexCompleted; // Hoenn dex is considered complete, even though the hoenn dex count is 210.
+ return gBirchDexRatingText_LessThan10;
}
void ShowPokedexRatingMessage(void)
diff --git a/src/braille_puzzles.c b/src/braille_puzzles.c
index 2ee4f91bb..4de945b9c 100644
--- a/src/braille_puzzles.c
+++ b/src/braille_puzzles.c
@@ -1,10 +1,11 @@
#include "global.h"
#include "braille_puzzles.h"
-#include "asm.h"
#include "event_data.h"
#include "field_camera.h"
#include "field_effect.h"
+#include "fieldmap.h"
#include "flags.h"
+#include "main.h"
#include "map_obj_lock.h"
#include "menu.h"
#include "rom6.h"
diff --git a/src/cable_club.c b/src/cable_club.c
index 45fb347f3..13ae65322 100644
--- a/src/cable_club.c
+++ b/src/cable_club.c
@@ -1,5 +1,5 @@
#include "global.h"
-#include "asm.h"
+#include "cable_club.h"
#include "field_message_box.h"
#include "link.h"
#include "main.h"
@@ -20,20 +20,9 @@ extern u8 gFieldLinkPlayerCount;
extern u8 gUnknown_081A4932[];
extern const u8 gUnknown_081A4975[];
-void sub_8082D4C();
-void sub_8082D60(u8, u8);
-u16 sub_8082D9C(u8, u8);
-u32 sub_8082DF4(u8);
-u32 sub_8082E28(u8);
-u32 sub_8082EB8(u8);
-void sub_8082FEC(u8 taskId);
static void sub_80830E4(u8 taskId);
-void sub_8083188(u8 taskId);
static void sub_8083288(u8 taskId);
static void sub_8083314(u8 taskId);
-void sub_80833C4(u8 taskId);
-void sub_8083418(u8 taskId);
-u8 sub_8083444(u8 taskId);
void sub_808303C(u8 taskId) {
s32 linkPlayerCount;
diff --git a/src/calculate_base_damage.c b/src/calculate_base_damage.c
index 7868a2c67..f3799ab66 100644
--- a/src/calculate_base_damage.c
+++ b/src/calculate_base_damage.c
@@ -16,9 +16,7 @@
#include "text.h"
extern u8 gPlayerPartyCount;
-extern struct Pokemon gPlayerParty[6];
extern u8 gEnemyPartyCount;
-extern struct Pokemon gEnemyParty[6];
extern u16 unk_20160BC[];
extern struct SecretBaseRecord gSecretBaseRecord;
@@ -36,21 +34,10 @@ extern u16 gTrainerBattleOpponent;
extern struct PokemonStorage gPokemonStorage;
extern u8 gBadEggNickname[];
-extern u32 gBitTable[];
-extern struct BaseStats gBaseStats[];
extern struct SpriteTemplate gSpriteTemplate_8208288[];
-extern u8 gTrainerClassToPicIndex[];
-extern u8 gTrainerClassToNameIndex[];
extern u8 gSecretBaseTrainerClasses[];
-extern u8 gUnknown_08208238[];
-extern u8 gUnknown_0820823C[];
-extern u8 gStatStageRatios[];
extern u8 gHoldEffectToType[][2];
-extern u8 battle_side_get_owner(u8);
-extern u8 sub_8018324(u8, u8, u8, u8, u16);
-extern u8 sub_803C348(u8);
-
#define APPLY_STAT_MOD(var, mon, stat, statIndex) \
{ \
(var) = (stat) * (gStatStageRatios)[(mon)->statStages[(statIndex)] * 2]; \
diff --git a/src/clear_save_data_menu.c b/src/clear_save_data_menu.c
index 690ce3f55..498562fe0 100644
--- a/src/clear_save_data_menu.c
+++ b/src/clear_save_data_menu.c
@@ -10,8 +10,6 @@
#include "strings2.h"
#include "task.h"
-extern const struct MenuAction gMenuYesNoItems[];
-
static void VBlankCB_ClearSaveDataScreen(void);
static void Task_InitMenu(u8);
static void Task_ProcessMenuInput(u8);
diff --git a/src/clock.c b/src/clock.c
index b263e99ae..1f2aac9fd 100644
--- a/src/clock.c
+++ b/src/clock.c
@@ -1,21 +1,18 @@
#include "global.h"
#include "clock.h"
#include "berry.h"
+#include "dewford_trend.h"
#include "event_data.h"
+#include "field_specials.h"
+#include "field_weather.h"
#include "lottery_corner.h"
#include "main.h"
#include "rom4.h"
#include "rtc.h"
+#include "time_events.h"
+#include "tv.h"
#include "wallclock.h"
-extern void UpdateDewfordTrendPerDay(u16);
-extern void UpdateTVShowsPerDay(u16);
-extern void UpdateWeatherPerDay(u16);
-extern void UpdatePartyPokerusTime(u16);
-extern void UpdateMirageRnd(u16);
-extern void UpdateBirchState(u16);
-extern void SetShoalItemFlag(u16);
-
static void InitTimeBasedEvents(void);
static void UpdatePerDay(struct Time *time);
static void UpdatePerMinute(struct Time *time);
diff --git a/src/contest_painting.c b/src/contest_painting.c
index d7bacb905..eddcc87c1 100644
--- a/src/contest_painting.c
+++ b/src/contest_painting.c
@@ -1,6 +1,6 @@
#include "global.h"
#include "contest_painting.h"
-#include "asm.h"
+#include "cute_sketch.h"
#include "data2.h"
#include "decompress.h"
#include "main.h"
@@ -11,6 +11,7 @@
#include "string_util.h"
#include "strings.h"
#include "text.h"
+#include "unknown_task.h"
extern u8 unk_2000000[];
extern u8 gUnknown_03000750;
@@ -105,11 +106,6 @@ static void VBlankCB_ContestPainting(void);
void sub_8106B90(); //should be static
static void sub_8107090(u8 arg0, u8 arg1);
-extern void sub_80FC7A0(struct Unk03005E20*);
-extern void sub_80FDA18(struct Unk03005E20*);
-extern void sub_80FD8CC(struct Unk03005E20*);
-extern void *species_and_otid_get_pal();
-
__attribute__((naked))
void sub_8106630(u32 arg0)
{
diff --git a/src/coord_event_weather.c b/src/coord_event_weather.c
index f033e5391..9c5a1ca4d 100644
--- a/src/coord_event_weather.c
+++ b/src/coord_event_weather.c
@@ -1,5 +1,6 @@
#include "global.h"
-#include "asm.h"
+#include "coord_event_weather.h"
+#include "field_weather.h"
struct CoordEventWeather
{
diff --git a/src/credits.c b/src/credits.c
index 5af2d1e3c..a7d6191e6 100644
--- a/src/credits.c
+++ b/src/credits.c
@@ -1,8 +1,9 @@
#include "global.h"
-#include "asm.h"
#include "data2.h"
#include "decompress.h"
#include "event_data.h"
+#include "hall_of_fame.h"
+#include "intro_credits_graphics.h"
#include "m4a.h"
#include "main.h"
#include "menu.h"
@@ -13,6 +14,7 @@
#include "sound.h"
#include "species.h"
#include "starter_choose.h"
+#include "task.h"
#include "trig.h"
asm(".set REG_BASE, 0x4000000");
@@ -21,8 +23,6 @@ asm(".set OFFSET_REG_BLDALPHA, 0x52");
asm(".set REG_BLDCNT, REG_BASE + OFFSET_REG_BLDCNT");
asm(".set REG_BLDALPHA, REG_BASE + OFFSET_REG_BLDALPHA");
-extern void *species_and_otid_get_pal(u32, u16, u16);
-
enum
{
PAGE_TITLE,
@@ -187,11 +187,6 @@ extern s16 gUnknown_0203935C;
extern u8 gReservedSpritePaletteCount;
-// data/starter_choose
-extern u16 gBirchBagGrassPal[32];
-extern u8 gBirchGrassTilemap[];
-extern u8 gBirchHelpGfx[];
-
// data/hall_of_fame
extern void *gUnknown_0840B5A0[];
@@ -211,14 +206,6 @@ extern const union AnimCmd *const gSpriteAnimTable_0840CA54[];
extern const union AnimCmd *const gSpriteAnimTable_0840CA94[];
extern struct SpriteTemplate gSpriteTemplate_840CAEC;
-// data/intro_credits_graphics
-extern const struct SpriteSheet gIntro2BrendanSpriteSheet;
-extern const struct SpriteSheet gIntro2MaySpriteSheet;
-extern const struct SpriteSheet gIntro2BicycleSpriteSheet;
-extern const struct SpritePalette gIntro2SpritePalettes[];
-extern const struct SpriteSheet gUnknown_08416E24;
-extern const struct SpriteSheet gUnknown_08416E34;
-
// graphics
extern u8 gCreditsCopyrightEnd_Gfx[];
extern u16 gIntroCopyright_Pal[16];
@@ -246,7 +233,7 @@ static void sub_8145128(u16, u16, u16);
static void sub_81452D0(u16 arg0, u16 palette);
static void spritecb_player_8145378(struct Sprite *sprite);
static void spritecb_rival_8145420(struct Sprite *sprite);
-static u8 sub_81456B4(u16 nationalNum, u16 x, u16 y, u16 position);
+static u8 sub_81456B4(u16 species, u16 x, u16 y, u16 position);
static void sub_81458DC(void);
static void vblank_8143948(void)
@@ -461,7 +448,7 @@ void task_a_8143D04(u8 taskIdA)
gReservedSpritePaletteCount = 8;
LZ77UnCompVram(&gBirchHelpGfx, (void *)VRAM);
LZ77UnCompVram(&gBirchGrassTilemap, (void *)(VRAM + 0x3800));
- LoadPalette(gBirchBagGrassPal + 1, 1, 31 * 2);
+ LoadPalette(gBirchBagGrassPal[0] + 1, 1, 31 * 2);
for (i = 0; i < 0x800; i++)
HALL_OF_FAME_SHEET_0[i] = 0x11;
@@ -1508,7 +1495,7 @@ void spritecb_81454E0(struct Sprite *sprite) {
static u8 sub_81456B4(u16 species, u16 x, u16 y, u16 position)
{
u32 personality;
- void *palette;
+ const u16 *palette;
u8 spriteId;
u8 spriteId2;
@@ -1585,7 +1572,7 @@ static void sub_81458DC(void) {
for (dexNum = 1, seenTypesCount = 0; dexNum < 386; dexNum++)
{
- if (sub_8090D90(dexNum, 1))
+ if (GetNationalPokedexFlag(dexNum, 1))
{
unk201C000->unk90[seenTypesCount] = dexNum;
seenTypesCount++;
diff --git a/src/data/pokedex_entries_en.h b/src/data/pokedex_entries_en.h
new file mode 100644
index 000000000..86da3d67b
--- /dev/null
+++ b/src/data/pokedex_entries_en.h
@@ -0,0 +1,9651 @@
+static const u8 DexDescription_Dummy_1[] = _(
+ "This is a newly discovered POKéMON.\n"
+ "It is currently under investigation.");
+static const u8 DexDescription_Dummy_2[] = _(
+ "No detailed information is available\n"
+ "at this time.");
+
+static const u8 DexDescription_Bulbasaur_1[] = _(
+ "BULBASAUR can be seen napping in\n"
+ "bright sunlight.\n"
+ "There is a seed on its back.");
+static const u8 DexDescription_Bulbasaur_2[] = _(
+ "By soaking up the sun’s rays, the seed\n"
+ "grows progressively larger.");
+
+static const u8 DexDescription_Ivysaur_1[] = _(
+ "There is a bud on this POKéMON’s back.\n"
+ "To support its weight, IVYSAUR’s legs\n"
+ "and trunk grow thick and strong.");
+static const u8 DexDescription_Ivysaur_2[] = _(
+ "If it starts spending more time lying\n"
+ "in the sunlight, it’s a sign that the\n"
+ "bud will bloom into a large flower soon.");
+
+static const u8 DexDescription_Venusaur_1[] = _(
+ "There is a large flower on VENUSAUR’s\n"
+ "back. The flower is said to take on vivid\n"
+ "colors if it gets plenty of nutrition");
+static const u8 DexDescription_Venusaur_2[] = _(
+ "and sunlight. The flower’s aroma\n"
+ "soothes the emotions of people.");
+
+static const u8 DexDescription_Charmander_1[] = _(
+ "The flame that burns at the tip of its\n"
+ "tail is an indication of its emotions.\n"
+ "The flame wavers when CHARMANDER is");
+static const u8 DexDescription_Charmander_2[] = _(
+ "enjoying itself. If the POKéMON becomes\n"
+ "enraged, the flame burns fiercely.");
+
+static const u8 DexDescription_Charmeleon_1[] = _(
+ "CHARMELEON mercilessly destroys its\n"
+ "foes using its sharp claws.\n"
+ "If it encounters a strong foe, it turns");
+static const u8 DexDescription_Charmeleon_2[] = _(
+ "aggressive. In this excited state, the\n"
+ "flame at the tip of its tail flares with a\n"
+ "bluish white color.");
+
+static const u8 DexDescription_Charizard_1[] = _(
+ "CHARIZARD flies around the sky in\n"
+ "search of powerful opponents.\n"
+ "It breathes fire of such great heat");
+static const u8 DexDescription_Charizard_2[] = _(
+ "that it melts anything. However, it\n"
+ "never turns its fiery breath on any\n"
+ "opponent weaker than itself.");
+
+static const u8 DexDescription_Squirtle_1[] = _(
+ "SQUIRTLE’s shell is not merely used\n"
+ "for protection.\n"
+ "The shell’s rounded shape and the");
+static const u8 DexDescription_Squirtle_2[] = _(
+ "grooves on its surface help minimize\n"
+ "resistance in water, enabling this\n"
+ "POKéMON to swim at high speeds.");
+
+static const u8 DexDescription_Wartortle_1[] = _(
+ "Its tail is large and covered with a rich,\n"
+ "thick fur. The tail becomes increasingly\n"
+ "deeper in color as WARTORTLE ages.");
+static const u8 DexDescription_Wartortle_2[] = _(
+ "The scratches on its shell are evidence\n"
+ "of this POKéMON’s toughness as a\n"
+ "battler.");
+
+static const u8 DexDescription_Blastoise_1[] = _(
+ "BLASTOISE has water spouts that\n"
+ "protrude from its shell. The water\n"
+ "spouts are very accurate.");
+static const u8 DexDescription_Blastoise_2[] = _(
+ "They can shoot bullets of water with\n"
+ "enough accuracy to strike empty cans\n"
+ "from a distance of over 160 feet.");
+
+static const u8 DexDescription_Caterpie_1[] = _(
+ "CATERPIE has a voracious appetite.\n"
+ "It can devour leaves bigger than its\n"
+ "body right before your eyes.");
+static const u8 DexDescription_Caterpie_2[] = _(
+ "From its antenna, this POKéMON releases\n"
+ "a terrifically strong odor.");
+
+static const u8 DexDescription_Metapod_1[] = _(
+ "The shell covering this POKéMON’s body\n"
+ "is as hard as an iron slab.\n"
+ "METAPOD does not move very much.");
+static const u8 DexDescription_Metapod_2[] = _(
+ "It stays still because it is preparing\n"
+ "its soft innards for evolution inside\n"
+ "the hard shell.");
+
+static const u8 DexDescription_Butterfree_1[] = _(
+ "BUTTERFREE has a superior ability to\n"
+ "search for delicious honey from\n"
+ "flowers.");
+static const u8 DexDescription_Butterfree_2[] = _(
+ "It can even search out, extract, and\n"
+ "carry honey from flowers that are\n"
+ "blooming over six miles from its nest.");
+
+static const u8 DexDescription_Weedle_1[] = _(
+ "WEEDLE has an extremely acute sense\n"
+ "of smell.\n"
+ "It is capable of distinguishing its");
+static const u8 DexDescription_Weedle_2[] = _(
+ "favorite kinds of leaves from those it\n"
+ "dislikes just by sniffing with its big\n"
+ "red proboscis (nose).");
+
+static const u8 DexDescription_Kakuna_1[] = _(
+ "KAKUNA remains virtually immobile as it\n"
+ "clings to a tree. However, on the\n"
+ "inside, it is extremely busy as it");
+static const u8 DexDescription_Kakuna_2[] = _(
+ "prepares for its coming evolution.\n"
+ "This is evident from how hot the shell\n"
+ "becomes to the touch.");
+
+static const u8 DexDescription_Beedrill_1[] = _(
+ "BEEDRILL is extremely territorial.\n"
+ "No one should ever approach its nest -\n"
+ "this is for their own safety.");
+static const u8 DexDescription_Beedrill_2[] = _(
+ "If angered, they will attack in a furious\n"
+ "swarm.");
+
+static const u8 DexDescription_Pidgey_1[] = _(
+ "PIDGEY has an extremely sharp sense\n"
+ "of direction.\n"
+ "It is capable of unerringly returning");
+static const u8 DexDescription_Pidgey_2[] = _(
+ "home to its nest, however far it may be\n"
+ "removed from its familiar surroundings.");
+
+static const u8 DexDescription_Pidgeotto_1[] = _(
+ "PIDGEOTTO claims a large area as its\n"
+ "own territory. This POKéMON flies\n"
+ "around, patrolling its living space.");
+static const u8 DexDescription_Pidgeotto_2[] = _(
+ "If its territory is violated, it shows\n"
+ "no mercy in thoroughly punishing the\n"
+ "foe with its sharp claws.");
+
+static const u8 DexDescription_Pidgeot_1[] = _(
+ "This POKéMON has a dazzling plumage of\n"
+ "beautifully glossy feathers.\n"
+ "Many TRAINERS are captivated by the");
+static const u8 DexDescription_Pidgeot_2[] = _(
+ "striking beauty of the feathers on its\n"
+ "head, compelling them to choose PIDGEOT\n"
+ "as their POKéMON.");
+
+static const u8 DexDescription_Rattata_1[] = _(
+ "RATTATA is cautious in the extreme.\n"
+ "Even while it is asleep, it constantly\n"
+ "listens by moving its ears around.");
+static const u8 DexDescription_Rattata_2[] = _(
+ "It is not picky about where it lives -\n"
+ "it will make its nest anywhere.");
+
+static const u8 DexDescription_Raticate_1[] = _(
+ "RATICATE’s sturdy fangs grow steadily.\n"
+ "To keep them ground down, it gnaws\n"
+ "on rocks and logs.");
+static const u8 DexDescription_Raticate_2[] = _(
+ "It may even chew on the walls of\n"
+ "houses.");
+
+static const u8 DexDescription_Spearow_1[] = _(
+ "SPEAROW has a very loud cry that can\n"
+ "be heard over half a mile away.\n"
+ "If its high, keening cry is heard");
+static const u8 DexDescription_Spearow_2[] = _(
+ "echoing all around, it is a sign that\n"
+ "they are warning each other of danger.");
+
+static const u8 DexDescription_Fearow_1[] = _(
+ "FEAROW is recognized by its long neck\n"
+ "and elongated beak.\n"
+ "They are conveniently shaped for");
+static const u8 DexDescription_Fearow_2[] = _(
+ "catching prey in soil or water.\n"
+ "It deftly moves its long and skinny\n"
+ "beak to pluck prey.");
+
+static const u8 DexDescription_Ekans_1[] = _(
+ "EKANS curls itself up in a spiral while\n"
+ "it rests.\n"
+ "Assuming this position allows it to");
+static const u8 DexDescription_Ekans_2[] = _(
+ "quickly respond to a threat from any\n"
+ "direction with a glare from its upraised\n"
+ "head.");
+
+static const u8 DexDescription_Arbok_1[] = _(
+ "This POKéMON is terrifically strong in\n"
+ "order to constrict things with its body.\n"
+ "It can even flatten steel oil drums.");
+static const u8 DexDescription_Arbok_2[] = _(
+ "Once ARBOK wraps its body around its\n"
+ "foe, escaping its crunching embrace is\n"
+ "impossible.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Pikachu_1[] = _(
+ "This POKéMON has electricity-storing\n"
+ "pouches on its cheeks. These appear to\n"
+ "become electrically charged during the");
+static const u8 DexDescription_Pikachu_2[] = _(
+ "night while PIKACHU sleeps.\n"
+ "It occasionally discharges electricity\n"
+ "when it is dozy after waking up.");
+#else
+static const u8 DexDescription_Pikachu_1[] = _(
+ "Whenever PIKACHU comes across\n"
+ "something new, it blasts it with a jolt\n"
+ "of electricity.");
+static const u8 DexDescription_Pikachu_2[] = _(
+ "If you come across a blackened berry,\n"
+ "it’s evidence that this POKéMON\n"
+ "mistook the intensity of its charge.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Raichu_1[] = _(
+ "This POKéMON exudes a weak electrical\n"
+ "charge from all over its body that makes\n"
+ "it take on a slight glow in darkness.");
+static const u8 DexDescription_Raichu_2[] = _(
+ "RAICHU searches for electricity by\n"
+ "planting its tail in the ground.");
+#else
+static const u8 DexDescription_Raichu_1[] = _(
+ "If the electrical sacks become\n"
+ "excessively charged, RAICHU plants its\n"
+ "tail in the ground and discharges.");
+static const u8 DexDescription_Raichu_2[] = _(
+ "Scorched patches of ground will be\n"
+ "found near this POKéMON’s nest.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sandshrew_1[] = _(
+ "SANDSHREW has a very dry hide that is\n"
+ "extremely tough. The POKéMON can roll\n"
+ "into a ball that repels any attack.");
+static const u8 DexDescription_Sandshrew_2[] = _(
+ "At night, it burrows into the desert\n"
+ "sand to sleep.");
+#else
+static const u8 DexDescription_Sandshrew_1[] = _(
+ "SANDSHREW’s body is configured to\n"
+ "absorb water without waste, enabling it\n"
+ "to survive in an arid desert.");
+static const u8 DexDescription_Sandshrew_2[] = _(
+ "This POKéMON curls up to protect itself\n"
+ "from its enemies.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sandslash_1[] = _(
+ "SANDSLASH can roll up its body as if it\n"
+ "were a ball covered with large spikes.\n"
+ "In battle, this POKéMON will try to make");
+static const u8 DexDescription_Sandslash_2[] = _(
+ "the foe flinch by jabbing it with its\n"
+ "spines. It then leaps at the stunned\n"
+ "foe to tear wildly with its sharp claws.");
+#else
+static const u8 DexDescription_Sandslash_1[] = _(
+ "SANDSLASH’s body is covered by tough\n"
+ "spikes, which are hardened sections of\n"
+ "its hide. Once a year, the old spikes fall");
+static const u8 DexDescription_Sandslash_2[] = _(
+ "out, to be replaced with new spikes that\n"
+ "grow out from beneath the old ones.");
+#endif
+
+static const u8 DexDescription_NidoranF_1[] = _(
+ "NIDORAN has barbs that secrete a\n"
+ "powerful poison. They are thought to\n"
+ "have developed as protection for this");
+static const u8 DexDescription_NidoranF_2[] = _(
+ "small-bodied POKéMON.\n"
+ "When enraged, it releases a horrible\n"
+ "toxin from its horn.");
+
+static const u8 DexDescription_Nidorina_1[] = _(
+ "When NIDORINA are with their friends or\n"
+ "family, they keep their barbs tucked\n"
+ "away to prevent hurting each other.");
+static const u8 DexDescription_Nidorina_2[] = _(
+ "This POKéMON appears to become\n"
+ "nervous if separated from the others.");
+
+static const u8 DexDescription_Nidoqueen_1[] = _(
+ "NIDOQUEEN’s body is encased in\n"
+ "extremely hard scales. It is adept at\n"
+ "sending foes flying with harsh tackles.");
+static const u8 DexDescription_Nidoqueen_2[] = _(
+ "This POKéMON is at its strongest when\n"
+ "it is defending its young.");
+
+static const u8 DexDescription_NidoranM_1[] = _(
+ "The male NIDORAN has developed\n"
+ "muscles for moving its ears. Thanks to\n"
+ "them, the ears can be freely moved in");
+static const u8 DexDescription_NidoranM_2[] = _(
+ "any direction. Even the slightest sound\n"
+ "does not escape this POKéMON’s notice.");
+
+static const u8 DexDescription_Nidorino_1[] = _(
+ "NIDORINO has a horn that is harder than\n"
+ "a diamond. If it senses a hostile\n"
+ "presence, all the barbs on its back");
+static const u8 DexDescription_Nidorino_2[] = _(
+ "bristle up at once, and it challenges\n"
+ "the foe with all its might.");
+
+static const u8 DexDescription_Nidoking_1[] = _(
+ "NIDOKING’s thick tail packs enormously\n"
+ "destructive power. With one swing, it\n"
+ "can topple a metal transmission tower.");
+static const u8 DexDescription_Nidoking_2[] = _(
+ "Once this POKéMON goes on a rampage,\n"
+ "there is no stopping it.");
+
+static const u8 DexDescription_Clefairy_1[] = _(
+ "On every night of a full moon, groups of\n"
+ "this POKéMON come out to play.\n"
+ "When dawn arrives, the tired CLEFAIRY");
+static const u8 DexDescription_Clefairy_2[] = _(
+ "return to their quiet mountain retreats\n"
+ "and go to sleep nestled up against each\n"
+ "other.");
+
+static const u8 DexDescription_Clefable_1[] = _(
+ "CLEFABLE moves by skipping lightly as if\n"
+ "it were flying using its wings. Its\n"
+ "bouncy step lets it even walk on water.");
+static const u8 DexDescription_Clefable_2[] = _(
+ "It is known to take strolls on lakes on\n"
+ "quiet, moonlit nights.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Vulpix_1[] = _(
+ "Inside VULPIX’s body burns a flame that\n"
+ "never goes out. During the daytime,\n"
+ "when the temperatures rise, this");
+static const u8 DexDescription_Vulpix_2[] = _(
+ "POKéMON releases flames from its mouth\n"
+ "to prevent its body from growing too\n"
+ "hot.");
+#else
+static const u8 DexDescription_Vulpix_1[] = _(
+ "At the time of its birth, VULPIX has one\n"
+ "white tail. The tail separates into six\n"
+ "if this POKéMON receives plenty of love");
+static const u8 DexDescription_Vulpix_2[] = _(
+ "from its TRAINER.\n"
+ "The six tails become magnificently\n"
+ "curled.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Ninetales_1[] = _(
+ "Legend has it that NINETALES came into\n"
+ "being when nine wizards possessing\n"
+ "sacred powers merged into one.");
+static const u8 DexDescription_Ninetales_2[] = _(
+ "This POKéMON is highly intelligent - it\n"
+ "can understand human speech.");
+#else
+static const u8 DexDescription_Ninetales_1[] = _(
+ "NINETALES casts a sinister light from\n"
+ "its bright red eyes to gain total\n"
+ "control over its foe’s mind.");
+static const u8 DexDescription_Ninetales_2[] = _(
+ "This POKéMON is said to live for a\n"
+ "thousand years.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Jigglypuff_1[] = _(
+ "When this POKéMON sings, it never\n"
+ "pauses to breathe. If it is in a battle\n"
+ "against an opponent that does not");
+static const u8 DexDescription_Jigglypuff_2[] = _(
+ "easily fall asleep, JIGGLYPUFF cannot\n"
+ "breathe, endangering its life.");
+#else
+static const u8 DexDescription_Jigglypuff_1[] = _(
+ "JIGGLYPUFF’s vocal chords can freely\n"
+ "adjust the wavelength of its voice.\n"
+ "This POKéMON uses this ability to sing");
+static const u8 DexDescription_Jigglypuff_2[] = _(
+ "at precisely the right wavelength to\n"
+ "make its foes most drowsy.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wigglytuff_1[] = _(
+ "WIGGLYTUFF’s body is very flexible.\n"
+ "By inhaling deeply, this POKéMON can\n"
+ "inflate itself seemingly without end.");
+static const u8 DexDescription_Wigglytuff_2[] = _(
+ "Once inflated, WIGGLYTUFF bounces\n"
+ "along lightly like a balloon.");
+#else
+static const u8 DexDescription_Wigglytuff_1[] = _(
+ "WIGGLYTUFF has large, saucerlike eyes.\n"
+ "The surfaces of its eyes are always\n"
+ "covered with a thin layer of tears.");
+static const u8 DexDescription_Wigglytuff_2[] = _(
+ "If any dust gets in this POKéMON’s\n"
+ "eyes, it is quickly washed away.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Zubat_1[] = _(
+ "ZUBAT avoids sunlight because exposure\n"
+ "causes it to become unhealthy.\n"
+ "During the daytime, it stays in caves or");
+static const u8 DexDescription_Zubat_2[] = _(
+ "under the eaves of old houses, sleeping\n"
+ "while hanging upside down.");
+#else
+static const u8 DexDescription_Zubat_1[] = _(
+ "ZUBAT remains quietly unmoving in a\n"
+ "dark spot during the bright daylight\n"
+ "hours. It does so because prolonged");
+static const u8 DexDescription_Zubat_2[] = _(
+ "exposure to the sun causes its body to\n"
+ "become slightly burned.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Golbat_1[] = _(
+ "GOLBAT bites down on prey with its four\n"
+ "fangs and drinks the victim’s blood.\n"
+ "It becomes active on inky dark");
+static const u8 DexDescription_Golbat_2[] = _(
+ "moonless nights, flying around to\n"
+ "attack people and POKéMON.");
+#else
+static const u8 DexDescription_Golbat_1[] = _(
+ "GOLBAT loves to drink the blood of\n"
+ "living things. It is particularly active\n"
+ "in the pitch black of night.");
+static const u8 DexDescription_Golbat_2[] = _(
+ "This POKéMON flits around in the night\n"
+ "skies, seeking fresh blood.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Oddish_1[] = _(
+ "ODDISH searches for fertile, nutrient-\n"
+ "rich soil, then plants itself.\n"
+ "During the daytime, while it is planted,");
+static const u8 DexDescription_Oddish_2[] = _(
+ "this POKéMON’s feet are thought to\n"
+ "change shape and become similar to\n"
+ "the roots of trees.");
+#else
+static const u8 DexDescription_Oddish_1[] = _(
+ "During the daytime, ODDISH buries\n"
+ "itself in soil to absorb nutrients from \n"
+ "the ground using its entire body.");
+static const u8 DexDescription_Oddish_2[] = _(
+ "The more fertile the soil, the glossier\n"
+ "its leaves become.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Gloom_1[] = _(
+ "From its mouth GLOOM drips honey that\n"
+ "smells absolutely horrible.\n"
+ "Apparently, it loves the horrid stench.");
+static const u8 DexDescription_Gloom_2[] = _(
+ "It sniffs the noxious fumes and then \n"
+ "drools even more of its honey.");
+#else
+static const u8 DexDescription_Gloom_1[] = _(
+ "GLOOM releases a foul fragrance from\n"
+ "the pistil of its flower. When faced\n"
+ "with danger, the stench worsens.");
+static const u8 DexDescription_Gloom_2[] = _(
+ "If this POKéMON is feeling calm and\n"
+ "secure, it does not release its usual\n"
+ "stinky aroma.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Vileplume_1[] = _(
+ "VILEPLUME has the world’s largest\n"
+ "petals. They are used to attract prey\n"
+ "that are then doused with toxic spores.");
+static const u8 DexDescription_Vileplume_2[] = _(
+ "Once the prey are immobilized, this\n"
+ "POKéMON catches and devours them.");
+#else
+static const u8 DexDescription_Vileplume_1[] = _(
+ "VILEPLUME’s toxic pollen triggers\n"
+ "atrocious allergy attacks. That’s why\n"
+ "it is advisable never to approach any");
+static const u8 DexDescription_Vileplume_2[] = _(
+ "attractive flowers in a jungle, however\n"
+ "pretty they may be.");
+#endif
+
+#ifdef SAPPHIRE
+#if REVISION >= 1
+static const u8 DexDescription_Paras_1[] = _(
+ "PARAS has parasitic mushrooms growing\n"
+ "on its back called tochukaso. They grow\n"
+ "large by drawing nutrients from this");
+static const u8 DexDescription_Paras_2[] = _(
+ "BUG/GRASS POKéMON host. They are\n" // Identify Paras as BUG/GRASS type rather than just BUG
+ "highly valued as a medicine for\n"
+ "extending life.");
+#else
+static const u8 DexDescription_Paras_1[] = _(
+ "PARAS has parasitic mushrooms growing\n"
+ "on its back called tochukaso. They grow\n"
+ "large by drawing nutrients from this");
+static const u8 DexDescription_Paras_2[] = _(
+ "BUG POKéMON host. They are highly\n"
+ "valued as a medicine for extending life.");
+#endif
+#else
+#if REVISION >= 1
+static const u8 DexDescription_Paras_1[] = _(
+ "PARAS has parasitic mushrooms growing\n"
+ "on its back called tochukaso. They grow\n"
+ "large by drawing nutrients from this");
+static const u8 DexDescription_Paras_2[] = _(
+ "BUG/GRASS POKéMON host. They are\n"
+ "highly valued as a medicine for\n"
+ "extending life.");
+#else
+static const u8 DexDescription_Paras_1[] = _(
+ "PARAS has parasitic mushrooms growing\n"
+ "on its back called tochukaso. They grow\n"
+ "large by drawing nutrients from the BUG");
+static const u8 DexDescription_Paras_2[] = _(
+ "POKéMON host. They are highly valued as\n"
+ "a medicine for extending life.");
+#endif
+#endif
+
+static const u8 DexDescription_Parasect_1[] = _(
+ "PARASECT is known to infest large trees\n"
+ "en masse and drain nutrients from the\n"
+ "lower trunk and roots.");
+static const u8 DexDescription_Parasect_2[] = _(
+ "When an infested tree dies, they move\n"
+ "onto another tree all at once.");
+
+static const u8 DexDescription_Venonat_1[] = _(
+ "VENONAT is said to have evolved with\n"
+ "a coat of thin, stiff hair that covers\n"
+ "its entire body for protection.");
+static const u8 DexDescription_Venonat_2[] = _(
+ "It possesses large eyes that never fail\n"
+ "to spot even miniscule prey.");
+
+static const u8 DexDescription_Venomoth_1[] = _(
+ "VENOMOTH is nocturnal - it is a POKéMON\n"
+ "that only becomes active at night.\n"
+ "Its favorite prey are small insects");
+static const u8 DexDescription_Venomoth_2[] = _(
+ "that gather around streetlights,\n"
+ "attracted by the light in the darkness.");
+
+static const u8 DexDescription_Diglett_1[] = _(
+ "DIGLETT are raised in most farms.\n"
+ "The reason is simple - wherever this\n"
+ "POKéMON burrows, the soil is left");
+static const u8 DexDescription_Diglett_2[] = _(
+ "perfectly tilled for planting crops.\n"
+ "This soil is made ideal for growing\n"
+ "delicious vegetables.");
+
+static const u8 DexDescription_Dugtrio_1[] = _(
+ "DUGTRIO are actually triplets that\n"
+ "emerged from one body. As a result,\n"
+ "each triplet thinks exactly like the");
+static const u8 DexDescription_Dugtrio_2[] = _(
+ "other two triplets.\n"
+ "They work cooperatively to burrow\n"
+ "endlessly.");
+
+static const u8 DexDescription_Meowth_1[] = _(
+ "MEOWTH withdraws its sharp claws into\n"
+ "its paws to slinkily sneak about without\n"
+ "making any incriminating footsteps.");
+static const u8 DexDescription_Meowth_2[] = _(
+ "For some reason, this POKéMON loves\n"
+ "shiny coins that glitter with light.");
+
+static const u8 DexDescription_Persian_1[] = _(
+ "PERSIAN has six bold whiskers that give\n"
+ "it a look of toughness. The whiskers \n"
+ "sense air movements to determine what");
+static const u8 DexDescription_Persian_2[] = _(
+ "is in the POKéMON’s surrounding\n"
+ "vicinity. It becomes docile if grabbed\n"
+ "by the whiskers.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Psyduck_1[] = _(
+ "If it uses its mysterious power,\n"
+ "PSYDUCK can’t remember having done so.\n"
+ "It apparently can’t form a memory of");
+static const u8 DexDescription_Psyduck_2[] = _(
+ "such an event because it goes into\n"
+ "an altered state that is much like\n"
+ "deep sleep.");
+#else
+static const u8 DexDescription_Psyduck_1[] = _(
+ "PSYDUCK uses a mysterious power.\n"
+ "When it does so, this POKéMON \n"
+ "generates brain waves that are");
+static const u8 DexDescription_Psyduck_2[] = _(
+ "supposedly only seen in sleepers.\n"
+ "This discovery spurred controversy\n"
+ "among scholars.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Golduck_1[] = _(
+ "GOLDUCK is the fastest swimmer among\n"
+ "all POKéMON. It swims effortlessly, even\n"
+ "in a rough, stormy sea.");
+static const u8 DexDescription_Golduck_2[] = _(
+ "It sometimes rescues people from\n"
+ "wrecked ships floundering in high seas.");
+#else
+static const u8 DexDescription_Golduck_1[] = _(
+ "The webbed flippers on its forelegs and\n"
+ "hind legs and the streamlined body of\n"
+ "GOLDUCK give it frightening speed.");
+static const u8 DexDescription_Golduck_2[] = _(
+ "This POKéMON is definitely much faster\n"
+ "than even the most athletic swimmer.");
+#endif
+
+static const u8 DexDescription_Mankey_1[] = _(
+ "When MANKEY starts shaking and its\n"
+ "nasal breathing turns rough, it’s a sure\n"
+ "sign that it is becoming angry.");
+static const u8 DexDescription_Mankey_2[] = _(
+ "However, because it goes into a\n"
+ "towering rage almost instantly, it is\n"
+ "impossible for anyone to flee its wrath.");
+
+static const u8 DexDescription_Primeape_1[] = _(
+ "When PRIMEAPE becomes furious, its\n"
+ "blood circulation is boosted. In turn,\n"
+ "its muscles are made even stronger.");
+static const u8 DexDescription_Primeape_2[] = _(
+ "However, it also becomes much less\n"
+ "intelligent at the same time.");
+
+static const u8 DexDescription_Growlithe_1[] = _(
+ "GROWLITHE has a superb sense of smell.\n"
+ "Once it smells anything, this POKéMON\n"
+ "won’t forget the scent, no matter what.");
+static const u8 DexDescription_Growlithe_2[] = _(
+ "It uses its advanced olfactory sense\n"
+ "to determine the emotions of other\n"
+ "living things.");
+
+static const u8 DexDescription_Arcanine_1[] = _(
+ "ARCANINE is known for its high speed.\n"
+ "It is said to be capable of running over\n"
+ "6,200 miles in a single day and night.");
+static const u8 DexDescription_Arcanine_2[] = _(
+ "The fire that blazes wildly within this\n"
+ "POKéMON’s body is its source of power.");
+
+static const u8 DexDescription_Poliwag_1[] = _(
+ "POLIWAG has a very thin skin. It is\n"
+ "possible to see the POKéMON’s spiral\n"
+ "innards right through the skin.");
+static const u8 DexDescription_Poliwag_2[] = _(
+ "Despite its thinness, however, the skin\n"
+ "is also very flexible. Even sharp fangs\n"
+ "bounce right off it.");
+
+static const u8 DexDescription_Poliwhirl_1[] = _(
+ "The surface of POLIWHIRL’s body is\n"
+ "always wet and slick with an oily fluid.\n"
+ "Because of this greasy covering, it can");
+static const u8 DexDescription_Poliwhirl_2[] = _(
+ "easily slip and slide out of the clutches\n"
+ "of any enemy in battle.");
+
+static const u8 DexDescription_Poliwrath_1[] = _(
+ "POLIWRATH’s highly developed, brawny\n"
+ "muscles never grow fatigued, however\n"
+ "much it exercises.");
+static const u8 DexDescription_Poliwrath_2[] = _(
+ "It is so tirelessly strong, this POKéMON\n"
+ "can swim back and forth across the\n"
+ "Pacific Ocean without effort.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Abra_1[] = _(
+ "ABRA needs to sleep for eighteen hours\n"
+ "a day. If it doesn’t, this POKéMON loses\n"
+ "its ability to use telekinetic powers.");
+static const u8 DexDescription_Abra_2[] = _(
+ "If it is attacked, ABRA escapes using\n"
+ "TELEPORT while it is still sleeping.");
+#else
+static const u8 DexDescription_Abra_1[] = _(
+ "ABRA sleeps for eighteen hours a day.\n"
+ "However, it can sense the presence of\n"
+ "foes even while it is sleeping.");
+static const u8 DexDescription_Abra_2[] = _(
+ "In such a situation, this POKéMON\n"
+ "immediately teleports to safety.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Kadabra_1[] = _(
+ "KADABRA holds a silver spoon in its\n"
+ "hand. The spoon is used to amplify the\n"
+ "alpha waves in its brain.");
+static const u8 DexDescription_Kadabra_2[] = _(
+ "Without the spoon, the POKéMON is said\n"
+ "to be limited to half the usual amount\n"
+ "of its telekinetic powers.");
+#else
+static const u8 DexDescription_Kadabra_1[] = _(
+ "KADABRA emits a peculiar alpha wave\n"
+ "if it develops a headache. Only those\n"
+ "people with a particularly strong");
+static const u8 DexDescription_Kadabra_2[] = _(
+ "psyche can hope to become a TRAINER\n"
+ "of this POKéMON.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Alakazam_1[] = _(
+ "ALAKAZAM’s brain continually grows,\n"
+ "infinitely multiplying brain cells.\n"
+ "This amazing brain gives this POKéMON");
+static const u8 DexDescription_Alakazam_2[] = _(
+ "an astoundingly high IQ of 5,000.\n"
+ "It has a thorough memory of everything\n"
+ "that has occurred in the world.");
+#else
+static const u8 DexDescription_Alakazam_1[] = _(
+ "ALAKAZAM’s brain continually grows,\n"
+ "making its head far too heavy to\n"
+ "support with its neck.");
+static const u8 DexDescription_Alakazam_2[] = _(
+ "This POKéMON holds its head up using\n"
+ "its psychokinetic power instead.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Machop_1[] = _(
+ "MACHOP exercises by hefting around\n"
+ "a GRAVELER as if it were a barbell.\n"
+ "There are some MACHOP that travel");
+static const u8 DexDescription_Machop_2[] = _(
+ "the world in a quest to master all\n"
+ "kinds of martial arts.");
+#else
+static const u8 DexDescription_Machop_1[] = _(
+ "MACHOP’s muscles are special - they\n"
+ "never get sore no matter how much they\n"
+ "are used in exercise.");
+static const u8 DexDescription_Machop_2[] = _(
+ "This POKéMON has sufficient power to\n"
+ "hurl a hundred adult humans.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Machoke_1[] = _(
+ "MACHOKE undertakes bodybuilding every\n"
+ "day even as it helps people with tough,\n"
+ "physically demanding labor.");
+static const u8 DexDescription_Machoke_2[] = _(
+ "On its days off, this POKéMON heads to\n"
+ "the fields and mountains to exercise\n"
+ "and train.");
+#else
+static const u8 DexDescription_Machoke_1[] = _(
+ "MACHOKE’s thoroughly toned muscles\n"
+ "possess the hardness of steel.\n"
+ "This POKéMON has so much strength,");
+static const u8 DexDescription_Machoke_2[] = _(
+ "it can easily hold aloft a sumo wrestler\n"
+ "on just one finger.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Machamp_1[] = _(
+ "MACHAMP is known as the POKéMON that\n"
+ "has mastered every kind of martial arts.\n"
+ "If it grabs hold of the foe with its four");
+static const u8 DexDescription_Machamp_2[] = _(
+ "arms, the battle is all but over.\n"
+ "The hapless foe is thrown far over the\n"
+ "horizon.");
+#else
+static const u8 DexDescription_Machamp_1[] = _(
+ "MACHAMP has the power to hurl anything\n"
+ "aside. However, trying to do any work\n"
+ "requiring care and dexterity causes");
+static const u8 DexDescription_Machamp_2[] = _(
+ "its arms to get tangled.\n"
+ "This POKéMON tends to leap into action\n"
+ "before it thinks.");
+#endif
+
+static const u8 DexDescription_Bellsprout_1[] = _(
+ "BELLSPROUT’s thin and flexible body\n"
+ "lets it bend and sway to avoid any\n"
+ "attack, however strong it may be.");
+static const u8 DexDescription_Bellsprout_2[] = _(
+ "From its mouth, this POKéMON spits a\n"
+ "corrosive fluid that melts even iron.");
+
+static const u8 DexDescription_Weepinbell_1[] = _(
+ "WEEPINBELL has a large hook on its rear\n"
+ "end. At night, the POKéMON hooks on to\n"
+ "a tree branch and goes to sleep.");
+static const u8 DexDescription_Weepinbell_2[] = _(
+ "If it moves around in its sleep, it may\n"
+ "wake up to find itself on the ground.");
+
+static const u8 DexDescription_Victreebel_1[] = _(
+ "VICTREEBEL has a long vine that\n"
+ "extends from its head. This vine is\n"
+ "waved and flicked about as if it were");
+static const u8 DexDescription_Victreebel_2[] = _(
+ "an animal to attract prey. When an\n"
+ "unsuspecting prey draws near, this\n"
+ "POKéMON swallows it whole.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Tentacool_1[] = _(
+ "TENTACOOL absorbs sunlight and\n"
+ "refracts it using water inside its body\n"
+ "to convert it into beam energy.");
+static const u8 DexDescription_Tentacool_2[] = _(
+ "This POKéMON shoots beams from its\n"
+ "crystal-like eyes.");
+#else
+static const u8 DexDescription_Tentacool_1[] = _(
+ "TENTACOOL’s body is largely composed\n"
+ "of water. If it is removed from the\n"
+ "sea, it dries up like parchment.");
+static const u8 DexDescription_Tentacool_2[] = _(
+ "If this POKéMON happens to become\n"
+ "dehydrated, put it back into the sea.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Tentacruel_1[] = _(
+ "TENTACRUEL has tentacles that can be\n"
+ "freely elongated and shortened at will.\n"
+ "It ensnares prey with its tentacles and");
+static const u8 DexDescription_Tentacruel_2[] = _(
+ "weakens the prey by dosing it with a\n"
+ "harsh toxin. It can catch up to 80\n"
+ "prey at the same time.");
+#else
+static const u8 DexDescription_Tentacruel_1[] = _(
+ "TENTACRUEL has large red orbs on its\n"
+ "head. The orbs glow before lashing the\n"
+ "vicinity with a harsh ultrasonic blast.");
+static const u8 DexDescription_Tentacruel_2[] = _(
+ "This POKéMON’s outburst creates rough\n"
+ "waves around it.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Geodude_1[] = _(
+ "When GEODUDE sleeps deeply, it buries\n"
+ "itself halfway into the ground.\n"
+ "It will not awaken even if hikers step");
+static const u8 DexDescription_Geodude_2[] = _(
+ "on it unwittingly.\n"
+ "In the morning, this POKéMON rolls\n"
+ "downhill in search of food.");
+#else
+static const u8 DexDescription_Geodude_1[] = _(
+ "The longer a GEODUDE lives, the more\n"
+ "its edges are chipped and worn away,\n"
+ "making it more rounded in appearance.");
+static const u8 DexDescription_Geodude_2[] = _(
+ "However, this POKéMON’s heart will\n"
+ "remain hard, craggy, and rough always.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Graveler_1[] = _(
+ "Rocks are GRAVELER’s favorite food.\n"
+ "This POKéMON will climb a mountain from\n"
+ "the base to the summit, crunchingly");
+static const u8 DexDescription_Graveler_2[] = _(
+ "feasting on rocks all the while.\n"
+ "Upon reaching the peak, it rolls back\n"
+ "down to the bottom.");
+#else
+static const u8 DexDescription_Graveler_1[] = _(
+ "GRAVELER grows by feeding on rocks.\n"
+ "Apparently, it prefers to eat rocks\n"
+ "that are covered in moss.");
+static const u8 DexDescription_Graveler_2[] = _(
+ "This POKéMON eats its way through\n"
+ "a ton of rocks on a daily basis.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Golem_1[] = _(
+ "GOLEM is known for rolling down from\n"
+ "mountains. To prevent them from rolling\n"
+ "into the homes of people downhill,");
+static const u8 DexDescription_Golem_2[] = _(
+ "grooves have been dug into the sides of\n"
+ "mountains to serve as guideways for\n"
+ "diverting this POKéMON’s course.");
+#else
+static const u8 DexDescription_Golem_1[] = _(
+ "GOLEM live up on mountains.\n"
+ "If there is a large earthquake, these\n"
+ "POKéMON will come rolling down off");
+static const u8 DexDescription_Golem_2[] = _(
+ "the mountains en masse to the\n"
+ "foothills below.");
+#endif
+
+static const u8 DexDescription_Ponyta_1[] = _(
+ "PONYTA is very weak at birth.\n"
+ "It can barely stand up.\n"
+ "This POKéMON becomes stronger by");
+static const u8 DexDescription_Ponyta_2[] = _(
+ "stumbling and falling to keep up with\n"
+ "its parent.");
+
+static const u8 DexDescription_Rapidash_1[] = _(
+ "RAPIDASH usually can be seen casually\n"
+ "cantering in the fields and plains.\n"
+ "However, when this POKéMON turns");
+static const u8 DexDescription_Rapidash_2[] = _(
+ "serious, its fiery manes flare and blaze\n"
+ "as it gallops its way up to 150 mph.");
+
+static const u8 DexDescription_Slowpoke_1[] = _(
+ "SLOWPOKE uses its tail to catch prey by\n"
+ "dipping it in water at the side of a\n"
+ "river.");
+static const u8 DexDescription_Slowpoke_2[] = _(
+ "However, this POKéMON often forgets\n"
+ "what it’s doing and often spends entire\n"
+ "days just loafing at water’s edge.");
+
+static const u8 DexDescription_Slowbro_1[] = _(
+ "SLOWBRO’s tail has a SHELLDER firmly\n"
+ "attached with a bite. As a result, the\n"
+ "tail can’t be used for fishing anymore.");
+static const u8 DexDescription_Slowbro_2[] = _(
+ "This causes SLOWBRO to grudgingly swim\n"
+ "and catch prey instead.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Magnemite_1[] = _(
+ "MAGNEMITE floats in the air by emitting\n"
+ "electromagnetic waves from the units\n"
+ "at its sides. These waves block gravity.");
+static const u8 DexDescription_Magnemite_2[] = _(
+ "This POKéMON becomes incapable of\n"
+ "flight if its internal electrical supply\n"
+ "is depleted.");
+#else
+static const u8 DexDescription_Magnemite_1[] = _(
+ "MAGNEMITE attaches itself to power\n"
+ "lines to feed on electricity.\n"
+ "If your house has a power outage,");
+static const u8 DexDescription_Magnemite_2[] = _(
+ "check your circuit breakers. You may\n"
+ "find a large number of this POKéMON\n"
+ "clinging to the breaker box.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Magneton_1[] = _(
+ "MAGNETON emits a powerful magnetic\n"
+ "force that is fatal to electronics and\n"
+ "precision instruments. Because of");
+static const u8 DexDescription_Magneton_2[] = _(
+ "this, it is said that some towns warn\n"
+ "people to keep this POKéMON inside\n"
+ "a POKé BALL.");
+#else
+static const u8 DexDescription_Magneton_1[] = _(
+ "MAGNETON emits a powerful magnetic\n"
+ "force that is fatal to mechanical\n"
+ "devices. As a result, large cities sound");
+static const u8 DexDescription_Magneton_2[] = _(
+ "sirens to warn citizens of large-scale\n"
+ "outbreaks of this POKéMON.");
+#endif
+
+static const u8 DexDescription_Farfetchd_1[] = _(
+ "FARFETCH’D is always seen with a stick\n"
+ "from a plant of some sort. Apparently,\n"
+ "there are good sticks and bad sticks.");
+static const u8 DexDescription_Farfetchd_2[] = _(
+ "This POKéMON has been known to fight\n"
+ "with others over sticks.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Doduo_1[] = _(
+ "DODUO’s two heads contain completely\n"
+ "identical brains.\n"
+ "A scientific study reported that on");
+static const u8 DexDescription_Doduo_2[] = _(
+ "rare occasions, there will be examples\n"
+ "of this POKéMON possessing different\n"
+ "sets of brains.");
+#else
+static const u8 DexDescription_Doduo_1[] = _(
+ "DODUO’s two heads never sleep at the\n"
+ "same time.\n"
+ "Its two heads take turns sleeping,");
+static const u8 DexDescription_Doduo_2[] = _(
+ "so one head can always keep watch for\n"
+ "enemies while the other one sleeps.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Dodrio_1[] = _(
+ "Apparently, the heads aren’t the only\n"
+ "parts of the body that DODRIO has\n"
+ "three of.");
+static const u8 DexDescription_Dodrio_2[] = _(
+ "It has three sets of hearts and lungs\n"
+ "as well, so it is capable of running long\n"
+ "distances without rest.");
+#else
+static const u8 DexDescription_Dodrio_1[] = _(
+ "Watch out if DODRIO’s three heads are\n"
+ "looking in three separate directions.\n"
+ "It’s a sure sign that it is on its guard.");
+static const u8 DexDescription_Dodrio_2[] = _(
+ "Don’t go near this POKéMON if it’s being\n"
+ "wary - it may decide to peck you.");
+#endif
+
+static const u8 DexDescription_Seel_1[] = _(
+ "SEEL hunts for prey in the frigid sea\n"
+ "underneath sheets of ice.\n"
+ "When it needs to breathe, it punches");
+static const u8 DexDescription_Seel_2[] = _(
+ "a hole through the ice with the\n"
+ "sharply protruding section of its head.");
+
+static const u8 DexDescription_Dewgong_1[] = _(
+ "DEWGONG loves to snooze on bitterly\n"
+ "cold ice.\n"
+ "The sight of this POKéMON sleeping on");
+static const u8 DexDescription_Dewgong_2[] = _(
+ "a glacier was mistakenly thought to be\n"
+ "a mermaid by a mariner long ago.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Grimer_1[] = _(
+ "GRIMER emerged from the sludge that\n"
+ "settled on a polluted seabed.\n"
+ "This POKéMON loves anything filthy.");
+static const u8 DexDescription_Grimer_2[] = _(
+ "It constantly leaks a horribly germ-\n"
+ "infested fluid from all over its body.");
+#else
+static const u8 DexDescription_Grimer_1[] = _(
+ "GRIMER’s sludgy and rubbery body can\n"
+ "be forced through any opening, however\n"
+ "small it may be.");
+static const u8 DexDescription_Grimer_2[] = _(
+ "This POKéMON enters sewer pipes to\n"
+ "drink filthy wastewater.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Muk_1[] = _(
+ "This POKéMON’s favorite food is\n"
+ "anything that is repugnantly filthy.\n"
+ "In dirty towns where people think");
+static const u8 DexDescription_Muk_2[] = _(
+ "nothing of throwing away litter on the\n"
+ "streets, MUK are certain to gather.");
+#else
+static const u8 DexDescription_Muk_1[] = _(
+ "From MUK’s body seeps a foul fluid that\n"
+ "gives off a nose-bendingly horrible\n"
+ "stench.");
+static const u8 DexDescription_Muk_2[] = _(
+ "Just one drop of this POKéMON’s body\n"
+ "fluid can turn a pool stagnant and\n"
+ "rancid.");
+#endif
+
+static const u8 DexDescription_Shellder_1[] = _(
+ "At night, this POKéMON uses its broad\n"
+ "tongue to burrow a hole in the seafloor\n"
+ "sand and then sleep in it.");
+static const u8 DexDescription_Shellder_2[] = _(
+ "While it is sleeping, SHELLDER closes its\n"
+ "shell, but leaves its tongue hanging\n"
+ "out.");
+
+static const u8 DexDescription_Cloyster_1[] = _(
+ "CLOYSTER is capable of swimming in the\n"
+ "sea. It does so by swallowing water,\n"
+ "then jetting it out toward the rear.");
+static const u8 DexDescription_Cloyster_2[] = _(
+ "This POKéMON shoots spikes from its\n"
+ "shell using the same system.");
+
+static const u8 DexDescription_Gastly_1[] = _(
+ "GASTLY is largely composed of gaseous\n"
+ "matter. When exposed to a strong wind,\n"
+ "the gaseous body quickly dwindles away.");
+static const u8 DexDescription_Gastly_2[] = _(
+ "Groups of this POKéMON cluster under\n"
+ "the eaves of houses to escape the\n"
+ "ravages of wind.");
+
+static const u8 DexDescription_Haunter_1[] = _(
+ "HAUNTER is a dangerous POKéMON.\n"
+ "If one beckons you while floating in\n"
+ "darkness, you must never approach it.");
+static const u8 DexDescription_Haunter_2[] = _(
+ "This POKéMON will try to lick you with its\n"
+ "tongue and steal your life away.");
+
+static const u8 DexDescription_Gengar_1[] = _(
+ "Sometimes, on a dark night, your shadow\n"
+ "thrown by a streetlight will suddenly\n"
+ "and startlingly overtake you.");
+static const u8 DexDescription_Gengar_2[] = _(
+ "It is actually a GENGAR running past\n"
+ "you, pretending to be your shadow.");
+
+static const u8 DexDescription_Onix_1[] = _(
+ "ONIX has a magnet in its brain. It acts\n"
+ "as a compass so that this POKéMON does\n"
+ "not lose direction while it is tunneling.");
+static const u8 DexDescription_Onix_2[] = _(
+ "As it grows older, its body becomes\n"
+ "increasingly rounder and smoother.");
+
+static const u8 DexDescription_Drowzee_1[] = _(
+ "If your nose becomes itchy while you\n"
+ "are sleeping, it’s a sure sign that one\n"
+ "of these POKéMON is standing above");
+static const u8 DexDescription_Drowzee_2[] = _(
+ "your pillow and trying to eat your dream\n"
+ "through your nostrils.");
+
+static const u8 DexDescription_Hypno_1[] = _(
+ "HYPNO holds a pendulum in its hand.\n"
+ "The arcing movement and glitter of the\n"
+ "pendulum lull the foe into a deep state");
+static const u8 DexDescription_Hypno_2[] = _(
+ "of hypnosis.\n"
+ "While this POKéMON searches for prey,\n"
+ "it polishes the pendulum.");
+
+static const u8 DexDescription_Krabby_1[] = _(
+ "KRABBY live on beaches, burrowed inside\n"
+ "holes dug into the sand.\n"
+ "On sandy beaches with little in the way");
+static const u8 DexDescription_Krabby_2[] = _(
+ "of food, these POKéMON can be seen\n"
+ "squabbling with each other over\n"
+ "territory.");
+
+static const u8 DexDescription_Kingler_1[] = _(
+ "KINGLER has an enormous, oversized\n"
+ "claw. It waves this huge claw in the\n"
+ "air to communicate with others.");
+static const u8 DexDescription_Kingler_2[] = _(
+ "However, because the claw is so heavy,\n"
+ "the POKéMON quickly tires.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Voltorb_1[] = _(
+ "VOLTORB is extremely sensitive - it\n"
+ "explodes at the slightest of shocks.\n"
+ "It is rumored that it was first created");
+static const u8 DexDescription_Voltorb_2[] = _(
+ "when a POKé BALL was exposed to a\n"
+ "powerful pulse of energy.");
+#else
+static const u8 DexDescription_Voltorb_1[] = _(
+ "VOLTORB was first sighted at a company\n"
+ "that manufactures POKé BALLS.\n"
+ "The link between that sighting and");
+static const u8 DexDescription_Voltorb_2[] = _(
+ "the fact that this POKéMON looks very\n"
+ "similar to a POKé BALL remains a\n"
+ "mystery.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Electrode_1[] = _(
+ "One of ELECTRODE’s characteristics is\n"
+ "its attraction to electricity.\n"
+ "It is a problematical POKéMON that");
+static const u8 DexDescription_Electrode_2[] = _(
+ "congregates mostly at electrical\n"
+ "power plants to feed on electricity\n"
+ "that has just been generated.");
+#else
+static const u8 DexDescription_Electrode_1[] = _(
+ "ELECTRODE eats electricity in the\n"
+ "atmosphere. On days when lightning\n"
+ "strikes, you can see this POKéMON");
+static const u8 DexDescription_Electrode_2[] = _(
+ "exploding all over the place from\n"
+ "eating too much electricity.");
+#endif
+
+static const u8 DexDescription_Exeggcute_1[] = _(
+ "This POKéMON consists of six eggs that\n"
+ "form a closely knit cluster. The six eggs\n"
+ "attract each other and spin around.");
+static const u8 DexDescription_Exeggcute_2[] = _(
+ "When cracks increasingly appear on the\n"
+ "eggs, EXEGGCUTE is close to evolution.");
+
+static const u8 DexDescription_Exeggutor_1[] = _(
+ "EXEGGUTOR originally came from the\n"
+ "tropics. Its heads steadily grow larger\n"
+ "from exposure to strong sunlight.");
+static const u8 DexDescription_Exeggutor_2[] = _(
+ "It is said that when the heads fall off,\n"
+ "they group together to form EXEGGCUTE.");
+
+static const u8 DexDescription_Cubone_1[] = _(
+ "CUBONE pines for the mother it will\n"
+ "never see again. Seeing a likeness of\n"
+ "its mother in the full moon, it cries.");
+static const u8 DexDescription_Cubone_2[] = _(
+ "The stains on the skull the POKéMON\n"
+ "wears are made by the tears it sheds.");
+
+static const u8 DexDescription_Marowak_1[] = _(
+ "MAROWAK is the evolved form of a CUBONE\n"
+ "that has overcome its sadness at the\n"
+ "loss of its mother and grown tough.");
+static const u8 DexDescription_Marowak_2[] = _(
+ "This POKéMON’s tempered and hardened\n"
+ "spirit is not easily broken.");
+
+static const u8 DexDescription_Hitmonlee_1[] = _(
+ "HITMONLEE’s legs freely contract and\n"
+ "stretch. Using these springlike legs, it\n"
+ "bowls over foes with devastating kicks.");
+static const u8 DexDescription_Hitmonlee_2[] = _(
+ "After battle, it rubs down its legs and\n"
+ "loosens the muscles to overcome\n"
+ "fatigue.");
+
+static const u8 DexDescription_Hitmonchan_1[] = _(
+ "HITMONCHAN is said to possess the\n"
+ "spirit of a boxer who had been working\n"
+ "towards a world championship.");
+static const u8 DexDescription_Hitmonchan_2[] = _(
+ "This POKéMON has an indomitable spirit\n"
+ "and will never give up in the face of\n"
+ "adversity.");
+
+static const u8 DexDescription_Lickitung_1[] = _(
+ "Whenever LICKITUNG comes across\n"
+ "something new, it will unfailingly give it\n"
+ "a lick. It does so because it memorizes");
+static const u8 DexDescription_Lickitung_2[] = _(
+ "things by texture and by taste.\n"
+ "It is somewhat put off by sour things.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Koffing_1[] = _(
+ "KOFFING embodies toxic substances.\n"
+ "It mixes the toxins with raw garbage to\n"
+ "set off a chemical reaction that");
+static const u8 DexDescription_Koffing_2[] = _(
+ "results in a terribly powerful poison\n"
+ "gas. The higher the temperature, the\n"
+ "more gas is concocted by this POKéMON.");
+#else
+static const u8 DexDescription_Koffing_1[] = _(
+ "If KOFFING becomes agitated, it raises\n"
+ "the toxicity of its internal gases and\n"
+ "jets them out from all over its body.");
+static const u8 DexDescription_Koffing_2[] = _(
+ "This POKéMON may also overinflate its\n"
+ "round body, then explode.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Weezing_1[] = _(
+ "WEEZING alternately shrinks and\n"
+ "inflates its twin bodies to mix together\n"
+ "toxic gases inside.");
+static const u8 DexDescription_Weezing_2[] = _(
+ "The more the gases are mixed, the more\n"
+ "powerful the toxins become. The\n"
+ "POKéMON also becomes more putrid.");
+#else
+static const u8 DexDescription_Weezing_1[] = _(
+ "WEEZING loves the gases given off by\n"
+ "rotted kitchen garbage. This POKéMON\n"
+ "will find a dirty, unkempt house and");
+static const u8 DexDescription_Weezing_2[] = _(
+ "make it its home. At night, when the\n"
+ "people in the house are asleep, it will\n"
+ "go through the trash.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Rhyhorn_1[] = _(
+ "RHYHORN’s brain is very small. It is so\n"
+ "dense, while on a run it forgets why it\n"
+ "started running in the first place.");
+static const u8 DexDescription_Rhyhorn_2[] = _(
+ "It apparently remembers sometimes if it\n"
+ "demolishes something.");
+#else
+static const u8 DexDescription_Rhyhorn_1[] = _(
+ "RHYHORN runs in a straight line,\n"
+ "smashing everything in its path.\n"
+ "It is not bothered even if it rushes");
+static const u8 DexDescription_Rhyhorn_2[] = _(
+ "headlong into a block of steel.\n"
+ "This POKéMON may feel some pain from\n"
+ "the collision the next day, however.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Rhydon_1[] = _(
+ "RHYDON has a horn that serves as a\n"
+ "drill. It is used for destroying rocks\n"
+ "and boulders.");
+static const u8 DexDescription_Rhydon_2[] = _(
+ "This POKéMON occasionally rams into\n"
+ "streams of magma, but the armor-like\n"
+ "hide prevents it from feeling the heat.");
+#else
+static const u8 DexDescription_Rhydon_1[] = _(
+ "RHYDON’s horn can crush even uncut\n"
+ "diamonds. One sweeping blow of its tail\n"
+ "can topple a building.");
+static const u8 DexDescription_Rhydon_2[] = _(
+ "This POKéMON’s hide is extremely tough.\n"
+ "Even direct cannon hits don’t leave\n"
+ "a scratch.");
+#endif
+
+static const u8 DexDescription_Chansey_1[] = _(
+ "CHANSEY lays nutritionally excellent\n"
+ "eggs on an everyday basis.\n"
+ "The eggs are so delicious, they are");
+static const u8 DexDescription_Chansey_2[] = _(
+ "easily and eagerly devoured by even\n"
+ "those people who have lost their\n"
+ "appetite.");
+
+static const u8 DexDescription_Tangela_1[] = _(
+ "TANGELA’s vines snap off easily if they\n"
+ "are grabbed. This happens without pain,\n"
+ "allowing it to make a quick getaway.");
+static const u8 DexDescription_Tangela_2[] = _(
+ "The lost vines are replaced by newly\n"
+ "grown vines the very next day.");
+
+static const u8 DexDescription_Kangaskhan_1[] = _(
+ "If you come across a young KANGASKHAN\n"
+ "playing by itself, you must never\n"
+ "disturb it or attempt to catch it.");
+static const u8 DexDescription_Kangaskhan_2[] = _(
+ "The baby POKéMON’s parent is sure to\n"
+ "be in the area, and it will become\n"
+ "violently enraged at you.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Horsea_1[] = _(
+ "If HORSEA senses danger, it will\n"
+ "reflexively spray a dense black ink\n"
+ "from its mouth and try to escape.");
+static const u8 DexDescription_Horsea_2[] = _(
+ "This POKéMON swims by cleverly flapping\n"
+ "the fins on its back.");
+#else
+static const u8 DexDescription_Horsea_1[] = _(
+ "HORSEA eats small insects and moss off\n"
+ "of rocks. If the ocean current turns\n"
+ "fast, this POKéMON anchors itself by");
+static const u8 DexDescription_Horsea_2[] = _(
+ "wrapping its tail around rocks or coral\n"
+ "to prevent being washed away.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Seadra_1[] = _(
+ "SEADRA generates whirlpools by spinning\n"
+ "its body. The whirlpools are strong\n"
+ "enough to swallow even fishing boats.");
+static const u8 DexDescription_Seadra_2[] = _(
+ "This POKéMON weakens prey with these\n"
+ "currents, then swallows it whole.");
+#else
+static const u8 DexDescription_Seadra_1[] = _(
+ "SEADRA sleeps after wriggling itself\n"
+ "between the branches of coral.\n"
+ "Those trying to harvest coral are");
+static const u8 DexDescription_Seadra_2[] = _(
+ "occasionally stung by this POKéMON’s\n"
+ "poison barbs if they fail to notice it.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Goldeen_1[] = _(
+ "GOLDEEN loves swimming wild and free\n"
+ "in rivers and ponds.\n"
+ "If one of these POKéMON is placed in an");
+static const u8 DexDescription_Goldeen_2[] = _(
+ "aquarium, it will shatter even the\n"
+ "thickest glass with one ram of its horn\n"
+ "and make its escape.");
+#else
+static const u8 DexDescription_Goldeen_1[] = _(
+ "GOLDEEN is a very beautiful POKéMON\n"
+ "with fins that billow elegantly in water.\n"
+ "However, don’t let your guard down");
+static const u8 DexDescription_Goldeen_2[] = _(
+ "around this POKéMON - it could ram you\n"
+ "powerfully with its horn.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Seaking_1[] = _(
+ "SEAKING is very protective of its eggs.\n"
+ "The male and female will take turns\n"
+ "patrolling around their nest and eggs.");
+static const u8 DexDescription_Seaking_2[] = _(
+ "The guarding of eggs by these POKéMON\n"
+ "goes on for over a month.");
+#else
+static const u8 DexDescription_Seaking_1[] = _(
+ "In the autumn, SEAKING males can be\n"
+ "seen performing courtship dances in\n"
+ "riverbeds to woo females.");
+static const u8 DexDescription_Seaking_2[] = _(
+ "During this season, this POKéMON’s body\n"
+ "coloration is at its most beautiful.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Staryu_1[] = _(
+ "STARYU apparently communicates with\n"
+ "the stars in the night sky by flashing\n"
+ "the red core at the center of its body.");
+static const u8 DexDescription_Staryu_2[] = _(
+ "If parts of its body are torn, this\n"
+ "POKéMON simply regenerates the\n"
+ "missing pieces and limbs.");
+#else
+static const u8 DexDescription_Staryu_1[] = _(
+ "STARYU’s center section has an organ\n"
+ "called the core that shines bright red.\n"
+ "If you go to a beach toward the");
+static const u8 DexDescription_Staryu_2[] = _(
+ "end of summer, the glowing cores of\n"
+ "these POKéMON look like the stars\n"
+ "in the sky.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Starmie_1[] = _(
+ "STARMIE swims through water by\n"
+ "spinning its star-shaped body as if it\n"
+ "were a propeller on a ship.");
+static const u8 DexDescription_Starmie_2[] = _(
+ "The core at the center of this\n"
+ "POKéMON’s body glows in seven colors.");
+#else
+static const u8 DexDescription_Starmie_1[] = _(
+ "STARMIE’s center section - the core -\n"
+ "glows brightly in seven colors.\n"
+ "Because of its luminous nature, this");
+static const u8 DexDescription_Starmie_2[] = _(
+ "POKéMON has been given the nickname\n"
+ "“the gem of the sea.”");
+#endif
+
+static const u8 DexDescription_Mrmime_1[] = _(
+ "MR. MIME is a master of pantomime.\n"
+ "Its gestures and motions convince\n"
+ "watchers that something unseeable");
+static const u8 DexDescription_Mrmime_2[] = _(
+ "actually exists. Once it is believed,\n"
+ "it will exist as if it were a real thing.");
+
+static const u8 DexDescription_Scyther_1[] = _(
+ "SCYTHER is blindingly fast. Its blazing\n"
+ "speed enhances the effectiveness of\n"
+ "the twin scythes on its forearms.");
+static const u8 DexDescription_Scyther_2[] = _(
+ "This POKéMON’s scythes are so\n"
+ "effective, they can slice through thick\n"
+ "logs in one wicked stroke.");
+
+static const u8 DexDescription_Jynx_1[] = _(
+ "JYNX walks rhythmically, swaying and\n"
+ "shaking its hips as if it were dancing.\n"
+ "Its motions are so bouncingly alluring,");
+static const u8 DexDescription_Jynx_2[] = _(
+ "people seeing it are compelled to shake\n"
+ "their hips without giving any thought\n"
+ "to what they are doing.");
+
+static const u8 DexDescription_Electabuzz_1[] = _(
+ "When a storm arrives, gangs of this\n"
+ "POKéMON compete with each other to\n"
+ "scale heights that are likely to be");
+static const u8 DexDescription_Electabuzz_2[] = _(
+ "stricken by lightning bolts.\n"
+ "Some towns use ELECTABUZZ in place of\n"
+ "lightning rods.");
+
+static const u8 DexDescription_Magmar_1[] = _(
+ "In battle, MAGMAR blows out intensely\n"
+ "hot flames from all over its body to\n"
+ "intimidate its opponent.");
+static const u8 DexDescription_Magmar_2[] = _(
+ "This POKéMON’s fiery bursts create\n"
+ "heat waves that ignite grass and trees\n"
+ "in its surroundings.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Pinsir_1[] = _(
+ "PINSIR has a pair of massive horns \n"
+ "Protruding from the surface of these\n"
+ "horns are thorns.");
+static const u8 DexDescription_Pinsir_2[] = _(
+ "These thorns are driven deeply into the\n"
+ "foe’s body when the pincer closes,\n"
+ "making it tough for the foe to escape.");
+#else
+static const u8 DexDescription_Pinsir_1[] = _(
+ "PINSIR is astoundingly strong. It can\n"
+ "grip a foe weighing twice its weight\n"
+ "in its horns and easily lift it.");
+static const u8 DexDescription_Pinsir_2[] = _(
+ "This POKéMON’s movements turn sluggish\n"
+ "in cold places.");
+#endif
+
+static const u8 DexDescription_Tauros_1[] = _(
+ "This POKéMON is not satisfied unless\n"
+ "it is rampaging at all times.\n"
+ "If there is no opponent for TAUROS to");
+static const u8 DexDescription_Tauros_2[] = _(
+ "battle, it will charge at thick trees and\n"
+ "knock them down to calm itself.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Magikarp_1[] = _(
+ "MAGIKARP is virtually useless in battle\n"
+ "as it can only splash around.\n"
+ "As a result, it is considered to be weak.");
+static const u8 DexDescription_Magikarp_2[] = _(
+ "However, it is actually a very hardy\n"
+ "POKéMON that can survive in any body of\n"
+ "water no matter how polluted it is.");
+#else
+static const u8 DexDescription_Magikarp_1[] = _(
+ "MAGIKARP is a pathetic excuse for a\n"
+ "POKéMON that is only capable of\n"
+ "flopping and splashing.");
+static const u8 DexDescription_Magikarp_2[] = _(
+ "This behavior prompted scientists to\n"
+ "undertake research into it.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Gyarados_1[] = _(
+ "Once GYARADOS goes on a rampage, its\n"
+ "ferociously violent blood doesn’t calm\n"
+ "until it has burned everything down.");
+static const u8 DexDescription_Gyarados_2[] = _(
+ "There are records of this POKéMON’s\n"
+ "rampages lasting a whole month.");
+#else
+static const u8 DexDescription_Gyarados_1[] = _(
+ "When MAGIKARP evolves into GYARADOS,\n"
+ "its brain cells undergo a structural\n"
+ "transformation. It is said that this");
+static const u8 DexDescription_Gyarados_2[] = _(
+ "transformation is to blame for this\n"
+ "POKéMON’s wildly violent nature.");
+#endif
+
+static const u8 DexDescription_Lapras_1[] = _(
+ "People have driven LAPRAS almost to the\n"
+ "point of extinction. In the evenings,\n"
+ "this POKéMON is said to sing plaintively");
+static const u8 DexDescription_Lapras_2[] = _(
+ "as it seeks what few others of its kind\n"
+ "still remain.");
+
+static const u8 DexDescription_Ditto_1[] = _(
+ "DITTO rearranges its cell structure to\n"
+ "transform itself into other shapes.\n"
+ "However, if it tries to transform itself");
+static const u8 DexDescription_Ditto_2[] = _(
+ "into something by relying on its memory,\n"
+ "this POKéMON manages to get details\n"
+ "wrong.");
+
+static const u8 DexDescription_Eevee_1[] = _(
+ "EEVEE has an unstable genetic makeup\n"
+ "that suddenly mutates due to the\n"
+ "environment in which it lives.");
+static const u8 DexDescription_Eevee_2[] = _(
+ "Radiation from various STONES causes\n"
+ "this POKéMON to evolve.");
+
+static const u8 DexDescription_Vaporeon_1[] = _(
+ "VAPOREON underwent a spontaneous\n"
+ "mutation and grew fins and gills that\n"
+ "allow it to live underwater.");
+static const u8 DexDescription_Vaporeon_2[] = _(
+ "This POKéMON has the ability to freely\n"
+ "control water.");
+
+static const u8 DexDescription_Jolteon_1[] = _(
+ "JOLTEON’s cells generate a low level of\n"
+ "electricity. This power is amplified by\n"
+ "the static electricity of its fur,");
+static const u8 DexDescription_Jolteon_2[] = _(
+ "enabling the POKéMON to drop\n"
+ "thunderbolts. The bristling fur is made\n"
+ "of electrically charged needles.");
+
+static const u8 DexDescription_Flareon_1[] = _(
+ "FLAREON’s fluffy fur has a functional\n"
+ "purpose - it releases heat into the air\n"
+ "so that its body does not get");
+static const u8 DexDescription_Flareon_2[] = _(
+ "excessively hot.\n"
+ "This POKéMON’s body temperature can\n"
+ "rise to a maximum of 1,650 degrees F.");
+
+static const u8 DexDescription_Porygon_1[] = _(
+ "PORYGON is capable of reverting itself\n"
+ "entirely back to program data and\n"
+ "entering cyberspace.");
+static const u8 DexDescription_Porygon_2[] = _(
+ "This POKéMON is copy-protected so it\n"
+ "cannot be duplicated by copying.");
+
+static const u8 DexDescription_Omanyte_1[] = _(
+ "OMANYTE is one of the ancient and long-\n"
+ "since-extinct POKéMON that have been\n"
+ "regenerated from fossils by people.");
+static const u8 DexDescription_Omanyte_2[] = _(
+ "If attacked by an enemy, it withdraws\n"
+ "itself inside its hard shell.");
+
+static const u8 DexDescription_Omastar_1[] = _(
+ "OMASTAR uses its tentacles to capture\n"
+ "its prey. It is believed to have become\n"
+ "extinct because its shell grew too large");
+static const u8 DexDescription_Omastar_2[] = _(
+ "and heavy, causing its movements to\n"
+ "become too slow and ponderous.");
+
+static const u8 DexDescription_Kabuto_1[] = _(
+ "KABUTO is a POKéMON that has been\n"
+ "regenerated from a fossil. However, in\n"
+ "extremely rare cases, living examples");
+static const u8 DexDescription_Kabuto_2[] = _(
+ "have been discovered.\n"
+ "The POKéMON has not changed at all for\n"
+ "300 million years.");
+
+static const u8 DexDescription_Kabutops_1[] = _(
+ "KABUTOPS swam underwater to hunt for\n"
+ "its prey in ancient times.\n"
+ "The POKéMON was apparently evolving");
+static const u8 DexDescription_Kabutops_2[] = _(
+ "from being a water-dweller to living on\n"
+ "land as evident from the beginnings of\n"
+ "change in its gills and legs.");
+
+static const u8 DexDescription_Aerodactyl_1[] = _(
+ "AERODACTYL is a POKéMON from the age\n"
+ "of dinosaurs. It was regenerated from\n"
+ "genetic material extracted from amber.");
+static const u8 DexDescription_Aerodactyl_2[] = _(
+ "It is imagined to have been the king of\n"
+ "the skies in ancient times.");
+
+static const u8 DexDescription_Snorlax_1[] = _(
+ "SNORLAX’s typical day consists of\n"
+ "nothing more than eating and sleeping.\n"
+ "It is such a docile POKéMON that there");
+static const u8 DexDescription_Snorlax_2[] = _(
+ "are children who use its expansive belly\n"
+ "as a place to play.");
+
+static const u8 DexDescription_Articuno_1[] = _(
+ "ARTICUNO is a legendary bird POKéMON\n"
+ "that can control ice.\n"
+ "The flapping of its wings chills the air.");
+static const u8 DexDescription_Articuno_2[] = _(
+ "As a result, it is said that when this\n"
+ "POKéMON flies, snow will fall.");
+
+static const u8 DexDescription_Zapdos_1[] = _(
+ "ZAPDOS is a legendary bird POKéMON that\n"
+ "has the ability to control electricity.\n"
+ "It usually lives in thunderclouds.");
+static const u8 DexDescription_Zapdos_2[] = _(
+ "The POKéMON gains power if it is\n"
+ "stricken by lightning bolts.");
+
+static const u8 DexDescription_Moltres_1[] = _(
+ "MOLTRES is a legendary bird POKéMON\n"
+ "that has the ability to control fire.\n"
+ "If this POKéMON is injured, it is said to");
+static const u8 DexDescription_Moltres_2[] = _(
+ "dip its body in the molten magma of a\n"
+ "volcano to burn and heal itself.");
+
+static const u8 DexDescription_Dratini_1[] = _(
+ "DRATINI continually molts and sloughs\n"
+ "off its old skin.\n"
+ "It does so because the life energy");
+static const u8 DexDescription_Dratini_2[] = _(
+ "within its body steadily builds to reach\n"
+ "uncontrollable levels.");
+
+static const u8 DexDescription_Dragonair_1[] = _(
+ "DRAGONAIR stores an enormous amount\n"
+ "of energy inside its body.\n"
+ "It is said to alter weather conditions");
+static const u8 DexDescription_Dragonair_2[] = _(
+ "in its vicinity by discharging energy\n"
+ "from the crystals on its neck and tail.");
+
+static const u8 DexDescription_Dragonite_1[] = _(
+ "DRAGONITE is capable of circling the\n"
+ "globe in just sixteen hours.\n"
+ "It is a kindhearted POKéMON that leads");
+static const u8 DexDescription_Dragonite_2[] = _(
+ "lost and foundering ships in a storm to\n"
+ "the safety of land.");
+
+static const u8 DexDescription_Mewtwo_1[] = _(
+ "MEWTWO is a POKéMON that was created\n"
+ "by genetic manipulation.\n"
+ "However, even though the scientific");
+static const u8 DexDescription_Mewtwo_2[] = _(
+ "power of humans created this POKéMON’s\n"
+ "body, they failed to endow MEWTWO with\n"
+ "a compassionate heart.");
+
+static const u8 DexDescription_Mew_1[] = _(
+ "MEW is said to possess the genetic\n"
+ "composition of all POKéMON.\n"
+ "It is capable of making itself invisible");
+static const u8 DexDescription_Mew_2[] = _(
+ "at will, so it entirely avoids notice even\n"
+ "if it approaches people.");
+
+static const u8 DexDescription_Chikorita_1[] = _(
+ "In battle, CHIKORITA waves its leaf\n"
+ "around to keep the foe at bay.\n"
+ "However, a sweet fragrance also wafts");
+static const u8 DexDescription_Chikorita_2[] = _(
+ "from the leaf, becalming the battling\n"
+ "POKéMON and creating a cozy, friendly\n"
+ "atmosphere all around.");
+
+static const u8 DexDescription_Bayleef_1[] = _(
+ "BAYLEEF’s neck is ringed by curled-up\n"
+ "leaves. Inside each tubular leaf is a\n"
+ "small shoot of a tree.");
+static const u8 DexDescription_Bayleef_2[] = _(
+ "The fragrance of this shoot makes\n"
+ "people peppy.");
+
+static const u8 DexDescription_Meganium_1[] = _(
+ "The fragrance of MEGANIUM’s flower\n"
+ "soothes and calms emotions.\n"
+ "In battle, this POKéMON gives off more");
+static const u8 DexDescription_Meganium_2[] = _(
+ "of its becalming scent to blunt the\n"
+ "foe’s fighting spirit.");
+
+static const u8 DexDescription_Cyndaquil_1[] = _(
+ "CYNDAQUIL protects itself by flaring up\n"
+ "the flames on its back.\n"
+ "The flames are vigorous if the POKéMON");
+static const u8 DexDescription_Cyndaquil_2[] = _(
+ "is angry. However, if it is tired, the\n"
+ "flames splutter fitfully with incomplete\n"
+ "combustion.");
+
+static const u8 DexDescription_Quilava_1[] = _(
+ "QUILAVA keeps its foes at bay with the\n"
+ "intensity of its flames and gusts of\n"
+ "superheated air.");
+static const u8 DexDescription_Quilava_2[] = _(
+ "This POKéMON applies its outstanding\n"
+ "nimbleness to dodge attacks even while\n"
+ "scorching the foe with flames.");
+
+static const u8 DexDescription_Typhlosion_1[] = _(
+ "TYPHLOSION obscures itself behind a\n"
+ "shimmering heat haze that it creates\n"
+ "using its intensely hot flames.");
+static const u8 DexDescription_Typhlosion_2[] = _(
+ "This POKéMON creates blazing explosive\n"
+ "blasts that burn everything to cinders.");
+
+static const u8 DexDescription_Totodile_1[] = _(
+ "Despite the smallness of its body,\n"
+ "TOTODILE’s jaws are very powerful.\n"
+ "While the POKéMON may think it is just");
+static const u8 DexDescription_Totodile_2[] = _(
+ "playfully nipping, its bite has enough\n"
+ "power to cause serious injury.");
+
+static const u8 DexDescription_Croconaw_1[] = _(
+ "Once CROCONAW has clamped its jaws on\n"
+ "its foe, it will absolutely not let go.\n"
+ "Because the tips of its fangs are");
+static const u8 DexDescription_Croconaw_2[] = _(
+ "forked back like barbed fishhooks, they\n"
+ "become impossible to remove when \n"
+ "they have sunk in.");
+
+static const u8 DexDescription_Feraligatr_1[] = _(
+ "FERALIGATR intimidates its foes by\n"
+ "opening its huge mouth.\n"
+ "In battle, it will kick the ground hard");
+static const u8 DexDescription_Feraligatr_2[] = _(
+ "with its thick and powerful hind legs to\n"
+ "charge at the foe at an incredible\n"
+ "speed.");
+
+static const u8 DexDescription_Sentret_1[] = _(
+ "When SENTRET sleeps, it does so while\n"
+ "another stands guard. The sentry wakes\n"
+ "the others at the first sign of danger.");
+static const u8 DexDescription_Sentret_2[] = _(
+ "When this POKéMON becomes separated\n"
+ "from its pack, it becomes incapable of\n"
+ "sleep due to fear.");
+
+static const u8 DexDescription_Furret_1[] = _(
+ "FURRET has a very slim build.\n"
+ "When under attack, it can slickly squirm\n"
+ "through narrow spaces and get away.");
+static const u8 DexDescription_Furret_2[] = _(
+ "In spite of its short limbs, this\n"
+ "POKéMON is very nimble and fleet.");
+
+static const u8 DexDescription_Hoothoot_1[] = _(
+ "HOOTHOOT has an internal organ that\n"
+ "senses and tracks the earth’s rotation.\n"
+ "Using this special organ, this POKéMON");
+static const u8 DexDescription_Hoothoot_2[] = _(
+ "begins hooting at precisely the same\n"
+ "time every day.");
+
+static const u8 DexDescription_Noctowl_1[] = _(
+ "NOCTOWL never fails at catching prey in\n"
+ "darkness. This POKéMON owes its\n"
+ "success to its superior vision that");
+static const u8 DexDescription_Noctowl_2[] = _(
+ "allows it to see in minimal light, and to\n"
+ "its soft, supple wings that make no\n"
+ "sound in flight.");
+
+static const u8 DexDescription_Ledyba_1[] = _(
+ "LEDYBA secretes an aromatic fluid from\n"
+ "where its legs join its body. This fluid\n"
+ "is used for communicating with others.");
+static const u8 DexDescription_Ledyba_2[] = _(
+ "This POKéMON conveys its feelings to\n"
+ "others by altering the fluid’s scent.");
+
+static const u8 DexDescription_Ledian_1[] = _(
+ "It is said that in lands with clean air,\n"
+ "where the stars fill the sky, there live\n"
+ "LEDIAN in countless numbers.");
+static const u8 DexDescription_Ledian_2[] = _(
+ "There is a good reason for this - the\n"
+ "POKéMON uses the light of the stars\n"
+ "as its energy.");
+
+static const u8 DexDescription_Spinarak_1[] = _(
+ "The web spun by SPINARAK can be\n"
+ "considered its second nervous system.\n"
+ "It is said that this POKéMON can");
+static const u8 DexDescription_Spinarak_2[] = _(
+ "determine what kind of prey is touching\n"
+ "its web just by the tiny vibrations it\n"
+ "feels through the web’s strands.");
+
+static const u8 DexDescription_Ariados_1[] = _(
+ "ARIADOS’s feet are tipped with tiny\n"
+ "hooked claws that enable it to scuttle\n"
+ "on ceilings and vertical walls.");
+static const u8 DexDescription_Ariados_2[] = _(
+ "This POKéMON constricts the foe with\n"
+ "thin and strong silk webbing.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Crobat_1[] = _(
+ "CROBAT sneaks up on its intended prey\n"
+ "using wings that barely make a sound.\n"
+ "This POKéMON rests by hanging on a");
+static const u8 DexDescription_Crobat_2[] = _(
+ "tree branch with its rear legs that\n"
+ "serve as wings.");
+#else
+static const u8 DexDescription_Crobat_1[] = _(
+ "If this POKéMON is flying by fluttering\n"
+ "only a pair of wings on either the\n"
+ "forelegs or hind legs, it’s proof that");
+static const u8 DexDescription_Crobat_2[] = _(
+ "CROBAT has been flying a long distance.\n"
+ "It switches the wings it uses if it is\n"
+ "tired.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Chinchou_1[] = _(
+ "CHINCHOU’s two antennas are filled with\n"
+ "cells that generate strong electricity.\n"
+ "This POKéMON’s cells create so much");
+static const u8 DexDescription_Chinchou_2[] = _(
+ "electrical power, it even makes itself\n"
+ "tingle slightly.");
+#else
+static const u8 DexDescription_Chinchou_1[] = _(
+ "CHINCHOU lets loose positive and\n"
+ "negative electrical charges from its\n"
+ "two antennas to make its prey faint.");
+static const u8 DexDescription_Chinchou_2[] = _(
+ "This POKéMON flashes its electric\n"
+ "lights to exchange signals with others.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lanturn_1[] = _(
+ "LANTURN is known to emit light.\n"
+ "If you peer down into the dark sea from\n"
+ "a ship at night, you can sometimes see");
+static const u8 DexDescription_Lanturn_2[] = _(
+ "this POKéMON’s light rising from the\n"
+ "depths where it swims. It gives the sea\n"
+ "an appearance of a starlit night.");
+#else
+static const u8 DexDescription_Lanturn_1[] = _(
+ "LANTURN is nicknamed “the deep-sea\n"
+ "star” for its illuminated antenna.\n"
+ "This POKéMON produces light by");
+static const u8 DexDescription_Lanturn_2[] = _(
+ "causing a chemical reaction between\n"
+ "bacteria and its bodily fluids inside\n"
+ "the antenna.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Pichu_1[] = _(
+ "When PICHU plays with others, it may\n"
+ "short out electricity with another\n"
+ "PICHU, creating a shower of sparks.");
+static const u8 DexDescription_Pichu_2[] = _(
+ "In that event, this POKéMON will begin\n"
+ "crying, startled by the flash of sparks.");
+#else
+static const u8 DexDescription_Pichu_1[] = _(
+ "PICHU charges itself with electricity\n"
+ "more easily on days with thunderclouds\n"
+ "or when the air is very dry.");
+static const u8 DexDescription_Pichu_2[] = _(
+ "You can hear the crackling of static\n"
+ "electricity coming off this POKéMON.");
+#endif
+
+static const u8 DexDescription_Cleffa_1[] = _(
+ "On nights with many shooting stars,\n"
+ "CLEFFA can be seen dancing in a ring.\n"
+ "They dance through the night and stop");
+static const u8 DexDescription_Cleffa_2[] = _(
+ "only at the break of day, when these\n"
+ "POKéMON quench their thirst with the\n"
+ "morning dew.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Igglybuff_1[] = _(
+ "IGGLYBUFF has a soft and plushy body\n"
+ "that feels very much like a marshmallow.\n"
+ "From this body wafts a gently sweet");
+static const u8 DexDescription_Igglybuff_2[] = _(
+ "fragrance that soothes and calms the\n"
+ "emotions of its foes.");
+#else
+static const u8 DexDescription_Igglybuff_1[] = _(
+ "IGGLYBUFF’s vocal chords are not\n"
+ "sufficiently developed. It would hurt\n"
+ "its throat if it were to sing too much.");
+static const u8 DexDescription_Igglybuff_2[] = _(
+ "This POKéMON gargles with freshwater\n"
+ "from a clean stream.");
+#endif
+
+static const u8 DexDescription_Togepi_1[] = _(
+ "As its energy, TOGEPI uses the positive\n"
+ "emotions of compassion and pleasure\n"
+ "exuded by people and POKéMON.");
+static const u8 DexDescription_Togepi_2[] = _(
+ "This POKéMON stores up feelings of\n"
+ "happiness inside its shell, then shares\n"
+ "them with others.");
+
+static const u8 DexDescription_Togetic_1[] = _(
+ "TOGETIC is said to be a POKéMON that\n"
+ "brings good fortune. When the POKéMON\n"
+ "spots someone who is pure of heart,");
+static const u8 DexDescription_Togetic_2[] = _(
+ "it is said to appear and share its\n"
+ "happiness with that person.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Natu_1[] = _(
+ "NATU has a highly developed jumping\n"
+ "ability. The POKéMON flaps and leaps\n"
+ "onto tree branches that are taller than");
+static const u8 DexDescription_Natu_2[] = _(
+ "grown-up people to pick at the tree’s\n"
+ "new shoots.");
+#else
+static const u8 DexDescription_Natu_1[] = _(
+ "NATU cannot fly because its wings are\n"
+ "not yet fully grown. If your eyes meet\n"
+ "with this POKéMON’s eyes, it will stare");
+static const u8 DexDescription_Natu_2[] = _(
+ "back intently at you. But if you move\n"
+ "even slightly, it will hop away to safety.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Xatu_1[] = _(
+ "XATU is known to stand motionless while\n"
+ "staring at the sun all day long.\n"
+ "Some people revere it as a mystical");
+static const u8 DexDescription_Xatu_2[] = _(
+ "POKéMON out of their belief that XATU\n"
+ "is in possession of the power to see\n"
+ "into the future.");
+#else
+static const u8 DexDescription_Xatu_1[] = _(
+ "XATU stands rooted and still in one\n"
+ "spot all day long. People believe that\n"
+ "this POKéMON does so out of fear of");
+static const u8 DexDescription_Xatu_2[] = _(
+ "the terrible things it has foreseen in\n"
+ "the future.");
+#endif
+
+static const u8 DexDescription_Mareep_1[] = _(
+ "MAREEP’s fluffy coat of wool rubs\n"
+ "together and builds a static charge.\n"
+ "The more static electricity is charged,");
+static const u8 DexDescription_Mareep_2[] = _(
+ "the more brightly the lightbulb at the\n"
+ "tip of its tail grows.");
+
+static const u8 DexDescription_Flaaffy_1[] = _(
+ "FLAAFFY’s wool quality changes so that\n"
+ "it can generate a high amount of static\n"
+ "electricity with a small amount of wool.");
+static const u8 DexDescription_Flaaffy_2[] = _(
+ "The bare and slick parts of its hide are\n"
+ "shielded against electricity.");
+
+static const u8 DexDescription_Ampharos_1[] = _(
+ "AMPHAROS gives off so much light that\n"
+ "it can be seen even from space.\n"
+ "People in the old days used the light of");
+static const u8 DexDescription_Ampharos_2[] = _(
+ "this POKéMON to send signals back and\n"
+ "forth with others far away.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Bellossom_1[] = _(
+ "A BELLOSSOM grows flowers more\n"
+ "beautifully if it has evolved from a\n"
+ "smelly GLOOM - the stinkier the better.");
+static const u8 DexDescription_Bellossom_2[] = _(
+ "At night, this POKéMON closes its\n"
+ "petals and goes to sleep.");
+#else
+static const u8 DexDescription_Bellossom_1[] = _(
+ "When BELLOSSOM gets exposed to plenty\n"
+ "of sunlight, the leaves ringing its body\n"
+ "begin to spin around.");
+static const u8 DexDescription_Bellossom_2[] = _(
+ "This POKéMON’s dancing is renowned in\n"
+ "the southern lands.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Marill_1[] = _(
+ "When fishing for food at the edge of a\n"
+ "fast-running stream, MARILL wraps its\n"
+ "tail around the trunk of a tree.");
+static const u8 DexDescription_Marill_2[] = _(
+ "This POKéMON’s tail is flexible and\n"
+ "configured to stretch.");
+#else
+static const u8 DexDescription_Marill_1[] = _(
+ "MARILL’s oil-filled tail acts much like\n"
+ "a life preserver. If you see just its\n"
+ "tail bobbing on the water’s surface,");
+static const u8 DexDescription_Marill_2[] = _(
+ "it’s a sure indication that this POKéMON\n"
+ "is diving beneath the water to feed on\n"
+ "aquatic plants.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Azumarill_1[] = _(
+ "AZUMARILL can make balloons out of\n"
+ "air. It makes these air balloons if it\n"
+ "spots a drowning POKéMON.");
+static const u8 DexDescription_Azumarill_2[] = _(
+ "The air balloons enable the POKéMON in\n"
+ "trouble to breathe.");
+#else
+static const u8 DexDescription_Azumarill_1[] = _(
+ "AZUMARILL’s long ears are indispensable\n"
+ "sensors. By focusing its hearing, this\n"
+ "POKéMON can identify what kinds of");
+static const u8 DexDescription_Azumarill_2[] = _(
+ "prey are around, even in rough and\n"
+ "fast-running rivers.");
+#endif
+
+static const u8 DexDescription_Sudowoodo_1[] = _(
+ "SUDOWOODO camouflages itself as a tree\n"
+ "to avoid being attacked by enemies.\n"
+ "However, because the forelegs remain");
+static const u8 DexDescription_Sudowoodo_2[] = _(
+ "green throughout the year, the POKéMON\n"
+ "is easily identified as a fake during\n"
+ "the winter.");
+
+static const u8 DexDescription_Politoed_1[] = _(
+ "The curled hair on POLITOED’s head is\n"
+ "proof of its status as a king. It is said\n"
+ "that the longer and more curled the");
+static const u8 DexDescription_Politoed_2[] = _(
+ "hair, the more respect this POKéMON\n"
+ "earns from its peers.");
+
+static const u8 DexDescription_Hoppip_1[] = _(
+ "This POKéMON drifts and floats with the\n"
+ "wind. If it senses the approach of\n"
+ "strong winds, HOPPIP links its leaves");
+static const u8 DexDescription_Hoppip_2[] = _(
+ "with other HOPPIP to prepare against\n"
+ "being blown away.");
+
+static const u8 DexDescription_Skiploom_1[] = _(
+ "SKIPLOOM’s flower blossoms when the\n"
+ "temperature rises above 64 degrees F.\n"
+ "How much the flower opens depends on");
+static const u8 DexDescription_Skiploom_2[] = _(
+ "the temperature. For that reason, this\n"
+ "POKéMON is sometimes used as a\n"
+ "thermometer.");
+
+static const u8 DexDescription_Jumpluff_1[] = _(
+ "JUMPLUFF rides warm southern winds to\n"
+ "cross the sea and fly to foreign lands.\n"
+ "The POKéMON descends to the ground");
+static const u8 DexDescription_Jumpluff_2[] = _(
+ "when it encounters cold air while it is\n"
+ "floating.");
+
+static const u8 DexDescription_Aipom_1[] = _(
+ "AIPOM’s tail ends in a hand-like\n"
+ "appendage that can be cleverly\n"
+ "manipulated.");
+static const u8 DexDescription_Aipom_2[] = _(
+ "However, because the POKéMON uses its\n"
+ "tail so much, its real hands have become\n"
+ "rather clumsy.");
+
+static const u8 DexDescription_Sunkern_1[] = _(
+ "SUNKERN tries to move as little as it\n"
+ "possibly can. It does so because it\n"
+ "tries to conserve all the nutrients it");
+static const u8 DexDescription_Sunkern_2[] = _(
+ "has stored in its body for its\n"
+ "evolution. It will not eat a thing, \n"
+ "subsisting only on morning dew.");
+
+static const u8 DexDescription_Sunflora_1[] = _(
+ "SUNFLORA converts solar energy into\n"
+ "nutrition. It moves around actively in\n"
+ "the daytime when it is warm.");
+static const u8 DexDescription_Sunflora_2[] = _(
+ "It stops moving as soon as the sun goes\n"
+ "down for the night.");
+
+static const u8 DexDescription_Yanma_1[] = _(
+ "YANMA is capable of seeing 360 degrees\n"
+ "without having to move its eyes.\n"
+ "It is a great flier that is adept at");
+static const u8 DexDescription_Yanma_2[] = _(
+ "making sudden stops and turning midair.\n"
+ "This POKéMON uses its flying ability to\n"
+ "quickly chase down targeted prey.");
+
+static const u8 DexDescription_Wooper_1[] = _(
+ "WOOPER usually lives in water.\n"
+ "However, it occasionally comes out onto\n"
+ "land in search of food.");
+static const u8 DexDescription_Wooper_2[] = _(
+ "On land, it coats its body with a gooey,\n"
+ "toxic film.");
+
+static const u8 DexDescription_Quagsire_1[] = _(
+ "QUAGSIRE hunts for food by leaving\n"
+ "its mouth wide open in water and waiting\n"
+ "for its prey to blunder in unaware.");
+static const u8 DexDescription_Quagsire_2[] = _(
+ "Because the POKéMON does not move,\n"
+ "it does not get very hungry.");
+
+static const u8 DexDescription_Espeon_1[] = _(
+ "ESPEON is extremely loyal to any\n"
+ "TRAINER it considers to be worthy.\n"
+ "It is said that this POKéMON developed");
+static const u8 DexDescription_Espeon_2[] = _(
+ "its precognitive powers to protect its\n"
+ "TRAINER from harm.");
+
+static const u8 DexDescription_Umbreon_1[] = _(
+ "UMBREON evolved as a result of exposure\n"
+ "to the moon’s waves.\n"
+ "It hides silently in darkness and waits");
+static const u8 DexDescription_Umbreon_2[] = _(
+ "for its foes to make a move.\n"
+ "The rings on its body glow when it leaps\n"
+ "to attack.");
+
+static const u8 DexDescription_Murkrow_1[] = _(
+ "MURKROW was feared and loathed as the\n"
+ "alleged bearer of ill fortune.\n"
+ "This POKéMON shows strong interest in");
+static const u8 DexDescription_Murkrow_2[] = _(
+ "anything that sparkles or glitters.\n"
+ "It will even try to steal rings from\n"
+ "women.");
+
+static const u8 DexDescription_Slowking_1[] = _(
+ "SLOWKING undertakes research every\n"
+ "day in an effort to solve the mysteries\n"
+ "of the world.");
+static const u8 DexDescription_Slowking_2[] = _(
+ "However, this POKéMON apparently\n"
+ "forgets everything it has learned if\n"
+ "the SHELLDER on its head comes off.");
+
+static const u8 DexDescription_Misdreavus_1[] = _(
+ "MISDREAVUS frightens people with a\n"
+ "creepy, sobbing cry. The POKéMON\n"
+ "apparently uses its red spheres to");
+static const u8 DexDescription_Misdreavus_2[] = _(
+ "absorb the fearful feelings of foes and\n"
+ "turn them into nutrition.");
+
+static const u8 DexDescription_Unown_1[] = _(
+ "This POKéMON is shaped like ancient\n"
+ "writing. It is a mystery as to which\n"
+ "came first, the ancient writings or the");
+static const u8 DexDescription_Unown_2[] = _(
+ "various UNOWN. Research into this\n"
+ "topic is ongoing but nothing is known.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wobbuffet_1[] = _(
+ "WOBBUFFET does nothing but endure\n"
+ "attacks - it won’t attack on its own.\n"
+ "However, it won’t endure an attack on");
+static const u8 DexDescription_Wobbuffet_2[] = _(
+ "its tail. When that happens, the\n"
+ "POKéMON will try to take the foe with it\n"
+ "using DESTINY BOND.");
+#else
+static const u8 DexDescription_Wobbuffet_1[] = _(
+ "If two or more WOBBUFFET meet, they will\n"
+ "turn competitive and try to outdo each\n"
+ "other’s endurance.");
+static const u8 DexDescription_Wobbuffet_2[] = _(
+ "However, they may try to see which one\n"
+ "can endure the longest without food.\n"
+ "TRAINERS need to beware of this habit.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Girafarig_1[] = _(
+ "GIRAFARIG’s rear head contains a tiny\n"
+ "brain that is too small for thinking.\n"
+ "However, the rear head doesn’t need to");
+static const u8 DexDescription_Girafarig_2[] = _(
+ "sleep, so it can keep watch over its\n"
+ "surroundings 24 hours a day.");
+#else
+static const u8 DexDescription_Girafarig_1[] = _(
+ "GIRAFARIG’s rear head also has a brain,\n"
+ "but it is small. The rear head attacks in\n"
+ "response to smells and sounds.");
+static const u8 DexDescription_Girafarig_2[] = _(
+ "Approaching this POKéMON from behind\n"
+ "can cause the rear head to suddenly\n"
+ "lash out and bite.");
+#endif
+
+static const u8 DexDescription_Pineco_1[] = _(
+ "PINECO hangs from a tree branch and\n"
+ "patiently waits for prey to come along.\n"
+ "If the POKéMON is disturbed while");
+static const u8 DexDescription_Pineco_2[] = _(
+ "eating by someone shaking its tree, it\n"
+ "drops down to the ground and explodes\n"
+ "with no warning.");
+
+static const u8 DexDescription_Forretress_1[] = _(
+ "FORRETRESS conceals itself inside its\n"
+ "hardened steel shell. The shell is opened\n"
+ "when the POKéMON is catching prey,");
+static const u8 DexDescription_Forretress_2[] = _(
+ "but it does so at such a quick pace\n"
+ "that the shell’s inside cannot be seen.");
+
+static const u8 DexDescription_Dunsparce_1[] = _(
+ "DUNSPARCE has a drill for its tail.\n"
+ "It uses this tail to burrow into the\n"
+ "ground backwards.");
+static const u8 DexDescription_Dunsparce_2[] = _(
+ "This POKéMON is known to make its nest\n"
+ "in complex shapes deep under the\n"
+ "ground.");
+
+static const u8 DexDescription_Gligar_1[] = _(
+ "GLIGAR glides through the air without\n"
+ "a sound as if it were sliding.\n"
+ "This POKéMON hangs on to the face of");
+static const u8 DexDescription_Gligar_2[] = _(
+ "its foe using its clawed hind legs and\n"
+ "the large pincers on its forelegs, then\n"
+ "injects the prey with its poison barb.");
+
+static const u8 DexDescription_Steelix_1[] = _(
+ "STEELIX lives even further underground\n"
+ "than ONIX. This POKéMON is known to dig\n"
+ "towards the earth’s core.");
+static const u8 DexDescription_Steelix_2[] = _(
+ "There are records of this POKéMON\n"
+ "reaching a depth of over six-tenths\n"
+ "of a mile underground.");
+
+static const u8 DexDescription_Snubbull_1[] = _(
+ "By baring its fangs and making a scary\n"
+ "face, SNUBBULL sends smaller POKéMON\n"
+ "scurrying away in terror.");
+static const u8 DexDescription_Snubbull_2[] = _(
+ "However, this POKéMON seems a little\n"
+ "sad at making its foes flee.");
+
+static const u8 DexDescription_Granbull_1[] = _(
+ "GRANBULL has a particularly well-\n"
+ "developed lower jaw. The enormous fangs\n"
+ "are heavy, causing the POKéMON to tip");
+static const u8 DexDescription_Granbull_2[] = _(
+ "its head back for balance.\n"
+ "Unless it is startled, it will not try to\n"
+ "bite indiscriminately.");
+
+static const u8 DexDescription_Qwilfish_1[] = _(
+ "QWILFISH sucks in water, inflating\n"
+ "itself. This POKéMON uses the pressure\n"
+ "of the water it swallowed to shoot");
+static const u8 DexDescription_Qwilfish_2[] = _(
+ "toxic quills all at once from all over\n"
+ "its body. It finds swimming somewhat\n"
+ "challenging.");
+
+static const u8 DexDescription_Scizor_1[] = _(
+ "SCIZOR has a body with the hardness of\n"
+ "steel. It is not easily fazed by ordinary\n"
+ "sorts of attacks.");
+static const u8 DexDescription_Scizor_2[] = _(
+ "This POKéMON flaps its wings to\n"
+ "regulate its body temperature.");
+
+static const u8 DexDescription_Shuckle_1[] = _(
+ "SHUCKLE quietly hides itself under\n"
+ "rocks, keeping its body concealed\n"
+ "inside its hard shell while eating");
+static const u8 DexDescription_Shuckle_2[] = _(
+ "berries it has stored away.\n"
+ "The berries mix with its body fluids to\n"
+ "become a juice.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Heracross_1[] = _(
+ "HERACROSS has sharp claws on its feet.\n"
+ "These are planted firmly into the\n"
+ "ground or the bark of a tree, giving the");
+static const u8 DexDescription_Heracross_2[] = _(
+ "POKéMON a secure and solid footing\n"
+ "to forcefully fling away foes with\n"
+ "its proud horn.");
+#else
+static const u8 DexDescription_Heracross_1[] = _(
+ "HERACROSS charges in a straight line at\n"
+ "its foe, slips beneath the foe’s grasp,\n"
+ "and then scoops up and hurls the");
+static const u8 DexDescription_Heracross_2[] = _(
+ "opponent with its mighty horn.\n"
+ "This POKéMON even has enough power\n"
+ "to topple a massive tree.");
+#endif
+
+static const u8 DexDescription_Sneasel_1[] = _(
+ "SNEASEL scales trees by punching its\n"
+ "hooked claws into the bark.\n"
+ "This POKéMON seeks out unguarded");
+static const u8 DexDescription_Sneasel_2[] = _(
+ "nests and steals eggs for food while\n"
+ "the parents are away.");
+
+static const u8 DexDescription_Teddiursa_1[] = _(
+ "This POKéMON likes to lick its palms that\n"
+ "are sweetened by being soaked in honey.\n"
+ "TEDDIURSA concocts its own honey by");
+static const u8 DexDescription_Teddiursa_2[] = _(
+ "blending fruits and pollen collected by\n"
+ "BEEDRILL.");
+
+static const u8 DexDescription_Ursaring_1[] = _(
+ "In the forests inhabited by URSARING,\n"
+ "it is said that there are many streams\n"
+ "and towering trees where they");
+static const u8 DexDescription_Ursaring_2[] = _(
+ "gather food. This POKéMON walks\n"
+ "through its forest gathering food\n"
+ "every day.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Slugma_1[] = _(
+ "SLUGMA does not have any blood in its\n"
+ "body. Instead, intensely hot magma\n"
+ "circulates throughout this POKéMON’s");
+static const u8 DexDescription_Slugma_2[] = _(
+ "body, carrying essential nutrients and\n"
+ "oxygen to its organs.");
+#else
+static const u8 DexDescription_Slugma_1[] = _(
+ "Molten magma courses throughout\n"
+ "SLUGMA’s circulatory system.\n"
+ "If this POKéMON is chilled, the magma");
+static const u8 DexDescription_Slugma_2[] = _(
+ "cools and hardens. Its body turns\n"
+ "brittle and chunks fall off, reducing\n"
+ "its size.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Magcargo_1[] = _(
+ "MAGCARGO’s body temperature is\n"
+ "approximately 18,000 degrees F.\n"
+ "Water is vaporized on contact.");
+static const u8 DexDescription_Magcargo_2[] = _(
+ "If this POKéMON is caught in the rain,\n"
+ "the raindrops instantly turn into\n"
+ "steam, cloaking the area in a thick fog.");
+#else
+static const u8 DexDescription_Magcargo_1[] = _(
+ "MAGCARGO’s shell is actually its skin\n"
+ "that hardened as a result of cooling.\n"
+ "Its shell is very brittle and fragile -");
+static const u8 DexDescription_Magcargo_2[] = _(
+ "just touching it causes it to crumble\n"
+ "apart. This POKéMON returns to its\n"
+ "original size by dipping itself in magma.");
+#endif
+
+static const u8 DexDescription_Swinub_1[] = _(
+ "SWINUB roots for food by rubbing its\n"
+ "snout against the ground. Its favorite\n"
+ "food is a mushroom that grows under");
+static const u8 DexDescription_Swinub_2[] = _(
+ "the cover of dead grass.\n"
+ "This POKéMON occasionally roots out\n"
+ "hot springs.");
+
+static const u8 DexDescription_Piloswine_1[] = _(
+ "PILOSWINE is covered by a thick coat\n"
+ "of long hair that enables it to endure\n"
+ "the freezing cold.");
+static const u8 DexDescription_Piloswine_2[] = _(
+ "This POKéMON uses its tusks to dig up\n"
+ "food that has been buried under ice.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Corsola_1[] = _(
+ "Clusters of CORSOLA congregate in warm\n"
+ "seas where they serve as ideal hiding\n"
+ "places for smaller POKéMON.");
+static const u8 DexDescription_Corsola_2[] = _(
+ "When the water temperature falls, this\n"
+ "POKéMON migrates to the southern seas.");
+#else
+static const u8 DexDescription_Corsola_1[] = _(
+ "CORSOLA’s branches glitter very\n"
+ "beautifully in seven colors when they\n"
+ "catch sunlight.");
+static const u8 DexDescription_Corsola_2[] = _(
+ "If any branch breaks off, this POKéMON\n"
+ "grows it back in just one night.");
+#endif
+
+static const u8 DexDescription_Remoraid_1[] = _(
+ "REMORAID sucks in water, then expels it\n"
+ "at high velocity using its abdominal\n"
+ "muscles to shoot down flying prey.");
+static const u8 DexDescription_Remoraid_2[] = _(
+ "When evolution draws near, this POKéMON\n"
+ "travels downstream from rivers.");
+
+static const u8 DexDescription_Octillery_1[] = _(
+ "OCTILLERY grabs onto its foe using\n"
+ "its tentacles. This POKéMON tries to\n"
+ "immobilize it before delivering the");
+static const u8 DexDescription_Octillery_2[] = _(
+ "finishing blow.\n"
+ "If the foe turns out to be too strong,\n"
+ "OCTILLERY spews ink to escape.");
+
+static const u8 DexDescription_Delibird_1[] = _(
+ "DELIBIRD carries its food bundled up\n"
+ "in its tail. There once was a famous\n"
+ "explorer who managed to reach the peak");
+static const u8 DexDescription_Delibird_2[] = _(
+ "of Mt. Everest thanks to one of these\n"
+ "POKéMON sharing its food.");
+
+static const u8 DexDescription_Mantine_1[] = _(
+ "On sunny days, schools of MANTINE can\n"
+ "be seen elegantly leaping over the\n"
+ "sea’s waves.");
+static const u8 DexDescription_Mantine_2[] = _(
+ "This POKéMON is not bothered by the\n"
+ "REMORAID that hitches rides.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Skarmory_1[] = _(
+ "SKARMORY’s steel wings become tattered\n"
+ "and bashed in from repeated battles.\n"
+ "Once a year, the battered wings grow");
+static const u8 DexDescription_Skarmory_2[] = _(
+ "back completely, restoring the cutting\n"
+ "edges to their pristine state.");
+#else
+static const u8 DexDescription_Skarmory_1[] = _(
+ "SKARMORY is entirely encased in hard,\n"
+ "protective armor. This POKéMON flies at\n"
+ "close to 190 mph.");
+static const u8 DexDescription_Skarmory_2[] = _(
+ "It slashes foes with its wings that\n"
+ "possess swordlike cutting edges.");
+#endif
+
+static const u8 DexDescription_Houndour_1[] = _(
+ "HOUNDOUR hunt as a coordinated pack.\n"
+ "They communicate with each other using\n"
+ "a variety of cries to corner their prey.");
+static const u8 DexDescription_Houndour_2[] = _(
+ "This POKéMON’s remarkable teamwork is\n"
+ "unparalleled.");
+
+static const u8 DexDescription_Houndoom_1[] = _(
+ "In a HOUNDOOM pack, the one with its\n"
+ "horns raked sharply towards the back\n"
+ "serves a leadership role.");
+static const u8 DexDescription_Houndoom_2[] = _(
+ "These POKéMON choose their leader by\n"
+ "fighting amongst themselves.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Kingdra_1[] = _(
+ "KINGDRA sleeps on the seafloor where\n"
+ "it is otherwise devoid of life.\n"
+ "When a storm arrives, the POKéMON is");
+static const u8 DexDescription_Kingdra_2[] = _(
+ "said to awaken and wander about in\n"
+ "search of prey.");
+#else
+static const u8 DexDescription_Kingdra_1[] = _(
+ "KINGDRA lives at extreme ocean depths\n"
+ "that are otherwise uninhabited.\n"
+ "It has long been believed that the");
+static const u8 DexDescription_Kingdra_2[] = _(
+ "yawning of this POKéMON creates\n"
+ "spiraling ocean currents.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Phanpy_1[] = _(
+ "PHANPY uses its long nose to shower\n"
+ "itself. When others gather around, they\n"
+ "thoroughly douse each other with water.");
+static const u8 DexDescription_Phanpy_2[] = _(
+ "These POKéMON can be seen drying their\n"
+ "soaking-wet bodies at the edge of\n"
+ "water.");
+#else
+static const u8 DexDescription_Phanpy_1[] = _(
+ "For its nest, PHANPY digs a vertical pit \n"
+ "in the ground at the edge of a river.\n"
+ "It marks the area around its nest with");
+static const u8 DexDescription_Phanpy_2[] = _(
+ "its trunk to let the others know that\n"
+ "the area has been claimed.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Donphan_1[] = _(
+ "If DONPHAN were to tackle with its hard\n"
+ "body, even a house could be destroyed.\n"
+ "Using its massive strength, the");
+static const u8 DexDescription_Donphan_2[] = _(
+ "POKéMON helps clear rock and mud slides\n"
+ "that block mountain trails.");
+#else
+static const u8 DexDescription_Donphan_1[] = _(
+ "DONPHAN’s favorite attack is curling\n"
+ "its body into a ball, then charging at\n"
+ "its foe while rolling at high speed.");
+static const u8 DexDescription_Donphan_2[] = _(
+ "Once it starts rolling, this POKéMON\n"
+ "can’t stop very easily.");
+#endif
+
+static const u8 DexDescription_Porygon2_1[] = _(
+ "PORYGON2 was created by humans using\n"
+ "the power of science. The man-made\n"
+ "POKéMON has been endowed with");
+static const u8 DexDescription_Porygon2_2[] = _(
+ "artificial intelligence that enables it\n"
+ "to learn new gestures and emotions\n"
+ "on its own.");
+
+static const u8 DexDescription_Stantler_1[] = _(
+ "STANTLER’s magnificent antlers were\n"
+ "traded at high prices as works of art.\n"
+ "As a result, this POKéMON was hunted");
+static const u8 DexDescription_Stantler_2[] = _(
+ "close to extinction by those who were\n"
+ "after the priceless antlers.");
+
+static const u8 DexDescription_Smeargle_1[] = _(
+ "SMEARGLE marks the boundaries of its\n"
+ "territory using a body fluid that leaks\n"
+ "out from the tip of its tail.");
+static const u8 DexDescription_Smeargle_2[] = _(
+ "Over 5,000 different marks left by this\n"
+ "POKéMON have been found.");
+
+static const u8 DexDescription_Tyrogue_1[] = _(
+ "TYROGUE becomes stressed out if it\n"
+ "does not get to train every day.\n"
+ "When raising this POKéMON, the TRAINER");
+static const u8 DexDescription_Tyrogue_2[] = _(
+ "must establish and uphold various\n"
+ "training methods.");
+
+static const u8 DexDescription_Hitmontop_1[] = _(
+ "HITMONTOP spins on its head at high\n"
+ "speed, all the while delivering kicks.\n"
+ "This technique is a remarkable mix of");
+static const u8 DexDescription_Hitmontop_2[] = _(
+ "both offense and defense at the same\n"
+ "time. The POKéMON travels faster\n"
+ "spinning than it does walking.");
+
+static const u8 DexDescription_Smoochum_1[] = _(
+ "SMOOCHUM actively runs about, but\n"
+ "also falls quite often.\n"
+ "Whenever the chance arrives, it will");
+static const u8 DexDescription_Smoochum_2[] = _(
+ "look for its reflection to make sure its\n"
+ "face hasn’t become dirty.");
+
+static const u8 DexDescription_Elekid_1[] = _(
+ "ELEKID stores electricity in its body.\n"
+ "If it touches metal and accidentally\n"
+ "discharges all its built-up electricity,");
+static const u8 DexDescription_Elekid_2[] = _(
+ "this POKéMON begins swinging its arms\n"
+ "in circles to recharge itself.");
+
+static const u8 DexDescription_Magby_1[] = _(
+ "MAGBY’s state of health is determined\n"
+ "by observing the fire it breathes.\n"
+ "If the POKéMON is spouting yellow");
+static const u8 DexDescription_Magby_2[] = _(
+ "flames from its mouth, it is in good\n"
+ "health. When it is fatigued, black smoke\n"
+ "will be mixed in with the flames.");
+
+static const u8 DexDescription_Miltank_1[] = _(
+ "MILTANK gives over five gallons of milk\n"
+ "on a daily basis. Its sweet milk is\n"
+ "enjoyed by children and grown-ups alike.");
+static const u8 DexDescription_Miltank_2[] = _(
+ "People who can’t drink milk turn it into\n"
+ "yogurt and eat it instead.");
+
+static const u8 DexDescription_Blissey_1[] = _(
+ "BLISSEY senses sadness with its fluffy\n"
+ "coat of fur. If it does so, this POKéMON\n"
+ "will rush over to the sad person,");
+static const u8 DexDescription_Blissey_2[] = _(
+ "however far they may be, to share an\n"
+ "egg of happiness that brings a smile\n"
+ "to any face.");
+
+static const u8 DexDescription_Raikou_1[] = _(
+ "RAIKOU embodies the speed of lightning.\n"
+ "The roars of this POKéMON send shock\n"
+ "waves shuddering through the air and");
+static const u8 DexDescription_Raikou_2[] = _(
+ "shake the ground as if lightning bolts\n"
+ "had come crashing down.");
+
+static const u8 DexDescription_Entei_1[] = _(
+ "ENTEI embodies the passion of magma.\n"
+ "This POKéMON is thought to have been\n"
+ "born in the eruption of a volcano.");
+static const u8 DexDescription_Entei_2[] = _(
+ "It sends up massive bursts of fire that\n"
+ "utterly consume all that they touch.");
+
+static const u8 DexDescription_Suicune_1[] = _(
+ "SUICUNE embodies the compassion of\n"
+ "a pure spring of water. It runs across\n"
+ "the land with gracefulness.");
+static const u8 DexDescription_Suicune_2[] = _(
+ "This POKéMON has the power to purify\n"
+ "dirty water.");
+
+static const u8 DexDescription_Larvitar_1[] = _(
+ "LARVITAR is born deep under the ground.\n"
+ "To come up to the surface, this POKéMON\n"
+ "must eat its way through the soil above.");
+static const u8 DexDescription_Larvitar_2[] = _(
+ "Until it does so, LARVITAR cannot see\n"
+ "its parent’s face.");
+
+static const u8 DexDescription_Pupitar_1[] = _(
+ "PUPITAR creates a gas inside its body\n"
+ "that it compresses and forcefully\n"
+ "ejects to propel itself like a jet.");
+static const u8 DexDescription_Pupitar_2[] = _(
+ "The body is very durable - it avoids\n"
+ "damage even if it hits solid steel.");
+
+static const u8 DexDescription_Tyranitar_1[] = _(
+ "TYRANITAR is so overwhelmingly\n"
+ "powerful, it can bring down a whole\n"
+ "mountain to make its nest.");
+static const u8 DexDescription_Tyranitar_2[] = _(
+ "This POKéMON wanders about in\n"
+ "mountains seeking new opponents to\n"
+ "fight.");
+
+static const u8 DexDescription_Lugia_1[] = _(
+ "LUGIA’s wings pack devastating power -\n"
+ "a light fluttering of its wings can blow\n"
+ "apart regular houses.");
+static const u8 DexDescription_Lugia_2[] = _(
+ "As a result, this POKéMON chooses to\n"
+ "live out of sight deep under the sea.");
+
+static const u8 DexDescription_HoOh_1[] = _(
+ "HO-OH’s feathers glow in seven colors\n"
+ "depending on the angle at which they\n"
+ "are struck by light.");
+static const u8 DexDescription_HoOh_2[] = _(
+ "These feathers are said to bring\n"
+ "happiness to the bearers. This POKéMON\n"
+ "is said to live at the foot of a rainbow.");
+
+static const u8 DexDescription_Celebi_1[] = _(
+ "This POKéMON came from the future by\n"
+ "crossing over time.\n"
+ "It is thought that so long as CELEBI");
+static const u8 DexDescription_Celebi_2[] = _(
+ "appears, a bright and shining future\n"
+ "awaits us.");
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Treecko_1[] = _(
+ "TREECKO is cool, calm, and collected -\n"
+ "it never panics under any situation.\n"
+ "If a bigger foe were to glare at this");
+static const u8 DexDescription_Treecko_2[] = _(
+ "POKéMON, it would glare right back\n"
+ "without conceding an inch of ground.");
+#else
+static const u8 DexDescription_Treecko_1[] = _(
+ "TREECKO has small hooks on the bottom\n"
+ "of its feet that enable it to scale\n"
+ "vertical walls.");
+static const u8 DexDescription_Treecko_2[] = _(
+ "This POKéMON attacks by slamming foes\n"
+ "with its thick tail.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Grovyle_1[] = _(
+ "This POKéMON adeptly flies from branch\n"
+ "to branch in trees.\n"
+ "In a forest, no POKéMON can ever hope");
+static const u8 DexDescription_Grovyle_2[] = _(
+ "to catch a fleeing GROVYLE however\n"
+ "fast they may be.");
+#else
+static const u8 DexDescription_Grovyle_1[] = _(
+ "The leaves growing out of GROVYLE’s\n"
+ "body are convenient for camouflaging\n"
+ "it from enemies in the forest.");
+static const u8 DexDescription_Grovyle_2[] = _(
+ "This POKéMON is a master at climbing\n"
+ "trees in jungles.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sceptile_1[] = _(
+ "SCEPTILE has seeds growing on its back.\n"
+ "They are said to be bursting with\n"
+ "nutrients that revitalize trees.");
+static const u8 DexDescription_Sceptile_2[] = _(
+ "This POKéMON raises the trees in a\n"
+ "forest with loving care.");
+#else
+static const u8 DexDescription_Sceptile_1[] = _(
+ "The leaves growing on SCEPTILE’s body\n"
+ "are very sharp edged. This POKéMON is\n"
+ "very agile - it leaps all over the");
+static const u8 DexDescription_Sceptile_2[] = _(
+ "branches of trees and jumps on its foe\n"
+ "from above or behind.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Torchic_1[] = _(
+ "TORCHIC has a place inside its body\n"
+ "where it keeps its flame. Give it a hug -\n"
+ "it will be glowing with warmth.");
+static const u8 DexDescription_Torchic_2[] = _(
+ "This POKéMON is covered all over by a\n"
+ "fluffy coat of down.");
+#else
+static const u8 DexDescription_Torchic_1[] = _(
+ "TORCHIC sticks with its TRAINER,\n"
+ "following behind with unsteady\n"
+ "steps.");
+static const u8 DexDescription_Torchic_2[] = _(
+ "This POKéMON breathes fire of over\n"
+ "1,800 degrees F, including fireballs\n"
+ "that leave the foe scorched black.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Combusken_1[] = _(
+ "COMBUSKEN battles with the intensely\n"
+ "hot flames it spews from its beak and\n"
+ "with outstandingly destructive kicks.");
+static const u8 DexDescription_Combusken_2[] = _(
+ "This POKéMON’s cry is very loud and\n"
+ "distracting.");
+#else
+static const u8 DexDescription_Combusken_1[] = _(
+ "COMBUSKEN toughens up its legs and\n"
+ "thighs by running through fields and\n"
+ "mountains.");
+static const u8 DexDescription_Combusken_2[] = _(
+ "This POKéMON’s legs possess both speed\n"
+ "and power, enabling it to dole out ten\n"
+ "kicks in one second.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Blaziken_1[] = _(
+ "BLAZIKEN has incredibly strong legs -\n"
+ "it can easily clear a 30-story building\n"
+ "in one leap.");
+static const u8 DexDescription_Blaziken_2[] = _(
+ "This POKéMON’s blazing punches leave\n"
+ "its foes scorched and blackened.");
+#else
+static const u8 DexDescription_Blaziken_1[] = _(
+ "In battle, BLAZIKEN blows out intense\n"
+ "flames from its wrists and attacks foes\n"
+ "courageously.");
+static const u8 DexDescription_Blaziken_2[] = _(
+ "The stronger the foe, the more\n"
+ "intensely this POKéMON’s wrists burn.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Mudkip_1[] = _(
+ "In water, MUDKIP breathes using the\n"
+ "gills on its cheeks.\n"
+ "If it is faced with a tight situation in");
+static const u8 DexDescription_Mudkip_2[] = _(
+ "battle, this POKéMON will unleash its\n"
+ "amazing power - it can crush rocks\n"
+ "bigger than itself.");
+#else
+static const u8 DexDescription_Mudkip_1[] = _(
+ "The fin on MUDKIP’s head acts as highly\n"
+ "sensitive radar. Using this fin to sense\n"
+ "movements of water and air, this");
+static const u8 DexDescription_Mudkip_2[] = _(
+ "POKéMON can determine what is taking\n"
+ "place around it without using its eyes.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Marshtomp_1[] = _(
+ "MARSHTOMP is much faster at traveling\n"
+ "through mud than it is at swimming.\n"
+ "This POKéMON’s hindquarters exhibit");
+static const u8 DexDescription_Marshtomp_2[] = _(
+ "obvious development, giving it the\n"
+ "ability to walk on just its hind legs.");
+#else
+static const u8 DexDescription_Marshtomp_1[] = _(
+ "The surface of MARSHTOMP’s body is\n"
+ "enveloped by a thin, sticky film that\n"
+ "enables it to live on land.");
+static const u8 DexDescription_Marshtomp_2[] = _(
+ "This POKéMON plays in mud on beaches\n"
+ "when the ocean tide is low.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Swampert_1[] = _(
+ "SWAMPERT predicts storms by sensing\n"
+ "subtle differences in the sounds of\n"
+ "waves and tidal winds with its fins.");
+static const u8 DexDescription_Swampert_2[] = _(
+ "If a storm is approaching, it piles up\n"
+ "boulders to protect itself.");
+#else
+static const u8 DexDescription_Swampert_1[] = _(
+ "SWAMPERT is very strong. It has enough\n"
+ "power to easily drag a boulder weighing\n"
+ "more than a ton.");
+static const u8 DexDescription_Swampert_2[] = _(
+ "This POKéMON also has powerful vision\n"
+ "that lets it see even in murky water.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Poochyena_1[] = _(
+ "POOCHYENA is an omnivore - it will eat\n"
+ "anything. A distinguishing feature is\n"
+ "how large its fangs are compared to");
+static const u8 DexDescription_Poochyena_2[] = _(
+ "its body. This POKéMON tries to\n"
+ "intimidate its foes by making the hair\n"
+ "on its tail bristle out.");
+#else
+static const u8 DexDescription_Poochyena_1[] = _(
+ "At first sight, POOCHYENA takes a bite\n"
+ "at anything that moves.\n"
+ "This POKéMON chases after prey until");
+static const u8 DexDescription_Poochyena_2[] = _(
+ "the victim becomes exhausted.\n"
+ "However, it may turn tail if the prey\n"
+ "strikes back.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Mightyena_1[] = _(
+ "MIGHTYENA travel and act as a pack\n"
+ "in the wild. The memory of its life in the\n"
+ "wild compels the POKéMON to obey only");
+static const u8 DexDescription_Mightyena_2[] = _(
+ "those TRAINERS that it recognizes to\n"
+ "possess superior skill.");
+#else
+static const u8 DexDescription_Mightyena_1[] = _(
+ "MIGHTYENA gives obvious signals when\n"
+ "it is preparing to attack. It starts to\n"
+ "growl deeply and then flattens its body.");
+static const u8 DexDescription_Mightyena_2[] = _(
+ "This POKéMON will bite savagely with its\n"
+ "sharply pointed fangs.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Zigzagoon_1[] = _(
+ "The hair on ZIGZAGOON’s back is \n"
+ "bristly. It rubs the hard back hair\n"
+ "against trees to leave its territorial");
+static const u8 DexDescription_Zigzagoon_2[] = _(
+ "markings.\n"
+ "This POKéMON may play dead to fool foes\n"
+ "in battle.");
+#else
+static const u8 DexDescription_Zigzagoon_1[] = _(
+ "ZIGZAGOON restlessly wanders\n"
+ "everywhere at all times. This POKéMON\n"
+ "does so because it is very curious.");
+static const u8 DexDescription_Zigzagoon_2[] = _(
+ "It becomes interested in anything\n"
+ "that it happens to see.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Linoone_1[] = _(
+ "When hunting, LINOONE will make a\n"
+ "beeline straight for the prey at a full\n"
+ "run. While this POKéMON is capable of");
+static const u8 DexDescription_Linoone_2[] = _(
+ "topping 60 mph, it has to come to a\n"
+ "screeching halt before it can turn.");
+#else
+static const u8 DexDescription_Linoone_1[] = _(
+ "LINOONE always runs full speed and only\n"
+ "in straight lines. If facing an obstacle,\n"
+ "it makes a right-angle turn to evade it.");
+static const u8 DexDescription_Linoone_2[] = _(
+ "This POKéMON is very challenged by\n"
+ "gently curving roads.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wurmple_1[] = _(
+ "WURMPLE is targeted by SWELLOW as\n"
+ "prey. This POKéMON will try to resist by\n"
+ "pointing the spikes on its rear at the");
+static const u8 DexDescription_Wurmple_2[] = _(
+ "attacking predator.\n"
+ "It will weaken the foe by leaking poison\n"
+ "from the spikes.");
+#else
+static const u8 DexDescription_Wurmple_1[] = _(
+ "Using the spikes on its rear end, \n"
+ "WURMPLE peels the bark off trees and\n"
+ "feeds on the sap that oozes out.");
+static const u8 DexDescription_Wurmple_2[] = _(
+ "This POKéMON’s feet are tipped with\n"
+ "suction pads that allow it to cling to\n"
+ "glass without slipping.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Silcoon_1[] = _(
+ "SILCOON was thought to endure hunger\n"
+ "and not consume anything before its\n"
+ "evolution. However, it is now thought");
+static const u8 DexDescription_Silcoon_2[] = _(
+ "that this POKéMON slakes its thirst by\n"
+ "drinking rainwater that collects on its\n"
+ "silk.");
+#else
+static const u8 DexDescription_Silcoon_1[] = _(
+ "SILCOON tethers itself to a tree branch\n"
+ "using silk to keep from falling. There, \n"
+ "this POKéMON hangs quietly while it");
+static const u8 DexDescription_Silcoon_2[] = _(
+ "awaits evolution.\n"
+ "It peers out of the silk cocoon through\n"
+ "a small hole.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Beautifly_1[] = _(
+ "BEAUTIFLY has a long mouth like a coiled\n"
+ "needle, which is very convenient for\n"
+ "collecting pollen from flowers.");
+static const u8 DexDescription_Beautifly_2[] = _(
+ "This POKéMON rides the spring winds as\n"
+ "it flits around gathering pollen.");
+#else
+static const u8 DexDescription_Beautifly_1[] = _(
+ "BEAUTIFLY’s favorite food is the sweet\n"
+ "pollen of flowers. If you want to see\n"
+ "this POKéMON, just leave a potted");
+static const u8 DexDescription_Beautifly_2[] = _(
+ "flower by an open window. BEAUTIFLY\n"
+ "is sure to come looking for pollen.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Cascoon_1[] = _(
+ "If it is attacked, CASCOON remains\n"
+ "motionless however badly it may be\n"
+ "hurt. It does so because if it were to");
+static const u8 DexDescription_Cascoon_2[] = _(
+ "move, its body would be weak upon\n"
+ "evolution. This POKéMON will also not\n"
+ "forget the pain it endured.");
+#else
+static const u8 DexDescription_Cascoon_1[] = _(
+ "CASCOON makes its protective cocoon\n"
+ "by wrapping its body entirely with a\n"
+ "fine silk from its mouth. Once the silk");
+static const u8 DexDescription_Cascoon_2[] = _(
+ "goes around its body, it hardens.\n"
+ "This POKéMON prepares for its evolution\n"
+ "inside the cocoon.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Dustox_1[] = _(
+ "When DUSTOX flaps its wings, a fine\n"
+ "dust is scattered all over. This dust is\n"
+ "actually a powerful poison that will");
+static const u8 DexDescription_Dustox_2[] = _(
+ "even make a pro wrestler sick.\n"
+ "This POKéMON searches for food using\n"
+ "its antennae like radar.");
+#else
+static const u8 DexDescription_Dustox_1[] = _(
+ "DUSTOX is instinctively drawn to light.\n"
+ "Swarms of this POKéMON are attracted\n"
+ "by the bright lights of cities, where");
+static const u8 DexDescription_Dustox_2[] = _(
+ "they wreak havoc by stripping the\n"
+ "leaves off roadside trees for food.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lotad_1[] = _(
+ "LOTAD is said to have dwelled on land\n"
+ "before. However, this POKéMON is\n"
+ "thought to have returned to water");
+static const u8 DexDescription_Lotad_2[] = _(
+ "because the leaf on its head grew large\n"
+ "and heavy. It now lives by floating\n"
+ "atop the water.");
+#else
+static const u8 DexDescription_Lotad_1[] = _(
+ "LOTAD live in ponds and lakes, where\n"
+ "they float on the surface.\n"
+ "It grows weak if its broad leaf dies.");
+static const u8 DexDescription_Lotad_2[] = _(
+ "On rare occasions, this POKéMON travels\n"
+ "on land in search of clean water.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lombre_1[] = _(
+ "LOMBRE’s entire body is covered by a\n"
+ "slippery, slimy film. It feels horribly\n"
+ "unpleasant to be touched by this");
+static const u8 DexDescription_Lombre_2[] = _(
+ "POKéMON’s hands.\n"
+ "LOMBRE is often mistaken for a human\n"
+ "child.");
+#else
+static const u8 DexDescription_Lombre_1[] = _(
+ "LOMBRE is nocturnal - it will get active\n"
+ "after dusk. It is also a mischief-maker.\n"
+ "When this POKéMON spots anglers,");
+static const u8 DexDescription_Lombre_2[] = _(
+ "it tugs on their fishing lines from\n"
+ "beneath the surface and enjoys their\n"
+ "consternation.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Ludicolo_1[] = _(
+ "Upon hearing an upbeat and cheerful\n"
+ "rhythm, the cells in LUDICOLO’s body\n"
+ "become very energetic and active.");
+static const u8 DexDescription_Ludicolo_2[] = _(
+ "Even in battle, this POKéMON will\n"
+ "exhibit an amazing amount of power.");
+#else
+static const u8 DexDescription_Ludicolo_1[] = _(
+ "LUDICOLO begins dancing as soon as\n"
+ "it hears cheerful, festive music.\n"
+ "This POKéMON is said to appear when it");
+static const u8 DexDescription_Ludicolo_2[] = _(
+ "hears the singing of children on hiking\n"
+ "outings.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Seedot_1[] = _(
+ "SEEDOT looks exactly like an acorn\n"
+ "when it is dangling from a tree branch.\n"
+ "It startles other POKéMON by suddenly");
+static const u8 DexDescription_Seedot_2[] = _(
+ "moving.\n"
+ "This POKéMON polishes its body once a\n"
+ "day using leaves.");
+#else
+static const u8 DexDescription_Seedot_1[] = _(
+ "SEEDOT attaches itself to a tree\n"
+ "branch using the top of its head.\n"
+ "It sucks moisture from the tree while");
+static const u8 DexDescription_Seedot_2[] = _(
+ "hanging off the branch.\n"
+ "The more water it drinks, the glossier\n"
+ "this POKéMON’s body becomes.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Nuzleaf_1[] = _(
+ "This POKéMON pulls out the leaf on its\n"
+ "head and makes a flute with it.\n"
+ "The sound of NUZLEAF’s flute strikes");
+static const u8 DexDescription_Nuzleaf_2[] = _(
+ "fear and uncertainty in the hearts of\n"
+ "people lost in a forest.");
+#else
+static const u8 DexDescription_Nuzleaf_1[] = _(
+ "NUZLEAF live in densely overgrown\n"
+ "forests. They occasionally venture out\n"
+ "of the forest to startle people.");
+static const u8 DexDescription_Nuzleaf_2[] = _(
+ "This POKéMON dislikes having its long\n"
+ "nose pinched.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Shiftry_1[] = _(
+ "SHIFTRY’s large fans generate awesome\n"
+ "gusts of wind at a speed close to 100\n"
+ "feet per second. The whipped-up wind");
+static const u8 DexDescription_Shiftry_2[] = _(
+ "blows anything away.\n"
+ "This POKéMON chooses to live quietly\n"
+ "deep in forests.");
+#else
+static const u8 DexDescription_Shiftry_1[] = _(
+ "SHIFTRY is a mysterious POKéMON that\n"
+ "is said to live atop towering trees \n"
+ "dating back over a thousand years.");
+static const u8 DexDescription_Shiftry_2[] = _(
+ "It creates terrific windstorms with\n"
+ "the fans it holds.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Taillow_1[] = _(
+ "TAILLOW is young - it has only just\n"
+ "left its nest. As a result, it sometimes\n"
+ "becomes lonesome and cries at night.");
+static const u8 DexDescription_Taillow_2[] = _(
+ "This POKéMON feeds on WURMPLE that\n"
+ "live in forests.");
+#else
+static const u8 DexDescription_Taillow_1[] = _(
+ "TAILLOW courageously stands its\n"
+ "ground against foes, however strong\n"
+ "they may be.");
+static const u8 DexDescription_Taillow_2[] = _(
+ "This gutsy POKéMON will remain defiant\n"
+ "even after a loss. On the other hand,\n"
+ "it cries loudly if it becomes hungry.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Swellow_1[] = _(
+ "SWELLOW is very conscientious about\n"
+ "the upkeep of its glossy wings.\n"
+ "Once two SWELLOW are gathered, they");
+static const u8 DexDescription_Swellow_2[] = _(
+ "diligently take care of cleaning each\n"
+ "other’s wings.");
+#else
+static const u8 DexDescription_Swellow_1[] = _(
+ "SWELLOW flies high above our heads,\n"
+ "making graceful arcs in the sky.\n"
+ "This POKéMON dives at a steep angle as");
+static const u8 DexDescription_Swellow_2[] = _(
+ "soon as it spots its prey. The hapless\n"
+ "prey is tightly grasped by SWELLOW’s\n"
+ "clawed feet, preventing escape.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wingull_1[] = _(
+ "WINGULL rides updrafts rising from the\n"
+ "sea by extending its long and narrow\n"
+ "wings to glide.");
+static const u8 DexDescription_Wingull_2[] = _(
+ "This POKéMON’s long beak is useful for\n"
+ "catching prey.");
+#else
+static const u8 DexDescription_Wingull_1[] = _(
+ "WINGULL has the habit of carrying prey\n"
+ "and valuables in its beak and hiding\n"
+ "them in all sorts of locations.");
+static const u8 DexDescription_Wingull_2[] = _(
+ "This POKéMON rides the winds and flies\n"
+ "as if it were skating across the sky.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Pelipper_1[] = _(
+ "PELIPPER searches for food while in\n"
+ "flight by skimming the wave tops.\n"
+ "This POKéMON dips its large bill in the");
+static const u8 DexDescription_Pelipper_2[] = _(
+ "sea to scoop up food, then swallows\n"
+ "everything in one big gulp.");
+#else
+static const u8 DexDescription_Pelipper_1[] = _(
+ "PELIPPER is a flying transporter that\n"
+ "carries small POKéMON and eggs inside\n"
+ "its massive bill.");
+static const u8 DexDescription_Pelipper_2[] = _(
+ "This POKéMON builds its nest on steep\n"
+ "cliffs facing the sea.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Ralts_1[] = _(
+ "RALTS has the ability to sense the\n"
+ "emotions of people.\n"
+ "If its TRAINER is in a cheerful mood,");
+static const u8 DexDescription_Ralts_2[] = _(
+ "this POKéMON grows cheerful and joyous\n"
+ "in the same way.");
+#else
+static const u8 DexDescription_Ralts_1[] = _(
+ "RALTS senses the emotions of\n"
+ "people using the horns on its head.\n"
+ "This POKéMON rarely appears before");
+static const u8 DexDescription_Ralts_2[] = _(
+ "people. But when it does, it draws\n"
+ "closer if it senses that the person has\n"
+ "a positive disposition.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Kirlia_1[] = _(
+ "KIRLIA uses the horns on its head\n"
+ "to amplify its psychokinetic power.\n"
+ "When the POKéMON uses its power,");
+static const u8 DexDescription_Kirlia_2[] = _(
+ "the air around it becomes distorted,\n"
+ "creating mirages of nonexistent\n"
+ "scenery.");
+#else
+static const u8 DexDescription_Kirlia_1[] = _(
+ "It is said that a KIRLIA that is\n"
+ "exposed to the positive emotions of\n"
+ "its TRAINER grows beautiful.");
+static const u8 DexDescription_Kirlia_2[] = _(
+ "This POKéMON controls psychokinetic\n"
+ "powers with its highly developed brain.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Gardevoir_1[] = _(
+ "GARDEVOIR has the psychokinetic\n"
+ "power to distort the dimensions and\n"
+ "create a small black hole.");
+static const u8 DexDescription_Gardevoir_2[] = _(
+ "This POKéMON will try to protect its\n"
+ "TRAINER even at the risk of its own\n"
+ "life.");
+#else
+static const u8 DexDescription_Gardevoir_1[] = _(
+ "GARDEVOIR has the ability to read the\n"
+ "future. If it senses impending danger\n"
+ "to its TRAINER, this POKéMON is said to");
+static const u8 DexDescription_Gardevoir_2[] = _(
+ "unleash its psychokinetic energy at\n"
+ "full power.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Surskit_1[] = _(
+ "If SURSKIT senses danger, it secretes\n"
+ "a thick, sugary syrup from the tip of\n"
+ "its head.");
+static const u8 DexDescription_Surskit_2[] = _(
+ "There are some POKéMON that love\n"
+ "eating this syrup.");
+#else
+static const u8 DexDescription_Surskit_1[] = _(
+ "From the tips of its feet, SURSKIT\n"
+ "secretes an oil that enables it to walk\n"
+ "on water as if it were skating.");
+static const u8 DexDescription_Surskit_2[] = _(
+ "This POKéMON feeds on microscopic\n"
+ "organisms in ponds and lakes.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Masquerain_1[] = _(
+ "MASQUERAIN’s antennas have eyelike\n"
+ "patterns that usually give it an angry\n"
+ "look. If the “eyes” are droopy and");
+static const u8 DexDescription_Masquerain_2[] = _(
+ "appear sad, it is said to be a sign\n"
+ "that a heavy rainfall is on its way.");
+#else
+static const u8 DexDescription_Masquerain_1[] = _(
+ "MASQUERAIN intimidates enemies with\n"
+ "the eyelike patterns on its antennas.\n"
+ "This POKéMON flaps its four wings to");
+static const u8 DexDescription_Masquerain_2[] = _(
+ "freely fly in any direction - even\n"
+ "sideways and backwards - as if it were\n"
+ "a helicopter.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Shroomish_1[] = _(
+ "If SHROOMISH senses danger, it shakes\n"
+ "its body and scatters spores from the\n"
+ "top of its head.");
+static const u8 DexDescription_Shroomish_2[] = _(
+ "This POKéMON’s spores are so toxic,\n"
+ "they make trees and weeds wilt.");
+#else
+static const u8 DexDescription_Shroomish_1[] = _(
+ "SHROOMISH live in damp soil in the dark\n"
+ "depths of forests. They are often\n"
+ "found keeping still under fallen leaves.");
+static const u8 DexDescription_Shroomish_2[] = _(
+ "This POKéMON feeds on compost that\n"
+ "is made up of fallen, rotted leaves.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Breloom_1[] = _(
+ "The seeds ringing BRELOOM’s tail are\n"
+ "made of hardened toxic spores. It is\n"
+ "horrible to eat the seeds.");
+static const u8 DexDescription_Breloom_2[] = _(
+ "Just taking a bite of this POKéMON’s\n"
+ "seed will cause your stomach to rumble.");
+#else
+static const u8 DexDescription_Breloom_1[] = _(
+ "BRELOOM closes in on its foe with light\n"
+ "and sprightly footwork, then throws\n"
+ "punches with its stretchy arms.");
+static const u8 DexDescription_Breloom_2[] = _(
+ "This POKéMON’s fighting technique puts\n"
+ "boxers to shame.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Slakoth_1[] = _(
+ "SLAKOTH’s heart beats just once a\n"
+ "minute. Whatever happens, it is\n"
+ "content to loaf around motionless.");
+static const u8 DexDescription_Slakoth_2[] = _(
+ "It is rare to see this POKéMON in\n"
+ "motion.");
+#else
+static const u8 DexDescription_Slakoth_1[] = _(
+ "SLAKOTH lolls around for over twenty\n"
+ "hours every day. Because it moves so\n"
+ "little, it does not need much food.");
+static const u8 DexDescription_Slakoth_2[] = _(
+ "This POKéMON’s sole daily meal consists\n"
+ "of just three leaves.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Vigoroth_1[] = _(
+ "VIGOROTH is simply incapable of\n"
+ "remaining still. Even when it tries to\n"
+ "sleep, the blood in its veins grows");
+static const u8 DexDescription_Vigoroth_2[] = _(
+ "agitated, compelling this POKéMON to\n"
+ "run wild throughout the jungle before\n"
+ "it can settle down.");
+#else
+static const u8 DexDescription_Vigoroth_1[] = _(
+ "VIGOROTH is always itching and agitated\n"
+ "to go on a wild rampage. It simply can’t\n"
+ "tolerate sitting still for even a minute.");
+static const u8 DexDescription_Vigoroth_2[] = _(
+ "This POKéMON’s stress level rises if it\n"
+ "can’t be moving constantly.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Slaking_1[] = _(
+ "Wherever SLAKING live, rings of over\n"
+ "a yard in diameter appear in grassy\n"
+ "fields. They are made by the POKéMON");
+static const u8 DexDescription_Slaking_2[] = _(
+ "as it eats all the grass within reach\n"
+ "while lying prone on the ground.");
+#else
+static const u8 DexDescription_Slaking_1[] = _(
+ "SLAKING spends all day lying down and\n"
+ "lolling about.\n"
+ "It eats grass growing within its reach.");
+static const u8 DexDescription_Slaking_2[] = _(
+ "If it eats all the grass it can reach,\n"
+ "this POKéMON reluctantly moves to\n"
+ "another spot.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Nincada_1[] = _(
+ "NINCADA lives underground. It uses its\n"
+ "sharp claws to carve the roots of trees\n"
+ "and absorb moisture and nutrients.");
+static const u8 DexDescription_Nincada_2[] = _(
+ "This POKéMON can’t withstand bright\n"
+ "sunlight so avoids it.");
+#else
+static const u8 DexDescription_Nincada_1[] = _(
+ "NINCADA lives underground for many\n"
+ "years in complete darkness.\n"
+ "This POKéMON absorbs nutrients from");
+static const u8 DexDescription_Nincada_2[] = _(
+ "the roots of trees. It stays motionless\n"
+ "as it waits for evolution.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Ninjask_1[] = _(
+ "If NINJASK is not trained properly,\n"
+ "it will refuse to obey the TRAINER and\n"
+ "cry loudly continuously.");
+static const u8 DexDescription_Ninjask_2[] = _(
+ "Because of this quality, this POKéMON\n"
+ "is said to be one that puts the\n"
+ "TRAINER’s abilities to the test.");
+#else
+static const u8 DexDescription_Ninjask_1[] = _(
+ "NINJASK moves around at such a high\n"
+ "speed that it cannot be seen, even\n"
+ "while its crying can be clearly heard.");
+static const u8 DexDescription_Ninjask_2[] = _(
+ "For that reason, this POKéMON was long\n"
+ "believed to be invisible.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Shedinja_1[] = _(
+ "SHEDINJA is a peculiar POKéMON.\n"
+ "It seems to appear unsought in a POKé\n"
+ "BALL after a NINCADA evolves.");
+static const u8 DexDescription_Shedinja_2[] = _(
+ "This bizarre POKéMON is entirely\n"
+ "immobile - it doesn’t even breathe.");
+#else
+static const u8 DexDescription_Shedinja_1[] = _(
+ "SHEDINJA’s hard body doesn’t move -\n"
+ "not even a twitch. In fact, its body\n"
+ "appears to be merely a hollow shell.");
+static const u8 DexDescription_Shedinja_2[] = _(
+ "It is believed that this POKéMON will\n"
+ "steal the spirit of anyone peering into\n"
+ "its hollow body from its back.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Whismur_1[] = _(
+ "WHISMUR is very timid. If it starts to\n"
+ "cry loudly, it becomes startled by its\n"
+ "own crying and cries even harder.");
+static const u8 DexDescription_Whismur_2[] = _(
+ "When it finally stops crying, the\n"
+ "POKéMON goes to sleep, all tired out.");
+#else
+static const u8 DexDescription_Whismur_1[] = _(
+ "Normally, WHISMUR’s voice is very quiet -\n"
+ "it is barely audible even if one is\n"
+ "paying close attention.");
+static const u8 DexDescription_Whismur_2[] = _(
+ "However, if this POKéMON senses danger,\n"
+ "it starts crying at an earsplitting\n"
+ "volume.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Loudred_1[] = _(
+ "LOUDRED shouts while stamping its feet.\n"
+ "After it finishes shouting, this\n"
+ "POKéMON becomes incapable of hearing");
+static const u8 DexDescription_Loudred_2[] = _(
+ "anything for a while. This is considered\n"
+ "to be a weak point.");
+#else
+static const u8 DexDescription_Loudred_1[] = _(
+ "LOUDRED’s bellowing can completely\n"
+ "decimate a wood-frame house. It uses\n"
+ "its voice to punish its foes.");
+static const u8 DexDescription_Loudred_2[] = _(
+ "This POKéMON’s round ears serve as\n"
+ "loudspeakers.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Exploud_1[] = _(
+ "EXPLOUD communicates its feelings to\n"
+ "the others by emitting whistle-like\n"
+ "sounds from the tubes on its body.");
+static const u8 DexDescription_Exploud_2[] = _(
+ "This POKéMON only raises its voice when\n"
+ "it is in battle.");
+#else
+static const u8 DexDescription_Exploud_1[] = _(
+ "EXPLOUD triggers earthquakes with the\n"
+ "tremors it creates by bellowing. If this\n"
+ "POKéMON violently inhales from the");
+static const u8 DexDescription_Exploud_2[] = _(
+ "ports on its body, it’s a sign that it is\n"
+ "preparing to let loose a huge bellow.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Makuhita_1[] = _(
+ "MAKUHITA has a tireless spirit -\n"
+ "it will never give up hope. It eats a lot\n"
+ "of food, gets plenty of sleep, and it");
+static const u8 DexDescription_Makuhita_2[] = _(
+ "trains very rigorously. By living that\n"
+ "way, this POKéMON packs its body with\n"
+ "energy.");
+#else
+static const u8 DexDescription_Makuhita_1[] = _(
+ "MAKUHITA is tenacious - it will keep\n"
+ "getting up and attacking its foe\n"
+ "however many times it is knocked down.");
+static const u8 DexDescription_Makuhita_2[] = _(
+ "Every time it gets back up, this\n"
+ "POKéMON stores more energy in its body\n"
+ "for evolving.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Hariyama_1[] = _(
+ "HARIYAMA’s thick body may appear fat,\n"
+ "but it is actually a hunk of solid muscle.\n"
+ "If this POKéMON bears down and");
+static const u8 DexDescription_Hariyama_2[] = _(
+ "tightens all its muscles, its body\n"
+ "becomes as hard as a rock.");
+#else
+static const u8 DexDescription_Hariyama_1[] = _(
+ "HARIYAMA practices its straight-arm\n"
+ "slaps in any number of locations.\n"
+ "One hit of this POKéMON’s powerful,");
+static const u8 DexDescription_Hariyama_2[] = _(
+ "openhanded, straight-arm punches\n"
+ "could snap a telephone pole in two.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Azurill_1[] = _(
+ "AZURILL’s tail is large and bouncy.\n"
+ "It is packed full of the nutrients this\n"
+ "POKéMON needs to grow.");
+static const u8 DexDescription_Azurill_2[] = _(
+ "AZURILL can be seen bouncing and\n"
+ "playing on its big, rubbery tail.");
+#else
+static const u8 DexDescription_Azurill_1[] = _(
+ "AZURILL spins its tail as if it were a\n"
+ "lasso, then hurls it far. The momentum\n"
+ "of the throw sends its body flying, too.");
+static const u8 DexDescription_Azurill_2[] = _(
+ "Using this unique action, one of these\n"
+ "POKéMON managed to hurl itself a record\n"
+ "33 feet.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Nosepass_1[] = _(
+ "NOSEPASS had been said to be completely\n"
+ "unmoving, with its magnetic nose\n"
+ "pointed due north.");
+static const u8 DexDescription_Nosepass_2[] = _(
+ "However, close observation has revealed\n"
+ "that the POKéMON actually moves by a\n"
+ "little over 3/8 of an inch every year.");
+#else
+static const u8 DexDescription_Nosepass_1[] = _(
+ "NOSEPASS’s magnetic nose is always\n"
+ "pointed to the north. If two of these\n"
+ "POKéMON meet, they cannot turn");
+static const u8 DexDescription_Nosepass_2[] = _(
+ "their faces to each other when they\n"
+ "are close because their magnetic noses\n"
+ "repel one another.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Skitty_1[] = _(
+ "SKITTY is known to chase around\n"
+ "playfully after its own tail. In the wild,\n"
+ "this POKéMON lives in holes in the trees");
+static const u8 DexDescription_Skitty_2[] = _(
+ "of forests. It is very popular as a pet\n"
+ "because of its adorable looks.");
+#else
+static const u8 DexDescription_Skitty_1[] = _(
+ "SKITTY has the habit of becoming\n"
+ "fascinated by moving objects and\n"
+ "chasing them around.");
+static const u8 DexDescription_Skitty_2[] = _(
+ "This POKéMON is known to chase after\n"
+ "its own tail and become dizzy.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Delcatty_1[] = _(
+ "DELCATTY sleeps anywhere it wants\n"
+ "without keeping a permanent nest.\n"
+ "If other POKéMON approach it as it");
+static const u8 DexDescription_Delcatty_2[] = _(
+ "sleeps, this POKéMON will never fight -\n"
+ "it will just move away somewhere else.");
+#else
+static const u8 DexDescription_Delcatty_1[] = _(
+ "DELCATTY prefers to live an unfettered\n"
+ "existence in which it can do as it\n"
+ "pleases at its own pace.");
+static const u8 DexDescription_Delcatty_2[] = _(
+ "Because this POKéMON eats and sleeps\n"
+ "whenever it decides, its daily routines\n"
+ "are completely random.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sableye_1[] = _(
+ "SABLEYE digs the ground with sharpened\n"
+ "claws to find rocks that it eats.\n"
+ "Substances in the eaten rocks");
+static const u8 DexDescription_Sableye_2[] = _(
+ "crystallize and rise up to the POKéMON’s\n"
+ "body surface.");
+#else
+static const u8 DexDescription_Sableye_1[] = _(
+ "SABLEYE lead quiet lives deep inside\n"
+ "caverns. They are feared, however,\n"
+ "because these POKéMON are thought to");
+static const u8 DexDescription_Sableye_2[] = _(
+ "steal the spirits of people when their\n"
+ "eyes burn with a sinister glow in the\n"
+ "darkness.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Mawile_1[] = _(
+ "Don’t be taken in by this POKéMON’s\n"
+ "cute face - it’s very dangerous. MAWILE\n"
+ "fools the foe into letting down its");
+static const u8 DexDescription_Mawile_2[] = _(
+ "guard, then chomps down with its\n"
+ "massive jaws. The steel jaws are really\n"
+ "horns that have been transformed.");
+#else
+#if REVISION >= 1
+static const u8 DexDescription_Mawile_1[] = _(
+ "MAWILE’s huge jaws are actually steel\n"
+ "horns that have been transformed.\n"
+ "Its docile-looking face serves to lull");
+static const u8 DexDescription_Mawile_2[] = _(
+ "its foe into letting down its guard.\n"
+ "When the foe least expects it, MAWILE\n" // Correct spelling of MAWILE
+ "chomps it with its gaping jaws.");
+#else
+static const u8 DexDescription_Mawile_1[] = _(
+ "MAWHILE’s huge jaws are actually steel\n"
+ "horns that have been transformed.\n"
+ "Its docile-looking face serves to lull");
+static const u8 DexDescription_Mawile_2[] = _(
+ "its foe into letting down its guard.\n"
+ "When the foe least expects it, MAWHILE\n"
+ "chomps it with its gaping jaws.");
+#endif
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Aron_1[] = _(
+ "ARON has a body of steel.\n"
+ "With one all-out charge, this POKéMON\n"
+ "can demolish even a heavy dump truck.");
+static const u8 DexDescription_Aron_2[] = _(
+ "The destroyed dump truck then becomes\n"
+ "a handy meal for the POKéMON.");
+#else
+static const u8 DexDescription_Aron_1[] = _(
+ "This POKéMON has a body of steel.\n"
+ "To make its body, ARON feeds on\n"
+ "iron ore that it digs from mountains.");
+static const u8 DexDescription_Aron_2[] = _(
+ "Occasionally, it causes major trouble by\n"
+ "eating bridges and rails.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lairon_1[] = _(
+ "LAIRON feeds on iron contained in\n"
+ "rocks and water. It makes its nest on\n"
+ "mountains where iron ore is buried.");
+static const u8 DexDescription_Lairon_2[] = _(
+ "As a result, the POKéMON often clashes\n"
+ "with humans mining the iron ore.");
+#else
+static const u8 DexDescription_Lairon_1[] = _(
+ "LAIRON tempers its steel body by\n"
+ "drinking highly nutritious mineral\n"
+ "springwater until it is bloated.");
+static const u8 DexDescription_Lairon_2[] = _(
+ "This POKéMON makes its nest close to\n"
+ "springs of delicious water.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Aggron_1[] = _(
+ "AGGRON is surprisingly protective\n"
+ "of its environment. If its mountain\n"
+ "is ravaged by a landslide or a fire, this");
+static const u8 DexDescription_Aggron_2[] = _(
+ "POKéMON will haul topsoil to the area,\n"
+ "plant trees, and beautifully restore its\n"
+ "own territory.");
+#else
+static const u8 DexDescription_Aggron_1[] = _(
+ "AGGRON claims an entire mountain as its\n"
+ "own territory. It mercilessly beats up\n"
+ "anything that violates its environment.");
+static const u8 DexDescription_Aggron_2[] = _(
+ "This POKéMON vigilantly patrols its\n"
+ "territory at all times.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Meditite_1[] = _(
+ "MEDITITE heightens its inner energy\n"
+ "through meditation. It survives on\n"
+ "just one berry a day.");
+static const u8 DexDescription_Meditite_2[] = _(
+ "Minimal eating is another aspect of\n"
+ "this POKéMON’s training.");
+#else
+static const u8 DexDescription_Meditite_1[] = _(
+ "MEDITITE undertakes rigorous mental\n"
+ "training deep in the mountains.\n"
+ "However, whenever it meditates, this");
+static const u8 DexDescription_Meditite_2[] = _(
+ "POKéMON always loses its concentration\n"
+ "and focus. As a result, its training\n"
+ "never ends.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Medicham_1[] = _(
+ "Through the power of meditation,\n"
+ "MEDICHAM developed its sixth sense.\n"
+ "It gained the ability to use");
+static const u8 DexDescription_Medicham_2[] = _(
+ "psychokinetic powers. This POKéMON is\n"
+ "known to meditate for a whole month\n"
+ "without eating.");
+#else
+static const u8 DexDescription_Medicham_1[] = _(
+ "It is said that through meditation,\n"
+ "MEDICHAM heightens energy inside\n"
+ "its body and sharpens its sixth sense.");
+static const u8 DexDescription_Medicham_2[] = _(
+ "This POKéMON hides its presence by\n"
+ "merging itself with fields and\n"
+ "mountains.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Electrike_1[] = _(
+ "ELECTRIKE runs faster than the human\n"
+ "eye can follow. The friction from\n"
+ "running is converted into electricity,");
+static const u8 DexDescription_Electrike_2[] = _(
+ "which is then stored in this POKéMON’s\n"
+ "fur.");
+#else
+static const u8 DexDescription_Electrike_1[] = _(
+ "ELECTRIKE stores electricity in its\n"
+ "long body hair. This POKéMON stimulates\n"
+ "its leg muscles with electric charges.");
+static const u8 DexDescription_Electrike_2[] = _(
+ "These jolts of power give its legs\n"
+ "explosive acceleration performance.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Manectric_1[] = _(
+ "MANECTRIC discharges strong\n"
+ "electricity from its mane. The mane is\n"
+ "used for collecting electricity in the");
+static const u8 DexDescription_Manectric_2[] = _(
+ "atmosphere. This POKéMON creates\n"
+ "thunderclouds above its head.");
+#else
+static const u8 DexDescription_Manectric_1[] = _(
+ "MANECTRIC is constantly discharging\n"
+ "electricity from its mane. The sparks\n"
+ "sometimes ignite forest fires.");
+static const u8 DexDescription_Manectric_2[] = _(
+ "When it enters a battle, this POKéMON\n"
+ "creates thunderclouds.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Plusle_1[] = _(
+ "When PLUSLE is cheering on its partner,\n"
+ "it flashes with electric sparks from all\n"
+ "over its body.");
+static const u8 DexDescription_Plusle_2[] = _(
+ "If its partner loses, this POKéMON cries\n"
+ "loudly.");
+#else
+static const u8 DexDescription_Plusle_1[] = _(
+ "PLUSLE always acts as a cheerleader\n"
+ "for its partners. Whenever a teammate\n"
+ "puts out a good effort in battle, this");
+static const u8 DexDescription_Plusle_2[] = _(
+ "POKéMON shorts out its body to create\n"
+ "the crackling noises of sparks to show\n"
+ "its joy.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Minun_1[] = _(
+ "MINUN loves to cheer on its partner in\n"
+ "battle. It gives off sparks from its\n"
+ "body while it is doing so.");
+static const u8 DexDescription_Minun_2[] = _(
+ "If its partner is in trouble, this\n"
+ "POKéMON gives off increasing amounts\n"
+ "of sparks.");
+#else
+static const u8 DexDescription_Minun_1[] = _(
+ "MINUN is more concerned about cheering\n"
+ "on its partners than its own safety.\n"
+ "It shorts out the electricity in its");
+static const u8 DexDescription_Minun_2[] = _(
+ "body to create brilliant showers of\n"
+ "sparks to cheer on its teammates.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Volbeat_1[] = _(
+ "VOLBEAT’s tail glows like a lightbulb.\n"
+ "With other VOLBEAT, it uses its tail to\n"
+ "draw geometric shapes in the night sky.");
+static const u8 DexDescription_Volbeat_2[] = _(
+ "This POKéMON loves the sweet aroma\n"
+ "given off by ILLUMISE.");
+#else
+static const u8 DexDescription_Volbeat_1[] = _(
+ "With the arrival of night, VOLBEAT emits\n"
+ "light from its tail. It communicates with\n"
+ "others by adjusting the intensity and");
+static const u8 DexDescription_Volbeat_2[] = _(
+ "flashing of its light.\n"
+ "This POKéMON is attracted by the sweet\n"
+ "aroma of ILLUMISE.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Illumise_1[] = _(
+ "ILLUMISE leads a flight of illuminated\n"
+ "VOLBEAT to draw signs in the night sky.\n"
+ "This POKéMON is said to earn greater");
+static const u8 DexDescription_Illumise_2[] = _(
+ "respect from its peers by composing\n"
+ "more complex designs in the sky.");
+#else
+static const u8 DexDescription_Illumise_1[] = _(
+ "ILLUMISE attracts a swarm of VOLBEAT\n"
+ "using a sweet fragrance. Once the\n"
+ "VOLBEAT have gathered, this POKéMON");
+static const u8 DexDescription_Illumise_2[] = _(
+ "leads the lit-up swarm in drawing\n"
+ "geometric designs on the canvas of\n"
+ "the night sky.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Roselia_1[] = _(
+ "On extremely rare occasions, a ROSELIA\n"
+ "is said to appear with its flowers in\n"
+ "unusual colors.");
+static const u8 DexDescription_Roselia_2[] = _(
+ "The thorns on this POKéMON’s head\n"
+ "contain a vicious poison.");
+#else
+static const u8 DexDescription_Roselia_1[] = _(
+ "ROSELIA shoots sharp thorns as\n"
+ "projectiles at any opponent that tries\n"
+ "to steal the flowers on its arms.");
+static const u8 DexDescription_Roselia_2[] = _(
+ "The aroma of this POKéMON brings\n"
+ "serenity to living things.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Gulpin_1[] = _(
+ "Most of GULPIN’s body is made up of its\n"
+ "stomach - its heart and brain are very\n"
+ "small in comparison.");
+static const u8 DexDescription_Gulpin_2[] = _(
+ "This POKéMON’s stomach contains\n"
+ "special enzymes that dissolve anything.");
+#else
+static const u8 DexDescription_Gulpin_1[] = _(
+ "Virtually all of GULPIN’s body is its\n"
+ "stomach. As a result, it can swallow\n"
+ "something its own size.");
+static const u8 DexDescription_Gulpin_2[] = _(
+ "This POKéMON’s stomach contains a\n"
+ "special fluid that digests anything.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Swalot_1[] = _(
+ "SWALOT has no teeth, so what it\n"
+ "eats, it swallows whole, no matter what.\n"
+ "Its cavernous mouth yawns widely.");
+static const u8 DexDescription_Swalot_2[] = _(
+ "An automobile tire could easily fit\n"
+ "inside this POKéMON’s mouth.");
+#else
+static const u8 DexDescription_Swalot_1[] = _(
+ "When SWALOT spots prey, it spurts out\n"
+ "a hideously toxic fluid from its pores\n"
+ "and sprays the target.");
+static const u8 DexDescription_Swalot_2[] = _(
+ "Once the prey has weakened, this\n"
+ "POKéMON gulps it down whole with its\n"
+ "cavernous mouth.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Carvanha_1[] = _(
+ "If anything invades CARVANHA’s\n"
+ "territory, it will swarm and tear at the\n"
+ "intruder with its pointed fangs.");
+static const u8 DexDescription_Carvanha_2[] = _(
+ "On its own, however, this POKéMON turns\n"
+ "suddenly timid.");
+#else
+static const u8 DexDescription_Carvanha_1[] = _(
+ "CARVANHA’s strongly developed jaws\n"
+ "and its sharply pointed fangs pack the\n"
+ "destructive power to rip out boat hulls.");
+static const u8 DexDescription_Carvanha_2[] = _(
+ "Many boats have been attacked and\n"
+ "sunk by this POKéMON.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sharpedo_1[] = _(
+ "SHARPEDO can swim at speeds of up to\n"
+ "75 mph by jetting seawater out of its\n"
+ "backside.");
+static const u8 DexDescription_Sharpedo_2[] = _(
+ "This POKéMON’s drawback is its inability\n"
+ "to swim long distances.");
+#else
+static const u8 DexDescription_Sharpedo_1[] = _(
+ "Nicknamed “the bully of the sea,”\n"
+ "SHARPEDO is widely feared.\n"
+ "Its cruel fangs grow back immediately");
+static const u8 DexDescription_Sharpedo_2[] = _(
+ "if they snap off.\n"
+ "Just one of these POKéMON can\n"
+ "thoroughly tear apart a supertanker.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wailmer_1[] = _(
+ "WAILMER can store water inside its body\n"
+ "to transform itself into a ball for\n"
+ "bouncing around on the ground.");
+static const u8 DexDescription_Wailmer_2[] = _(
+ "By filling itself up with more water, this\n"
+ "POKéMON can elevate the height of its\n"
+ "bounces.");
+#else
+static const u8 DexDescription_Wailmer_1[] = _(
+ "WAILMER’s nostrils are located above\n"
+ "its eyes. This playful POKéMON loves\n"
+ "to startle people by forcefully snorting");
+static const u8 DexDescription_Wailmer_2[] = _(
+ "out seawater it stores inside its body\n"
+ "out of its nostrils.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wailord_1[] = _(
+ "When chasing prey, WAILORD herds them\n"
+ "by leaping out of the water and making\n"
+ "a humongous splash.");
+static const u8 DexDescription_Wailord_2[] = _(
+ "It is breathtaking to see this POKéMON\n"
+ "leaping out of the sea with others in\n"
+ "its pod.");
+#else
+static const u8 DexDescription_Wailord_1[] = _(
+ "WAILORD is the largest of all identified\n"
+ "POKéMON up to now.\n"
+ "This giant POKéMON swims languorously");
+static const u8 DexDescription_Wailord_2[] = _(
+ "in the vast open sea, eating massive\n"
+ "amounts of food at once with its\n"
+ "enormous mouth.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Numel_1[] = _(
+ "NUMEL stores magma of almost 2,200\n"
+ "degrees F within its body. If it gets\n"
+ "wet, the magma cools and hardens.");
+static const u8 DexDescription_Numel_2[] = _(
+ "In that event, the POKéMON’s body\n"
+ "grows heavy and its movements become\n"
+ "sluggish.");
+#else
+static const u8 DexDescription_Numel_1[] = _(
+ "NUMEL is extremely dull witted - it\n"
+ "doesn’t notice being hit. However, it\n"
+ "can’t stand hunger for even a second.");
+static const u8 DexDescription_Numel_2[] = _(
+ "This POKéMON’s body is a seething\n"
+ "cauldron of boiling magma.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Camerupt_1[] = _(
+ "The humps on CAMERUPT’s back are\n"
+ "formed by a transformation of its\n"
+ "bones. They sometimes blast out molten");
+static const u8 DexDescription_Camerupt_2[] = _(
+ "magma. This POKéMON apparently erupts\n"
+ "often when it is enraged.");
+#else
+static const u8 DexDescription_Camerupt_1[] = _(
+ "CAMERUPT has a volcano inside its body.\n"
+ "Magma of 18,000 degrees F courses\n"
+ "through its body.");
+static const u8 DexDescription_Camerupt_2[] = _(
+ "Occasionally, the humps on this\n"
+ "POKéMON’s back erupt, spewing the\n"
+ "superheated magma.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Torkoal_1[] = _(
+ "TORKOAL generates energy by burning\n"
+ "coal. It grows weaker as the fire\n"
+ "dies down.");
+static const u8 DexDescription_Torkoal_2[] = _(
+ "When it is preparing for battle, this\n"
+ "POKéMON burns more coal.");
+#else
+static const u8 DexDescription_Torkoal_1[] = _(
+ "TORKOAL digs through mountains in\n"
+ "search of coal. If it finds some, it fills\n"
+ "hollow spaces on its shell with the coal");
+static const u8 DexDescription_Torkoal_2[] = _(
+ "and burns it.\n"
+ "If it is attacked, this POKéMON spouts\n"
+ "thick black smoke to beat a retreat.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Spoink_1[] = _(
+ "SPOINK keeps a pearl on top of its head.\n"
+ "The pearl functions to amplify this\n"
+ "POKéMON’s psychokinetic powers.");
+static const u8 DexDescription_Spoink_2[] = _(
+ "It is therefore on a constant search\n"
+ "for a bigger pearl.");
+#else
+static const u8 DexDescription_Spoink_1[] = _(
+ "SPOINK bounces around on its tail.\n"
+ "The shock of its bouncing makes its\n"
+ "heart pump. As a result, this POKéMON");
+static const u8 DexDescription_Spoink_2[] = _(
+ "cannot afford to stop bouncing - if it\n"
+ "stops, its heart will stop.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Grumpig_1[] = _(
+ "GRUMPIG uses the black pearls on its\n"
+ "body to wield its fantastic powers.\n"
+ "When it is doing so, it dances bizarrely.");
+static const u8 DexDescription_Grumpig_2[] = _(
+ "This POKéMON’s black pearls are valuable\n"
+ "as works of art.");
+#else
+static const u8 DexDescription_Grumpig_1[] = _(
+ "GRUMPIG uses the black pearls on its\n"
+ "body to amplify its psychic power waves\n"
+ "for gaining total control over its foe.");
+static const u8 DexDescription_Grumpig_2[] = _(
+ "When this POKéMON uses its special\n"
+ "power, its snorting breath grows\n"
+ "labored.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Spinda_1[] = _(
+ "No two SPINDA are said to have\n"
+ "identical spot patterns on their hides.\n"
+ "This POKéMON moves in a curious manner");
+static const u8 DexDescription_Spinda_2[] = _(
+ "as if it is stumbling in dizziness.\n"
+ "Its lurching movements can cause the\n"
+ "opponent to become confused.");
+#else
+static const u8 DexDescription_Spinda_1[] = _(
+ "All the SPINDA that exist in the\n"
+ "world are said to have utterly unique\n"
+ "spot patterns.");
+static const u8 DexDescription_Spinda_2[] = _(
+ "The shaky, tottering steps of this\n"
+ "POKéMON give it the appearance of\n"
+ "dancing.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Trapinch_1[] = _(
+ "TRAPINCH is a patient hunter. It digs\n"
+ "an inescapable pit in a desert and waits\n"
+ "for its prey to come tumbling down.");
+static const u8 DexDescription_Trapinch_2[] = _(
+ "This POKéMON can go a whole week\n"
+ "without access to any water.");
+#else
+static const u8 DexDescription_Trapinch_1[] = _(
+ "TRAPINCH’s nest is a sloped, bowl-like\n"
+ "pit dug in sand. This POKéMON patiently\n"
+ "waits for prey to tumble down the pit.");
+static const u8 DexDescription_Trapinch_2[] = _(
+ "Its giant jaws have enough strength\n"
+ "to crush even boulders.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Vibrava_1[] = _(
+ "VIBRAVA’s wings have not yet\n"
+ "completed the process of growing.\n"
+ "Rather than flying long distances,");
+static const u8 DexDescription_Vibrava_2[] = _(
+ "they are more useful for generating\n"
+ "ultrasonic waves by vibrating.");
+#else
+static const u8 DexDescription_Vibrava_1[] = _(
+ "To make prey faint, VIBRAVA generates\n"
+ "ultrasonic waves by vigorously making\n"
+ "its two wings vibrate.");
+static const u8 DexDescription_Vibrava_2[] = _(
+ "This POKéMON’s ultrasonic waves are so\n"
+ "powerful, they can bring on headaches\n"
+ "in people.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Flygon_1[] = _(
+ "FLYGON whips up a sandstorm by\n"
+ "flapping its wings. The wings create a\n"
+ "series of notes that sound like singing.");
+static const u8 DexDescription_Flygon_2[] = _(
+ "Because the “singing” is the only thing\n"
+ "that can be heard in a sandstorm, this\n"
+ "POKéMON is said to be the desert spirit.");
+#else
+static const u8 DexDescription_Flygon_1[] = _(
+ "FLYGON is nicknamed “the elemental \n"
+ "spirit of the desert.” Because its\n"
+ "flapping wings whip up a cloud of sand,");
+static const u8 DexDescription_Flygon_2[] = _(
+ "this POKéMON is always enveloped in a\n"
+ "sandstorm while flying.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Cacnea_1[] = _(
+ "The more arid and harsh the\n"
+ "environment, the more pretty and\n"
+ "fragrant a flower CACNEA grows.");
+static const u8 DexDescription_Cacnea_2[] = _(
+ "This POKéMON battles by wildly swinging\n"
+ "its thorny arms.");
+#else
+static const u8 DexDescription_Cacnea_1[] = _(
+ "CACNEA lives in arid locations such\n"
+ "as deserts. It releases a strong aroma\n"
+ "from its flower to attract prey.");
+static const u8 DexDescription_Cacnea_2[] = _(
+ "When prey comes near, this POKéMON\n"
+ "shoots sharp thorns from its body to\n"
+ "bring the victim down.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Cacturne_1[] = _(
+ "If a traveler is going through a desert\n"
+ "in the thick of night, CACTURNE\n"
+ "will follow in a ragtag group.");
+static const u8 DexDescription_Cacturne_2[] = _(
+ "The POKéMON are biding their time,\n"
+ "waiting for the traveler to tire and\n"
+ "become incapable of moving.");
+#else
+static const u8 DexDescription_Cacturne_1[] = _(
+ "During the daytime, CACTURNE remains\n"
+ "unmoving so that it does not lose any\n"
+ "moisture to the harsh desert sun.");
+static const u8 DexDescription_Cacturne_2[] = _(
+ "This POKéMON becomes active at night\n"
+ "when the temperature drops.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Swablu_1[] = _(
+ "SWABLU loves to make things clean.\n"
+ "If it spots something dirty, it will wipe\n"
+ "and polish it with its cottony wings.");
+static const u8 DexDescription_Swablu_2[] = _(
+ "If its wings become dirty, this POKéMON\n"
+ "finds a stream and showers itself.");
+#else
+static const u8 DexDescription_Swablu_1[] = _(
+ "SWABLU has light and fluffy wings that\n"
+ "are like cottony clouds. This POKéMON\n"
+ "is not frightened of people.");
+static const u8 DexDescription_Swablu_2[] = _(
+ "It lands on the heads of people and\n"
+ "sits there like a cotton-fluff hat.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Altaria_1[] = _(
+ "ALTARIA sings in a gorgeous soprano.\n"
+ "Its wings are like cotton clouds.\n"
+ "This POKéMON catches updrafts with its");
+static const u8 DexDescription_Altaria_2[] = _(
+ "buoyant wings and soars way up into\n"
+ "the wild blue yonder.");
+#else
+static const u8 DexDescription_Altaria_1[] = _(
+ "ALTARIA dances and wheels through the\n"
+ "sky among billowing, cotton-like clouds.\n"
+ "By singing melodies in its crystal-clear");
+static const u8 DexDescription_Altaria_2[] = _(
+ "voice, this POKéMON makes its listeners\n"
+ "experience dreamy wonderment.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Zangoose_1[] = _(
+ "ZANGOOSE usually stays on all fours,\n"
+ "but when angered, it gets up on its\n"
+ "hind legs and extends its claws.");
+static const u8 DexDescription_Zangoose_2[] = _(
+ "This POKéMON shares a bitter rivalry\n"
+ "with SEVIPER that dates back over\n"
+ "generations.");
+#else
+static const u8 DexDescription_Zangoose_1[] = _(
+ "Memories of battling its arch-rival\n"
+ "SEVIPER are etched into every cell of\n"
+ "ZANGOOSE’s body.");
+static const u8 DexDescription_Zangoose_2[] = _(
+ "This POKéMON adroitly dodges attacks\n"
+ "with incredible agility.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Seviper_1[] = _(
+ "SEVIPER’s swordlike tail serves two\n"
+ "purposes - it slashes foes and douses\n"
+ "them with secreted poison.");
+static const u8 DexDescription_Seviper_2[] = _(
+ "This POKéMON will not give up its long-\n"
+ "running blood feud with ZANGOOSE.");
+#else
+static const u8 DexDescription_Seviper_1[] = _(
+ "SEVIPER shares a generations-long\n"
+ "feud with ZANGOOSE. The scars on its\n"
+ "body are evidence of vicious battles.");
+static const u8 DexDescription_Seviper_2[] = _(
+ "This POKéMON attacks using its sword-\n"
+ "edged tail.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lunatone_1[] = _(
+ "LUNATONE becomes active around the\n"
+ "time of the full moon. Instead of\n"
+ "walking, it moves by floating in midair.");
+static const u8 DexDescription_Lunatone_2[] = _(
+ "The POKéMON’s intimidating red eyes\n"
+ "cause all those who see it to become\n"
+ "transfixed with fear.");
+#else
+static const u8 DexDescription_Lunatone_1[] = _(
+ "LUNATONE was discovered at a location\n"
+ "where a meteorite fell. As a result, some\n"
+ "people theorize that this POKéMON");
+static const u8 DexDescription_Lunatone_2[] = _(
+ "came from space. However, no one has\n"
+ "been able to prove this theory so far.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Solrock_1[] = _(
+ "Sunlight is the source of SOLROCK’s\n"
+ "power. It is said to possess the ability\n"
+ "to read the emotions of others.");
+static const u8 DexDescription_Solrock_2[] = _(
+ "This POKéMON gives off intense heat\n"
+ "while rotating its body.");
+#else
+static const u8 DexDescription_Solrock_1[] = _(
+ "SOLROCK is a new species of POKéMON\n"
+ "that is said to have fallen from space.\n"
+ "It floats in air and moves silently.");
+static const u8 DexDescription_Solrock_2[] = _(
+ "In battle, this POKéMON releases\n"
+ "intensely bright light.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Barboach_1[] = _(
+ "BARBOACH’s body is covered with a\n"
+ "slimy film. If a foe grabs it, this\n"
+ "POKéMON just slips out of the enemy’s");
+static const u8 DexDescription_Barboach_2[] = _(
+ "grip.\n"
+ "This POKéMON grows weak if the slimy\n"
+ "coating dries up.");
+#else
+static const u8 DexDescription_Barboach_1[] = _(
+ "BARBOACH’s sensitive whiskers serve\n"
+ "as a superb radar system.\n"
+ "This POKéMON hides in mud, leaving only");
+static const u8 DexDescription_Barboach_2[] = _(
+ "its two whiskers exposed while it waits\n"
+ "for prey to come along.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Whiscash_1[] = _(
+ "If WHISCASH goes on a wild rampage,\n"
+ "it sets off a quake-like tremor with a\n"
+ "radius of over three miles.");
+static const u8 DexDescription_Whiscash_2[] = _(
+ "This POKéMON has the ability to predict\n"
+ "real earthquakes.");
+#else
+static const u8 DexDescription_Whiscash_1[] = _(
+ "WHISCASH is extremely territorial.\n"
+ "Just one of these POKéMON will claim a\n"
+ "large pond as its exclusive territory.");
+static const u8 DexDescription_Whiscash_2[] = _(
+ "If a foe approaches it, it thrashes\n"
+ "about and triggers a massive\n"
+ "earthquake.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Corphish_1[] = _(
+ "CORPHISH catches prey with its sharp\n"
+ "claws. It has no likes or dislikes when it\n"
+ "comes to food - it will eat anything.");
+static const u8 DexDescription_Corphish_2[] = _(
+ "This POKéMON has no trouble living in\n"
+ "filthy water.");
+#else
+static const u8 DexDescription_Corphish_1[] = _(
+ "CORPHISH were originally foreign\n"
+ "POKéMON that were imported as pets.\n"
+ "They eventually turned up in the wild.");
+static const u8 DexDescription_Corphish_2[] = _(
+ "This POKéMON is very hardy and has\n"
+ "greatly increased its population.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Crawdaunt_1[] = _(
+ "CRAWDAUNT molts (sheds) its shell\n"
+ "regularly. Immediately after molting,\n"
+ "its shell is soft and tender.");
+static const u8 DexDescription_Crawdaunt_2[] = _(
+ "Until the shell hardens, this POKéMON\n"
+ "hides in its streambed burrow to avoid\n"
+ "attack from its foes.");
+#else
+static const u8 DexDescription_Crawdaunt_1[] = _(
+ "CRAWDAUNT has an extremely violent\n"
+ "nature that compels it to challenge\n"
+ "other living things to battle.");
+static const u8 DexDescription_Crawdaunt_2[] = _(
+ "Other life-forms refuse to live in\n"
+ "ponds inhabited by this POKéMON,\n"
+ "making them desolate places.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Baltoy_1[] = _(
+ "As soon as it spots others of its kind,\n"
+ "BALTOY congregates with them and\n"
+ "then begins crying noisily in unison.");
+static const u8 DexDescription_Baltoy_2[] = _(
+ "This POKéMON sleeps while cleverly\n"
+ "balancing itself on its one foot.");
+#else
+static const u8 DexDescription_Baltoy_1[] = _(
+ "BALTOY moves while spinning around on\n"
+ "its one foot. Primitive wall paintings\n"
+ "depicting this POKéMON living among");
+static const u8 DexDescription_Baltoy_2[] = _(
+ "people were discovered in some ancient\n"
+ "ruins.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Claydol_1[] = _(
+ "CLAYDOL is an enigma that appeared\n"
+ "from a clay statue made by an ancient\n"
+ "civilization dating back 20,000 years.");
+static const u8 DexDescription_Claydol_2[] = _(
+ "This POKéMON shoots beams from both\n"
+ "its hands.");
+#else
+static const u8 DexDescription_Claydol_1[] = _(
+ "CLAYDOL are said to be dolls of mud made\n"
+ "by primitive humans and brought to life\n"
+ "by exposure to a mysterious ray.");
+static const u8 DexDescription_Claydol_2[] = _(
+ "This POKéMON moves about while\n"
+ "levitating.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Lileep_1[] = _(
+ "LILEEP is an ancient POKéMON that was\n"
+ "regenerated from a fossil. It remains\n"
+ "permanently anchored to a rock.");
+static const u8 DexDescription_Lileep_2[] = _(
+ "From its immobile perch, this POKéMON\n"
+ "intently scans for prey with its two\n"
+ "eyes.");
+#else
+static const u8 DexDescription_Lileep_1[] = _(
+ "LILEEP became extinct approximately\n"
+ "a hundred million years ago.\n"
+ "This ancient POKéMON attaches itself");
+static const u8 DexDescription_Lileep_2[] = _(
+ "to a rock on the seafloor and catches\n"
+ "approaching prey using tentacles \n"
+ "shaped like flower petals.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Cradily_1[] = _(
+ "CRADILY’s body serves as an anchor,\n"
+ "preventing it from being washed away in\n"
+ "rough seas.");
+static const u8 DexDescription_Cradily_2[] = _(
+ "This POKéMON secretes a strong\n"
+ "digestive fluid from its tentacles.");
+#else
+static const u8 DexDescription_Cradily_1[] = _(
+ "CRADILY roams around the ocean floor\n"
+ "in search of food. This POKéMON freely\n"
+ "extends its tree trunk-like neck and");
+static const u8 DexDescription_Cradily_2[] = _(
+ "captures unwary prey using its eight\n"
+ "tentacles.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Anorith_1[] = _(
+ "ANORITH is said to be a type of \n"
+ "POKéMON predecessor, with eight wings\n"
+ "at the sides of its body.");
+static const u8 DexDescription_Anorith_2[] = _(
+ "This POKéMON swam in the primordial sea\n"
+ "by undulating these eight wings.");
+#else
+static const u8 DexDescription_Anorith_1[] = _(
+ "ANORITH was regenerated from a\n"
+ "prehistoric fossil. This primitive\n"
+ "POKéMON once lived in warm seas.");
+static const u8 DexDescription_Anorith_2[] = _(
+ "It grips its prey firmly between its\n"
+ "two large claws.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Armaldo_1[] = _(
+ "ARMALDO is a POKéMON species that\n"
+ "became extinct in prehistoric times.\n"
+ "This POKéMON is said to have walked on");
+static const u8 DexDescription_Armaldo_2[] = _(
+ "its hind legs, which would have been\n"
+ "more convenient for life on land.");
+#else
+static const u8 DexDescription_Armaldo_1[] = _(
+ "ARMALDO’s tough armor makes all attacks\n"
+ "bounce off. This POKéMON’s two\n"
+ "enormous claws can be freely extended");
+static const u8 DexDescription_Armaldo_2[] = _(
+ "or contracted. They have the power to\n"
+ "punch right through a steel slab.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Feebas_1[] = _(
+ "While FEEBAS’s body is in tatters,\n"
+ "it has a hardy and tenacious life force\n"
+ "that enables it to live anywhere.");
+static const u8 DexDescription_Feebas_2[] = _(
+ "However, this POKéMON is also slow and\n"
+ "dimwitted, making it an easy catch.");
+#else
+static const u8 DexDescription_Feebas_1[] = _(
+ "FEEBAS’s fins are ragged and\n"
+ "tattered from the start of its life.\n"
+ "Because of its shoddy appearance, this");
+static const u8 DexDescription_Feebas_2[] = _(
+ "POKéMON is largely ignored.\n"
+ "It is capable of living in both the sea\n"
+ "and in rivers.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Milotic_1[] = _(
+ "MILOTIC live at the bottom of large\n"
+ "lakes. When this POKéMON’s body glows a\n"
+ "vivid pink, it releases a pulsing wave of");
+static const u8 DexDescription_Milotic_2[] = _(
+ "energy that brings soothing calm to\n"
+ "restless spirits.");
+#else
+static const u8 DexDescription_Milotic_1[] = _(
+ "MILOTIC is said to be the most\n"
+ "beautiful of all the POKéMON.\n"
+ "It has the power to becalm such");
+static const u8 DexDescription_Milotic_2[] = _(
+ "emotions as anger and hostility to quell\n"
+ "bitter feuding.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Castform_1[] = _(
+ "CASTFORM borrows the power of nature\n"
+ "to transform itself into the guises of\n"
+ "the sun, rain clouds, and snow clouds.");
+static const u8 DexDescription_Castform_2[] = _(
+ "This POKéMON’s feelings change with the\n"
+ "weather.");
+#else
+static const u8 DexDescription_Castform_1[] = _(
+ "CASTFORM’s appearance changes with\n"
+ "the weather.\n"
+ "This POKéMON gained the ability to use");
+static const u8 DexDescription_Castform_2[] = _(
+ "the vast power of nature to protect\n"
+ "its tiny body.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Kecleon_1[] = _(
+ "KECLEON alters its body coloration to\n"
+ "blend in with its surroundings, allowing\n"
+ "it to sneak up on its prey unnoticed.");
+static const u8 DexDescription_Kecleon_2[] = _(
+ "Then it lashes out with its long,\n"
+ "stretchy tongue to instantly ensnare\n"
+ "the unsuspecting target.");
+#else
+static const u8 DexDescription_Kecleon_1[] = _(
+ "KECLEON is capable of changing its body\n"
+ "colors at will to blend in with its\n"
+ "surroundings.");
+static const u8 DexDescription_Kecleon_2[] = _(
+ "There is one exception - this POKéMON\n"
+ "can’t change the zigzag pattern on its\n"
+ "belly.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Shuppet_1[] = _(
+ "SHUPPET grows by feeding on dark\n"
+ "emotions, such as vengefulness and \n"
+ "envy, in the hearts of people.");
+static const u8 DexDescription_Shuppet_2[] = _(
+ "It roams through cities in search of\n"
+ "grudges that taint people.");
+#else
+static const u8 DexDescription_Shuppet_1[] = _(
+ "SHUPPET is attracted by feelings\n"
+ "of jealousy and vindictiveness.\n"
+ "If someone develops strong feelings of");
+static const u8 DexDescription_Shuppet_2[] = _(
+ "vengeance, this POKéMON will appear\n"
+ "in a swarm and line up beneath the eaves\n"
+ "of that person’s home.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Banette_1[] = _(
+ "A cursed energy permeated the stuffing\n"
+ "of a discarded and forgotten plush doll,\n"
+ "giving it new life as BANETTE.");
+static const u8 DexDescription_Banette_2[] = _(
+ "The POKéMON’s energy would escape if it\n"
+ "were to ever open its mouth.");
+#else
+static const u8 DexDescription_Banette_1[] = _(
+ "BANETTE generates energy for laying\n"
+ "strong curses by sticking pins into its\n"
+ "own body.");
+static const u8 DexDescription_Banette_2[] = _(
+ "This POKéMON was originally a pitiful\n"
+ "plush doll that was thrown away.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Duskull_1[] = _(
+ "DUSKULL wanders lost among the deep\n"
+ "darkness of midnight. There is an oft-\n"
+ "told admonishment given to misbehaving");
+static const u8 DexDescription_Duskull_2[] = _(
+ "children that this POKéMON will spirit\n"
+ "away bad children who earn scoldings\n"
+ "from their mothers.");
+#else
+static const u8 DexDescription_Duskull_1[] = _(
+ "DUSKULL can pass through any wall no\n"
+ "matter how thick it may be.\n"
+ "Once this POKéMON chooses a target,");
+static const u8 DexDescription_Duskull_2[] = _(
+ "it will doggedly pursue the intended\n"
+ "victim until the break of dawn.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Dusclops_1[] = _(
+ "DUSCLOPS absorbs anything, however\n"
+ "large the object may be. This POKéMON\n"
+ "hypnotizes its foe by waving its hands");
+static const u8 DexDescription_Dusclops_2[] = _(
+ "in a macabre manner and by bringing its\n"
+ "single eye to bear. The hypnotized foe\n"
+ "is made to do DUSCLOPS’s bidding.");
+#else
+static const u8 DexDescription_Dusclops_1[] = _(
+ "DUSCLOPS’s body is completely hollow -\n"
+ "there is nothing at all inside.\n"
+ "It is said that its body is like a black");
+static const u8 DexDescription_Dusclops_2[] = _(
+ "hole. This POKéMON will absorb anything\n"
+ "into its body, but nothing will ever come\n"
+ "back out.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Tropius_1[] = _(
+ "Children of the southern tropics eat\n"
+ "as snacks the fruit that grows in\n"
+ "bunches around the neck of TROPIUS.");
+static const u8 DexDescription_Tropius_2[] = _(
+ "This POKéMON flies by flapping the\n"
+ "leaves on its back as if they were\n"
+ "wings.");
+#else
+static const u8 DexDescription_Tropius_1[] = _(
+ "The bunches of fruit around TROPIUS’s\n"
+ "neck are very popular with children.\n"
+ "This POKéMON loves fruit, and eats it");
+static const u8 DexDescription_Tropius_2[] = _(
+ "continuously. Apparently, its love for\n"
+ "fruit resulted in its own outgrowth\n"
+ "of fruit.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Chimecho_1[] = _(
+ "In high winds, CHIMECHO cries as it\n"
+ "hangs from a tree branch or the eaves\n"
+ "of a building using a suction cup on its");
+static const u8 DexDescription_Chimecho_2[] = _(
+ "head.\n"
+ "This POKéMON plucks berries with its\n"
+ "long tail and eats them.");
+#else
+static const u8 DexDescription_Chimecho_1[] = _(
+ "CHIMECHO makes its cries echo\n"
+ "inside its hollow body. When this\n"
+ "POKéMON becomes enraged, its cries");
+static const u8 DexDescription_Chimecho_2[] = _(
+ "result in ultrasonic waves that have\n"
+ "the power to knock foes flying.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Absol_1[] = _(
+ "ABSOL has the ability to foretell the\n"
+ "coming of natural disasters.\n"
+ "It lives in a harsh, rugged mountain");
+static const u8 DexDescription_Absol_2[] = _(
+ "environment. This POKéMON very rarely\n"
+ "ventures down from the mountains.");
+#else
+static const u8 DexDescription_Absol_1[] = _(
+ "Every time ABSOL appears before people,\n"
+ "it is followed by a disaster such as an\n"
+ "earthquake or a tidal wave.");
+static const u8 DexDescription_Absol_2[] = _(
+ "As a result, it came to be known as the\n"
+ "disaster POKéMON.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Wynaut_1[] = _(
+ "WYNAUT gather on moonlit nights to play\n"
+ "by squeezing up against each other.\n"
+ "By being squeezed, this POKéMON gains");
+static const u8 DexDescription_Wynaut_2[] = _(
+ "endurance and is trained to dole out\n"
+ "powerful counterattacks.");
+#else
+static const u8 DexDescription_Wynaut_1[] = _(
+ "WYNAUT can always be seen with a big,\n"
+ "happy smile on its face. Look at its tail\n"
+ "to determine if it is angry.");
+static const u8 DexDescription_Wynaut_2[] = _(
+ "When angered, this POKéMON will be\n"
+ "slapping the ground with its tail.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Snorunt_1[] = _(
+ "SNORUNT survives by eating only snow\n"
+ "and ice.\n"
+ "Old folklore claims that a house visited");
+static const u8 DexDescription_Snorunt_2[] = _(
+ "by this POKéMON is sure to prosper for\n"
+ "many generations to come.");
+#else
+static const u8 DexDescription_Snorunt_1[] = _(
+ "SNORUNT live in regions with heavy\n"
+ "snowfall. In seasons without snow, such\n"
+ "as spring and summer, this POKéMON");
+static const u8 DexDescription_Snorunt_2[] = _(
+ "steals away to live quietly among\n"
+ "stalactites and stalagmites deep in\n"
+ "caverns.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Glalie_1[] = _(
+ "GLALIE has the ability to freely\n"
+ "control ice. For example, it can\n"
+ "instantly freeze its foe solid.");
+static const u8 DexDescription_Glalie_2[] = _(
+ "After immobilizing its foe in ice, this\n"
+ "POKéMON enjoys eating it in leisurely\n"
+ "fashion.");
+#else
+static const u8 DexDescription_Glalie_1[] = _(
+ "GLALIE has a body made of rock, which it\n"
+ "hardens with an armor of ice.\n"
+ "This POKéMON has the ability to freeze");
+static const u8 DexDescription_Glalie_2[] = _(
+ "moisture in the atmosphere into any\n"
+ "shape it desires.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Spheal_1[] = _(
+ "SPHEAL always travels by rolling\n"
+ "around on its ball-like body. When the\n"
+ "season for ice floes arrives, this");
+static const u8 DexDescription_Spheal_2[] = _(
+ "POKéMON can be seen rolling about on\n"
+ "ice and crossing the sea.");
+#else
+static const u8 DexDescription_Spheal_1[] = _(
+ "SPHEAL is much faster rolling than \n"
+ "walking to get around. When groups of\n"
+ "this POKéMON eat, they all clap at once");
+static const u8 DexDescription_Spheal_2[] = _(
+ "to show their pleasure. Because of this,\n"
+ "their mealtimes are noisy.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Sealeo_1[] = _(
+ "SEALEO often balances and rolls\n"
+ "things on the tip of its nose. While the\n"
+ "POKéMON is rolling something, it checks");
+static const u8 DexDescription_Sealeo_2[] = _(
+ "the object’s aroma and texture to\n"
+ "determine whether it likes the object\n"
+ "or not.");
+#else
+static const u8 DexDescription_Sealeo_1[] = _(
+ "SEALEO has the habit of always juggling\n"
+ "on the tip of its nose anything it sees\n"
+ "for the first time.");
+static const u8 DexDescription_Sealeo_2[] = _(
+ "This POKéMON occasionally entertains\n"
+ "itself by balancing and rolling a SPHEAL\n"
+ "on its nose.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Walrein_1[] = _(
+ "WALREIN swims all over in frigid\n"
+ "seawater while crushing icebergs with\n"
+ "its grand, imposing tusks.");
+static const u8 DexDescription_Walrein_2[] = _(
+ "Its thick layer of blubber makes enemy\n"
+ "attacks bounce off harmlessly.");
+#else
+static const u8 DexDescription_Walrein_1[] = _(
+ "WALREIN’s two massively developed\n"
+ "tusks can totally shatter blocks of\n"
+ "ice weighing ten tons with one blow.");
+static const u8 DexDescription_Walrein_2[] = _(
+ "This POKéMON’s thick coat of blubber\n"
+ "insulates it from subzero temperatures.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Clamperl_1[] = _(
+ "CLAMPERL grows while being protected\n"
+ "by its rock-hard shell. When its body\n"
+ "becomes too large to fit inside the");
+static const u8 DexDescription_Clamperl_2[] = _(
+ "shell, it is sure evidence that this\n"
+ "POKéMON is getting close to evolution.");
+#else
+static const u8 DexDescription_Clamperl_1[] = _(
+ "CLAMPERL’s sturdy shell is not only good\n"
+ "for protection - it is also used for\n"
+ "clamping and catching prey.");
+static const u8 DexDescription_Clamperl_2[] = _(
+ "A fully grown CLAMPERL’s shell will be\n"
+ "scored with nicks and scratches all\n"
+ "over.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Huntail_1[] = _(
+ "HUNTAIL’s tail is shaped like a fish.\n"
+ "It uses the tail to attract prey, then\n"
+ "swallows the prey whole with its large,");
+static const u8 DexDescription_Huntail_2[] = _(
+ "gaping mouth.\n"
+ "This POKéMON swims by wiggling its\n"
+ "slender body like a snake.");
+#else
+static const u8 DexDescription_Huntail_1[] = _(
+ "HUNTAIL’s presence went unnoticed by\n"
+ "people for a long time because it lives\n"
+ "at extreme depths in the sea.");
+static const u8 DexDescription_Huntail_2[] = _(
+ "This POKéMON’s eyes can see clearly\n"
+ "even in the murky dark depths of the\n"
+ "ocean.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Gorebyss_1[] = _(
+ "Although GOREBYSS is the very picture\n"
+ "of elegance and beauty while swimming,\n"
+ "it is also cruel. When it spots prey, this");
+static const u8 DexDescription_Gorebyss_2[] = _(
+ "POKéMON inserts its thin mouth into the\n"
+ "prey’s body and drains the prey of its\n"
+ "body fluids.");
+#else
+static const u8 DexDescription_Gorebyss_1[] = _(
+ "GOREBYSS lives in the southern seas\n"
+ "at extreme depths. Its body is built to\n"
+ "withstand the enormous pressure of");
+static const u8 DexDescription_Gorebyss_2[] = _(
+ "water at incredible depths. Because of\n"
+ "this, this POKéMON’s body is unharmed\n"
+ "by ordinary attacks.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Relicanth_1[] = _(
+ "RELICANTH is a rare species that was\n"
+ "discovered in deep-sea explorations.\n"
+ "This POKéMON’s body withstands the");
+static const u8 DexDescription_Relicanth_2[] = _(
+ "enormous water pressure of the ocean\n"
+ "depths. Its body is covered in tough\n"
+ "scales that are like craggy rocks.");
+#else
+static const u8 DexDescription_Relicanth_1[] = _(
+ "RELICANTH is a POKéMON species that\n"
+ "existed for a hundred million years\n"
+ "without ever changing its form.");
+static const u8 DexDescription_Relicanth_2[] = _(
+ "This ancient POKéMON feeds on\n"
+ "microscopic organisms with its\n"
+ "toothless mouth.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Luvdisc_1[] = _(
+ "LUVDISC’s heart-shaped body is a\n"
+ "symbol of love and romance.\n"
+ "It is said that any couple meeting this");
+static const u8 DexDescription_Luvdisc_2[] = _(
+ "POKéMON is promised a loving\n"
+ "relationship that never ends.");
+#else
+static const u8 DexDescription_Luvdisc_1[] = _(
+ "LUVDISC live in shallow seas in the\n"
+ "tropics. This heart-shaped POKéMON\n"
+ "earned its name by swimming after");
+static const u8 DexDescription_Luvdisc_2[] = _(
+ "loving couples it spotted in the\n"
+ "ocean’s waves.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Bagon_1[] = _(
+ "BAGON harbors a never-ending dream of\n"
+ "one day soaring high among the clouds.\n"
+ "As if trying to dispel its frustration");
+static const u8 DexDescription_Bagon_2[] = _(
+ "over its inability to fly, this POKéMON\n"
+ "slams its hard head against huge rocks\n"
+ "and shatters them into pebbles.");
+#else
+static const u8 DexDescription_Bagon_1[] = _(
+ "BAGON has a dream of one day soaring\n"
+ "in the sky. In doomed efforts to fly,\n"
+ "this POKéMON hurls itself off cliffs.");
+static const u8 DexDescription_Bagon_2[] = _(
+ "As a result of its dives, its head has \n"
+ "grown tough and as hard as tempered\n"
+ "steel.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Shelgon_1[] = _(
+ "Covering SHELGON’s body are outgrowths\n"
+ "much like bones. The shell is very hard\n"
+ "and bounces off enemy attacks.");
+static const u8 DexDescription_Shelgon_2[] = _(
+ "When awaiting evolution, this POKéMON\n"
+ "hides away in a cavern.");
+#else
+static const u8 DexDescription_Shelgon_1[] = _(
+ "Inside SHELGON’s armor-like shell, cells\n"
+ "are in the midst of transformation\n"
+ "to create an entirely new body.");
+static const u8 DexDescription_Shelgon_2[] = _(
+ "This POKéMON’s shell is extremely heavy,\n"
+ "making its movements sluggish.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Salamence_1[] = _(
+ "By evolving into SALAMENCE, this\n"
+ "POKéMON finally realizes its long-held\n"
+ "dream of growing wings.");
+static const u8 DexDescription_Salamence_2[] = _(
+ "To express its joy, it flies and wheels\n"
+ "all over the sky while spouting flames\n"
+ "from its mouth.");
+#else
+static const u8 DexDescription_Salamence_1[] = _(
+ "SALAMENCE came about as a result of a\n"
+ "strong, long-held dream of growing\n"
+ "wings. It is said that this powerful");
+static const u8 DexDescription_Salamence_2[] = _(
+ "desire triggered a sudden mutation in\n"
+ "this POKéMON’s cells, causing it to\n"
+ "sprout its magnificent wings.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Beldum_1[] = _(
+ "BELDUM keeps itself floating by\n"
+ "generating a magnetic force that\n"
+ "repels earth’s natural magnetism.");
+static const u8 DexDescription_Beldum_2[] = _(
+ "When it sleeps, this POKéMON anchors\n"
+ "itself to a cliff using the hooks on\n"
+ "its rear.");
+#else
+static const u8 DexDescription_Beldum_1[] = _(
+ "Instead of blood, a powerful magnetic\n"
+ "force courses throughout BELDUM’s\n"
+ "body. This POKéMON communicates with");
+static const u8 DexDescription_Beldum_2[] = _(
+ "others by sending controlled pulses of\n"
+ "magnetism.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Metang_1[] = _(
+ "When two BELDUM fuse together, METANG\n"
+ "is formed. The brains of the BELDUM are\n"
+ "joined by a magnetic nervous system.");
+static const u8 DexDescription_Metang_2[] = _(
+ "This POKéMON turns its arms to the rear\n"
+ "for traveling at high speed.");
+#else
+static const u8 DexDescription_Metang_1[] = _(
+ "When two BELDUM fuse together, METANG\n"
+ "is formed. The brains of the BELDUM are\n"
+ "joined by a magnetic nervous system.");
+static const u8 DexDescription_Metang_2[] = _(
+ "By linking its brains magnetically,\n"
+ "this POKéMON generates strong\n"
+ "psychokinetic power.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Metagross_1[] = _(
+ "METAGROSS is the result of two METANG\n"
+ "achieving fusion. When hunting, this\n"
+ "POKéMON pins the prey to the ground");
+static const u8 DexDescription_Metagross_2[] = _(
+ "under its massive body. It then eats\n"
+ "the helpless victim using the large \n"
+ "mouth on its stomach.");
+#else
+static const u8 DexDescription_Metagross_1[] = _(
+ "METAGROSS has four brains in total.\n"
+ "Combined, the four brains can breeze\n"
+ "through difficult calculations faster");
+static const u8 DexDescription_Metagross_2[] = _(
+ "than a supercomputer.\n"
+ "This POKéMON can float in the air by\n"
+ "tucking in its four legs.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Regirock_1[] = _(
+ "REGIROCK’s body is composed entirely of\n"
+ "rocks. Recently, a study made the\n"
+ "startling discovery that the rocks");
+static const u8 DexDescription_Regirock_2[] = _(
+ "were all unearthed from different\n"
+ "locations.");
+#else
+static const u8 DexDescription_Regirock_1[] = _(
+ "REGIROCK was sealed away by people\n"
+ "long ago. If this POKéMON’s body is\n"
+ "damaged in battle, it is said to seek");
+static const u8 DexDescription_Regirock_2[] = _(
+ "out suitable rocks on its own to repair\n"
+ "itself.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Regice_1[] = _(
+ "REGICE cloaks itself with frigid air of\n"
+ "negative 328 degrees F.\n"
+ "Things will freeze solid just by going");
+static const u8 DexDescription_Regice_2[] = _(
+ "near this POKéMON.\n"
+ "Its icy body is so cold, it will not melt\n"
+ "even if it is immersed in magma.");
+#else
+static const u8 DexDescription_Regice_1[] = _(
+ "REGICE’s body was made during an ice\n"
+ "age. The deep-frozen body can’t be\n"
+ "melted, even by fire.");
+static const u8 DexDescription_Regice_2[] = _(
+ "This POKéMON controls frigid air of\n"
+ "minus 328 degrees F.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Registeel_1[] = _(
+ "REGISTEEL was imprisoned by people\n"
+ "in ancient times.\n"
+ "The metal composing its body is thought");
+static const u8 DexDescription_Registeel_2[] = _(
+ "to be a curious substance that is not\n"
+ "of this earth.");
+#else
+static const u8 DexDescription_Registeel_1[] = _(
+ "REGISTEEL has a body that is harder\n"
+ "than any kind of metal.\n"
+ "Its body is apparently hollow.");
+static const u8 DexDescription_Registeel_2[] = _(
+ "No one has any idea what this POKéMON\n"
+ "eats.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Latias_1[] = _(
+ "LATIAS is highly intelligent and capable\n"
+ "of understanding human speech.\n"
+ "It is covered with a glass-like down.");
+static const u8 DexDescription_Latias_2[] = _(
+ "The POKéMON enfolds its body with its\n"
+ "down and refracts light to alter its\n"
+ "appearance.");
+#else
+static const u8 DexDescription_Latias_1[] = _(
+ "LATIAS is highly sensitive to the\n"
+ "emotions of people. If it senses any\n"
+ "hostility, this POKéMON ruffles the");
+static const u8 DexDescription_Latias_2[] = _(
+ "feathers all over its body and cries\n"
+ "shrilly to intimidate the foe.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Latios_1[] = _(
+ "LATIOS will only open its heart to a\n"
+ "TRAINER with a compassionate spirit.\n"
+ "This POKéMON can fly faster than a jet");
+static const u8 DexDescription_Latios_2[] = _(
+ "plane by folding its forelegs to minimize\n"
+ "air resistance.");
+#else
+static const u8 DexDescription_Latios_1[] = _(
+ "LATIOS has the ability to make its foe\n"
+ "see an image of what it has seen or\n"
+ "imagines in its head.");
+static const u8 DexDescription_Latios_2[] = _(
+ "This POKéMON is intelligent and\n"
+ "understands human speech.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Kyogre_1[] = _(
+ "KYOGRE is named in mythology as the\n"
+ "POKéMON that expanded the sea by\n"
+ "covering the land with torrential rains");
+static const u8 DexDescription_Kyogre_2[] = _(
+ "and towering tidal waves.\n"
+ "It took to sleep after a cataclysmic\n"
+ "battle with GROUDON.");
+#else
+static const u8 DexDescription_Kyogre_1[] = _(
+ "KYOGRE has the power to create massive\n"
+ "rain clouds that cover the entire sky\n"
+ "and bring about torrential downpours.");
+static const u8 DexDescription_Kyogre_2[] = _(
+ "This POKéMON saved people who were\n"
+ "suffering from droughts.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Groudon_1[] = _(
+ "GROUDON has the power to scatter rain\n"
+ "clouds and make water evaporate with\n"
+ "light and heat.");
+static const u8 DexDescription_Groudon_2[] = _(
+ "It came as a savior to people who had\n"
+ "been suffering from terrible floods.");
+#else
+static const u8 DexDescription_Groudon_1[] = _(
+ "GROUDON has long been described in \n"
+ "mythology as the POKéMON that raised\n"
+ "lands and expanded continents.");
+static const u8 DexDescription_Groudon_2[] = _(
+ "This POKéMON took to sleep after a\n"
+ "cataclysmic battle with KYOGRE.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Rayquaza_1[] = _(
+ "RAYQUAZA is said to have lived for\n"
+ "hundreds of millions of years in the\n"
+ "earth’s ozone layer, above the clouds.");
+static const u8 DexDescription_Rayquaza_2[] = _(
+ "Its existence had been completely\n"
+ "unknown because it lived so high in\n"
+ "the sky.");
+#else
+static const u8 DexDescription_Rayquaza_1[] = _(
+ "RAYQUAZA lived for hundreds of millions\n"
+ "of years in the earth’s ozone layer, \n"
+ "never descending to the ground.");
+static const u8 DexDescription_Rayquaza_2[] = _(
+ "This POKéMON appears to feed on water\n"
+ "and particles in the atmosphere.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Jirachi_1[] = _(
+ "JIRACHI will awaken from its sleep of\n"
+ "a thousand years if you sing to it in a\n"
+ "voice of purity.");
+static const u8 DexDescription_Jirachi_2[] = _(
+ "It is said to make true any wish that\n"
+ "people desire.");
+#else
+static const u8 DexDescription_Jirachi_1[] = _(
+ "A legend states that JIRACHI will make\n"
+ "true any wish that is written on notes\n"
+ "attached to its head when it awakens.");
+static const u8 DexDescription_Jirachi_2[] = _(
+ "If this POKéMON senses danger, it will\n"
+ "fight without awakening.");
+#endif
+
+#ifdef SAPPHIRE
+static const u8 DexDescription_Deoxys_1[] = _(
+ "DEOXYS emerged from a virus that came\n"
+ "from space. It is highly intelligent and\n"
+ "wields psychokinetic powers.");
+static const u8 DexDescription_Deoxys_2[] = _(
+ "This POKéMON shoots lasers from the\n"
+ "crystalline organ on its chest.");
+#else
+static const u8 DexDescription_Deoxys_1[] = _(
+ "The DNA of a space virus underwent a\n"
+ "sudden mutation upon exposure to a\n"
+ "laser beam and resulted in DEOXYS.");
+static const u8 DexDescription_Deoxys_2[] = _(
+ "The crystalline organ on this POKéMON’s\n"
+ "chest appears to be its brain.");
+#endif
+
+static const struct PokedexEntry gPokedexEntries[] =
+{
+ { //Dummy
+ .categoryName = _("UNKNOWN"),
+ .height = 0,
+ .weight = 0,
+ .descriptionPage1 = DexDescription_Dummy_1,
+ .descriptionPage2 = DexDescription_Dummy_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Bulbasaur
+ .categoryName = _("SEED"),
+ .height = 7,
+ .weight = 69,
+ .descriptionPage1 = DexDescription_Bulbasaur_1,
+ .descriptionPage2 = DexDescription_Bulbasaur_2,
+ .pokemonScale = 356,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ivysaur
+ .categoryName = _("SEED"),
+ .height = 10,
+ .weight = 130,
+ .descriptionPage1 = DexDescription_Ivysaur_1,
+ .descriptionPage2 = DexDescription_Ivysaur_2,
+ .pokemonScale = 335,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Venusaur
+ .categoryName = _("SEED"),
+ .height = 20,
+ .weight = 1000,
+ .descriptionPage1 = DexDescription_Venusaur_1,
+ .descriptionPage2 = DexDescription_Venusaur_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 388,
+ .trainerOffset = 6,
+ },
+ { //Charmander
+ .categoryName = _("LIZARD"),
+ .height = 6,
+ .weight = 85,
+ .descriptionPage1 = DexDescription_Charmander_1,
+ .descriptionPage2 = DexDescription_Charmander_2,
+ .pokemonScale = 444,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Charmeleon
+ .categoryName = _("FLAME"),
+ .height = 11,
+ .weight = 190,
+ .descriptionPage1 = DexDescription_Charmeleon_1,
+ .descriptionPage2 = DexDescription_Charmeleon_2,
+ .pokemonScale = 302,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Charizard
+ .categoryName = _("FLAME"),
+ .height = 17,
+ .weight = 905,
+ .descriptionPage1 = DexDescription_Charizard_1,
+ .descriptionPage2 = DexDescription_Charizard_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 302,
+ .trainerOffset = 3,
+ },
+ { //Squirtle
+ .categoryName = _("TINY TURTLE"),
+ .height = 5,
+ .weight = 90,
+ .descriptionPage1 = DexDescription_Squirtle_1,
+ .descriptionPage2 = DexDescription_Squirtle_2,
+ .pokemonScale = 412,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wartortle
+ .categoryName = _("TURTLE"),
+ .height = 10,
+ .weight = 225,
+ .descriptionPage1 = DexDescription_Wartortle_1,
+ .descriptionPage2 = DexDescription_Wartortle_2,
+ .pokemonScale = 332,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Blastoise
+ .categoryName = _("SHELLFISH"),
+ .height = 16,
+ .weight = 855,
+ .descriptionPage1 = DexDescription_Blastoise_1,
+ .descriptionPage2 = DexDescription_Blastoise_2,
+ .pokemonScale = 256,
+ .pokemonOffset = -1,
+ .trainerScale = 293,
+ .trainerOffset = 2,
+ },
+ { //Caterpie
+ .categoryName = _("WORM"),
+ .height = 3,
+ .weight = 29,
+ .descriptionPage1 = DexDescription_Caterpie_1,
+ .descriptionPage2 = DexDescription_Caterpie_2,
+ .pokemonScale = 549,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Metapod
+ .categoryName = _("COCOON"),
+ .height = 7,
+ .weight = 99,
+ .descriptionPage1 = DexDescription_Metapod_1,
+ .descriptionPage2 = DexDescription_Metapod_2,
+ .pokemonScale = 350,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Butterfree
+ .categoryName = _("BUTTERFLY"),
+ .height = 11,
+ .weight = 320,
+ .descriptionPage1 = DexDescription_Butterfree_1,
+ .descriptionPage2 = DexDescription_Butterfree_2,
+ .pokemonScale = 312,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Weedle
+ .categoryName = _("HAIRY BUG"),
+ .height = 3,
+ .weight = 32,
+ .descriptionPage1 = DexDescription_Weedle_1,
+ .descriptionPage2 = DexDescription_Weedle_2,
+ .pokemonScale = 455,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kakuna
+ .categoryName = _("COCOON"),
+ .height = 6,
+ .weight = 100,
+ .descriptionPage1 = DexDescription_Kakuna_1,
+ .descriptionPage2 = DexDescription_Kakuna_2,
+ .pokemonScale = 424,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Beedrill
+ .categoryName = _("POISON BEE"),
+ .height = 10,
+ .weight = 295,
+ .descriptionPage1 = DexDescription_Beedrill_1,
+ .descriptionPage2 = DexDescription_Beedrill_2,
+ .pokemonScale = 366,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pidgey
+ .categoryName = _("TINY BIRD"),
+ .height = 3,
+ .weight = 18,
+ .descriptionPage1 = DexDescription_Pidgey_1,
+ .descriptionPage2 = DexDescription_Pidgey_2,
+ .pokemonScale = 508,
+ .pokemonOffset = -3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pidgeotto
+ .categoryName = _("BIRD"),
+ .height = 11,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Pidgeotto_1,
+ .descriptionPage2 = DexDescription_Pidgeotto_2,
+ .pokemonScale = 331,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pidgeot
+ .categoryName = _("BIRD"),
+ .height = 15,
+ .weight = 395,
+ .descriptionPage1 = DexDescription_Pidgeot_1,
+ .descriptionPage2 = DexDescription_Pidgeot_2,
+ .pokemonScale = 269,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Rattata
+ .categoryName = _("MOUSE"),
+ .height = 3,
+ .weight = 35,
+ .descriptionPage1 = DexDescription_Rattata_1,
+ .descriptionPage2 = DexDescription_Rattata_2,
+ .pokemonScale = 481,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Raticate
+ .categoryName = _("MOUSE"),
+ .height = 7,
+ .weight = 185,
+ .descriptionPage1 = DexDescription_Raticate_1,
+ .descriptionPage2 = DexDescription_Raticate_2,
+ .pokemonScale = 459,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Spearow
+ .categoryName = _("TINY BIRD"),
+ .height = 3,
+ .weight = 20,
+ .descriptionPage1 = DexDescription_Spearow_1,
+ .descriptionPage2 = DexDescription_Spearow_2,
+ .pokemonScale = 571,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Fearow
+ .categoryName = _("BEAK"),
+ .height = 12,
+ .weight = 380,
+ .descriptionPage1 = DexDescription_Fearow_1,
+ .descriptionPage2 = DexDescription_Fearow_2,
+ .pokemonScale = 278,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ekans
+ .categoryName = _("SNAKE"),
+ .height = 20,
+ .weight = 69,
+ .descriptionPage1 = DexDescription_Ekans_1,
+ .descriptionPage2 = DexDescription_Ekans_2,
+ .pokemonScale = 298,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Arbok
+ .categoryName = _("COBRA"),
+ .height = 35,
+ .weight = 650,
+ .descriptionPage1 = DexDescription_Arbok_1,
+ .descriptionPage2 = DexDescription_Arbok_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 296,
+ .trainerOffset = 2,
+ },
+ { //Pikachu
+ .categoryName = _("MOUSE"),
+ .height = 4,
+ .weight = 60,
+ .descriptionPage1 = DexDescription_Pikachu_1,
+ .descriptionPage2 = DexDescription_Pikachu_2,
+ .pokemonScale = 479,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Raichu
+ .categoryName = _("MOUSE"),
+ .height = 8,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Raichu_1,
+ .descriptionPage2 = DexDescription_Raichu_2,
+ .pokemonScale = 426,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sandshrew
+ .categoryName = _("MOUSE"),
+ .height = 6,
+ .weight = 120,
+ .descriptionPage1 = DexDescription_Sandshrew_1,
+ .descriptionPage2 = DexDescription_Sandshrew_2,
+ .pokemonScale = 365,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sandslash
+ .categoryName = _("MOUSE"),
+ .height = 10,
+ .weight = 295,
+ .descriptionPage1 = DexDescription_Sandslash_1,
+ .descriptionPage2 = DexDescription_Sandslash_2,
+ .pokemonScale = 341,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //NidoranF
+ .categoryName = _("POISON PIN"),
+ .height = 4,
+ .weight = 70,
+ .descriptionPage1 = DexDescription_NidoranF_1,
+ .descriptionPage2 = DexDescription_NidoranF_2,
+ .pokemonScale = 488,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nidorina
+ .categoryName = _("POISON PIN"),
+ .height = 8,
+ .weight = 200,
+ .descriptionPage1 = DexDescription_Nidorina_1,
+ .descriptionPage2 = DexDescription_Nidorina_2,
+ .pokemonScale = 381,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nidoqueen
+ .categoryName = _("DRILL"),
+ .height = 13,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Nidoqueen_1,
+ .descriptionPage2 = DexDescription_Nidoqueen_2,
+ .pokemonScale = 293,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //NidoranM
+ .categoryName = _("POISON PIN"),
+ .height = 5,
+ .weight = 90,
+ .descriptionPage1 = DexDescription_NidoranM_1,
+ .descriptionPage2 = DexDescription_NidoranM_2,
+ .pokemonScale = 511,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nidorino
+ .categoryName = _("POISON PIN"),
+ .height = 9,
+ .weight = 195,
+ .descriptionPage1 = DexDescription_Nidorino_1,
+ .descriptionPage2 = DexDescription_Nidorino_2,
+ .pokemonScale = 408,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nidoking
+ .categoryName = _("DRILL"),
+ .height = 14,
+ .weight = 620,
+ .descriptionPage1 = DexDescription_Nidoking_1,
+ .descriptionPage2 = DexDescription_Nidoking_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Clefairy
+ .categoryName = _("FAIRY"),
+ .height = 6,
+ .weight = 75,
+ .descriptionPage1 = DexDescription_Clefairy_1,
+ .descriptionPage2 = DexDescription_Clefairy_2,
+ .pokemonScale = 441,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Clefable
+ .categoryName = _("FAIRY"),
+ .height = 13,
+ .weight = 400,
+ .descriptionPage1 = DexDescription_Clefable_1,
+ .descriptionPage2 = DexDescription_Clefable_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Vulpix
+ .categoryName = _("FOX"),
+ .height = 6,
+ .weight = 99,
+ .descriptionPage1 = DexDescription_Vulpix_1,
+ .descriptionPage2 = DexDescription_Vulpix_2,
+ .pokemonScale = 542,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ninetales
+ .categoryName = _("FOX"),
+ .height = 11,
+ .weight = 199,
+ .descriptionPage1 = DexDescription_Ninetales_1,
+ .descriptionPage2 = DexDescription_Ninetales_2,
+ .pokemonScale = 339,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Jigglypuff
+ .categoryName = _("BALLOON"),
+ .height = 5,
+ .weight = 55,
+ .descriptionPage1 = DexDescription_Jigglypuff_1,
+ .descriptionPage2 = DexDescription_Jigglypuff_2,
+ .pokemonScale = 433,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wigglytuff
+ .categoryName = _("BALLOON"),
+ .height = 10,
+ .weight = 120,
+ .descriptionPage1 = DexDescription_Wigglytuff_1,
+ .descriptionPage2 = DexDescription_Wigglytuff_2,
+ .pokemonScale = 328,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Zubat
+ .categoryName = _("BAT"),
+ .height = 8,
+ .weight = 75,
+ .descriptionPage1 = DexDescription_Zubat_1,
+ .descriptionPage2 = DexDescription_Zubat_2,
+ .pokemonScale = 362,
+ .pokemonOffset = -5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Golbat
+ .categoryName = _("BAT"),
+ .height = 16,
+ .weight = 550,
+ .descriptionPage1 = DexDescription_Golbat_1,
+ .descriptionPage2 = DexDescription_Golbat_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Oddish
+ .categoryName = _("WEED"),
+ .height = 5,
+ .weight = 54,
+ .descriptionPage1 = DexDescription_Oddish_1,
+ .descriptionPage2 = DexDescription_Oddish_2,
+ .pokemonScale = 423,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gloom
+ .categoryName = _("WEED"),
+ .height = 8,
+ .weight = 86,
+ .descriptionPage1 = DexDescription_Gloom_1,
+ .descriptionPage2 = DexDescription_Gloom_2,
+ .pokemonScale = 329,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Vileplume
+ .categoryName = _("FLOWER"),
+ .height = 12,
+ .weight = 186,
+ .descriptionPage1 = DexDescription_Vileplume_1,
+ .descriptionPage2 = DexDescription_Vileplume_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Paras
+ .categoryName = _("MUSHROOM"),
+ .height = 3,
+ .weight = 54,
+ .descriptionPage1 = DexDescription_Paras_1,
+ .descriptionPage2 = DexDescription_Paras_2,
+ .pokemonScale = 593,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Parasect
+ .categoryName = _("MUSHROOM"),
+ .height = 10,
+ .weight = 295,
+ .descriptionPage1 = DexDescription_Parasect_1,
+ .descriptionPage2 = DexDescription_Parasect_2,
+ .pokemonScale = 307,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Venonat
+ .categoryName = _("INSECT"),
+ .height = 10,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Venonat_1,
+ .descriptionPage2 = DexDescription_Venonat_2,
+ .pokemonScale = 360,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = -1,
+ },
+ { //Venomoth
+ .categoryName = _("POISON MOTH"),
+ .height = 15,
+ .weight = 125,
+ .descriptionPage1 = DexDescription_Venomoth_1,
+ .descriptionPage2 = DexDescription_Venomoth_2,
+ .pokemonScale = 285,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 1,
+ },
+ { //Diglett
+ .categoryName = _("MOLE"),
+ .height = 2,
+ .weight = 8,
+ .descriptionPage1 = DexDescription_Diglett_1,
+ .descriptionPage2 = DexDescription_Diglett_2,
+ .pokemonScale = 833,
+ .pokemonOffset = 25,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Dugtrio
+ .categoryName = _("MOLE"),
+ .height = 7,
+ .weight = 333,
+ .descriptionPage1 = DexDescription_Dugtrio_1,
+ .descriptionPage2 = DexDescription_Dugtrio_2,
+ .pokemonScale = 406,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Meowth
+ .categoryName = _("SCRATCH CAT"),
+ .height = 4,
+ .weight = 42,
+ .descriptionPage1 = DexDescription_Meowth_1,
+ .descriptionPage2 = DexDescription_Meowth_2,
+ .pokemonScale = 480,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Persian
+ .categoryName = _("CLASSY CAT"),
+ .height = 10,
+ .weight = 320,
+ .descriptionPage1 = DexDescription_Persian_1,
+ .descriptionPage2 = DexDescription_Persian_2,
+ .pokemonScale = 320,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Psyduck
+ .categoryName = _("DUCK"),
+ .height = 8,
+ .weight = 196,
+ .descriptionPage1 = DexDescription_Psyduck_1,
+ .descriptionPage2 = DexDescription_Psyduck_2,
+ .pokemonScale = 369,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Golduck
+ .categoryName = _("DUCK"),
+ .height = 17,
+ .weight = 766,
+ .descriptionPage1 = DexDescription_Golduck_1,
+ .descriptionPage2 = DexDescription_Golduck_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 273,
+ .trainerOffset = 1,
+ },
+ { //Mankey
+ .categoryName = _("PIG MONKEY"),
+ .height = 5,
+ .weight = 280,
+ .descriptionPage1 = DexDescription_Mankey_1,
+ .descriptionPage2 = DexDescription_Mankey_2,
+ .pokemonScale = 404,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Primeape
+ .categoryName = _("PIG MONKEY"),
+ .height = 10,
+ .weight = 320,
+ .descriptionPage1 = DexDescription_Primeape_1,
+ .descriptionPage2 = DexDescription_Primeape_2,
+ .pokemonScale = 326,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Growlithe
+ .categoryName = _("PUPPY"),
+ .height = 7,
+ .weight = 190,
+ .descriptionPage1 = DexDescription_Growlithe_1,
+ .descriptionPage2 = DexDescription_Growlithe_2,
+ .pokemonScale = 346,
+ .pokemonOffset = 14,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Arcanine
+ .categoryName = _("LEGENDARY"),
+ .height = 19,
+ .weight = 1550,
+ .descriptionPage1 = DexDescription_Arcanine_1,
+ .descriptionPage2 = DexDescription_Arcanine_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 312,
+ .trainerOffset = 4,
+ },
+ { //Poliwag
+ .categoryName = _("TADPOLE"),
+ .height = 6,
+ .weight = 124,
+ .descriptionPage1 = DexDescription_Poliwag_1,
+ .descriptionPage2 = DexDescription_Poliwag_2,
+ .pokemonScale = 369,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Poliwhirl
+ .categoryName = _("TADPOLE"),
+ .height = 10,
+ .weight = 200,
+ .descriptionPage1 = DexDescription_Poliwhirl_1,
+ .descriptionPage2 = DexDescription_Poliwhirl_2,
+ .pokemonScale = 288,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Poliwrath
+ .categoryName = _("TADPOLE"),
+ .height = 13,
+ .weight = 540,
+ .descriptionPage1 = DexDescription_Poliwrath_1,
+ .descriptionPage2 = DexDescription_Poliwrath_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Abra
+ .categoryName = _("PSI"),
+ .height = 9,
+ .weight = 195,
+ .descriptionPage1 = DexDescription_Abra_1,
+ .descriptionPage2 = DexDescription_Abra_2,
+ .pokemonScale = 363,
+ .pokemonOffset = 14,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kadabra
+ .categoryName = _("PSI"),
+ .height = 13,
+ .weight = 565,
+ .descriptionPage1 = DexDescription_Kadabra_1,
+ .descriptionPage2 = DexDescription_Kadabra_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Alakazam
+ .categoryName = _("PSI"),
+ .height = 15,
+ .weight = 480,
+ .descriptionPage1 = DexDescription_Alakazam_1,
+ .descriptionPage2 = DexDescription_Alakazam_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Machop
+ .categoryName = _("SUPERPOWER"),
+ .height = 8,
+ .weight = 195,
+ .descriptionPage1 = DexDescription_Machop_1,
+ .descriptionPage2 = DexDescription_Machop_2,
+ .pokemonScale = 342,
+ .pokemonOffset = 14,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Machoke
+ .categoryName = _("SUPERPOWER"),
+ .height = 15,
+ .weight = 705,
+ .descriptionPage1 = DexDescription_Machoke_1,
+ .descriptionPage2 = DexDescription_Machoke_2,
+ .pokemonScale = 323,
+ .pokemonOffset = 9,
+ .trainerScale = 257,
+ .trainerOffset = 0,
+ },
+ { //Machamp
+ .categoryName = _("SUPERPOWER"),
+ .height = 16,
+ .weight = 1300,
+ .descriptionPage1 = DexDescription_Machamp_1,
+ .descriptionPage2 = DexDescription_Machamp_2,
+ .pokemonScale = 280,
+ .pokemonOffset = 1,
+ .trainerScale = 269,
+ .trainerOffset = -1,
+ },
+ { //Bellsprout
+ .categoryName = _("FLOWER"),
+ .height = 7,
+ .weight = 40,
+ .descriptionPage1 = DexDescription_Bellsprout_1,
+ .descriptionPage2 = DexDescription_Bellsprout_2,
+ .pokemonScale = 354,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Weepinbell
+ .categoryName = _("FLYCATCHER"),
+ .height = 10,
+ .weight = 64,
+ .descriptionPage1 = DexDescription_Weepinbell_1,
+ .descriptionPage2 = DexDescription_Weepinbell_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Victreebel
+ .categoryName = _("FLYCATCHER"),
+ .height = 17,
+ .weight = 155,
+ .descriptionPage1 = DexDescription_Victreebel_1,
+ .descriptionPage2 = DexDescription_Victreebel_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 312,
+ .trainerOffset = 3,
+ },
+ { //Tentacool
+ .categoryName = _("JELLYFISH"),
+ .height = 9,
+ .weight = 455,
+ .descriptionPage1 = DexDescription_Tentacool_1,
+ .descriptionPage2 = DexDescription_Tentacool_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Tentacruel
+ .categoryName = _("JELLYFISH"),
+ .height = 16,
+ .weight = 550,
+ .descriptionPage1 = DexDescription_Tentacruel_1,
+ .descriptionPage2 = DexDescription_Tentacruel_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 312,
+ .trainerOffset = 1,
+ },
+ { //Geodude
+ .categoryName = _("ROCK"),
+ .height = 4,
+ .weight = 200,
+ .descriptionPage1 = DexDescription_Geodude_1,
+ .descriptionPage2 = DexDescription_Geodude_2,
+ .pokemonScale = 347,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Graveler
+ .categoryName = _("ROCK"),
+ .height = 10,
+ .weight = 1050,
+ .descriptionPage1 = DexDescription_Graveler_1,
+ .descriptionPage2 = DexDescription_Graveler_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Golem
+ .categoryName = _("MEGATON"),
+ .height = 14,
+ .weight = 3000,
+ .descriptionPage1 = DexDescription_Golem_1,
+ .descriptionPage2 = DexDescription_Golem_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 296,
+ .trainerOffset = 2,
+ },
+ { //Ponyta
+ .categoryName = _("FIRE HORSE"),
+ .height = 10,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Ponyta_1,
+ .descriptionPage2 = DexDescription_Ponyta_2,
+ .pokemonScale = 283,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Rapidash
+ .categoryName = _("FIRE HORSE"),
+ .height = 17,
+ .weight = 950,
+ .descriptionPage1 = DexDescription_Rapidash_1,
+ .descriptionPage2 = DexDescription_Rapidash_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 289,
+ .trainerOffset = 1,
+ },
+ { //Slowpoke
+ .categoryName = _("DOPEY"),
+ .height = 12,
+ .weight = 360,
+ .descriptionPage1 = DexDescription_Slowpoke_1,
+ .descriptionPage2 = DexDescription_Slowpoke_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Slowbro
+ .categoryName = _("HERMIT CRAB"),
+ .height = 16,
+ .weight = 785,
+ .descriptionPage1 = DexDescription_Slowbro_1,
+ .descriptionPage2 = DexDescription_Slowbro_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 296,
+ .trainerOffset = 2,
+ },
+ { //Magnemite
+ .categoryName = _("MAGNET"),
+ .height = 3,
+ .weight = 60,
+ .descriptionPage1 = DexDescription_Magnemite_1,
+ .descriptionPage2 = DexDescription_Magnemite_2,
+ .pokemonScale = 288,
+ .pokemonOffset = -9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Magneton
+ .categoryName = _("MAGNET"),
+ .height = 10,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Magneton_1,
+ .descriptionPage2 = DexDescription_Magneton_2,
+ .pokemonScale = 292,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Farfetchd
+ .categoryName = _("WILD DUCK"),
+ .height = 8,
+ .weight = 150,
+ .descriptionPage1 = DexDescription_Farfetchd_1,
+ .descriptionPage2 = DexDescription_Farfetchd_2,
+ .pokemonScale = 330,
+ .pokemonOffset = 2,
+ .trainerScale = 293,
+ .trainerOffset = 2,
+ },
+ { //Doduo
+ .categoryName = _("TWIN BIRD"),
+ .height = 14,
+ .weight = 392,
+ .descriptionPage1 = DexDescription_Doduo_1,
+ .descriptionPage2 = DexDescription_Doduo_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 257,
+ .trainerOffset = -1,
+ },
+ { //Dodrio
+ .categoryName = _("TRIPLE BIRD"),
+ .height = 18,
+ .weight = 852,
+ .descriptionPage1 = DexDescription_Dodrio_1,
+ .descriptionPage2 = DexDescription_Dodrio_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 268,
+ .trainerOffset = 0,
+ },
+ { //Seel
+ .categoryName = _("SEA LION"),
+ .height = 11,
+ .weight = 900,
+ .descriptionPage1 = DexDescription_Seel_1,
+ .descriptionPage2 = DexDescription_Seel_2,
+ .pokemonScale = 297,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Dewgong
+ .categoryName = _("SEA LION"),
+ .height = 17,
+ .weight = 1200,
+ .descriptionPage1 = DexDescription_Dewgong_1,
+ .descriptionPage2 = DexDescription_Dewgong_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 275,
+ .trainerOffset = 0,
+ },
+ { //Grimer
+ .categoryName = _("SLUDGE"),
+ .height = 9,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Grimer_1,
+ .descriptionPage2 = DexDescription_Grimer_2,
+ .pokemonScale = 258,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Muk
+ .categoryName = _("SLUDGE"),
+ .height = 12,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Muk_1,
+ .descriptionPage2 = DexDescription_Muk_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shellder
+ .categoryName = _("BIVALVE"),
+ .height = 3,
+ .weight = 40,
+ .descriptionPage1 = DexDescription_Shellder_1,
+ .descriptionPage2 = DexDescription_Shellder_2,
+ .pokemonScale = 675,
+ .pokemonOffset = 24,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Cloyster
+ .categoryName = _("BIVALVE"),
+ .height = 15,
+ .weight = 1325,
+ .descriptionPage1 = DexDescription_Cloyster_1,
+ .descriptionPage2 = DexDescription_Cloyster_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 269,
+ .trainerOffset = 1,
+ },
+ { //Gastly
+ .categoryName = _("GAS"),
+ .height = 13,
+ .weight = 1,
+ .descriptionPage1 = DexDescription_Gastly_1,
+ .descriptionPage2 = DexDescription_Gastly_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Haunter
+ .categoryName = _("GAS"),
+ .height = 16,
+ .weight = 1,
+ .descriptionPage1 = DexDescription_Haunter_1,
+ .descriptionPage2 = DexDescription_Haunter_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 293,
+ .trainerOffset = 2,
+ },
+ { //Gengar
+ .categoryName = _("SHADOW"),
+ .height = 15,
+ .weight = 405,
+ .descriptionPage1 = DexDescription_Gengar_1,
+ .descriptionPage2 = DexDescription_Gengar_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 302,
+ .trainerOffset = 2,
+ },
+ { //Onix
+ .categoryName = _("ROCK SNAKE"),
+ .height = 88,
+ .weight = 2100,
+ .descriptionPage1 = DexDescription_Onix_1,
+ .descriptionPage2 = DexDescription_Onix_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 515,
+ .trainerOffset = 14,
+ },
+ { //Drowzee
+ .categoryName = _("HYPNOSIS"),
+ .height = 10,
+ .weight = 324,
+ .descriptionPage1 = DexDescription_Drowzee_1,
+ .descriptionPage2 = DexDescription_Drowzee_2,
+ .pokemonScale = 274,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hypno
+ .categoryName = _("HYPNOSIS"),
+ .height = 16,
+ .weight = 756,
+ .descriptionPage1 = DexDescription_Hypno_1,
+ .descriptionPage2 = DexDescription_Hypno_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 257,
+ .trainerOffset = 0,
+ },
+ { //Krabby
+ .categoryName = _("RIVER CRAB"),
+ .height = 4,
+ .weight = 65,
+ .descriptionPage1 = DexDescription_Krabby_1,
+ .descriptionPage2 = DexDescription_Krabby_2,
+ .pokemonScale = 469,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kingler
+ .categoryName = _("PINCER"),
+ .height = 13,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Kingler_1,
+ .descriptionPage2 = DexDescription_Kingler_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Voltorb
+ .categoryName = _("BALL"),
+ .height = 5,
+ .weight = 104,
+ .descriptionPage1 = DexDescription_Voltorb_1,
+ .descriptionPage2 = DexDescription_Voltorb_2,
+ .pokemonScale = 364,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Electrode
+ .categoryName = _("BALL"),
+ .height = 12,
+ .weight = 666,
+ .descriptionPage1 = DexDescription_Electrode_1,
+ .descriptionPage2 = DexDescription_Electrode_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Exeggcute
+ .categoryName = _("EGG"),
+ .height = 4,
+ .weight = 25,
+ .descriptionPage1 = DexDescription_Exeggcute_1,
+ .descriptionPage2 = DexDescription_Exeggcute_2,
+ .pokemonScale = 489,
+ .pokemonOffset = -4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Exeggutor
+ .categoryName = _("COCONUT"),
+ .height = 20,
+ .weight = 1200,
+ .descriptionPage1 = DexDescription_Exeggutor_1,
+ .descriptionPage2 = DexDescription_Exeggutor_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 309,
+ .trainerOffset = 5,
+ },
+ { //Cubone
+ .categoryName = _("LONELY"),
+ .height = 4,
+ .weight = 65,
+ .descriptionPage1 = DexDescription_Cubone_1,
+ .descriptionPage2 = DexDescription_Cubone_2,
+ .pokemonScale = 545,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Marowak
+ .categoryName = _("BONE KEEPER"),
+ .height = 10,
+ .weight = 450,
+ .descriptionPage1 = DexDescription_Marowak_1,
+ .descriptionPage2 = DexDescription_Marowak_2,
+ .pokemonScale = 293,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hitmonlee
+ .categoryName = _("KICKING"),
+ .height = 15,
+ .weight = 498,
+ .descriptionPage1 = DexDescription_Hitmonlee_1,
+ .descriptionPage2 = DexDescription_Hitmonlee_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 259,
+ .trainerOffset = 1,
+ },
+ { //Hitmonchan
+ .categoryName = _("PUNCHING"),
+ .height = 14,
+ .weight = 502,
+ .descriptionPage1 = DexDescription_Hitmonchan_1,
+ .descriptionPage2 = DexDescription_Hitmonchan_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 277,
+ .trainerOffset = 2,
+ },
+ { //Lickitung
+ .categoryName = _("LICKING"),
+ .height = 12,
+ .weight = 655,
+ .descriptionPage1 = DexDescription_Lickitung_1,
+ .descriptionPage2 = DexDescription_Lickitung_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Koffing
+ .categoryName = _("POISON GAS"),
+ .height = 6,
+ .weight = 10,
+ .descriptionPage1 = DexDescription_Koffing_1,
+ .descriptionPage2 = DexDescription_Koffing_2,
+ .pokemonScale = 369,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Weezing
+ .categoryName = _("POISON GAS"),
+ .height = 12,
+ .weight = 95,
+ .descriptionPage1 = DexDescription_Weezing_1,
+ .descriptionPage2 = DexDescription_Weezing_2,
+ .pokemonScale = 305,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Rhyhorn
+ .categoryName = _("SPIKES"),
+ .height = 10,
+ .weight = 1150,
+ .descriptionPage1 = DexDescription_Rhyhorn_1,
+ .descriptionPage2 = DexDescription_Rhyhorn_2,
+ .pokemonScale = 267,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Rhydon
+ .categoryName = _("DRILL"),
+ .height = 19,
+ .weight = 1200,
+ .descriptionPage1 = DexDescription_Rhydon_1,
+ .descriptionPage2 = DexDescription_Rhydon_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 299,
+ .trainerOffset = 2,
+ },
+ { //Chansey
+ .categoryName = _("EGG"),
+ .height = 11,
+ .weight = 346,
+ .descriptionPage1 = DexDescription_Chansey_1,
+ .descriptionPage2 = DexDescription_Chansey_2,
+ .pokemonScale = 257,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Tangela
+ .categoryName = _("VINE"),
+ .height = 10,
+ .weight = 350,
+ .descriptionPage1 = DexDescription_Tangela_1,
+ .descriptionPage2 = DexDescription_Tangela_2,
+ .pokemonScale = 304,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kangaskhan
+ .categoryName = _("PARENT"),
+ .height = 22,
+ .weight = 800,
+ .descriptionPage1 = DexDescription_Kangaskhan_1,
+ .descriptionPage2 = DexDescription_Kangaskhan_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 387,
+ .trainerOffset = 8,
+ },
+ { //Horsea
+ .categoryName = _("DRAGON"),
+ .height = 4,
+ .weight = 80,
+ .descriptionPage1 = DexDescription_Horsea_1,
+ .descriptionPage2 = DexDescription_Horsea_2,
+ .pokemonScale = 399,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Seadra
+ .categoryName = _("DRAGON"),
+ .height = 12,
+ .weight = 250,
+ .descriptionPage1 = DexDescription_Seadra_1,
+ .descriptionPage2 = DexDescription_Seadra_2,
+ .pokemonScale = 299,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Goldeen
+ .categoryName = _("GOLDFISH"),
+ .height = 6,
+ .weight = 150,
+ .descriptionPage1 = DexDescription_Goldeen_1,
+ .descriptionPage2 = DexDescription_Goldeen_2,
+ .pokemonScale = 379,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Seaking
+ .categoryName = _("GOLDFISH"),
+ .height = 13,
+ .weight = 390,
+ .descriptionPage1 = DexDescription_Seaking_1,
+ .descriptionPage2 = DexDescription_Seaking_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Staryu
+ .categoryName = _("STAR SHAPE"),
+ .height = 8,
+ .weight = 345,
+ .descriptionPage1 = DexDescription_Staryu_1,
+ .descriptionPage2 = DexDescription_Staryu_2,
+ .pokemonScale = 326,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Starmie
+ .categoryName = _("MYSTERIOUS"),
+ .height = 11,
+ .weight = 800,
+ .descriptionPage1 = DexDescription_Starmie_1,
+ .descriptionPage2 = DexDescription_Starmie_2,
+ .pokemonScale = 301,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Mrmime
+ .categoryName = _("BARRIER"),
+ .height = 13,
+ .weight = 545,
+ .descriptionPage1 = DexDescription_Mrmime_1,
+ .descriptionPage2 = DexDescription_Mrmime_2,
+ .pokemonScale = 258,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Scyther
+ .categoryName = _("MANTIS"),
+ .height = 15,
+ .weight = 560,
+ .descriptionPage1 = DexDescription_Scyther_1,
+ .descriptionPage2 = DexDescription_Scyther_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 1,
+ .trainerScale = 293,
+ .trainerOffset = 2,
+ },
+ { //Jynx
+ .categoryName = _("HUMAN SHAPE"),
+ .height = 14,
+ .weight = 406,
+ .descriptionPage1 = DexDescription_Jynx_1,
+ .descriptionPage2 = DexDescription_Jynx_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 300,
+ .trainerOffset = 1,
+ },
+ { //Electabuzz
+ .categoryName = _("ELECTRIC"),
+ .height = 11,
+ .weight = 300,
+ .descriptionPage1 = DexDescription_Electabuzz_1,
+ .descriptionPage2 = DexDescription_Electabuzz_2,
+ .pokemonScale = 351,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Magmar
+ .categoryName = _("SPITFIRE"),
+ .height = 13,
+ .weight = 445,
+ .descriptionPage1 = DexDescription_Magmar_1,
+ .descriptionPage2 = DexDescription_Magmar_2,
+ .pokemonScale = 277,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pinsir
+ .categoryName = _("STAG BEETLE"),
+ .height = 15,
+ .weight = 550,
+ .descriptionPage1 = DexDescription_Pinsir_1,
+ .descriptionPage2 = DexDescription_Pinsir_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 257,
+ .trainerOffset = 0,
+ },
+ { //Tauros
+ .categoryName = _("WILD BULL"),
+ .height = 14,
+ .weight = 884,
+ .descriptionPage1 = DexDescription_Tauros_1,
+ .descriptionPage2 = DexDescription_Tauros_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Magikarp
+ .categoryName = _("FISH"),
+ .height = 9,
+ .weight = 100,
+ .descriptionPage1 = DexDescription_Magikarp_1,
+ .descriptionPage2 = DexDescription_Magikarp_2,
+ .pokemonScale = 310,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gyarados
+ .categoryName = _("ATROCIOUS"),
+ .height = 65,
+ .weight = 2350,
+ .descriptionPage1 = DexDescription_Gyarados_1,
+ .descriptionPage2 = DexDescription_Gyarados_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 481,
+ .trainerOffset = 13,
+ },
+ { //Lapras
+ .categoryName = _("TRANSPORT"),
+ .height = 25,
+ .weight = 2200,
+ .descriptionPage1 = DexDescription_Lapras_1,
+ .descriptionPage2 = DexDescription_Lapras_2,
+ .pokemonScale = 257,
+ .pokemonOffset = 10,
+ .trainerScale = 423,
+ .trainerOffset = 8,
+ },
+ { //Ditto
+ .categoryName = _("TRANSFORM"),
+ .height = 3,
+ .weight = 40,
+ .descriptionPage1 = DexDescription_Ditto_1,
+ .descriptionPage2 = DexDescription_Ditto_2,
+ .pokemonScale = 633,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Eevee
+ .categoryName = _("EVOLUTION"),
+ .height = 3,
+ .weight = 65,
+ .descriptionPage1 = DexDescription_Eevee_1,
+ .descriptionPage2 = DexDescription_Eevee_2,
+ .pokemonScale = 476,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Vaporeon
+ .categoryName = _("BUBBLE JET"),
+ .height = 10,
+ .weight = 290,
+ .descriptionPage1 = DexDescription_Vaporeon_1,
+ .descriptionPage2 = DexDescription_Vaporeon_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Jolteon
+ .categoryName = _("LIGHTNING"),
+ .height = 8,
+ .weight = 245,
+ .descriptionPage1 = DexDescription_Jolteon_1,
+ .descriptionPage2 = DexDescription_Jolteon_2,
+ .pokemonScale = 283,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Flareon
+ .categoryName = _("FLAME"),
+ .height = 9,
+ .weight = 250,
+ .descriptionPage1 = DexDescription_Flareon_1,
+ .descriptionPage2 = DexDescription_Flareon_2,
+ .pokemonScale = 306,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Porygon
+ .categoryName = _("VIRTUAL"),
+ .height = 8,
+ .weight = 365,
+ .descriptionPage1 = DexDescription_Porygon_1,
+ .descriptionPage2 = DexDescription_Porygon_2,
+ .pokemonScale = 328,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Omanyte
+ .categoryName = _("SPIRAL"),
+ .height = 4,
+ .weight = 75,
+ .descriptionPage1 = DexDescription_Omanyte_1,
+ .descriptionPage2 = DexDescription_Omanyte_2,
+ .pokemonScale = 521,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Omastar
+ .categoryName = _("SPIRAL"),
+ .height = 10,
+ .weight = 350,
+ .descriptionPage1 = DexDescription_Omastar_1,
+ .descriptionPage2 = DexDescription_Omastar_2,
+ .pokemonScale = 307,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kabuto
+ .categoryName = _("SHELLFISH"),
+ .height = 5,
+ .weight = 115,
+ .descriptionPage1 = DexDescription_Kabuto_1,
+ .descriptionPage2 = DexDescription_Kabuto_2,
+ .pokemonScale = 454,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kabutops
+ .categoryName = _("SHELLFISH"),
+ .height = 13,
+ .weight = 405,
+ .descriptionPage1 = DexDescription_Kabutops_1,
+ .descriptionPage2 = DexDescription_Kabutops_2,
+ .pokemonScale = 271,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Aerodactyl
+ .categoryName = _("FOSSIL"),
+ .height = 18,
+ .weight = 590,
+ .descriptionPage1 = DexDescription_Aerodactyl_1,
+ .descriptionPage2 = DexDescription_Aerodactyl_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 302,
+ .trainerOffset = 4,
+ },
+ { //Snorlax
+ .categoryName = _("SLEEPING"),
+ .height = 21,
+ .weight = 4600,
+ .descriptionPage1 = DexDescription_Snorlax_1,
+ .descriptionPage2 = DexDescription_Snorlax_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 423,
+ .trainerOffset = 11,
+ },
+ { //Articuno
+ .categoryName = _("FREEZE"),
+ .height = 17,
+ .weight = 554,
+ .descriptionPage1 = DexDescription_Articuno_1,
+ .descriptionPage2 = DexDescription_Articuno_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 309,
+ .trainerOffset = 2,
+ },
+ { //Zapdos
+ .categoryName = _("ELECTRIC"),
+ .height = 16,
+ .weight = 526,
+ .descriptionPage1 = DexDescription_Zapdos_1,
+ .descriptionPage2 = DexDescription_Zapdos_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 318,
+ .trainerOffset = 3,
+ },
+ { //Moltres
+ .categoryName = _("FLAME"),
+ .height = 20,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Moltres_1,
+ .descriptionPage2 = DexDescription_Moltres_2,
+ .pokemonScale = 270,
+ .pokemonOffset = 0,
+ .trainerScale = 387,
+ .trainerOffset = 8,
+ },
+ { //Dratini
+ .categoryName = _("DRAGON"),
+ .height = 18,
+ .weight = 33,
+ .descriptionPage1 = DexDescription_Dratini_1,
+ .descriptionPage2 = DexDescription_Dratini_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 8,
+ .trainerScale = 386,
+ .trainerOffset = 6,
+ },
+ { //Dragonair
+ .categoryName = _("DRAGON"),
+ .height = 40,
+ .weight = 165,
+ .descriptionPage1 = DexDescription_Dragonair_1,
+ .descriptionPage2 = DexDescription_Dragonair_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 411,
+ .trainerOffset = 5,
+ },
+ { //Dragonite
+ .categoryName = _("DRAGON"),
+ .height = 22,
+ .weight = 2100,
+ .descriptionPage1 = DexDescription_Dragonite_1,
+ .descriptionPage2 = DexDescription_Dragonite_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 309,
+ .trainerOffset = 4,
+ },
+ { //Mewtwo
+ .categoryName = _("GENETIC"),
+ .height = 20,
+ .weight = 1220,
+ .descriptionPage1 = DexDescription_Mewtwo_1,
+ .descriptionPage2 = DexDescription_Mewtwo_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 309,
+ .trainerOffset = 4,
+ },
+ { //Mew
+ .categoryName = _("NEW SPECIES"),
+ .height = 4,
+ .weight = 40,
+ .descriptionPage1 = DexDescription_Mew_1,
+ .descriptionPage2 = DexDescription_Mew_2,
+ .pokemonScale = 457,
+ .pokemonOffset = -2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Chikorita
+ .categoryName = _("LEAF"),
+ .height = 9,
+ .weight = 64,
+ .descriptionPage1 = DexDescription_Chikorita_1,
+ .descriptionPage2 = DexDescription_Chikorita_2,
+ .pokemonScale = 512,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Bayleef
+ .categoryName = _("LEAF"),
+ .height = 12,
+ .weight = 158,
+ .descriptionPage1 = DexDescription_Bayleef_1,
+ .descriptionPage2 = DexDescription_Bayleef_2,
+ .pokemonScale = 296,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Meganium
+ .categoryName = _("HERB"),
+ .height = 18,
+ .weight = 1005,
+ .descriptionPage1 = DexDescription_Meganium_1,
+ .descriptionPage2 = DexDescription_Meganium_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 277,
+ .trainerOffset = 1,
+ },
+ { //Cyndaquil
+ .categoryName = _("FIRE MOUSE"),
+ .height = 5,
+ .weight = 79,
+ .descriptionPage1 = DexDescription_Cyndaquil_1,
+ .descriptionPage2 = DexDescription_Cyndaquil_2,
+ .pokemonScale = 539,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Quilava
+ .categoryName = _("VOLCANO"),
+ .height = 9,
+ .weight = 190,
+ .descriptionPage1 = DexDescription_Quilava_1,
+ .descriptionPage2 = DexDescription_Quilava_2,
+ .pokemonScale = 329,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Typhlosion
+ .categoryName = _("VOLCANO"),
+ .height = 17,
+ .weight = 795,
+ .descriptionPage1 = DexDescription_Typhlosion_1,
+ .descriptionPage2 = DexDescription_Typhlosion_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 268,
+ .trainerOffset = 1,
+ },
+ { //Totodile
+ .categoryName = _("BIG JAW"),
+ .height = 6,
+ .weight = 95,
+ .descriptionPage1 = DexDescription_Totodile_1,
+ .descriptionPage2 = DexDescription_Totodile_2,
+ .pokemonScale = 487,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Croconaw
+ .categoryName = _("BIG JAW"),
+ .height = 11,
+ .weight = 250,
+ .descriptionPage1 = DexDescription_Croconaw_1,
+ .descriptionPage2 = DexDescription_Croconaw_2,
+ .pokemonScale = 378,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Feraligatr
+ .categoryName = _("BIG JAW"),
+ .height = 23,
+ .weight = 888,
+ .descriptionPage1 = DexDescription_Feraligatr_1,
+ .descriptionPage2 = DexDescription_Feraligatr_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 342,
+ .trainerOffset = 7,
+ },
+ { //Sentret
+ .categoryName = _("SCOUT"),
+ .height = 8,
+ .weight = 60,
+ .descriptionPage1 = DexDescription_Sentret_1,
+ .descriptionPage2 = DexDescription_Sentret_2,
+ .pokemonScale = 439,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Furret
+ .categoryName = _("LONG BODY"),
+ .height = 18,
+ .weight = 325,
+ .descriptionPage1 = DexDescription_Furret_1,
+ .descriptionPage2 = DexDescription_Furret_2,
+ .pokemonScale = 346,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hoothoot
+ .categoryName = _("OWL"),
+ .height = 7,
+ .weight = 212,
+ .descriptionPage1 = DexDescription_Hoothoot_1,
+ .descriptionPage2 = DexDescription_Hoothoot_2,
+ .pokemonScale = 380,
+ .pokemonOffset = -2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Noctowl
+ .categoryName = _("OWL"),
+ .height = 16,
+ .weight = 408,
+ .descriptionPage1 = DexDescription_Noctowl_1,
+ .descriptionPage2 = DexDescription_Noctowl_2,
+ .pokemonScale = 278,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ledyba
+ .categoryName = _("FIVE STAR"),
+ .height = 10,
+ .weight = 108,
+ .descriptionPage1 = DexDescription_Ledyba_1,
+ .descriptionPage2 = DexDescription_Ledyba_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ledian
+ .categoryName = _("FIVE STAR"),
+ .height = 14,
+ .weight = 356,
+ .descriptionPage1 = DexDescription_Ledian_1,
+ .descriptionPage2 = DexDescription_Ledian_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Spinarak
+ .categoryName = _("STRING SPIT"),
+ .height = 5,
+ .weight = 85,
+ .descriptionPage1 = DexDescription_Spinarak_1,
+ .descriptionPage2 = DexDescription_Spinarak_2,
+ .pokemonScale = 414,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ariados
+ .categoryName = _("LONG LEG"),
+ .height = 11,
+ .weight = 335,
+ .descriptionPage1 = DexDescription_Ariados_1,
+ .descriptionPage2 = DexDescription_Ariados_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Crobat
+ .categoryName = _("BAT"),
+ .height = 18,
+ .weight = 750,
+ .descriptionPage1 = DexDescription_Crobat_1,
+ .descriptionPage2 = DexDescription_Crobat_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 281,
+ .trainerOffset = 1,
+ },
+ { //Chinchou
+ .categoryName = _("ANGLER"),
+ .height = 5,
+ .weight = 120,
+ .descriptionPage1 = DexDescription_Chinchou_1,
+ .descriptionPage2 = DexDescription_Chinchou_2,
+ .pokemonScale = 424,
+ .pokemonOffset = -2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Lanturn
+ .categoryName = _("LIGHT"),
+ .height = 12,
+ .weight = 225,
+ .descriptionPage1 = DexDescription_Lanturn_1,
+ .descriptionPage2 = DexDescription_Lanturn_2,
+ .pokemonScale = 269,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pichu
+ .categoryName = _("TINY MOUSE"),
+ .height = 3,
+ .weight = 20,
+ .descriptionPage1 = DexDescription_Pichu_1,
+ .descriptionPage2 = DexDescription_Pichu_2,
+ .pokemonScale = 508,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Cleffa
+ .categoryName = _("STAR SHAPE"),
+ .height = 3,
+ .weight = 30,
+ .descriptionPage1 = DexDescription_Cleffa_1,
+ .descriptionPage2 = DexDescription_Cleffa_2,
+ .pokemonScale = 462,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Igglybuff
+ .categoryName = _("BALLOON"),
+ .height = 3,
+ .weight = 10,
+ .descriptionPage1 = DexDescription_Igglybuff_1,
+ .descriptionPage2 = DexDescription_Igglybuff_2,
+ .pokemonScale = 457,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Togepi
+ .categoryName = _("SPIKE BALL"),
+ .height = 3,
+ .weight = 15,
+ .descriptionPage1 = DexDescription_Togepi_1,
+ .descriptionPage2 = DexDescription_Togepi_2,
+ .pokemonScale = 507,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Togetic
+ .categoryName = _("HAPPINESS"),
+ .height = 6,
+ .weight = 32,
+ .descriptionPage1 = DexDescription_Togetic_1,
+ .descriptionPage2 = DexDescription_Togetic_2,
+ .pokemonScale = 424,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Natu
+ .categoryName = _("TINY BIRD"),
+ .height = 2,
+ .weight = 20,
+ .descriptionPage1 = DexDescription_Natu_1,
+ .descriptionPage2 = DexDescription_Natu_2,
+ .pokemonScale = 610,
+ .pokemonOffset = 25,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Xatu
+ .categoryName = _("MYSTIC"),
+ .height = 15,
+ .weight = 150,
+ .descriptionPage1 = DexDescription_Xatu_1,
+ .descriptionPage2 = DexDescription_Xatu_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 318,
+ .trainerOffset = 4,
+ },
+ { //Mareep
+ .categoryName = _("WOOL"),
+ .height = 6,
+ .weight = 78,
+ .descriptionPage1 = DexDescription_Mareep_1,
+ .descriptionPage2 = DexDescription_Mareep_2,
+ .pokemonScale = 379,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Flaaffy
+ .categoryName = _("WOOL"),
+ .height = 8,
+ .weight = 133,
+ .descriptionPage1 = DexDescription_Flaaffy_1,
+ .descriptionPage2 = DexDescription_Flaaffy_2,
+ .pokemonScale = 372,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ampharos
+ .categoryName = _("LIGHT"),
+ .height = 14,
+ .weight = 615,
+ .descriptionPage1 = DexDescription_Ampharos_1,
+ .descriptionPage2 = DexDescription_Ampharos_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Bellossom
+ .categoryName = _("FLOWER"),
+ .height = 4,
+ .weight = 58,
+ .descriptionPage1 = DexDescription_Bellossom_1,
+ .descriptionPage2 = DexDescription_Bellossom_2,
+ .pokemonScale = 472,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Marill
+ .categoryName = _("AQUA MOUSE"),
+ .height = 4,
+ .weight = 85,
+ .descriptionPage1 = DexDescription_Marill_1,
+ .descriptionPage2 = DexDescription_Marill_2,
+ .pokemonScale = 476,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Azumarill
+ .categoryName = _("AQUA RABBIT"),
+ .height = 8,
+ .weight = 285,
+ .descriptionPage1 = DexDescription_Azumarill_1,
+ .descriptionPage2 = DexDescription_Azumarill_2,
+ .pokemonScale = 448,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sudowoodo
+ .categoryName = _("IMITATION"),
+ .height = 12,
+ .weight = 380,
+ .descriptionPage1 = DexDescription_Sudowoodo_1,
+ .descriptionPage2 = DexDescription_Sudowoodo_2,
+ .pokemonScale = 305,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Politoed
+ .categoryName = _("FROG"),
+ .height = 11,
+ .weight = 339,
+ .descriptionPage1 = DexDescription_Politoed_1,
+ .descriptionPage2 = DexDescription_Politoed_2,
+ .pokemonScale = 289,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hoppip
+ .categoryName = _("COTTONWEED"),
+ .height = 4,
+ .weight = 5,
+ .descriptionPage1 = DexDescription_Hoppip_1,
+ .descriptionPage2 = DexDescription_Hoppip_2,
+ .pokemonScale = 562,
+ .pokemonOffset = -7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Skiploom
+ .categoryName = _("COTTONWEED"),
+ .height = 6,
+ .weight = 10,
+ .descriptionPage1 = DexDescription_Skiploom_1,
+ .descriptionPage2 = DexDescription_Skiploom_2,
+ .pokemonScale = 387,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Jumpluff
+ .categoryName = _("COTTONWEED"),
+ .height = 8,
+ .weight = 30,
+ .descriptionPage1 = DexDescription_Jumpluff_1,
+ .descriptionPage2 = DexDescription_Jumpluff_2,
+ .pokemonScale = 418,
+ .pokemonOffset = -4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Aipom
+ .categoryName = _("LONG TAIL"),
+ .height = 8,
+ .weight = 115,
+ .descriptionPage1 = DexDescription_Aipom_1,
+ .descriptionPage2 = DexDescription_Aipom_2,
+ .pokemonScale = 363,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sunkern
+ .categoryName = _("SEED"),
+ .height = 3,
+ .weight = 18,
+ .descriptionPage1 = DexDescription_Sunkern_1,
+ .descriptionPage2 = DexDescription_Sunkern_2,
+ .pokemonScale = 541,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sunflora
+ .categoryName = _("SUN"),
+ .height = 8,
+ .weight = 85,
+ .descriptionPage1 = DexDescription_Sunflora_1,
+ .descriptionPage2 = DexDescription_Sunflora_2,
+ .pokemonScale = 444,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Yanma
+ .categoryName = _("CLEAR WING"),
+ .height = 12,
+ .weight = 380,
+ .descriptionPage1 = DexDescription_Yanma_1,
+ .descriptionPage2 = DexDescription_Yanma_2,
+ .pokemonScale = 274,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wooper
+ .categoryName = _("WATER FISH"),
+ .height = 4,
+ .weight = 85,
+ .descriptionPage1 = DexDescription_Wooper_1,
+ .descriptionPage2 = DexDescription_Wooper_2,
+ .pokemonScale = 479,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Quagsire
+ .categoryName = _("WATER FISH"),
+ .height = 14,
+ .weight = 750,
+ .descriptionPage1 = DexDescription_Quagsire_1,
+ .descriptionPage2 = DexDescription_Quagsire_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Espeon
+ .categoryName = _("SUN"),
+ .height = 9,
+ .weight = 265,
+ .descriptionPage1 = DexDescription_Espeon_1,
+ .descriptionPage2 = DexDescription_Espeon_2,
+ .pokemonScale = 363,
+ .pokemonOffset = 14,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Umbreon
+ .categoryName = _("MOONLIGHT"),
+ .height = 10,
+ .weight = 270,
+ .descriptionPage1 = DexDescription_Umbreon_1,
+ .descriptionPage2 = DexDescription_Umbreon_2,
+ .pokemonScale = 317,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Murkrow
+ .categoryName = _("DARKNESS"),
+ .height = 5,
+ .weight = 21,
+ .descriptionPage1 = DexDescription_Murkrow_1,
+ .descriptionPage2 = DexDescription_Murkrow_2,
+ .pokemonScale = 401,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 1,
+ },
+ { //Slowking
+ .categoryName = _("ROYAL"),
+ .height = 20,
+ .weight = 795,
+ .descriptionPage1 = DexDescription_Slowking_1,
+ .descriptionPage2 = DexDescription_Slowking_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 309,
+ .trainerOffset = 5,
+ },
+ { //Misdreavus
+ .categoryName = _("SCREECH"),
+ .height = 7,
+ .weight = 10,
+ .descriptionPage1 = DexDescription_Misdreavus_1,
+ .descriptionPage2 = DexDescription_Misdreavus_2,
+ .pokemonScale = 407,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Unown
+ .categoryName = _("SYMBOL"),
+ .height = 5,
+ .weight = 50,
+ .descriptionPage1 = DexDescription_Unown_1,
+ .descriptionPage2 = DexDescription_Unown_2,
+ .pokemonScale = 411,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wobbuffet
+ .categoryName = _("PATIENT"),
+ .height = 13,
+ .weight = 285,
+ .descriptionPage1 = DexDescription_Wobbuffet_1,
+ .descriptionPage2 = DexDescription_Wobbuffet_2,
+ .pokemonScale = 274,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Girafarig
+ .categoryName = _("LONG NECK"),
+ .height = 15,
+ .weight = 415,
+ .descriptionPage1 = DexDescription_Girafarig_1,
+ .descriptionPage2 = DexDescription_Girafarig_2,
+ .pokemonScale = 281,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pineco
+ .categoryName = _("BAGWORM"),
+ .height = 6,
+ .weight = 72,
+ .descriptionPage1 = DexDescription_Pineco_1,
+ .descriptionPage2 = DexDescription_Pineco_2,
+ .pokemonScale = 445,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Forretress
+ .categoryName = _("BAGWORM"),
+ .height = 12,
+ .weight = 1258,
+ .descriptionPage1 = DexDescription_Forretress_1,
+ .descriptionPage2 = DexDescription_Forretress_2,
+ .pokemonScale = 293,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Dunsparce
+ .categoryName = _("LAND SNAKE"),
+ .height = 15,
+ .weight = 140,
+ .descriptionPage1 = DexDescription_Dunsparce_1,
+ .descriptionPage2 = DexDescription_Dunsparce_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gligar
+ .categoryName = _("FLYSCORPION"),
+ .height = 11,
+ .weight = 648,
+ .descriptionPage1 = DexDescription_Gligar_1,
+ .descriptionPage2 = DexDescription_Gligar_2,
+ .pokemonScale = 350,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Steelix
+ .categoryName = _("IRON SNAKE"),
+ .height = 92,
+ .weight = 4000,
+ .descriptionPage1 = DexDescription_Steelix_1,
+ .descriptionPage2 = DexDescription_Steelix_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 516,
+ .trainerOffset = 13,
+ },
+ { //Snubbull
+ .categoryName = _("FAIRY"),
+ .height = 6,
+ .weight = 78,
+ .descriptionPage1 = DexDescription_Snubbull_1,
+ .descriptionPage2 = DexDescription_Snubbull_2,
+ .pokemonScale = 465,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Granbull
+ .categoryName = _("FAIRY"),
+ .height = 14,
+ .weight = 487,
+ .descriptionPage1 = DexDescription_Granbull_1,
+ .descriptionPage2 = DexDescription_Granbull_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Qwilfish
+ .categoryName = _("BALLOON"),
+ .height = 5,
+ .weight = 39,
+ .descriptionPage1 = DexDescription_Qwilfish_1,
+ .descriptionPage2 = DexDescription_Qwilfish_2,
+ .pokemonScale = 430,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Scizor
+ .categoryName = _("PINCER"),
+ .height = 18,
+ .weight = 1180,
+ .descriptionPage1 = DexDescription_Scizor_1,
+ .descriptionPage2 = DexDescription_Scizor_2,
+ .pokemonScale = 278,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shuckle
+ .categoryName = _("MOLD"),
+ .height = 6,
+ .weight = 205,
+ .descriptionPage1 = DexDescription_Shuckle_1,
+ .descriptionPage2 = DexDescription_Shuckle_2,
+ .pokemonScale = 485,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Heracross
+ .categoryName = _("SINGLE HORN"),
+ .height = 15,
+ .weight = 540,
+ .descriptionPage1 = DexDescription_Heracross_1,
+ .descriptionPage2 = DexDescription_Heracross_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sneasel
+ .categoryName = _("SHARP CLAW"),
+ .height = 9,
+ .weight = 280,
+ .descriptionPage1 = DexDescription_Sneasel_1,
+ .descriptionPage2 = DexDescription_Sneasel_2,
+ .pokemonScale = 413,
+ .pokemonOffset = -3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Teddiursa
+ .categoryName = _("LITTLE BEAR"),
+ .height = 6,
+ .weight = 88,
+ .descriptionPage1 = DexDescription_Teddiursa_1,
+ .descriptionPage2 = DexDescription_Teddiursa_2,
+ .pokemonScale = 455,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ursaring
+ .categoryName = _("HIBERNATOR"),
+ .height = 18,
+ .weight = 1258,
+ .descriptionPage1 = DexDescription_Ursaring_1,
+ .descriptionPage2 = DexDescription_Ursaring_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Slugma
+ .categoryName = _("LAVA"),
+ .height = 7,
+ .weight = 350,
+ .descriptionPage1 = DexDescription_Slugma_1,
+ .descriptionPage2 = DexDescription_Slugma_2,
+ .pokemonScale = 329,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Magcargo
+ .categoryName = _("LAVA"),
+ .height = 8,
+ .weight = 550,
+ .descriptionPage1 = DexDescription_Magcargo_1,
+ .descriptionPage2 = DexDescription_Magcargo_2,
+ .pokemonScale = 332,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Swinub
+ .categoryName = _("PIG"),
+ .height = 4,
+ .weight = 65,
+ .descriptionPage1 = DexDescription_Swinub_1,
+ .descriptionPage2 = DexDescription_Swinub_2,
+ .pokemonScale = 324,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Piloswine
+ .categoryName = _("SWINE"),
+ .height = 11,
+ .weight = 558,
+ .descriptionPage1 = DexDescription_Piloswine_1,
+ .descriptionPage2 = DexDescription_Piloswine_2,
+ .pokemonScale = 306,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Corsola
+ .categoryName = _("CORAL"),
+ .height = 6,
+ .weight = 50,
+ .descriptionPage1 = DexDescription_Corsola_1,
+ .descriptionPage2 = DexDescription_Corsola_2,
+ .pokemonScale = 410,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Remoraid
+ .categoryName = _("JET"),
+ .height = 6,
+ .weight = 120,
+ .descriptionPage1 = DexDescription_Remoraid_1,
+ .descriptionPage2 = DexDescription_Remoraid_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Octillery
+ .categoryName = _("JET"),
+ .height = 9,
+ .weight = 285,
+ .descriptionPage1 = DexDescription_Octillery_1,
+ .descriptionPage2 = DexDescription_Octillery_2,
+ .pokemonScale = 296,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Delibird
+ .categoryName = _("DELIVERY"),
+ .height = 9,
+ .weight = 160,
+ .descriptionPage1 = DexDescription_Delibird_1,
+ .descriptionPage2 = DexDescription_Delibird_2,
+ .pokemonScale = 293,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Mantine
+ .categoryName = _("KITE"),
+ .height = 21,
+ .weight = 2200,
+ .descriptionPage1 = DexDescription_Mantine_1,
+ .descriptionPage2 = DexDescription_Mantine_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 342,
+ .trainerOffset = 7,
+ },
+ { //Skarmory
+ .categoryName = _("ARMOR BIRD"),
+ .height = 17,
+ .weight = 505,
+ .descriptionPage1 = DexDescription_Skarmory_1,
+ .descriptionPage2 = DexDescription_Skarmory_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 271,
+ .trainerOffset = 1,
+ },
+ { //Houndour
+ .categoryName = _("DARK"),
+ .height = 6,
+ .weight = 108,
+ .descriptionPage1 = DexDescription_Houndour_1,
+ .descriptionPage2 = DexDescription_Houndour_2,
+ .pokemonScale = 393,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Houndoom
+ .categoryName = _("DARK"),
+ .height = 14,
+ .weight = 350,
+ .descriptionPage1 = DexDescription_Houndoom_1,
+ .descriptionPage2 = DexDescription_Houndoom_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kingdra
+ .categoryName = _("DRAGON"),
+ .height = 18,
+ .weight = 1520,
+ .descriptionPage1 = DexDescription_Kingdra_1,
+ .descriptionPage2 = DexDescription_Kingdra_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 287,
+ .trainerOffset = 0,
+ },
+ { //Phanpy
+ .categoryName = _("LONG NOSE"),
+ .height = 5,
+ .weight = 335,
+ .descriptionPage1 = DexDescription_Phanpy_1,
+ .descriptionPage2 = DexDescription_Phanpy_2,
+ .pokemonScale = 465,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Donphan
+ .categoryName = _("ARMOR"),
+ .height = 11,
+ .weight = 1200,
+ .descriptionPage1 = DexDescription_Donphan_1,
+ .descriptionPage2 = DexDescription_Donphan_2,
+ .pokemonScale = 313,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Porygon2
+ .categoryName = _("VIRTUAL"),
+ .height = 6,
+ .weight = 325,
+ .descriptionPage1 = DexDescription_Porygon2_1,
+ .descriptionPage2 = DexDescription_Porygon2_2,
+ .pokemonScale = 320,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Stantler
+ .categoryName = _("BIG HORN"),
+ .height = 14,
+ .weight = 712,
+ .descriptionPage1 = DexDescription_Stantler_1,
+ .descriptionPage2 = DexDescription_Stantler_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Smeargle
+ .categoryName = _("PAINTER"),
+ .height = 12,
+ .weight = 580,
+ .descriptionPage1 = DexDescription_Smeargle_1,
+ .descriptionPage2 = DexDescription_Smeargle_2,
+ .pokemonScale = 287,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Tyrogue
+ .categoryName = _("SCUFFLE"),
+ .height = 7,
+ .weight = 210,
+ .descriptionPage1 = DexDescription_Tyrogue_1,
+ .descriptionPage2 = DexDescription_Tyrogue_2,
+ .pokemonScale = 292,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hitmontop
+ .categoryName = _("HANDSTAND"),
+ .height = 14,
+ .weight = 480,
+ .descriptionPage1 = DexDescription_Hitmontop_1,
+ .descriptionPage2 = DexDescription_Hitmontop_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 257,
+ .trainerOffset = 0,
+ },
+ { //Smoochum
+ .categoryName = _("KISS"),
+ .height = 4,
+ .weight = 60,
+ .descriptionPage1 = DexDescription_Smoochum_1,
+ .descriptionPage2 = DexDescription_Smoochum_2,
+ .pokemonScale = 440,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Elekid
+ .categoryName = _("ELECTRIC"),
+ .height = 6,
+ .weight = 235,
+ .descriptionPage1 = DexDescription_Elekid_1,
+ .descriptionPage2 = DexDescription_Elekid_2,
+ .pokemonScale = 363,
+ .pokemonOffset = 14,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Magby
+ .categoryName = _("LIVE COAL"),
+ .height = 7,
+ .weight = 214,
+ .descriptionPage1 = DexDescription_Magby_1,
+ .descriptionPage2 = DexDescription_Magby_2,
+ .pokemonScale = 284,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Miltank
+ .categoryName = _("MILK COW"),
+ .height = 12,
+ .weight = 755,
+ .descriptionPage1 = DexDescription_Miltank_1,
+ .descriptionPage2 = DexDescription_Miltank_2,
+ .pokemonScale = 280,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Blissey
+ .categoryName = _("HAPPINESS"),
+ .height = 15,
+ .weight = 468,
+ .descriptionPage1 = DexDescription_Blissey_1,
+ .descriptionPage2 = DexDescription_Blissey_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 310,
+ .trainerOffset = 3,
+ },
+ { //Raikou
+ .categoryName = _("THUNDER"),
+ .height = 19,
+ .weight = 1780,
+ .descriptionPage1 = DexDescription_Raikou_1,
+ .descriptionPage2 = DexDescription_Raikou_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 345,
+ .trainerOffset = 7,
+ },
+ { //Entei
+ .categoryName = _("VOLCANO"),
+ .height = 21,
+ .weight = 1980,
+ .descriptionPage1 = DexDescription_Entei_1,
+ .descriptionPage2 = DexDescription_Entei_2,
+ .pokemonScale = 259,
+ .pokemonOffset = 0,
+ .trainerScale = 345,
+ .trainerOffset = 7,
+ },
+ { //Suicune
+ .categoryName = _("AURORA"),
+ .height = 20,
+ .weight = 1870,
+ .descriptionPage1 = DexDescription_Suicune_1,
+ .descriptionPage2 = DexDescription_Suicune_2,
+ .pokemonScale = 269,
+ .pokemonOffset = 0,
+ .trainerScale = 345,
+ .trainerOffset = 7,
+ },
+ { //Larvitar
+ .categoryName = _("ROCK SKIN"),
+ .height = 6,
+ .weight = 720,
+ .descriptionPage1 = DexDescription_Larvitar_1,
+ .descriptionPage2 = DexDescription_Larvitar_2,
+ .pokemonScale = 472,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pupitar
+ .categoryName = _("HARD SHELL"),
+ .height = 12,
+ .weight = 1520,
+ .descriptionPage1 = DexDescription_Pupitar_1,
+ .descriptionPage2 = DexDescription_Pupitar_2,
+ .pokemonScale = 292,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Tyranitar
+ .categoryName = _("ARMOR"),
+ .height = 20,
+ .weight = 2020,
+ .descriptionPage1 = DexDescription_Tyranitar_1,
+ .descriptionPage2 = DexDescription_Tyranitar_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 345,
+ .trainerOffset = 7,
+ },
+ { //Lugia
+ .categoryName = _("DIVING"),
+ .height = 52,
+ .weight = 2160,
+ .descriptionPage1 = DexDescription_Lugia_1,
+ .descriptionPage2 = DexDescription_Lugia_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 721,
+ .trainerOffset = 19,
+ },
+ { //HoOh
+ .categoryName = _("RAINBOW"),
+ .height = 38,
+ .weight = 1990,
+ .descriptionPage1 = DexDescription_HoOh_1,
+ .descriptionPage2 = DexDescription_HoOh_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 610,
+ .trainerOffset = 17,
+ },
+ { //Celebi
+ .categoryName = _("TIME TRAVEL"),
+ .height = 6,
+ .weight = 50,
+ .descriptionPage1 = DexDescription_Celebi_1,
+ .descriptionPage2 = DexDescription_Celebi_2,
+ .pokemonScale = 393,
+ .pokemonOffset = -10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Treecko
+ .categoryName = _("WOOD GECKO"),
+ .height = 5,
+ .weight = 50,
+ .descriptionPage1 = DexDescription_Treecko_1,
+ .descriptionPage2 = DexDescription_Treecko_2,
+ .pokemonScale = 541,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Grovyle
+ .categoryName = _("WOOD GECKO"),
+ .height = 9,
+ .weight = 216,
+ .descriptionPage1 = DexDescription_Grovyle_1,
+ .descriptionPage2 = DexDescription_Grovyle_2,
+ .pokemonScale = 360,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sceptile
+ .categoryName = _("FOREST"),
+ .height = 17,
+ .weight = 522,
+ .descriptionPage1 = DexDescription_Sceptile_1,
+ .descriptionPage2 = DexDescription_Sceptile_2,
+ .pokemonScale = 256,
+ .pokemonOffset = -1,
+ .trainerScale = 275,
+ .trainerOffset = 2,
+ },
+ { //Torchic
+ .categoryName = _("CHICK"),
+ .height = 4,
+ .weight = 25,
+ .descriptionPage1 = DexDescription_Torchic_1,
+ .descriptionPage2 = DexDescription_Torchic_2,
+ .pokemonScale = 566,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Combusken
+ .categoryName = _("YOUNG FOWL"),
+ .height = 9,
+ .weight = 195,
+ .descriptionPage1 = DexDescription_Combusken_1,
+ .descriptionPage2 = DexDescription_Combusken_2,
+ .pokemonScale = 343,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Blaziken
+ .categoryName = _("BLAZE"),
+ .height = 19,
+ .weight = 520,
+ .descriptionPage1 = DexDescription_Blaziken_1,
+ .descriptionPage2 = DexDescription_Blaziken_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 301,
+ .trainerOffset = 4,
+ },
+ { //Mudkip
+ .categoryName = _("MUD FISH"),
+ .height = 4,
+ .weight = 76,
+ .descriptionPage1 = DexDescription_Mudkip_1,
+ .descriptionPage2 = DexDescription_Mudkip_2,
+ .pokemonScale = 535,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Marshtomp
+ .categoryName = _("MUD FISH"),
+ .height = 7,
+ .weight = 280,
+ .descriptionPage1 = DexDescription_Marshtomp_1,
+ .descriptionPage2 = DexDescription_Marshtomp_2,
+ .pokemonScale = 340,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Swampert
+ .categoryName = _("MUD FISH"),
+ .height = 15,
+ .weight = 819,
+ .descriptionPage1 = DexDescription_Swampert_1,
+ .descriptionPage2 = DexDescription_Swampert_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Poochyena
+ .categoryName = _("BITE"),
+ .height = 5,
+ .weight = 136,
+ .descriptionPage1 = DexDescription_Poochyena_1,
+ .descriptionPage2 = DexDescription_Poochyena_2,
+ .pokemonScale = 481,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Mightyena
+ .categoryName = _("BITE"),
+ .height = 10,
+ .weight = 370,
+ .descriptionPage1 = DexDescription_Mightyena_1,
+ .descriptionPage2 = DexDescription_Mightyena_2,
+ .pokemonScale = 362,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Zigzagoon
+ .categoryName = _("TINYRACCOON"),
+ .height = 4,
+ .weight = 175,
+ .descriptionPage1 = DexDescription_Zigzagoon_1,
+ .descriptionPage2 = DexDescription_Zigzagoon_2,
+ .pokemonScale = 560,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Linoone
+ .categoryName = _("RUSHING"),
+ .height = 5,
+ .weight = 325,
+ .descriptionPage1 = DexDescription_Linoone_1,
+ .descriptionPage2 = DexDescription_Linoone_2,
+ .pokemonScale = 321,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wurmple
+ .categoryName = _("WORM"),
+ .height = 3,
+ .weight = 36,
+ .descriptionPage1 = DexDescription_Wurmple_1,
+ .descriptionPage2 = DexDescription_Wurmple_2,
+ .pokemonScale = 711,
+ .pokemonOffset = 24,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Silcoon
+ .categoryName = _("COCOON"),
+ .height = 6,
+ .weight = 100,
+ .descriptionPage1 = DexDescription_Silcoon_1,
+ .descriptionPage2 = DexDescription_Silcoon_2,
+ .pokemonScale = 431,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Beautifly
+ .categoryName = _("BUTTERFLY"),
+ .height = 10,
+ .weight = 284,
+ .descriptionPage1 = DexDescription_Beautifly_1,
+ .descriptionPage2 = DexDescription_Beautifly_2,
+ .pokemonScale = 298,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Cascoon
+ .categoryName = _("COCOON"),
+ .height = 7,
+ .weight = 115,
+ .descriptionPage1 = DexDescription_Cascoon_1,
+ .descriptionPage2 = DexDescription_Cascoon_2,
+ .pokemonScale = 391,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Dustox
+ .categoryName = _("POISON MOTH"),
+ .height = 12,
+ .weight = 316,
+ .descriptionPage1 = DexDescription_Dustox_1,
+ .descriptionPage2 = DexDescription_Dustox_2,
+ .pokemonScale = 269,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Lotad
+ .categoryName = _("WATER WEED"),
+ .height = 5,
+ .weight = 26,
+ .descriptionPage1 = DexDescription_Lotad_1,
+ .descriptionPage2 = DexDescription_Lotad_2,
+ .pokemonScale = 406,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Lombre
+ .categoryName = _("JOLLY"),
+ .height = 12,
+ .weight = 325,
+ .descriptionPage1 = DexDescription_Lombre_1,
+ .descriptionPage2 = DexDescription_Lombre_2,
+ .pokemonScale = 277,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ludicolo
+ .categoryName = _("CAREFREE"),
+ .height = 15,
+ .weight = 550,
+ .descriptionPage1 = DexDescription_Ludicolo_1,
+ .descriptionPage2 = DexDescription_Ludicolo_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 268,
+ .trainerOffset = -1,
+ },
+ { //Seedot
+ .categoryName = _("ACORN"),
+ .height = 5,
+ .weight = 40,
+ .descriptionPage1 = DexDescription_Seedot_1,
+ .descriptionPage2 = DexDescription_Seedot_2,
+ .pokemonScale = 472,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nuzleaf
+ .categoryName = _("WILY"),
+ .height = 10,
+ .weight = 280,
+ .descriptionPage1 = DexDescription_Nuzleaf_1,
+ .descriptionPage2 = DexDescription_Nuzleaf_2,
+ .pokemonScale = 299,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shiftry
+ .categoryName = _("WICKED"),
+ .height = 13,
+ .weight = 596,
+ .descriptionPage1 = DexDescription_Shiftry_1,
+ .descriptionPage2 = DexDescription_Shiftry_2,
+ .pokemonScale = 290,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Taillow
+ .categoryName = _("TINYSWALLOW"),
+ .height = 3,
+ .weight = 23,
+ .descriptionPage1 = DexDescription_Taillow_1,
+ .descriptionPage2 = DexDescription_Taillow_2,
+ .pokemonScale = 465,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Swellow
+ .categoryName = _("SWALLOW"),
+ .height = 7,
+ .weight = 198,
+ .descriptionPage1 = DexDescription_Swellow_1,
+ .descriptionPage2 = DexDescription_Swellow_2,
+ .pokemonScale = 428,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wingull
+ .categoryName = _("SEAGULL"),
+ .height = 6,
+ .weight = 95,
+ .descriptionPage1 = DexDescription_Wingull_1,
+ .descriptionPage2 = DexDescription_Wingull_2,
+ .pokemonScale = 295,
+ .pokemonOffset = -2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Pelipper
+ .categoryName = _("WATER BIRD"),
+ .height = 12,
+ .weight = 280,
+ .descriptionPage1 = DexDescription_Pelipper_1,
+ .descriptionPage2 = DexDescription_Pelipper_2,
+ .pokemonScale = 288,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ralts
+ .categoryName = _("FEELING"),
+ .height = 4,
+ .weight = 66,
+ .descriptionPage1 = DexDescription_Ralts_1,
+ .descriptionPage2 = DexDescription_Ralts_2,
+ .pokemonScale = 457,
+ .pokemonOffset = -3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kirlia
+ .categoryName = _("EMOTION"),
+ .height = 8,
+ .weight = 202,
+ .descriptionPage1 = DexDescription_Kirlia_1,
+ .descriptionPage2 = DexDescription_Kirlia_2,
+ .pokemonScale = 354,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gardevoir
+ .categoryName = _("EMBRACE"),
+ .height = 16,
+ .weight = 484,
+ .descriptionPage1 = DexDescription_Gardevoir_1,
+ .descriptionPage2 = DexDescription_Gardevoir_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Surskit
+ .categoryName = _("POND SKATER"),
+ .height = 5,
+ .weight = 17,
+ .descriptionPage1 = DexDescription_Surskit_1,
+ .descriptionPage2 = DexDescription_Surskit_2,
+ .pokemonScale = 375,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Masquerain
+ .categoryName = _("EYEBALL"),
+ .height = 8,
+ .weight = 36,
+ .descriptionPage1 = DexDescription_Masquerain_1,
+ .descriptionPage2 = DexDescription_Masquerain_2,
+ .pokemonScale = 378,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shroomish
+ .categoryName = _("MUSHROOM"),
+ .height = 4,
+ .weight = 45,
+ .descriptionPage1 = DexDescription_Shroomish_1,
+ .descriptionPage2 = DexDescription_Shroomish_2,
+ .pokemonScale = 513,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Breloom
+ .categoryName = _("MUSHROOM"),
+ .height = 12,
+ .weight = 392,
+ .descriptionPage1 = DexDescription_Breloom_1,
+ .descriptionPage2 = DexDescription_Breloom_2,
+ .pokemonScale = 324,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Slakoth
+ .categoryName = _("SLACKER"),
+ .height = 8,
+ .weight = 240,
+ .descriptionPage1 = DexDescription_Slakoth_1,
+ .descriptionPage2 = DexDescription_Slakoth_2,
+ .pokemonScale = 291,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Vigoroth
+ .categoryName = _("WILD MONKEY"),
+ .height = 14,
+ .weight = 465,
+ .descriptionPage1 = DexDescription_Vigoroth_1,
+ .descriptionPage2 = DexDescription_Vigoroth_2,
+ .pokemonScale = 301,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Slaking
+ .categoryName = _("LAZY"),
+ .height = 20,
+ .weight = 1305,
+ .descriptionPage1 = DexDescription_Slaking_1,
+ .descriptionPage2 = DexDescription_Slaking_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 300,
+ .trainerOffset = 1,
+ },
+ { //Nincada
+ .categoryName = _("TRAINEE"),
+ .height = 5,
+ .weight = 55,
+ .descriptionPage1 = DexDescription_Nincada_1,
+ .descriptionPage2 = DexDescription_Nincada_2,
+ .pokemonScale = 405,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Ninjask
+ .categoryName = _("NINJA"),
+ .height = 8,
+ .weight = 120,
+ .descriptionPage1 = DexDescription_Ninjask_1,
+ .descriptionPage2 = DexDescription_Ninjask_2,
+ .pokemonScale = 383,
+ .pokemonOffset = -9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shedinja
+ .categoryName = _("SHED"),
+ .height = 8,
+ .weight = 12,
+ .descriptionPage1 = DexDescription_Shedinja_1,
+ .descriptionPage2 = DexDescription_Shedinja_2,
+ .pokemonScale = 372,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Whismur
+ .categoryName = _("WHISPER"),
+ .height = 6,
+ .weight = 163,
+ .descriptionPage1 = DexDescription_Whismur_1,
+ .descriptionPage2 = DexDescription_Whismur_2,
+ .pokemonScale = 373,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Loudred
+ .categoryName = _("BIG VOICE"),
+ .height = 10,
+ .weight = 405,
+ .descriptionPage1 = DexDescription_Loudred_1,
+ .descriptionPage2 = DexDescription_Loudred_2,
+ .pokemonScale = 356,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Exploud
+ .categoryName = _("LOUD NOISE"),
+ .height = 15,
+ .weight = 840,
+ .descriptionPage1 = DexDescription_Exploud_1,
+ .descriptionPage2 = DexDescription_Exploud_2,
+ .pokemonScale = 284,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Makuhita
+ .categoryName = _("GUTS"),
+ .height = 10,
+ .weight = 864,
+ .descriptionPage1 = DexDescription_Makuhita_1,
+ .descriptionPage2 = DexDescription_Makuhita_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Hariyama
+ .categoryName = _("ARM THRUST"),
+ .height = 23,
+ .weight = 2538,
+ .descriptionPage1 = DexDescription_Hariyama_1,
+ .descriptionPage2 = DexDescription_Hariyama_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 343,
+ .trainerOffset = 7,
+ },
+ { //Azurill
+ .categoryName = _("POLKA DOT"),
+ .height = 2,
+ .weight = 20,
+ .descriptionPage1 = DexDescription_Azurill_1,
+ .descriptionPage2 = DexDescription_Azurill_2,
+ .pokemonScale = 603,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Nosepass
+ .categoryName = _("COMPASS"),
+ .height = 10,
+ .weight = 970,
+ .descriptionPage1 = DexDescription_Nosepass_1,
+ .descriptionPage2 = DexDescription_Nosepass_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 9,
+ .trainerScale = 289,
+ .trainerOffset = 3,
+ },
+ { //Skitty
+ .categoryName = _("KITTEN"),
+ .height = 6,
+ .weight = 110,
+ .descriptionPage1 = DexDescription_Skitty_1,
+ .descriptionPage2 = DexDescription_Skitty_2,
+ .pokemonScale = 492,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Delcatty
+ .categoryName = _("PRIM"),
+ .height = 11,
+ .weight = 326,
+ .descriptionPage1 = DexDescription_Delcatty_1,
+ .descriptionPage2 = DexDescription_Delcatty_2,
+ .pokemonScale = 322,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sableye
+ .categoryName = _("DARKNESS"),
+ .height = 5,
+ .weight = 110,
+ .descriptionPage1 = DexDescription_Sableye_1,
+ .descriptionPage2 = DexDescription_Sableye_2,
+ .pokemonScale = 451,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Mawile
+ .categoryName = _("DECEIVER"),
+ .height = 6,
+ .weight = 115,
+ .descriptionPage1 = DexDescription_Mawile_1,
+ .descriptionPage2 = DexDescription_Mawile_2,
+ .pokemonScale = 466,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Aron
+ .categoryName = _("IRON ARMOR"),
+ .height = 4,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Aron_1,
+ .descriptionPage2 = DexDescription_Aron_2,
+ .pokemonScale = 419,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Lairon
+ .categoryName = _("IRON ARMOR"),
+ .height = 9,
+ .weight = 1200,
+ .descriptionPage1 = DexDescription_Lairon_1,
+ .descriptionPage2 = DexDescription_Lairon_2,
+ .pokemonScale = 275,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Aggron
+ .categoryName = _("IRON ARMOR"),
+ .height = 21,
+ .weight = 3600,
+ .descriptionPage1 = DexDescription_Aggron_1,
+ .descriptionPage2 = DexDescription_Aggron_2,
+ .pokemonScale = 256,
+ .pokemonOffset = -1,
+ .trainerScale = 350,
+ .trainerOffset = 6,
+ },
+ { //Meditite
+ .categoryName = _("MEDITATE"),
+ .height = 6,
+ .weight = 112,
+ .descriptionPage1 = DexDescription_Meditite_1,
+ .descriptionPage2 = DexDescription_Meditite_2,
+ .pokemonScale = 465,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Medicham
+ .categoryName = _("MEDITATE"),
+ .height = 13,
+ .weight = 315,
+ .descriptionPage1 = DexDescription_Medicham_1,
+ .descriptionPage2 = DexDescription_Medicham_2,
+ .pokemonScale = 298,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Electrike
+ .categoryName = _("LIGHTNING"),
+ .height = 6,
+ .weight = 152,
+ .descriptionPage1 = DexDescription_Electrike_1,
+ .descriptionPage2 = DexDescription_Electrike_2,
+ .pokemonScale = 290,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Manectric
+ .categoryName = _("DISCHARGE"),
+ .height = 15,
+ .weight = 402,
+ .descriptionPage1 = DexDescription_Manectric_1,
+ .descriptionPage2 = DexDescription_Manectric_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 257,
+ .trainerOffset = 0,
+ },
+ { //Plusle
+ .categoryName = _("CHEERING"),
+ .height = 4,
+ .weight = 42,
+ .descriptionPage1 = DexDescription_Plusle_1,
+ .descriptionPage2 = DexDescription_Plusle_2,
+ .pokemonScale = 515,
+ .pokemonOffset = -9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Minun
+ .categoryName = _("CHEERING"),
+ .height = 4,
+ .weight = 42,
+ .descriptionPage1 = DexDescription_Minun_1,
+ .descriptionPage2 = DexDescription_Minun_2,
+ .pokemonScale = 512,
+ .pokemonOffset = -7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Volbeat
+ .categoryName = _("FIREFLY"),
+ .height = 7,
+ .weight = 177,
+ .descriptionPage1 = DexDescription_Volbeat_1,
+ .descriptionPage2 = DexDescription_Volbeat_2,
+ .pokemonScale = 442,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Illumise
+ .categoryName = _("FIREFLY"),
+ .height = 6,
+ .weight = 177,
+ .descriptionPage1 = DexDescription_Illumise_1,
+ .descriptionPage2 = DexDescription_Illumise_2,
+ .pokemonScale = 572,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Roselia
+ .categoryName = _("THORN"),
+ .height = 3,
+ .weight = 20,
+ .descriptionPage1 = DexDescription_Roselia_1,
+ .descriptionPage2 = DexDescription_Roselia_2,
+ .pokemonScale = 677,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gulpin
+ .categoryName = _("STOMACH"),
+ .height = 4,
+ .weight = 103,
+ .descriptionPage1 = DexDescription_Gulpin_1,
+ .descriptionPage2 = DexDescription_Gulpin_2,
+ .pokemonScale = 593,
+ .pokemonOffset = 23,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Swalot
+ .categoryName = _("POISON BAG"),
+ .height = 17,
+ .weight = 800,
+ .descriptionPage1 = DexDescription_Swalot_1,
+ .descriptionPage2 = DexDescription_Swalot_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 345,
+ .trainerOffset = 3,
+ },
+ { //Carvanha
+ .categoryName = _("SAVAGE"),
+ .height = 8,
+ .weight = 208,
+ .descriptionPage1 = DexDescription_Carvanha_1,
+ .descriptionPage2 = DexDescription_Carvanha_2,
+ .pokemonScale = 362,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sharpedo
+ .categoryName = _("BRUTAL"),
+ .height = 18,
+ .weight = 888,
+ .descriptionPage1 = DexDescription_Sharpedo_1,
+ .descriptionPage2 = DexDescription_Sharpedo_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 317,
+ .trainerOffset = 3,
+ },
+ { //Wailmer
+ .categoryName = _("BALL WHALE"),
+ .height = 20,
+ .weight = 1300,
+ .descriptionPage1 = DexDescription_Wailmer_1,
+ .descriptionPage2 = DexDescription_Wailmer_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 493,
+ .trainerOffset = 0,
+ },
+ { //Wailord
+ .categoryName = _("FLOAT WHALE"),
+ .height = 145,
+ .weight = 3980,
+ .descriptionPage1 = DexDescription_Wailord_1,
+ .descriptionPage2 = DexDescription_Wailord_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 1352,
+ .trainerOffset = 18,
+ },
+ { //Numel
+ .categoryName = _("NUMB"),
+ .height = 7,
+ .weight = 240,
+ .descriptionPage1 = DexDescription_Numel_1,
+ .descriptionPage2 = DexDescription_Numel_2,
+ .pokemonScale = 342,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Camerupt
+ .categoryName = _("ERUPTION"),
+ .height = 19,
+ .weight = 2200,
+ .descriptionPage1 = DexDescription_Camerupt_1,
+ .descriptionPage2 = DexDescription_Camerupt_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 7,
+ .trainerScale = 345,
+ .trainerOffset = 6,
+ },
+ { //Torkoal
+ .categoryName = _("COAL"),
+ .height = 5,
+ .weight = 804,
+ .descriptionPage1 = DexDescription_Torkoal_1,
+ .descriptionPage2 = DexDescription_Torkoal_2,
+ .pokemonScale = 390,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Spoink
+ .categoryName = _("BOUNCE"),
+ .height = 7,
+ .weight = 306,
+ .descriptionPage1 = DexDescription_Spoink_1,
+ .descriptionPage2 = DexDescription_Spoink_2,
+ .pokemonScale = 423,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Grumpig
+ .categoryName = _("MANIPULATE"),
+ .height = 9,
+ .weight = 715,
+ .descriptionPage1 = DexDescription_Grumpig_1,
+ .descriptionPage2 = DexDescription_Grumpig_2,
+ .pokemonScale = 358,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Spinda
+ .categoryName = _("SPOT PANDA"),
+ .height = 11,
+ .weight = 50,
+ .descriptionPage1 = DexDescription_Spinda_1,
+ .descriptionPage2 = DexDescription_Spinda_2,
+ .pokemonScale = 321,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Trapinch
+ .categoryName = _("ANT PIT"),
+ .height = 7,
+ .weight = 150,
+ .descriptionPage1 = DexDescription_Trapinch_1,
+ .descriptionPage2 = DexDescription_Trapinch_2,
+ .pokemonScale = 298,
+ .pokemonOffset = 17,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Vibrava
+ .categoryName = _("VIBRATION"),
+ .height = 11,
+ .weight = 153,
+ .descriptionPage1 = DexDescription_Vibrava_1,
+ .descriptionPage2 = DexDescription_Vibrava_2,
+ .pokemonScale = 370,
+ .pokemonOffset = 11,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Flygon
+ .categoryName = _("MYSTIC"),
+ .height = 20,
+ .weight = 820,
+ .descriptionPage1 = DexDescription_Flygon_1,
+ .descriptionPage2 = DexDescription_Flygon_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 268,
+ .trainerOffset = 1,
+ },
+ { //Cacnea
+ .categoryName = _("CACTUS"),
+ .height = 4,
+ .weight = 513,
+ .descriptionPage1 = DexDescription_Cacnea_1,
+ .descriptionPage2 = DexDescription_Cacnea_2,
+ .pokemonScale = 455,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Cacturne
+ .categoryName = _("SCARECROW"),
+ .height = 13,
+ .weight = 774,
+ .descriptionPage1 = DexDescription_Cacturne_1,
+ .descriptionPage2 = DexDescription_Cacturne_2,
+ .pokemonScale = 327,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Swablu
+ .categoryName = _("COTTON BIRD"),
+ .height = 4,
+ .weight = 12,
+ .descriptionPage1 = DexDescription_Swablu_1,
+ .descriptionPage2 = DexDescription_Swablu_2,
+ .pokemonScale = 422,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Altaria
+ .categoryName = _("HUMMING"),
+ .height = 11,
+ .weight = 206,
+ .descriptionPage1 = DexDescription_Altaria_1,
+ .descriptionPage2 = DexDescription_Altaria_2,
+ .pokemonScale = 327,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Zangoose
+ .categoryName = _("CAT FERRET"),
+ .height = 13,
+ .weight = 403,
+ .descriptionPage1 = DexDescription_Zangoose_1,
+ .descriptionPage2 = DexDescription_Zangoose_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Seviper
+ .categoryName = _("FANG SNAKE"),
+ .height = 27,
+ .weight = 525,
+ .descriptionPage1 = DexDescription_Seviper_1,
+ .descriptionPage2 = DexDescription_Seviper_2,
+ .pokemonScale = 275,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Lunatone
+ .categoryName = _("METEORITE"),
+ .height = 10,
+ .weight = 1680,
+ .descriptionPage1 = DexDescription_Lunatone_1,
+ .descriptionPage2 = DexDescription_Lunatone_2,
+ .pokemonScale = 300,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Solrock
+ .categoryName = _("METEORITE"),
+ .height = 12,
+ .weight = 1540,
+ .descriptionPage1 = DexDescription_Solrock_1,
+ .descriptionPage2 = DexDescription_Solrock_2,
+ .pokemonScale = 328,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Barboach
+ .categoryName = _("WHISKERS"),
+ .height = 4,
+ .weight = 19,
+ .descriptionPage1 = DexDescription_Barboach_1,
+ .descriptionPage2 = DexDescription_Barboach_2,
+ .pokemonScale = 581,
+ .pokemonOffset = -3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Whiscash
+ .categoryName = _("WHISKERS"),
+ .height = 9,
+ .weight = 236,
+ .descriptionPage1 = DexDescription_Whiscash_1,
+ .descriptionPage2 = DexDescription_Whiscash_2,
+ .pokemonScale = 317,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Corphish
+ .categoryName = _("RUFFIAN"),
+ .height = 6,
+ .weight = 115,
+ .descriptionPage1 = DexDescription_Corphish_1,
+ .descriptionPage2 = DexDescription_Corphish_2,
+ .pokemonScale = 484,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Crawdaunt
+ .categoryName = _("ROGUE"),
+ .height = 11,
+ .weight = 328,
+ .descriptionPage1 = DexDescription_Crawdaunt_1,
+ .descriptionPage2 = DexDescription_Crawdaunt_2,
+ .pokemonScale = 365,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Baltoy
+ .categoryName = _("CLAY DOLL"),
+ .height = 5,
+ .weight = 215,
+ .descriptionPage1 = DexDescription_Baltoy_1,
+ .descriptionPage2 = DexDescription_Baltoy_2,
+ .pokemonScale = 457,
+ .pokemonOffset = 21,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Claydol
+ .categoryName = _("CLAY DOLL"),
+ .height = 15,
+ .weight = 1080,
+ .descriptionPage1 = DexDescription_Claydol_1,
+ .descriptionPage2 = DexDescription_Claydol_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 280,
+ .trainerOffset = 1,
+ },
+ { //Lileep
+ .categoryName = _("SEA LILY"),
+ .height = 10,
+ .weight = 238,
+ .descriptionPage1 = DexDescription_Lileep_1,
+ .descriptionPage2 = DexDescription_Lileep_2,
+ .pokemonScale = 305,
+ .pokemonOffset = 8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Cradily
+ .categoryName = _("BARNACLE"),
+ .height = 15,
+ .weight = 604,
+ .descriptionPage1 = DexDescription_Cradily_1,
+ .descriptionPage2 = DexDescription_Cradily_2,
+ .pokemonScale = 267,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Anorith
+ .categoryName = _("OLD SHRIMP"),
+ .height = 7,
+ .weight = 125,
+ .descriptionPage1 = DexDescription_Anorith_1,
+ .descriptionPage2 = DexDescription_Anorith_2,
+ .pokemonScale = 296,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Armaldo
+ .categoryName = _("PLATE"),
+ .height = 15,
+ .weight = 682,
+ .descriptionPage1 = DexDescription_Armaldo_1,
+ .descriptionPage2 = DexDescription_Armaldo_2,
+ .pokemonScale = 312,
+ .pokemonOffset = 3,
+ .trainerScale = 271,
+ .trainerOffset = 0,
+ },
+ { //Feebas
+ .categoryName = _("FISH"),
+ .height = 6,
+ .weight = 74,
+ .descriptionPage1 = DexDescription_Feebas_1,
+ .descriptionPage2 = DexDescription_Feebas_2,
+ .pokemonScale = 423,
+ .pokemonOffset = -4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Milotic
+ .categoryName = _("TENDER"),
+ .height = 62,
+ .weight = 1620,
+ .descriptionPage1 = DexDescription_Milotic_1,
+ .descriptionPage2 = DexDescription_Milotic_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 360,
+ .trainerOffset = 7,
+ },
+ { //Castform
+ .categoryName = _("WEATHER"),
+ .height = 3,
+ .weight = 8,
+ .descriptionPage1 = DexDescription_Castform_1,
+ .descriptionPage2 = DexDescription_Castform_2,
+ .pokemonScale = 435,
+ .pokemonOffset = -5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Kecleon
+ .categoryName = _("COLOR SWAP"),
+ .height = 10,
+ .weight = 220,
+ .descriptionPage1 = DexDescription_Kecleon_1,
+ .descriptionPage2 = DexDescription_Kecleon_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 10,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shuppet
+ .categoryName = _("PUPPET"),
+ .height = 6,
+ .weight = 23,
+ .descriptionPage1 = DexDescription_Shuppet_1,
+ .descriptionPage2 = DexDescription_Shuppet_2,
+ .pokemonScale = 440,
+ .pokemonOffset = 20,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Banette
+ .categoryName = _("MARIONETTE"),
+ .height = 11,
+ .weight = 125,
+ .descriptionPage1 = DexDescription_Banette_1,
+ .descriptionPage2 = DexDescription_Banette_2,
+ .pokemonScale = 262,
+ .pokemonOffset = 9,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Duskull
+ .categoryName = _("REQUIEM"),
+ .height = 8,
+ .weight = 150,
+ .descriptionPage1 = DexDescription_Duskull_1,
+ .descriptionPage2 = DexDescription_Duskull_2,
+ .pokemonScale = 406,
+ .pokemonOffset = -4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Dusclops
+ .categoryName = _("BECKON"),
+ .height = 16,
+ .weight = 306,
+ .descriptionPage1 = DexDescription_Dusclops_1,
+ .descriptionPage2 = DexDescription_Dusclops_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 299,
+ .trainerOffset = 1,
+ },
+ { //Tropius
+ .categoryName = _("FRUIT"),
+ .height = 20,
+ .weight = 1000,
+ .descriptionPage1 = DexDescription_Tropius_1,
+ .descriptionPage2 = DexDescription_Tropius_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 344,
+ .trainerOffset = 7,
+ },
+ { //Chimecho
+ .categoryName = _("WIND CHIME"),
+ .height = 6,
+ .weight = 10,
+ .descriptionPage1 = DexDescription_Chimecho_1,
+ .descriptionPage2 = DexDescription_Chimecho_2,
+ .pokemonScale = 505,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Absol
+ .categoryName = _("DISASTER"),
+ .height = 12,
+ .weight = 470,
+ .descriptionPage1 = DexDescription_Absol_1,
+ .descriptionPage2 = DexDescription_Absol_2,
+ .pokemonScale = 301,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Wynaut
+ .categoryName = _("BRIGHT"),
+ .height = 6,
+ .weight = 140,
+ .descriptionPage1 = DexDescription_Wynaut_1,
+ .descriptionPage2 = DexDescription_Wynaut_2,
+ .pokemonScale = 484,
+ .pokemonOffset = 19,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Snorunt
+ .categoryName = _("SNOW HAT"),
+ .height = 7,
+ .weight = 168,
+ .descriptionPage1 = DexDescription_Snorunt_1,
+ .descriptionPage2 = DexDescription_Snorunt_2,
+ .pokemonScale = 380,
+ .pokemonOffset = 15,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Glalie
+ .categoryName = _("FACE"),
+ .height = 15,
+ .weight = 2565,
+ .descriptionPage1 = DexDescription_Glalie_1,
+ .descriptionPage2 = DexDescription_Glalie_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 3,
+ .trainerScale = 344,
+ .trainerOffset = 0,
+ },
+ { //Spheal
+ .categoryName = _("CLAP"),
+ .height = 8,
+ .weight = 395,
+ .descriptionPage1 = DexDescription_Spheal_1,
+ .descriptionPage2 = DexDescription_Spheal_2,
+ .pokemonScale = 315,
+ .pokemonOffset = 16,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Sealeo
+ .categoryName = _("BALL ROLL"),
+ .height = 11,
+ .weight = 876,
+ .descriptionPage1 = DexDescription_Sealeo_1,
+ .descriptionPage2 = DexDescription_Sealeo_2,
+ .pokemonScale = 338,
+ .pokemonOffset = 13,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Walrein
+ .categoryName = _("ICE BREAK"),
+ .height = 14,
+ .weight = 1506,
+ .descriptionPage1 = DexDescription_Walrein_1,
+ .descriptionPage2 = DexDescription_Walrein_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 4,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Clamperl
+ .categoryName = _("BIVALVE"),
+ .height = 4,
+ .weight = 525,
+ .descriptionPage1 = DexDescription_Clamperl_1,
+ .descriptionPage2 = DexDescription_Clamperl_2,
+ .pokemonScale = 691,
+ .pokemonOffset = 22,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Huntail
+ .categoryName = _("DEEP SEA"),
+ .height = 17,
+ .weight = 270,
+ .descriptionPage1 = DexDescription_Huntail_1,
+ .descriptionPage2 = DexDescription_Huntail_2,
+ .pokemonScale = 307,
+ .pokemonOffset = 1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Gorebyss
+ .categoryName = _("SOUTH SEA"),
+ .height = 18,
+ .weight = 226,
+ .descriptionPage1 = DexDescription_Gorebyss_1,
+ .descriptionPage2 = DexDescription_Gorebyss_2,
+ .pokemonScale = 278,
+ .pokemonOffset = 5,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Relicanth
+ .categoryName = _("LONGEVITY"),
+ .height = 10,
+ .weight = 234,
+ .descriptionPage1 = DexDescription_Relicanth_1,
+ .descriptionPage2 = DexDescription_Relicanth_2,
+ .pokemonScale = 316,
+ .pokemonOffset = 7,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Luvdisc
+ .categoryName = _("RENDEZVOUS"),
+ .height = 6,
+ .weight = 87,
+ .descriptionPage1 = DexDescription_Luvdisc_1,
+ .descriptionPage2 = DexDescription_Luvdisc_2,
+ .pokemonScale = 371,
+ .pokemonOffset = 2,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Bagon
+ .categoryName = _("ROCK HEAD"),
+ .height = 6,
+ .weight = 421,
+ .descriptionPage1 = DexDescription_Bagon_1,
+ .descriptionPage2 = DexDescription_Bagon_2,
+ .pokemonScale = 448,
+ .pokemonOffset = 18,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Shelgon
+ .categoryName = _("ENDURANCE"),
+ .height = 11,
+ .weight = 1105,
+ .descriptionPage1 = DexDescription_Shelgon_1,
+ .descriptionPage2 = DexDescription_Shelgon_2,
+ .pokemonScale = 311,
+ .pokemonOffset = 12,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Salamence
+ .categoryName = _("DRAGON"),
+ .height = 15,
+ .weight = 1026,
+ .descriptionPage1 = DexDescription_Salamence_1,
+ .descriptionPage2 = DexDescription_Salamence_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Beldum
+ .categoryName = _("IRON BALL"),
+ .height = 6,
+ .weight = 952,
+ .descriptionPage1 = DexDescription_Beldum_1,
+ .descriptionPage2 = DexDescription_Beldum_2,
+ .pokemonScale = 414,
+ .pokemonOffset = -1,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Metang
+ .categoryName = _("IRON CLAW"),
+ .height = 12,
+ .weight = 2025,
+ .descriptionPage1 = DexDescription_Metang_1,
+ .descriptionPage2 = DexDescription_Metang_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 6,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Metagross
+ .categoryName = _("IRON LEG"),
+ .height = 16,
+ .weight = 5500,
+ .descriptionPage1 = DexDescription_Metagross_1,
+ .descriptionPage2 = DexDescription_Metagross_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 4,
+ .trainerScale = 447,
+ .trainerOffset = 9,
+ },
+ { //Regirock
+ .categoryName = _("ROCK PEAK"),
+ .height = 17,
+ .weight = 2300,
+ .descriptionPage1 = DexDescription_Regirock_1,
+ .descriptionPage2 = DexDescription_Regirock_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 2,
+ .trainerScale = 309,
+ .trainerOffset = 1,
+ },
+ { //Regice
+ .categoryName = _("ICEBERG"),
+ .height = 18,
+ .weight = 1750,
+ .descriptionPage1 = DexDescription_Regice_1,
+ .descriptionPage2 = DexDescription_Regice_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 301,
+ .trainerOffset = 2,
+ },
+ { //Registeel
+ .categoryName = _("IRON"),
+ .height = 19,
+ .weight = 2050,
+ .descriptionPage1 = DexDescription_Registeel_1,
+ .descriptionPage2 = DexDescription_Registeel_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 359,
+ .trainerOffset = 6,
+ },
+ { //Latias
+ .categoryName = _("EON"),
+ .height = 14,
+ .weight = 400,
+ .descriptionPage1 = DexDescription_Latias_1,
+ .descriptionPage2 = DexDescription_Latias_2,
+ .pokemonScale = 304,
+ .pokemonOffset = 3,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Latios
+ .categoryName = _("EON"),
+ .height = 20,
+ .weight = 600,
+ .descriptionPage1 = DexDescription_Latios_1,
+ .descriptionPage2 = DexDescription_Latios_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 294,
+ .trainerOffset = 3,
+ },
+ { //Kyogre
+ .categoryName = _("SEA BASIN"),
+ .height = 45,
+ .weight = 3520,
+ .descriptionPage1 = DexDescription_Kyogre_1,
+ .descriptionPage2 = DexDescription_Kyogre_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 614,
+ .trainerOffset = 13,
+ },
+ { //Groudon
+ .categoryName = _("CONTINENT"),
+ .height = 35,
+ .weight = 9500,
+ .descriptionPage1 = DexDescription_Groudon_1,
+ .descriptionPage2 = DexDescription_Groudon_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 515,
+ .trainerOffset = 14,
+ },
+ { //Rayquaza
+ .categoryName = _("SKY HIGH"),
+ .height = 70,
+ .weight = 2065,
+ .descriptionPage1 = DexDescription_Rayquaza_1,
+ .descriptionPage2 = DexDescription_Rayquaza_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 448,
+ .trainerOffset = 12,
+ },
+ { //Jirachi
+ .categoryName = _("WISH"),
+ .height = 3,
+ .weight = 11,
+ .descriptionPage1 = DexDescription_Jirachi_1,
+ .descriptionPage2 = DexDescription_Jirachi_2,
+ .pokemonScale = 608,
+ .pokemonOffset = -8,
+ .trainerScale = 256,
+ .trainerOffset = 0,
+ },
+ { //Deoxys
+ .categoryName = _("DNA"),
+ .height = 17,
+ .weight = 608,
+ .descriptionPage1 = DexDescription_Deoxys_1,
+ .descriptionPage2 = DexDescription_Deoxys_2,
+ .pokemonScale = 256,
+ .pokemonOffset = 0,
+ .trainerScale = 290,
+ .trainerOffset = 2,
+ },
+};
diff --git a/src/data/pokedex_orders.h b/src/data/pokedex_orders.h
new file mode 100644
index 000000000..3577e6793
--- /dev/null
+++ b/src/data/pokedex_orders.h
@@ -0,0 +1,1192 @@
+static const u16 gPokedexOrder_Alphabetical[] =
+{
+ 387,
+ 388,
+ 389,
+ 390,
+ 391,
+ 392,
+ 393,
+ 394,
+ 395,
+ 396,
+ 397,
+ 398,
+ 399,
+ 400,
+ 401,
+ 402,
+ 403,
+ 404,
+ 405,
+ 406,
+ 407,
+ 408,
+ 409,
+ 410,
+ 411,
+ 63, // Abra
+ 359, // Absol
+ 142, // Aerodactyl
+ 306, // Aggron
+ 190, // Aipom
+ 65, // Alakazam
+ 334, // Altaria
+ 181, // Ampharos
+ 347, // Anorith
+ 24, // Arbok
+ 59, // Arcanine
+ 168, // Ariados
+ 348, // Armaldo
+ 304, // Aron
+ 144, // Articuno
+ 184, // Azumarill
+ 298, // Azurill
+ 371, // Bagon
+ 343, // Baltoy
+ 354, // Banette
+ 339, // Barboach
+ 153, // Bayleef
+ 267, // Beautifly
+ 15, // Beedrill
+ 374, // Beldum
+ 182, // Bellossom
+ 69, // Bellsprout
+ 9, // Blastoise
+ 257, // Blaziken
+ 242, // Blissey
+ 286, // Breloom
+ 1, // Bulbasaur
+ 12, // Butterfree
+ 331, // Cacnea
+ 332, // Cacturne
+ 323, // Camerupt
+ 318, // Carvanha
+ 268, // Cascoon
+ 351, // Castform
+ 10, // Caterpie
+ 251, // Celebi
+ 113, // Chansey
+ 6, // Charizard
+ 4, // Charmander
+ 5, // Charmeleon
+ 152, // Chikorita
+ 358, // Chimecho
+ 170, // Chinchou
+ 366, // Clamperl
+ 344, // Claydol
+ 36, // Clefable
+ 35, // Clefairy
+ 173, // Cleffa
+ 91, // Cloyster
+ 256, // Combusken
+ 341, // Corphish
+ 222, // Corsola
+ 346, // Cradily
+ 342, // Crawdaunt
+ 169, // Crobat
+ 159, // Croconaw
+ 104, // Cubone
+ 155, // Cyndaquil
+ 301, // Delcatty
+ 225, // Delibird
+ 386, // Deoxys
+ 87, // Dewgong
+ 50, // Diglett
+ 132, // Ditto
+ 85, // Dodrio
+ 84, // Doduo
+ 232, // Donphan
+ 148, // Dragonair
+ 149, // Dragonite
+ 147, // Dratini
+ 96, // Drowzee
+ 51, // Dugtrio
+ 206, // Dunsparce
+ 356, // Dusclops
+ 355, // Duskull
+ 269, // Dustox
+ 133, // Eevee
+ 23, // Ekans
+ 125, // Electabuzz
+ 309, // Electrike
+ 101, // Electrode
+ 239, // Elekid
+ 244, // Entei
+ 196, // Espeon
+ 102, // Exeggcute
+ 103, // Exeggutor
+ 295, // Exploud
+ 83, // Farfetchd
+ 22, // Fearow
+ 349, // Feebas
+ 160, // Feraligatr
+ 180, // Flaaffy
+ 136, // Flareon
+ 330, // Flygon
+ 205, // Forretress
+ 162, // Furret
+ 282, // Gardevoir
+ 92, // Gastly
+ 94, // Gengar
+ 74, // Geodude
+ 203, // Girafarig
+ 362, // Glalie
+ 207, // Gligar
+ 44, // Gloom
+ 42, // Golbat
+ 118, // Goldeen
+ 55, // Golduck
+ 76, // Golem
+ 368, // Gorebyss
+ 210, // Granbull
+ 75, // Graveler
+ 88, // Grimer
+ 383, // Groudon
+ 253, // Grovyle
+ 58, // Growlithe
+ 326, // Grumpig
+ 316, // Gulpin
+ 130, // Gyarados
+ 297, // Hariyama
+ 93, // Haunter
+ 214, // Heracross
+ 107, // Hitmonchan
+ 106, // Hitmonlee
+ 237, // Hitmontop
+ 250, // Ho-Oh
+ 163, // Hoothoot
+ 187, // Hoppip
+ 116, // Horsea
+ 229, // Houndoom
+ 228, // Houndour
+ 367, // Huntail
+ 97, // Hypno
+ 174, // Igglybuff
+ 314, // Illumise
+ 2, // Ivysaur
+ 39, // Jigglypuff
+ 385, // Jirachi
+ 135, // Jolteon
+ 189, // Jumpluff
+ 124, // Jynx
+ 140, // Kabuto
+ 141, // Kabutops
+ 64, // Kadabra
+ 14, // Kakuna
+ 115, // Kangaskhan
+ 352, // Kecleon
+ 230, // Kingdra
+ 99, // Kingler
+ 281, // Kirlia
+ 109, // Koffing
+ 98, // Krabby
+ 382, // Kyogre
+ 305, // Lairon
+ 171, // Lanturn
+ 131, // Lapras
+ 246, // Larvitar
+ 380, // Latias
+ 381, // Latios
+ 166, // Ledian
+ 165, // Ledyba
+ 108, // Lickitung
+ 345, // Lileep
+ 264, // Linoone
+ 271, // Lombre
+ 270, // Lotad
+ 294, // Loudred
+ 272, // Ludicolo
+ 249, // Lugia
+ 337, // Lunatone
+ 370, // Luvdisc
+ 68, // Machamp
+ 67, // Machoke
+ 66, // Machop
+ 240, // Magby
+ 219, // Magcargo
+ 129, // Magikarp
+ 126, // Magmar
+ 81, // Magnemite
+ 82, // Magneton
+ 296, // Makuhita
+ 310, // Manectric
+ 56, // Mankey
+ 226, // Mantine
+ 179, // Mareep
+ 183, // Marill
+ 105, // Marowak
+ 259, // Marshtomp
+ 284, // Masquerain
+ 303, // Mawile
+ 308, // Medicham
+ 307, // Meditite
+ 154, // Meganium
+ 52, // Meowth
+ 376, // Metagross
+ 375, // Metang
+ 11, // Metapod
+ 151, // Mew
+ 150, // Mewtwo
+ 262, // Mightyena
+ 350, // Milotic
+ 241, // Miltank
+ 312, // Minun
+ 200, // Misdreavus
+ 146, // Moltres
+ 122, // Mr. mime
+ 258, // Mudkip
+ 89, // Muk
+ 198, // Murkrow
+ 177, // Natu
+ 34, // Nidoking
+ 31, // Nidoqueen
+ 29, // Nidoran?
+ 32, // Nidoran?
+ 30, // Nidorina
+ 33, // Nidorino
+ 290, // Nincada
+ 38, // Ninetales
+ 291, // Ninjask
+ 164, // Noctowl
+ 299, // Nosepass
+ 322, // Numel
+ 274, // Nuzleaf
+ 224, // Octillery
+ 43, // Oddish
+ 138, // Omanyte
+ 139, // Omastar
+ 95, // Onix
+ 46, // Paras
+ 47, // Parasect
+ 279, // Pelipper
+ 53, // Persian
+ 231, // Phanpy
+ 172, // Pichu
+ 18, // Pidgeot
+ 17, // Pidgeotto
+ 16, // Pidgey
+ 25, // Pikachu
+ 221, // Piloswine
+ 204, // Pineco
+ 127, // Pinsir
+ 311, // Plusle
+ 186, // Politoed
+ 60, // Poliwag
+ 61, // Poliwhirl
+ 62, // Poliwrath
+ 77, // Ponyta
+ 261, // Poochyena
+ 137, // Porygon
+ 233, // Porygon2
+ 57, // Primeape
+ 54, // Psyduck
+ 247, // Pupitar
+ 195, // Quagsire
+ 156, // Quilava
+ 211, // Qwilfish
+ 26, // Raichu
+ 243, // Raikou
+ 280, // Ralts
+ 78, // Rapidash
+ 20, // Raticate
+ 19, // Rattata
+ 384, // Rayquaza
+ 378, // Regice
+ 377, // Regirock
+ 379, // Registeel
+ 369, // Relicanth
+ 223, // Remoraid
+ 112, // Rhydon
+ 111, // Rhyhorn
+ 315, // Roselia
+ 302, // Sableye
+ 373, // Salamence
+ 27, // Sandshrew
+ 28, // Sandslash
+ 254, // Sceptile
+ 212, // Scizor
+ 123, // Scyther
+ 117, // Seadra
+ 119, // Seaking
+ 364, // Sealeo
+ 273, // Seedot
+ 86, // Seel
+ 161, // Sentret
+ 336, // Seviper
+ 319, // Sharpedo
+ 292, // Shedinja
+ 372, // Shelgon
+ 90, // Shellder
+ 275, // Shiftry
+ 285, // Shroomish
+ 213, // Shuckle
+ 353, // Shuppet
+ 266, // Silcoon
+ 227, // Skarmory
+ 188, // Skiploom
+ 300, // Skitty
+ 289, // Slaking
+ 287, // Slakoth
+ 80, // Slowbro
+ 199, // Slowking
+ 79, // Slowpoke
+ 218, // Slugma
+ 235, // Smeargle
+ 238, // Smoochum
+ 215, // Sneasel
+ 143, // Snorlax
+ 361, // Snorunt
+ 209, // Snubbull
+ 338, // Solrock
+ 21, // Spearow
+ 363, // Spheal
+ 167, // Spinarak
+ 327, // Spinda
+ 325, // Spoink
+ 7, // Squirtle
+ 234, // Stantler
+ 121, // Starmie
+ 120, // Staryu
+ 208, // Steelix
+ 185, // Sudowoodo
+ 245, // Suicune
+ 192, // Sunflora
+ 191, // Sunkern
+ 283, // Surskit
+ 333, // Swablu
+ 317, // Swalot
+ 260, // Swampert
+ 277, // Swellow
+ 220, // Swinub
+ 276, // Taillow
+ 114, // Tangela
+ 128, // Tauros
+ 216, // Teddiursa
+ 72, // Tentacool
+ 73, // Tentacruel
+ 175, // Togepi
+ 176, // Togetic
+ 255, // Torchic
+ 324, // Torkoal
+ 158, // Totodile
+ 328, // Trapinch
+ 252, // Treecko
+ 357, // Tropius
+ 157, // Typhlosion
+ 248, // Tyranitar
+ 236, // Tyrogue
+ 197, // Umbreon
+ 201, // Unown
+ 217, // Ursaring
+ 134, // Vaporeon
+ 49, // Venomoth
+ 48, // Venonat
+ 3, // Venusaur
+ 329, // Vibrava
+ 71, // Victreebel
+ 288, // Vigoroth
+ 45, // Vileplume
+ 313, // Volbeat
+ 100, // Voltorb
+ 37, // Vulpix
+ 320, // Wailmer
+ 321, // Wailord
+ 365, // Walrein
+ 8, // Wartortle
+ 13, // Weedle
+ 70, // Weepinbell
+ 110, // Weezing
+ 340, // Whiscash
+ 293, // Whismur
+ 40, // Wigglytuff
+ 278, // Wingull
+ 202, // Wobbuffet
+ 194, // Wooper
+ 265, // Wurmple
+ 360, // Wynaut
+ 178, // Xatu
+ 193, // Yanma
+ 335, // Zangoose
+ 145, // Zapdos
+ 263, // Zigzagoon
+ 41, // Zubat
+};
+static const u16 gPokedexOrder_Weight[] =
+{
+ 92, // Gastly
+ 93, // Haunter
+ 187, // Hoppip
+ 50, // Diglett
+ 351, // Castform
+ 109, // Koffing
+ 174, // Igglybuff
+ 200, // Misdreavus
+ 358, // Chimecho
+ 188, // Skiploom
+ 385, // Jirachi
+ 333, // Swablu
+ 292, // Shedinja
+ 175, // Togepi
+ 283, // Surskit
+ 16, // Pidgey
+ 191, // Sunkern
+ 339, // Barboach
+ 172, // Pichu
+ 298, // Azurill
+ 315, // Roselia
+ 177, // Natu
+ 21, // Spearow
+ 198, // Murkrow
+ 353, // Shuppet
+ 276, // Taillow
+ 102, // Exeggcute
+ 255, // Torchic
+ 270, // Lotad
+ 10, // Caterpie
+ 189, // Jumpluff
+ 173, // Cleffa
+ 13, // Weedle
+ 176, // Togetic
+ 147, // Dratini
+ 19, // Rattata
+ 284, // Masquerain
+ 265, // Wurmple
+ 211, // Qwilfish
+ 151, // Mew
+ 90, // Shellder
+ 273, // Seedot
+ 132, // Ditto
+ 69, // Bellsprout
+ 311, // Plusle
+ 52, // Meowth
+ 312, // Minun
+ 285, // Shroomish
+ 251, // Celebi
+ 222, // Corsola
+ 252, // Treecko
+ 327, // Spinda
+ 201, // Unown
+ 46, // Paras
+ 43, // Oddish
+ 39, // Jigglypuff
+ 290, // Nincada
+ 182, // Bellossom
+ 81, // Magnemite
+ 25, // Pikachu
+ 238, // Smoochum
+ 161, // Sentret
+ 70, // Weepinbell
+ 152, // Chikorita
+ 220, // Swinub
+ 133, // Eevee
+ 98, // Krabby
+ 104, // Cubone
+ 280, // Ralts
+ 1, // Bulbasaur
+ 23, // Ekans
+ 29, // Nidoran?
+ 204, // Pineco
+ 349, // Feebas
+ 138, // Omanyte
+ 41, // Zubat
+ 35, // Clefairy
+ 258, // Mudkip
+ 209, // Snubbull
+ 179, // Mareep
+ 155, // Cyndaquil
+ 116, // Horsea
+ 4, // Charmander
+ 192, // Sunflora
+ 183, // Marill
+ 194, // Wooper
+ 167, // Spinarak
+ 44, // Gloom
+ 370, // Luvdisc
+ 216, // Teddiursa
+ 32, // Nidoran?
+ 7, // Squirtle
+ 278, // Wingull
+ 158, // Totodile
+ 110, // Weezing
+ 37, // Vulpix
+ 11, // Metapod
+ 266, // Silcoon
+ 129, // Magikarp
+ 14, // Kakuna
+ 316, // Gulpin
+ 100, // Voltorb
+ 165, // Ledyba
+ 228, // Houndour
+ 300, // Skitty
+ 302, // Sableye
+ 307, // Meditite
+ 341, // Corphish
+ 190, // Aipom
+ 268, // Cascoon
+ 303, // Mawile
+ 140, // Kabuto
+ 40, // Wigglytuff
+ 27, // Sandshrew
+ 223, // Remoraid
+ 291, // Ninjask
+ 170, // Chinchou
+ 60, // Poliwag
+ 347, // Anorith
+ 49, // Venomoth
+ 354, // Banette
+ 2, // Ivysaur
+ 180, // Flaaffy
+ 261, // Poochyena
+ 360, // Wynaut
+ 206, // Dunsparce
+ 178, // Xatu
+ 355, // Duskull
+ 83, // Farfetchd
+ 328, // Trapinch
+ 118, // Goldeen
+ 309, // Electrike
+ 329, // Vibrava
+ 71, // Victreebel
+ 153, // Bayleef
+ 225, // Delibird
+ 293, // Whismur
+ 148, // Dragonair
+ 361, // Snorunt
+ 263, // Zigzagoon
+ 314, // Illumise
+ 313, // Volbeat
+ 20, // Raticate
+ 45, // Vileplume
+ 156, // Quilava
+ 5, // Charmeleon
+ 58, // Growlithe
+ 256, // Combusken
+ 66, // Machop
+ 63, // Abra
+ 33, // Nidorino
+ 54, // Psyduck
+ 277, // Swellow
+ 38, // Ninetales
+ 30, // Nidorina
+ 61, // Poliwhirl
+ 74, // Geodude
+ 281, // Kirlia
+ 213, // Shuckle
+ 334, // Altaria
+ 318, // Carvanha
+ 236, // Tyrogue
+ 163, // Hoothoot
+ 240, // Magby
+ 343, // Baltoy
+ 253, // Grovyle
+ 352, // Kecleon
+ 171, // Lanturn
+ 8, // Wartortle
+ 368, // Gorebyss
+ 369, // Relicanth
+ 239, // Elekid
+ 340, // Whiscash
+ 345, // Lileep
+ 322, // Numel
+ 287, // Slakoth
+ 135, // Jolteon
+ 159, // Croconaw
+ 136, // Flareon
+ 117, // Seadra
+ 196, // Espeon
+ 367, // Huntail
+ 197, // Umbreon
+ 259, // Marshtomp
+ 274, // Nuzleaf
+ 215, // Sneasel
+ 56, // Mankey
+ 279, // Pelipper
+ 267, // Beautifly
+ 224, // Octillery
+ 184, // Azumarill
+ 202, // Wobbuffet
+ 134, // Vaporeon
+ 28, // Sandslash
+ 47, // Parasect
+ 15, // Beedrill
+ 89, // Muk
+ 17, // Pidgeotto
+ 88, // Grimer
+ 26, // Raichu
+ 77, // Ponyta
+ 125, // Electabuzz
+ 48, // Venonat
+ 325, // Spoink
+ 356, // Dusclops
+ 308, // Medicham
+ 269, // Dustox
+ 53, // Persian
+ 12, // Butterfree
+ 57, // Primeape
+ 96, // Drowzee
+ 162, // Furret
+ 233, // Porygon2
+ 271, // Lombre
+ 264, // Linoone
+ 301, // Delcatty
+ 342, // Crawdaunt
+ 51, // Dugtrio
+ 168, // Ariados
+ 231, // Phanpy
+ 186, // Politoed
+ 120, // Staryu
+ 113, // Chansey
+ 139, // Omastar
+ 114, // Tangela
+ 218, // Slugma
+ 229, // Houndoom
+ 166, // Ledian
+ 79, // Slowpoke
+ 137, // Porygon
+ 262, // Mightyena
+ 193, // Yanma
+ 22, // Fearow
+ 185, // Sudowoodo
+ 119, // Seaking
+ 286, // Breloom
+ 84, // Doduo
+ 18, // Pidgeot
+ 363, // Spheal
+ 36, // Clefable
+ 380, // Latias
+ 310, // Manectric
+ 335, // Zangoose
+ 141, // Kabutops
+ 94, // Gengar
+ 294, // Loudred
+ 124, // Jynx
+ 164, // Noctowl
+ 203, // Girafarig
+ 371, // Bagon
+ 126, // Magmar
+ 105, // Marowak
+ 72, // Tentacool
+ 288, // Vigoroth
+ 242, // Blissey
+ 359, // Absol
+ 65, // Alakazam
+ 237, // Hitmontop
+ 282, // Gardevoir
+ 210, // Granbull
+ 106, // Hitmonlee
+ 107, // Hitmonchan
+ 227, // Skarmory
+ 331, // Cacnea
+ 257, // Blaziken
+ 254, // Sceptile
+ 336, // Seviper
+ 366, // Clamperl
+ 145, // Zapdos
+ 214, // Heracross
+ 62, // Poliwrath
+ 122, // Mr. mime
+ 127, // Pinsir
+ 272, // Ludicolo
+ 73, // Tentacruel
+ 42, // Golbat
+ 219, // Magcargo
+ 144, // Articuno
+ 221, // Piloswine
+ 123, // Scyther
+ 64, // Kadabra
+ 235, // Smeargle
+ 142, // Aerodactyl
+ 275, // Shiftry
+ 99, // Kingler
+ 31, // Nidoqueen
+ 82, // Magneton
+ 304, // Aron
+ 381, // Latios
+ 146, // Moltres
+ 346, // Cradily
+ 386, // Deoxys
+ 181, // Ampharos
+ 34, // Nidoking
+ 207, // Gligar
+ 24, // Arbok
+ 108, // Lickitung
+ 101, // Electrode
+ 348, // Armaldo
+ 67, // Machoke
+ 234, // Stantler
+ 326, // Grumpig
+ 246, // Larvitar
+ 169, // Crobat
+ 195, // Quagsire
+ 241, // Miltank
+ 97, // Hypno
+ 55, // Golduck
+ 332, // Cacturne
+ 80, // Slowbro
+ 157, // Typhlosion
+ 199, // Slowking
+ 115, // Kangaskhan
+ 121, // Starmie
+ 317, // Swalot
+ 324, // Torkoal
+ 260, // Swampert
+ 330, // Flygon
+ 295, // Exploud
+ 85, // Dodrio
+ 9, // Blastoise
+ 296, // Makuhita
+ 364, // Sealeo
+ 128, // Tauros
+ 319, // Sharpedo
+ 160, // Feraligatr
+ 86, // Seel
+ 6, // Charizard
+ 78, // Rapidash
+ 374, // Beldum
+ 299, // Nosepass
+ 3, // Venusaur
+ 357, // Tropius
+ 154, // Meganium
+ 373, // Salamence
+ 75, // Graveler
+ 344, // Claydol
+ 372, // Shelgon
+ 111, // Rhyhorn
+ 212, // Scizor
+ 87, // Dewgong
+ 112, // Rhydon
+ 232, // Donphan
+ 103, // Exeggutor
+ 305, // Lairon
+ 150, // Mewtwo
+ 217, // Ursaring
+ 205, // Forretress
+ 68, // Machamp
+ 320, // Wailmer
+ 289, // Slaking
+ 91, // Cloyster
+ 365, // Walrein
+ 247, // Pupitar
+ 230, // Kingdra
+ 338, // Solrock
+ 59, // Arcanine
+ 350, // Milotic
+ 337, // Lunatone
+ 378, // Regice
+ 243, // Raikou
+ 245, // Suicune
+ 244, // Entei
+ 250, // Ho-Oh
+ 248, // Tyranitar
+ 375, // Metang
+ 379, // Registeel
+ 384, // Rayquaza
+ 95, // Onix
+ 149, // Dragonite
+ 249, // Lugia
+ 131, // Lapras
+ 323, // Camerupt
+ 226, // Mantine
+ 377, // Regirock
+ 130, // Gyarados
+ 297, // Hariyama
+ 362, // Glalie
+ 76, // Golem
+ 382, // Kyogre
+ 306, // Aggron
+ 321, // Wailord
+ 208, // Steelix
+ 143, // Snorlax
+ 376, // Metagross
+ 383, // Groudon
+};
+static const u16 gPokedexOrder_Height[] =
+{
+ 50, // Diglett
+ 298, // Azurill
+ 177, // Natu
+ 13, // Weedle
+ 172, // Pichu
+ 173, // Cleffa
+ 175, // Togepi
+ 351, // Castform
+ 174, // Igglybuff
+ 10, // Caterpie
+ 276, // Taillow
+ 132, // Ditto
+ 133, // Eevee
+ 315, // Roselia
+ 21, // Spearow
+ 16, // Pidgey
+ 191, // Sunkern
+ 90, // Shellder
+ 19, // Rattata
+ 81, // Magnemite
+ 46, // Paras
+ 265, // Wurmple
+ 385, // Jirachi
+ 104, // Cubone
+ 258, // Mudkip
+ 194, // Wooper
+ 116, // Horsea
+ 52, // Meowth
+ 29, // Nidoran?
+ 220, // Swinub
+ 151, // Mew
+ 333, // Swablu
+ 304, // Aron
+ 311, // Plusle
+ 312, // Minun
+ 102, // Exeggcute
+ 25, // Pikachu
+ 182, // Bellossom
+ 316, // Gulpin
+ 263, // Zigzagoon
+ 285, // Shroomish
+ 138, // Omanyte
+ 331, // Cacnea
+ 98, // Krabby
+ 280, // Ralts
+ 187, // Hoppip
+ 255, // Torchic
+ 366, // Clamperl
+ 74, // Geodude
+ 183, // Marill
+ 339, // Barboach
+ 238, // Smoochum
+ 100, // Voltorb
+ 290, // Nincada
+ 302, // Sableye
+ 198, // Murkrow
+ 211, // Qwilfish
+ 7, // Squirtle
+ 252, // Treecko
+ 343, // Baltoy
+ 43, // Oddish
+ 270, // Lotad
+ 39, // Jigglypuff
+ 283, // Surskit
+ 155, // Cyndaquil
+ 140, // Kabuto
+ 264, // Linoone
+ 324, // Torkoal
+ 32, // Nidoran?
+ 167, // Spinarak
+ 56, // Mankey
+ 273, // Seedot
+ 261, // Poochyena
+ 231, // Phanpy
+ 201, // Unown
+ 170, // Chinchou
+ 233, // Porygon2
+ 60, // Poliwag
+ 371, // Bagon
+ 349, // Feebas
+ 353, // Shuppet
+ 158, // Totodile
+ 251, // Celebi
+ 360, // Wynaut
+ 27, // Sandshrew
+ 358, // Chimecho
+ 370, // Luvdisc
+ 228, // Houndour
+ 266, // Silcoon
+ 309, // Electrike
+ 4, // Charmander
+ 307, // Meditite
+ 278, // Wingull
+ 223, // Remoraid
+ 341, // Corphish
+ 222, // Corsola
+ 314, // Illumise
+ 209, // Snubbull
+ 37, // Vulpix
+ 246, // Larvitar
+ 374, // Beldum
+ 293, // Whismur
+ 204, // Pineco
+ 239, // Elekid
+ 35, // Clefairy
+ 213, // Shuckle
+ 216, // Teddiursa
+ 14, // Kakuna
+ 300, // Skitty
+ 176, // Togetic
+ 118, // Goldeen
+ 303, // Mawile
+ 179, // Mareep
+ 188, // Skiploom
+ 109, // Koffing
+ 51, // Dugtrio
+ 268, // Cascoon
+ 322, // Numel
+ 347, // Anorith
+ 313, // Volbeat
+ 163, // Hoothoot
+ 328, // Trapinch
+ 325, // Spoink
+ 11, // Metapod
+ 69, // Bellsprout
+ 361, // Snorunt
+ 20, // Raticate
+ 259, // Marshtomp
+ 277, // Swellow
+ 240, // Magby
+ 58, // Growlithe
+ 200, // Misdreavus
+ 1, // Bulbasaur
+ 236, // Tyrogue
+ 218, // Slugma
+ 287, // Slakoth
+ 281, // Kirlia
+ 190, // Aipom
+ 135, // Jolteon
+ 30, // Nidorina
+ 184, // Azumarill
+ 292, // Shedinja
+ 66, // Machop
+ 291, // Ninjask
+ 284, // Masquerain
+ 355, // Duskull
+ 192, // Sunflora
+ 189, // Jumpluff
+ 120, // Staryu
+ 180, // Flaaffy
+ 363, // Spheal
+ 54, // Psyduck
+ 219, // Magcargo
+ 83, // Farfetchd
+ 41, // Zubat
+ 137, // Porygon
+ 161, // Sentret
+ 318, // Carvanha
+ 44, // Gloom
+ 26, // Raichu
+ 129, // Magikarp
+ 215, // Sneasel
+ 305, // Lairon
+ 256, // Combusken
+ 224, // Octillery
+ 33, // Nidorino
+ 136, // Flareon
+ 225, // Delibird
+ 72, // Tentacool
+ 63, // Abra
+ 253, // Grovyle
+ 340, // Whiscash
+ 156, // Quilava
+ 196, // Espeon
+ 88, // Grimer
+ 152, // Chikorita
+ 326, // Grumpig
+ 299, // Nosepass
+ 53, // Persian
+ 262, // Mightyena
+ 48, // Venonat
+ 82, // Magneton
+ 77, // Ponyta
+ 296, // Makuhita
+ 337, // Lunatone
+ 28, // Sandslash
+ 96, // Drowzee
+ 114, // Tangela
+ 57, // Primeape
+ 165, // Ledyba
+ 40, // Wigglytuff
+ 47, // Parasect
+ 139, // Omastar
+ 294, // Loudred
+ 8, // Wartortle
+ 75, // Graveler
+ 197, // Umbreon
+ 345, // Lileep
+ 61, // Poliwhirl
+ 134, // Vaporeon
+ 15, // Beedrill
+ 105, // Marowak
+ 70, // Weepinbell
+ 369, // Relicanth
+ 111, // Rhyhorn
+ 2, // Ivysaur
+ 352, // Kecleon
+ 274, // Nuzleaf
+ 267, // Beautifly
+ 17, // Pidgeotto
+ 168, // Ariados
+ 86, // Seel
+ 186, // Politoed
+ 159, // Croconaw
+ 113, // Chansey
+ 354, // Banette
+ 232, // Donphan
+ 121, // Starmie
+ 5, // Charmeleon
+ 221, // Piloswine
+ 12, // Butterfree
+ 329, // Vibrava
+ 125, // Electabuzz
+ 342, // Crawdaunt
+ 301, // Delcatty
+ 334, // Altaria
+ 372, // Shelgon
+ 38, // Ninetales
+ 207, // Gligar
+ 364, // Sealeo
+ 327, // Spinda
+ 247, // Pupitar
+ 79, // Slowpoke
+ 338, // Solrock
+ 241, // Miltank
+ 22, // Fearow
+ 45, // Vileplume
+ 89, // Muk
+ 205, // Forretress
+ 185, // Sudowoodo
+ 359, // Absol
+ 193, // Yanma
+ 269, // Dustox
+ 108, // Lickitung
+ 235, // Smeargle
+ 171, // Lanturn
+ 101, // Electrode
+ 271, // Lombre
+ 286, // Breloom
+ 153, // Bayleef
+ 117, // Seadra
+ 110, // Weezing
+ 279, // Pelipper
+ 375, // Metang
+ 31, // Nidoqueen
+ 332, // Cacturne
+ 275, // Shiftry
+ 308, // Medicham
+ 335, // Zangoose
+ 141, // Kabutops
+ 99, // Kingler
+ 64, // Kadabra
+ 119, // Seaking
+ 36, // Clefable
+ 126, // Magmar
+ 202, // Wobbuffet
+ 92, // Gastly
+ 122, // Mr. mime
+ 62, // Poliwrath
+ 128, // Tauros
+ 380, // Latias
+ 181, // Ampharos
+ 288, // Vigoroth
+ 166, // Ledian
+ 76, // Golem
+ 365, // Walrein
+ 84, // Doduo
+ 229, // Houndoom
+ 34, // Nidoking
+ 124, // Jynx
+ 107, // Hitmonchan
+ 234, // Stantler
+ 210, // Granbull
+ 237, // Hitmontop
+ 195, // Quagsire
+ 344, // Claydol
+ 260, // Swampert
+ 242, // Blissey
+ 272, // Ludicolo
+ 295, // Exploud
+ 206, // Dunsparce
+ 127, // Pinsir
+ 91, // Cloyster
+ 67, // Machoke
+ 203, // Girafarig
+ 18, // Pidgeot
+ 178, // Xatu
+ 346, // Cradily
+ 106, // Hitmonlee
+ 49, // Venomoth
+ 94, // Gengar
+ 214, // Heracross
+ 362, // Glalie
+ 123, // Scyther
+ 373, // Salamence
+ 310, // Manectric
+ 348, // Armaldo
+ 65, // Alakazam
+ 97, // Hypno
+ 164, // Noctowl
+ 73, // Tentacruel
+ 356, // Dusclops
+ 145, // Zapdos
+ 42, // Golbat
+ 376, // Metagross
+ 282, // Gardevoir
+ 9, // Blastoise
+ 80, // Slowbro
+ 93, // Haunter
+ 68, // Machamp
+ 377, // Regirock
+ 317, // Swalot
+ 254, // Sceptile
+ 227, // Skarmory
+ 55, // Golduck
+ 386, // Deoxys
+ 71, // Victreebel
+ 78, // Rapidash
+ 6, // Charizard
+ 367, // Huntail
+ 87, // Dewgong
+ 144, // Articuno
+ 157, // Typhlosion
+ 142, // Aerodactyl
+ 368, // Gorebyss
+ 217, // Ursaring
+ 154, // Meganium
+ 378, // Regice
+ 212, // Scizor
+ 230, // Kingdra
+ 147, // Dratini
+ 85, // Dodrio
+ 319, // Sharpedo
+ 169, // Crobat
+ 162, // Furret
+ 59, // Arcanine
+ 243, // Raikou
+ 257, // Blaziken
+ 323, // Camerupt
+ 112, // Rhydon
+ 379, // Registeel
+ 23, // Ekans
+ 330, // Flygon
+ 357, // Tropius
+ 381, // Latios
+ 245, // Suicune
+ 146, // Moltres
+ 3, // Venusaur
+ 103, // Exeggutor
+ 199, // Slowking
+ 248, // Tyranitar
+ 289, // Slaking
+ 320, // Wailmer
+ 150, // Mewtwo
+ 306, // Aggron
+ 143, // Snorlax
+ 226, // Mantine
+ 244, // Entei
+ 149, // Dragonite
+ 115, // Kangaskhan
+ 297, // Hariyama
+ 160, // Feraligatr
+ 131, // Lapras
+ 336, // Seviper
+ 24, // Arbok
+ 383, // Groudon
+ 250, // Ho-Oh
+ 148, // Dragonair
+ 382, // Kyogre
+ 249, // Lugia
+ 350, // Milotic
+ 130, // Gyarados
+ 384, // Rayquaza
+ 95, // Onix
+ 208, // Steelix
+ 321, // Wailord
+};
diff --git a/src/daycare.c b/src/daycare.c
index 92be45cfa..cded18207 100644..100755
--- a/src/daycare.c
+++ b/src/daycare.c
@@ -1,7 +1,9 @@
#include "global.h"
+#include "daycare.h"
#include "pokemon.h"
+#include "species.h"
+#include "items.h"
#include "string_util.h"
-#include "asm.h"
extern u8 gLastFieldPokeMenuOpened;
@@ -33,70 +35,30 @@ u8 Daycare_CountPokemon(struct BoxPokemon *daycare_data)
return count;
}
-#ifndef ASDF
-__attribute__((naked))
-void sub_8041324(struct BoxPokemon * box_pokemon, void * void_pointer)
+void sub_8041324(struct BoxPokemon * box_pokemon, struct RecordMixing_UnknownStruct * void_pointer)
{
- asm(".syntax unified\n\
- push {r4-r7,lr}\n\
- mov r7, r10\n\
- mov r6, r9\n\
- mov r5, r8\n\
- push {r5-r7}\n\
- mov r9, r0\n\
- mov r10, r1\n\
- movs r7, 0\n\
- movs r5, 0\n\
- mov r6, r10\n\
- adds r6, 0x74\n\
- movs r0, 0x1\n\
- mov r8, r0\n\
-_0804133E:\n\
- lsls r0, r5, 2\n\
- adds r0, r5\n\
- lsls r0, 4\n\
- mov r1, r9\n\
- adds r4, r1, r0\n\
- adds r0, r4, 0\n\
- movs r1, 0xB\n\
- bl GetBoxMonData\n\
- cmp r0, 0\n\
- beq _0804136E\n\
- adds r0, r7, 0x1\n\
- lsls r0, 24\n\
- lsrs r7, r0, 24\n\
- adds r0, r4, 0\n\
- movs r1, 0xC\n\
- bl GetBoxMonData\n\
- adds r1, r0, 0\n\
- cmp r1, 0\n\
- bne _0804136E\n\
- lsls r0, r5, 1\n\
- adds r0, r6, r0\n\
- b _08041374\n\
-_0804136E:\n\
- lsls r0, r5, 1\n\
- adds r0, r6, r0\n\
- mov r1, r8\n\
-_08041374:\n\
- strh r1, [r0]\n\
- adds r0, r5, 0x1\n\
- lsls r0, 24\n\
- lsrs r5, r0, 24\n\
- cmp r5, 0x1\n\
- bls _0804133E\n\
- mov r0, r10\n\
- str r7, [r0, 0x70]\n\
- pop {r3-r5}\n\
- mov r8, r3\n\
- mov r9, r4\n\
- mov r10, r5\n\
- pop {r4-r7}\n\
- pop {r0}\n\
- bx r0\n\
- .syntax divided\n");
+ u8 i;
+ u8 specCount;
+ specCount = 0;
+ for (i=0; i<2; i++)
+ {
+ if (GetBoxMonData(&box_pokemon[i], MON_DATA_SPECIES) != SPECIES_NONE)
+ {
+ specCount ++;
+ if (GetBoxMonData(&box_pokemon[i], MON_DATA_HELD_ITEM) == ITEM_NONE)
+ {
+ void_pointer->unk74[i] = 0;
+ } else
+ {
+ void_pointer->unk74[i] = 1;
+ }
+ } else
+ {
+ void_pointer->unk74[i] = 1;
+ }
+ }
+ void_pointer->unk70 = specCount;
}
-#endif
s8 Daycare_FindEmptySpot(struct BoxPokemon * daycare_data)
{
diff --git a/src/decompress.c b/src/decompress.c
index 37aa1e8d5..1d38447b5 100644
--- a/src/decompress.c
+++ b/src/decompress.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "decompress.h"
-#include "asm.h"
#include "data2.h"
#include "species.h"
#include "text.h"
diff --git a/src/decoration.c b/src/decoration.c
index a2b0dcd31..a60870ab8 100755..100644
--- a/src/decoration.c
+++ b/src/decoration.c
@@ -1,5 +1,5 @@
#include "global.h"
-#include "asm.h"
+#include "main.h"
#include "map_object_constants.h"
#include "rom4.h"
#include "sound.h"
@@ -12,6 +12,7 @@
#include "palette.h"
#include "field_player_avatar.h"
#include "field_camera.h"
+#include "field_fadetransition.h"
#include "fieldmap.h"
#include "metatile_behavior.h"
#include "event_data.h"
@@ -1616,7 +1617,7 @@ void sub_80FE394(void)
void gpu_pal_decompress_alloc_tag_and_upload(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 10, 9);
MenuFillWindowRectWithBlankTile(2, 15, 27, 18);
FreeSpritePaletteByTag(6);
@@ -1683,7 +1684,7 @@ void sub_80FE528(u8 taskId) // PrintDecorationCategorySelectionMenuStrings
void sub_80FE5AC(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 29, 19);
sub_80FE528(taskId);
InitMenu(0, 1, 1, 9, gUnknown_020388F6, 13);
@@ -1720,7 +1721,7 @@ void sub_80FE604(u8 taskId)
gTasks[taskId].func = sub_80FE868;
} else
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 14, 19);
DisplayItemMessageOnField(taskId, gSecretBaseText_NoDecors, sub_80FE418, 0);
}
@@ -1749,7 +1750,7 @@ void sub_80FE728(u8 taskId)
void sub_80FE758(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 14, 19);
if (gTasks[taskId].data[11] != 2)
{
@@ -1777,7 +1778,7 @@ void sub_80FE7D4(u8 *dest, u8 decClass)
void sub_80FE7EC(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 29, 19);
sub_80FEC94(taskId);
@@ -1850,7 +1851,7 @@ void sub_80FE948(u8 taskId)
}
if (gMain.newKeys & A_BUTTON)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
gUnknown_020388F5 = gUnknown_020388F2 + gUnknown_020388F4;
if (gUnknown_020388F5 == gUnknown_020388D5)
@@ -1862,7 +1863,7 @@ void sub_80FE948(u8 taskId)
}
} else if (gMain.newKeys & B_BUTTON)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
gUnknown_083EC634[gTasks[taskId].data[11]].func2(taskId);
}
@@ -2050,7 +2051,7 @@ void sub_80FEF74(void)
sub_80F9520(gUnknown_020388F7, 8);
DestroyVerticalScrollIndicator(0);
DestroyVerticalScrollIndicator(1);
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 14, 19);
}
@@ -2080,7 +2081,7 @@ void sub_80FEFF4(u8 taskId)
void sub_80FF034(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 14, 19);
sub_80FE5AC(taskId);
}
@@ -3168,7 +3169,7 @@ void sub_8100038(u8 taskId)
void sub_81000A0(u8 taskId)
{
DisplayYesNoMenu(20, 8, 1);
- sub_80F914C(taskId, &gUnknown_083EC95C);
+ DoYesNoFuncWithChoice(taskId, &gUnknown_083EC95C);
}
void sub_81000C4(u8 taskId)
@@ -3226,7 +3227,7 @@ void sub_8100174(u8 taskId)
void sub_8100248(u8 taskId)
{
DisplayYesNoMenu(20, 8, 1);
- sub_80F914C(taskId, &gUnknown_083EC964);
+ DoYesNoFuncWithChoice(taskId, &gUnknown_083EC964);
}
void sub_810026C(u8 taskId)
@@ -3257,7 +3258,7 @@ void c1_overworld_prev_quest(u8 taskId)
case 1:
sub_81016F4();
FreeSpritePaletteByTag(0xbb8);
- gUnknown_0300485C = &sub_8100364;
+ gFieldCallback = &sub_8100364;
SetMainCallback2(c2_exit_to_overworld_2_switch);
DestroyTask(taskId);
break;
@@ -3705,7 +3706,7 @@ void sub_8100E70(u8 taskId)
data[2] = 1;
data[6] = 1;
data[5] = 1;
- sub_8072DEC();
+ HandleDestroyMenuCursors();
}
break;
case 1:
@@ -4047,7 +4048,7 @@ void sub_8101460(u8 taskId)
void sub_8101518(u8 taskId)
{
DisplayYesNoMenu(20, 8, 1);
- sub_80F914C(taskId, &gUnknown_083EC9CC);
+ DoYesNoFuncWithChoice(taskId, &gUnknown_083EC9CC);
}
void sub_810153C(u8 taskId)
@@ -4060,7 +4061,7 @@ void sub_810153C(u8 taskId)
void sub_810156C(u8 taskId)
{
DisplayYesNoMenu(20, 8, 1);
- sub_80F914C(taskId, &gUnknown_083EC9D4);
+ DoYesNoFuncWithChoice(taskId, &gUnknown_083EC9D4);
}
void sub_8101590(u8 taskId)
@@ -4089,7 +4090,7 @@ void sub_81015E0(u8 taskId)
break;
case 1:
sub_81016F4();
- gUnknown_0300485C = sub_8101678;
+ gFieldCallback = sub_8101678;
SetMainCallback2(c2_exit_to_overworld_2_switch);
DestroyTask(taskId);
break;
@@ -4184,7 +4185,7 @@ void sub_81017A0(u8 taskId)
void sub_8101824(u8 taskId)
{
DisplayYesNoMenu(20, 8, 1);
- sub_80F914C(taskId, &gUnknown_083ECAA0);
+ DoYesNoFuncWithChoice(taskId, &gUnknown_083ECAA0);
}
void sub_8101848(u8 taskId)
diff --git a/src/decoration_inventory.c b/src/decoration_inventory.c
new file mode 100644
index 000000000..35ba7e228
--- /dev/null
+++ b/src/decoration_inventory.c
@@ -0,0 +1,169 @@
+//
+// Created by Scott Norton on 6/5/17.
+//
+
+#include "global.h"
+#include "sprite.h"
+#include "task.h"
+#include "decoration.h"
+#include "decoration_inventory.h"
+
+#define DECOR_INV(ptr) {.items = (u8 *)&ptr, .size = sizeof ptr}
+
+struct DecorationInventory const gDecorationInventories[] = {
+ DECOR_INV(gSaveBlock1.decorDesk),
+ DECOR_INV(gSaveBlock1.decorChair),
+ DECOR_INV(gSaveBlock1.decorPlant),
+ DECOR_INV(gSaveBlock1.decorOrnament),
+ DECOR_INV(gSaveBlock1.decorMat),
+ DECOR_INV(gSaveBlock1.decorPoster),
+ DECOR_INV(gSaveBlock1.decorDoll),
+ DECOR_INV(gSaveBlock1.decorCushion)
+};
+
+void ClearDecorationInventory(u8 invIdx)
+{
+ u8 i;
+ for (i=0; i<gDecorationInventories[invIdx].size; i++)
+ {
+ gDecorationInventories[invIdx].items[i] = DECOR_NONE;
+ }
+}
+
+void ClearDecorationInventories(void)
+{
+ u8 i;
+ for (i=0; i<8; i++)
+ {
+ ClearDecorationInventory(i);
+ }
+}
+
+s8 sub_8133F9C(u8 invIdx)
+{
+ s8 i;
+ for (i=0; i<(s8)gDecorationInventories[invIdx].size; i++)
+ {
+ if (gDecorationInventories[invIdx].items[i] == DECOR_NONE)
+ {
+ return i;
+ }
+ }
+ return -1;
+}
+
+bool8 sub_8133FE4(u8 decorIdx)
+{
+ u8 invIdx;
+ u8 i;
+ invIdx = gDecorations[decorIdx].category;
+ for (i=0; i<gDecorationInventories[invIdx].size; i++)
+ {
+ if (gDecorationInventories[invIdx].items[i] == decorIdx)
+ {
+ return TRUE;
+ }
+ }
+ return FALSE;
+}
+
+bool8 IsThereStorageSpaceForDecoration(u8 decorIdx)
+{
+ u8 invIdx;
+ s8 invSlot;
+ if (decorIdx == DECOR_NONE)
+ {
+ return FALSE;
+ }
+ invIdx = gDecorations[decorIdx].category;
+ invSlot = sub_8133F9C(invIdx);
+ if (invSlot == -1)
+ {
+ return FALSE;
+ }
+ gDecorationInventories[invIdx].items[invSlot] = decorIdx;
+ return TRUE;
+}
+
+bool8 sub_8134074(u8 decorIdx)
+{
+ u8 invIdx;
+ if (decorIdx == DECOR_NONE)
+ {
+ return FALSE;
+ }
+ invIdx = gDecorations[decorIdx].category;
+ if (sub_8133F9C(invIdx) == -1)
+ {
+ return FALSE;
+ }
+ return TRUE;
+}
+
+s8 sub_81340A8(u8 decorIdx)
+{
+ u8 i;
+ u8 invIdx;
+ i = 0;
+ if (decorIdx == DECOR_NONE)
+ {
+ return FALSE;
+ }
+ for (i=0; i<gDecorationInventories[gDecorations[decorIdx].category].size; i++)
+ {
+ invIdx = gDecorations[decorIdx].category;
+ if (gDecorationInventories[invIdx].items[i] == decorIdx)
+ {
+ gDecorationInventories[invIdx].items[i] = DECOR_NONE;
+ sub_8134104(invIdx);
+ return TRUE;
+ }
+ }
+ return FALSE;
+}
+
+void sub_8134104(u8 invIdx)
+{
+ u8 i;
+ u8 j;
+ u8 tmp;
+ for (i=0; i<gDecorationInventories[invIdx].size; i++)
+ {
+ for (j=i+1; j<gDecorationInventories[invIdx].size; j++)
+ {
+ if (gDecorationInventories[invIdx].items[j] != 0 && (gDecorationInventories[invIdx].items[i] == DECOR_NONE || gDecorationInventories[invIdx].items[i] > gDecorationInventories[invIdx].items[j]))
+ {
+ tmp = gDecorationInventories[invIdx].items[i];
+ gDecorationInventories[invIdx].items[i] = gDecorationInventories[invIdx].items[j];
+ gDecorationInventories[invIdx].items[j] = tmp;
+ }
+ }
+ }
+}
+
+u8 sub_8134194(u8 invIdx)
+{
+ u8 i;
+ u8 count;
+ count = 0;
+ for (i=0; i<gDecorationInventories[invIdx].size; i++)
+ {
+ if (gDecorationInventories[invIdx].items[i] != 0)
+ {
+ count++;
+ }
+ }
+ return count;
+}
+
+u8 sub_81341D4(void)
+{
+ u8 i;
+ u8 count;
+ count = 0;
+ for (i=0; i<8; i++)
+ {
+ count += sub_8134194(i);
+ }
+ return count;
+}
diff --git a/src/dewford_trend.c b/src/dewford_trend.c
index e4ce0c0c7..aaf4dd66a 100644
--- a/src/dewford_trend.c
+++ b/src/dewford_trend.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "dewford_trend.h"
-#include "asm.h"
#include "easy_chat.h"
#include "event_data.h"
#include "link.h"
diff --git a/src/diploma.c b/src/diploma.c
index 80adac8f7..ba7de58aa 100644
--- a/src/diploma.c
+++ b/src/diploma.c
@@ -1,5 +1,5 @@
#include "global.h"
-#include "asm.h"
+#include "diploma.h"
#include "main.h"
#include "menu.h"
#include "palette.h"
@@ -10,6 +10,7 @@
#include "strings2.h"
#include "task.h"
#include "text.h"
+#include "unknown_task.h"
static void VBlankCB(void);
static void MainCB2(void);
diff --git a/src/easy_chat.c b/src/easy_chat.c
index b0168d3bc..cc2cd7030 100644
--- a/src/easy_chat.c
+++ b/src/easy_chat.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "easy_chat.h"
-#include "asm.h"
#include "data2.h"
#include "event_data.h"
#include "field_message_box.h"
@@ -11,17 +10,9 @@
#include "strings2.h"
#include "text.h"
-u8 sub_80EB37C(u16);
-u8 sub_80EB8C0(void);
-u8 sub_80EB868(u8);
-u16 sub_80EAE88(u8);
-void sub_80EB890(u8);
-u16 sub_80EB784(u16 group);
-u8 sub_80EAD7C(u8 group);
static bool8 sub_80EB680(u16 *, u16, u16, u16);
static u16 sub_80EB9D8(void);
static u16 sub_80EB960(void);
-u16 sub_80EB72C(u16);
extern void *gEasyChatGroupWords[];
extern const u8 gEasyChatGroupSizes[];
@@ -471,7 +462,7 @@ static u16 sub_80EB9D8(void) {
{
const u16 dexNum = SpeciesToNationalPokedexNum(*speciesList);
- const u8 local2 = sub_8090D90(dexNum, 0);
+ const u8 local2 = GetNationalPokedexFlag(dexNum, 0);
if (local2)
{
diff --git a/src/field_camera.c b/src/field_camera.c
index df5ccc301..1aed1549b 100644
--- a/src/field_camera.c
+++ b/src/field_camera.c
@@ -1,9 +1,9 @@
#include "global.h"
#include "field_camera.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
#include "berry.h"
#include "field_player_avatar.h"
+#include "fieldmap.h"
+#include "rotating_gate.h"
#include "sprite.h"
#include "text.h"
diff --git a/src/field_control_avatar.c b/src/field_control_avatar.c
index 8220a144b..2d8140be5 100644
--- a/src/field_control_avatar.c
+++ b/src/field_control_avatar.c
@@ -1,17 +1,25 @@
#include "global.h"
#include "field_control_avatar.h"
-#include "asm.h"
#include "battle_setup.h"
#include "bike.h"
+#include "coord_event_weather.h"
+#include "daycare.h"
#include "event_data.h"
+#include "field_fadetransition.h"
#include "field_player_avatar.h"
+#include "field_poison.h"
+#include "field_specials.h"
+#include "fieldmap.h"
#include "flags.h"
+#include "item_menu.h"
#include "metatile_behavior.h"
#include "rom4.h"
#include "safari_zone.h"
#include "script.h"
+#include "secret_base.h"
#include "songs.h"
#include "sound.h"
+#include "start_menu.h"
#include "trainer_see.h"
#include "vars.h"
#include "wild_encounter.h"
@@ -22,7 +30,6 @@ struct Coords32
s32 y;
};
-extern const struct Coords32 gUnknown_0821664C[];
extern u16 gScriptLastTalked;
extern u16 gScriptFacing;
extern struct LinkPlayerMapObject gLinkPlayerMapObjects[];
@@ -82,14 +89,10 @@ static u8 *TryGetFieldMoveScript(struct MapPosition *, u8, u8);
static bool32 sub_8068770(void);
static bool32 sub_80687A4(void);
static bool8 sub_80687E4(struct MapPosition *, u16, u16);
-bool8 mapheader_trigger_activate_at__run_now(struct MapPosition *);
-bool8 sub_8068870(u16 a);
-bool8 sub_8068894(void);
static void happiness_algorithm_step(void);
static bool8 overworld_poison_step(void);
static bool8 is_it_battle_time_3(u16);
static bool8 mapheader_run_first_tag2_script_list_match_conditionally(struct MapPosition *, u16, u8);
-bool8 sub_8068A64(struct MapPosition *, u16);
static bool8 sub_8068B30(u16);
static bool8 is_non_stair_warp_tile(u16, u8);
static s8 map_warp_check_packed(struct MapHeader *, struct MapPosition *);
@@ -98,21 +101,6 @@ static bool8 map_warp_consider_2_to_inside(struct MapPosition *, u16, u8);
static s8 map_warp_check(struct MapHeader *, u16, u16, u8);
static u8 *mapheader_trigger_activate_at(struct MapHeader *, u16, u16, u8);
static struct BgEvent *FindInvisibleMapObjectByPosition(struct MapHeader *, u16, u16, u8);
-u8 sub_8068F18(void);
-
-extern u8 mapheader_run_first_tag2_script_list_match(void);
-extern void sub_8071310(void);
-extern int sub_80A6D1C(void);
-extern u8 sub_80BC050();
-extern u8 sub_80422A0(void);
-extern s32 overworld_poison(void);
-extern void sub_8080E88();
-extern void walkrun_find_lowest_active_bit_in_bitfield(void);
-extern void sub_8080F2C(u8);
-extern void sub_8080F48(void);
-extern void sub_8080F58(void);
-extern void sub_80BC038();
-extern void DoCoordEventWeather(u8);
void FieldClearPlayerInput(struct FieldInput *input)
{
diff --git a/src/field_door.c b/src/field_door.c
index fa763a5d6..791ed4c94 100644
--- a/src/field_door.c
+++ b/src/field_door.c
@@ -1,7 +1,7 @@
#include "global.h"
#include "field_door.h"
-#include "asm.h"
#include "field_camera.h"
+#include "fieldmap.h"
#include "metatile_behavior.h"
#include "task.h"
diff --git a/src/field_effect.c b/src/field_effect.c
index bbc1144c1..9591bb6a0 100644..100755
--- a/src/field_effect.c
+++ b/src/field_effect.c
@@ -1,17 +1,427 @@
#include "global.h"
-#include "field_effect.h"
+#include "data2.h"
+#include "script.h"
+#include "trig.h"
+#include "main.h"
#include "field_weather.h"
+#include "decompress.h"
#include "sprite.h"
+#include "menu.h"
+#include "palette.h"
#include "text.h"
+#include "rom4.h"
+#include "task.h"
+#include "sound.h"
+#include "songs.h"
+#include "decoration.h"
+#include "field_player_avatar.h"
+#include "field_map_obj_helpers.h"
+#include "field_map_obj.h"
+#include "metatile_behavior.h"
+#include "field_camera.h"
+#include "field_effect.h"
+#include "field_fadetransition.h"
+#include "fieldmap.h"
+#include "field_map_obj.h"
+#include "util.h"
+#include "field_effect_helpers.h"
+
+#define subsprite_table(ptr) {.subsprites = ptr, .subspriteCount = (sizeof ptr) / (sizeof(struct Subsprite))}
+
+#define obj_frame_tiles(ptr) {.data = (u8 *)ptr, .size = sizeof ptr}
+
+const u32 gSpriteImage_839DC14[] = INCBIN_U32("graphics/birch_speech/birch.4bpp");
+const u16 gBirchPalette[16] = INCBIN_U16("graphics/birch_speech/birch.gbapal");
+const u32 gSpriteImage_839E434[] = INCBIN_U32("graphics/misc/pokeball_glow.4bpp");
+const u16 gFieldEffectObjectPalette4[16] = INCBIN_U16("graphics/field_effect_objects/palettes/04.gbapal");
+const u32 gSpriteImage_839E474[] = INCBIN_U32("graphics/misc/pokecenter_monitor/0.4bpp");
+const u32 gSpriteImage_839E534[] = INCBIN_U32("graphics/misc/pokecenter_monitor/1.4bpp");
+const u32 gSpriteImage_839E5F4[] = INCBIN_U32("graphics/misc/big_hof_monitor.4bpp");
+const u32 gSpriteImage_839E7F4[] = INCBIN_U32("graphics/misc/small_hof_monitor.4bpp");
+const u16 gFieldEffectObjectPalette5[16] = INCBIN_U16("graphics/field_effect_objects/palettes/05.gbapal");
+
+// Graphics for the lights streaking past your Pokemon when it uses a field move.
+const u32 gFieldMoveStreaksTiles[] = INCBIN_U32("graphics/misc/field_move_streaks.4bpp");
+const u16 gFieldMoveStreaksPalette[16] = INCBIN_U16("graphics/misc/field_move_streaks.gbapal");
+const u16 gFieldMoveStreaksTilemap[] = INCBIN_U16("graphics/misc/field_move_streaks_map.bin");
+
+// The following light streaks effect is used when the map is dark (e.g. a cave).
+const u32 gDarknessFieldMoveStreaksTiles[] = INCBIN_U32("graphics/misc/darkness_field_move_streaks.4bpp");
+const u16 gDarknessFieldMoveStreaksPalette[16] = INCBIN_U16("graphics/misc/darkness_field_move_streaks.gbapal");
+const u16 gDarknessFieldMoveStreaksTilemap[] = INCBIN_U16("graphics/misc/darkness_field_move_streaks_map.bin");
+
+bool8 (*const gFieldEffectScriptFuncs[])(u8 **, u32 *) = {
+ FieldEffectCmd_loadtiles,
+ FieldEffectCmd_loadfadedpal,
+ FieldEffectCmd_loadpal,
+ FieldEffectCmd_callnative,
+ FieldEffectCmd_end,
+ FieldEffectCmd_loadgfx_callnative,
+ FieldEffectCmd_loadtiles_callnative,
+ FieldEffectCmd_loadfadedpal_callnative,
+};
+
+const struct OamData gOamData_839F0F4 = {.size = 3};
+const struct OamData gOamData_839F0FC = {.size = 0};
+const struct OamData gOamData_839F104 = {.size = 1};
+
+const struct SpriteFrameImage gSpriteImageTable_839F10C[] = {
+ obj_frame_tiles(gSpriteImage_839DC14)
+};
+const struct SpritePalette gUnknown_0839F114 = {.data = gBirchPalette, .tag = 0x1006};
+
+const union AnimCmd gSpriteAnim_839F11C[] = {
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 1),
+ ANIMCMD_END
+};
+
+const union AnimCmd *const gSpriteAnimTable_839F124[] = {
+ gSpriteAnim_839F11C
+};
+
+const struct SpriteTemplate gSpriteTemplate_839F128 = {
+ .tileTag = 0xffff,
+ .paletteTag = 4102,
+ .oam = &gOamData_839F0F4,
+ .anims = (const union AnimCmd *const *)&gSpriteAnimTable_839F124,
+ .images = gSpriteImageTable_839F10C,
+ .affineAnims = (const union AffineAnimCmd *const *)&gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy
+};
+
+const struct SpritePalette gFieldEffectObjectPaletteInfo4 = {.data = gFieldEffectObjectPalette4, .tag = 0x1007};
+const struct SpritePalette gFieldEffectObjectPaletteInfo5 = {.data = gFieldEffectObjectPalette5, .tag = 0x1010};
+const struct OamData gOamData_839F150 = {
+ .shape = 1,
+ .size = 2
+};
+
+const struct SpriteFrameImage gSpriteImageTable_839F158[] = {
+ obj_frame_tiles(gSpriteImage_839E434)
+};
+
+const struct SpriteFrameImage gSpriteImageTable_839F160[] = {
+ obj_frame_tiles(gSpriteImage_839E474),
+ obj_frame_tiles(gSpriteImage_839E534)
+};
+
+const struct SpriteFrameImage gSpriteImageTable_839F170[] = {
+ obj_frame_tiles(gSpriteImage_839E5F4)
+};
+
+const struct SpriteFrameImage gSpriteImageTable_839F178[] = {
+ {.data = (u8 *)gSpriteImage_839E7F4, .size = 0x200} // the macro breaks down here
+};
+
+const struct Subsprite Unknown_39F180[] = {
+ {.x = -12, .y = -8, .priority = 2, .tileOffset = 0, .shape = 1, .size = 0},
+ {.x = 4, .y = -8, .priority = 2, .tileOffset = 2, .shape = 0, .size = 0},
+ {.x = -12, .y = 0, .priority = 2, .tileOffset = 3, .shape = 1, .size = 0},
+ {.x = 4, .y = 0, .priority = 2, .tileOffset = 5, .shape = 0, .size = 0}
+};
+
+const struct SubspriteTable gUnknown_0839F1A0 = subsprite_table(Unknown_39F180);
+
+const struct Subsprite Unknown_39F1A8[] = {
+ {.x = -32, .y = -8, .priority = 2, .tileOffset = 0, .shape = 1, .size = 1},
+ {.x = 0, .y = -8, .priority = 2, .tileOffset = 4, .shape = 1, .size = 1},
+ {.x = -32, .y = 0, .priority = 2, .tileOffset = 8, .shape = 1, .size = 1},
+ {.x = 0, .y = 0, .priority = 2, .tileOffset = 12, .shape = 1, .size = 1}
+};
+
+const struct SubspriteTable gUnknown_0839F1C8 = subsprite_table(Unknown_39F1A8);
+
+const union AnimCmd gSpriteAnim_839F1D0[] = {
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 1),
+ ANIMCMD_JUMP(0)
+};
+
+const union AnimCmd gSpriteAnim_839F1D8[] = {
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 1, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 1, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 1, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 0, .duration = 16),
+ ANIMCMD_FRAME(.imageValue = 1, .duration = 16),
+ ANIMCMD_END
+};
+
+const union AnimCmd *const gSpriteAnimTable_839F1FC[] = {
+ gSpriteAnim_839F1D0,
+ gSpriteAnim_839F1D8
+};
+
+const union AnimCmd *const gSpriteAnimTable_839F204[] = {
+ gSpriteAnim_839F1D0
+};
+
+const struct SpriteTemplate gSpriteTemplate_839F208 = {
+ .tileTag = 0xffff,
+ .paletteTag = 4103,
+ .oam = &gOamData_839F0FC,
+ .anims = gSpriteAnimTable_839F1FC,
+ .images = gSpriteImageTable_839F158,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCB_PokeballGlow
+};
+
+
+const struct SpriteTemplate gSpriteTemplate_839F220 = {
+ .tileTag = 0xffff,
+ .paletteTag = 4100,
+ .oam = &gOamData_839F104,
+ .anims = gSpriteAnimTable_839F1FC,
+ .images = gSpriteImageTable_839F160,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCB_PokecenterMonitor
+};
+
+
+const struct SpriteTemplate gSpriteTemplate_839F238 = {
+ .tileTag = 0xffff,
+ .paletteTag = 4112,
+ .oam = &gOamData_839F104,
+ .anims = gSpriteAnimTable_839F204,
+ .images = gSpriteImageTable_839F170,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCB_HallOfFameMonitor
+};
+
+
+const struct SpriteTemplate gSpriteTemplate_839F250 = {
+ .tileTag = 0xffff,
+ .paletteTag = 4112,
+ .oam = &gOamData_839F150,
+ .anims = gSpriteAnimTable_839F204,
+ .images = gSpriteImageTable_839F178,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCB_HallOfFameMonitor
+};
+
+void (*const gUnknown_0839F268[])(struct Task *) = {
+ PokecenterHealEffect_0,
+ PokecenterHealEffect_1,
+ PokecenterHealEffect_2,
+ PokecenterHealEffect_3
+};
-typedef bool8 (*FldEffCmd)(u8 **, u32 *);
+void (*const gUnknown_0839F278[])(struct Task *) = {
+ HallOfFameRecordEffect_0,
+ HallOfFameRecordEffect_1,
+ HallOfFameRecordEffect_2,
+ HallOfFameRecordEffect_3
+};
+
+void (*const gUnknown_0839F288[])(struct Sprite *) = {
+ PokeballGlowEffect_0,
+ PokeballGlowEffect_1,
+ PokeballGlowEffect_2,
+ PokeballGlowEffect_3,
+ PokeballGlowEffect_4,
+ PokeballGlowEffect_5,
+ PokeballGlowEffect_6,
+ PokeballGlowEffect_7
+};
+
+const struct Coords16 gUnknown_0839F2A8[] = {
+ {.x = 0, .y = 0},
+ {.x = 6, .y = 0},
+ {.x = 0, .y = 4},
+ {.x = 6, .y = 4},
+ {.x = 0, .y = 8},
+ {.x = 6, .y = 8}
+};
+
+const u8 gUnknown_0839F2C0[] = {16, 12, 8, 0};
+const u8 gUnknown_0839F2C4[] = {16, 12, 8, 0};
+const u8 gUnknown_0839F2C8[] = { 0, 0, 0, 0};
+
+bool8 (*const gUnknown_0839F2CC[])(struct Task *) = {
+ sub_80867AC,
+ sub_8086854,
+ sub_8086870,
+ sub_80868E4,
+ sub_808699C,
+ sub_80869B8,
+ sub_80869F8
+};
+
+bool8 (*const gUnknown_0839F2E8[])(struct Task *) = {
+ sub_8086AA0,
+ sub_8086AC0,
+ sub_8086B30,
+ sub_8086B54,
+ sub_8086B64,
+ sub_8086B88
+};
+
+bool8 (*const gUnknown_0839F300[])(struct Task *) = {
+ sub_8086CF4,
+ sub_8086D70,
+ sub_8086DB0,
+ sub_8086E10,
+ sub_8086E50,
+ sub_8086EB0,
+ sub_8086ED4
+};
+
+bool8 (*const gUnknown_0839F31C[])(struct Task *, struct MapObject *) = {
+ sub_8086FB0,
+ waterfall_1_do_anim_probably,
+ waterfall_2_wait_anim_finish_probably,
+ sub_8087030,
+ sub_8087058
+};
+
+bool8 (*const gUnknown_0839F330[])(struct Task *) = {
+ sub_8087124,
+ dive_2_unknown,
+ dive_3_unknown
+};
+
+bool8 (*const gUnknown_0839F33C[])(struct Task *, struct MapObject *, struct Sprite *) = {
+ sub_808722C,
+ sub_8087264,
+ sub_8087298,
+ sub_80872E4,
+ sub_80873D8,
+ sub_80873F4
+};
+
+bool8 (*const gUnknown_0839F354[])(struct Task *, struct MapObject *, struct Sprite *) = {
+ sub_80874CC,
+ sub_80874FC,
+ sub_8087548,
+ sub_808759C
+};
+
+bool8 (*const gUnknown_0839F364[])(struct Task *, struct MapObject *, struct Sprite *) = {
+ sub_80876C8,
+ sub_80876F8,
+ sub_8087774,
+ sub_80877AC,
+ sub_80877D4
+};
+
+void (*const gUnknown_0839F378[])(struct Task *) = {
+ sub_80878F4,
+ sub_8087914
+};
+
+const u8 gUnknown_0839F380[] = {1, 3, 4, 2, 1};
+
+void (*const gUnknown_0839F388[])(struct Task *) = {
+ sub_8087AA4,
+ sub_8087AC8
+};
+
+void (*const gUnknown_0839F390[])(struct Task *) = {
+ sub_8087BEC,
+ sub_8087C14,
+ sub_8087CA4,
+ sub_8087D78
+};
+
+void (*const gUnknown_0839F3A0[])(struct Task *) = {
+ sub_8087E4C,
+ sub_8087ED8,
+ sub_8087FDC
+};
+
+void (*const gUnknown_0839F3AC[])(struct Task *) = {
+ sub_8088150,
+ sub_80881C0,
+ sub_8088228,
+ sub_80882B4,
+ sub_80882E4,
+ sub_8088338,
+ sub_8088380
+};
+
+void (*const gUnknown_0839F3C8[])(struct Task *) = {
+ sub_80884AC,
+ sub_80884E8,
+ sub_8088554,
+ sub_80885A8,
+ sub_80885D8,
+ sub_808860C,
+ sub_808862C
+};
+
+void (*const gUnknown_0839F3E4[])(struct Task *) = {
+ sub_8088984,
+ sub_80889E4,
+ sub_8088A30,
+ sub_8088A78,
+ sub_8088AF4
+};
+
+void (*const gUnknown_0839F3F8[])(struct Task *) = {
+ sub_8088CA0,
+ sub_8088CF8,
+ sub_8088D3C,
+ sub_8088D94,
+ sub_8088DD8,
+ sub_8088E2C,
+ sub_8088EB4,
+ sub_8088F10,
+ sub_8088F30
+};
+
+const union AffineAnimCmd SpriteAffineAnim_839F41C[] = {
+ AFFINEANIMCMD_FRAME(8, 8, -30, 0),
+ AFFINEANIMCMD_FRAME(28, 28, 0, 30),
+ AFFINEANIMCMD_END
+};
+
+const union AffineAnimCmd SpriteAffineAnim_839F434[] = {
+ AFFINEANIMCMD_FRAME(256, 256, 64, 0),
+ AFFINEANIMCMD_FRAME(-10, -10, 0, 22),
+ AFFINEANIMCMD_END
+};
+
+const union AffineAnimCmd *const gSpriteAffineAnimTable_0839F44C[] = {
+ SpriteAffineAnim_839F41C,
+ SpriteAffineAnim_839F434
+};
+
+void (*const gUnknown_0839F454[])(struct Task *) = {
+ sub_80892A0,
+ sub_8089354,
+ sub_80893C0,
+ sub_8089414,
+ sub_808948C,
+ sub_80894C4,
+ fishE
+};
+
+const s16 gUnknown_0839F470[] = {
+ -2,
+ -4,
+ -5,
+ -6,
+ -7,
+ -8,
+ -8,
+ -8,
+ -7,
+ -7,
+ -6,
+ -5,
+ -3,
+ -2,
+ 0,
+ 2,
+ 4,
+ 8
+};
static u8 sActiveList[32];
extern u8 *gFieldEffectScriptPointers[];
-extern FldEffCmd gFieldEffectScriptFuncs[];
-
u32 FieldEffectStart(u8 id)
{
u8 *script;
@@ -207,3 +617,2789 @@ bool8 FieldEffectActiveListContains(u8 id)
return TRUE;
return FALSE;
}
+
+u8 CreateTrainerSprite_BirchSpeech(u8 gender, s16 x, s16 y, u8 subpriority, u8 *buffer)
+{
+ struct SpriteTemplate spriteTemplate;
+ LoadCompressedObjectPaletteOverrideBuffer(&gTrainerFrontPicPaletteTable[gender], buffer);
+ LoadCompressedObjectPicOverrideBuffer(&gTrainerFrontPicTable[gender], buffer);
+ spriteTemplate.tileTag = gTrainerFrontPicTable[gender].tag;
+ spriteTemplate.paletteTag = gTrainerFrontPicPaletteTable[gender].tag;
+ spriteTemplate.oam = &gOamData_839F0F4;
+ spriteTemplate.anims = gDummySpriteAnimTable;
+ spriteTemplate.images = NULL;
+ spriteTemplate.affineAnims = gDummySpriteAffineAnimTable;
+ spriteTemplate.callback = SpriteCallbackDummy;
+ return CreateSprite(&spriteTemplate, x, y, subpriority);
+}
+
+void LoadTrainerGfx_TrainerCard(u8 gender, u16 palOffset, u8 *dest)
+{
+ LZDecompressVram(gTrainerFrontPicTable[gender].data, dest);
+ LoadCompressedPalette(gTrainerFrontPicPaletteTable[gender].data, palOffset, 0x20);
+}
+
+u8 CreateBirchSprite(s16 x, s16 y, u8 subpriority)
+{
+ LoadSpritePalette(&gUnknown_0839F114);
+ return CreateSprite(&gSpriteTemplate_839F128, x, y, subpriority);
+}
+
+u8 CreateMonSprite_PicBox(u16 species, s16 x, s16 y, u8 subpriority)
+{
+ DecompressPicFromTable_2(&gMonFrontPicTable[species], gMonFrontPicCoords[species].coords, gMonFrontPicCoords[species].y_offset, gUnknown_081FAF4C[3], gUnknown_081FAF4C[3], species);
+ LoadCompressedObjectPalette(&gMonPaletteTable[species]);
+ GetMonSpriteTemplate_803C56C(species, 3);
+ gUnknown_02024E8C.paletteTag = gMonPaletteTable[0].tag;
+ sub_807DE38(IndexOfSpritePaletteTag(gMonPaletteTable[0].tag) + 0x10);
+ return CreateSprite(&gUnknown_02024E8C, x, y, subpriority);
+}
+
+u8 CreateMonSprite_FieldMove(u16 species, u32 d, u32 g, s16 x, s16 y, u8 subpriority)
+{
+ const struct SpritePalette *spritePalette;
+ HandleLoadSpecialPokePic(&gMonFrontPicTable[species], gMonFrontPicCoords[species].coords, gMonFrontPicCoords[species].y_offset, (u32)gUnknown_081FAF4C[3] /* this is actually u8* or something, pointing to ewram */, gUnknown_081FAF4C[3], species, g);
+ spritePalette = sub_80409C8(species, d, g);
+ LoadCompressedObjectPalette(spritePalette);
+ GetMonSpriteTemplate_803C56C(species, 3);
+ gUnknown_02024E8C.paletteTag = spritePalette->tag;
+ sub_807DE38(IndexOfSpritePaletteTag(spritePalette->tag) + 0x10);
+ return CreateSprite(&gUnknown_02024E8C, x, y, subpriority);
+}
+
+void FreeResourcesAndDestroySprite(struct Sprite *sprite)
+{
+ sub_807DE68();
+ FreeSpritePaletteByTag(GetSpritePaletteTagByPaletteNum(sprite->oam.paletteNum));
+ if (sprite->oam.affineMode != 0)
+ {
+ FreeOamMatrix(sprite->oam.matrixNum);
+ }
+ DestroySprite(sprite);
+}
+
+#ifdef NONMATCHING
+void MultiplyInvertedPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
+{
+ int curRed;
+ int curGreen;
+ int curBlue;
+
+ curRed = gPlttBufferUnfaded[i] & 0x1f;
+ curGreen = (gPlttBufferUnfaded[i] & (0x1f << 5)) >> 5;
+ curBlue = (gPlttBufferUnfaded[i] & (0x1f << 10)) >> 10;
+ curRed += (((0x1f - curRed) * r) >> 4);
+ curGreen += (((0x1f - curGreen) * g) >> 4);
+ curBlue += (((0x1f - curBlue) * b) >> 4);
+ gPlttBufferFaded[i] = RGB(curRed, curGreen, curBlue);
+}
+
+void MultiplyPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
+{
+ int curRed;
+ int curGreen;
+ int curBlue;
+
+ curRed = gPlttBufferUnfaded[i] & 0x1f;
+ curGreen = (gPlttBufferUnfaded[i] & (0x1f << 5)) >> 5;
+ curBlue = (gPlttBufferUnfaded[i] & (0x1f << 10)) >> 10;
+ curRed -= ((curRed * r) >> 4);
+ curGreen -= ((curGreen * g) >> 4);
+ curBlue -= ((curBlue * b) >> 4);
+ gPlttBufferFaded[i] = RGB(curRed, curGreen, curBlue);
+}
+#else
+__attribute__((naked))
+void MultiplyInvertedPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
+{
+ asm(".syntax unified\n"
+ "\tpush {r4-r7,lr}\n"
+ "\tmov r7, r9\n"
+ "\tmov r6, r8\n"
+ "\tpush {r6,r7}\n"
+ "\tlsls r0, 16\n"
+ "\tlsls r1, 24\n"
+ "\tlsrs r1, 24\n"
+ "\tlsls r2, 24\n"
+ "\tlsrs r2, 24\n"
+ "\tlsls r3, 24\n"
+ "\tlsrs r3, 24\n"
+ "\tldr r4, _08085D00 @ =gPlttBufferUnfaded\n"
+ "\tlsrs r0, 15\n"
+ "\tadds r4, r0, r4\n"
+ "\tldrh r4, [r4]\n"
+ "\tmovs r5, 0x1F\n"
+ "\tmov r9, r5\n"
+ "\tmov r8, r4\n"
+ "\tmov r6, r8\n"
+ "\tands r6, r5\n"
+ "\tmov r8, r6\n"
+ "\tmovs r6, 0xF8\n"
+ "\tlsls r6, 2\n"
+ "\tands r6, r4\n"
+ "\tlsrs r6, 5\n"
+ "\tmovs r5, 0xF8\n"
+ "\tlsls r5, 7\n"
+ "\tands r4, r5\n"
+ "\tlsrs r4, 10\n"
+ "\tmov r7, r9\n"
+ "\tmov r5, r8\n"
+ "\tsubs r7, r5\n"
+ "\tmov r12, r7\n"
+ "\tmov r7, r12\n"
+ "\tmuls r7, r1\n"
+ "\tadds r1, r7, 0\n"
+ "\tasrs r1, 4\n"
+ "\tadd r8, r1\n"
+ "\tmov r5, r9\n"
+ "\tsubs r1, r5, r6\n"
+ "\tmuls r1, r2\n"
+ "\tasrs r1, 4\n"
+ "\tadds r6, r1\n"
+ "\tsubs r5, r4\n"
+ "\tmov r9, r5\n"
+ "\tmov r1, r9\n"
+ "\tmuls r1, r3\n"
+ "\tasrs r1, 4\n"
+ "\tadds r4, r1\n"
+ "\tmov r7, r8\n"
+ "\tlsls r7, 16\n"
+ "\tlsls r6, 21\n"
+ "\torrs r6, r7\n"
+ "\tlsls r4, 26\n"
+ "\torrs r4, r6\n"
+ "\tlsrs r4, 16\n"
+ "\tldr r1, _08085D04 @ =gPlttBufferFaded\n"
+ "\tadds r0, r1\n"
+ "\tstrh r4, [r0]\n"
+ "\tpop {r3,r4}\n"
+ "\tmov r8, r3\n"
+ "\tmov r9, r4\n"
+ "\tpop {r4-r7}\n"
+ "\tpop {r0}\n"
+ "\tbx r0\n"
+ "\t.align 2, 0\n"
+ "_08085D00: .4byte gPlttBufferUnfaded\n"
+ "_08085D04: .4byte gPlttBufferFaded\n"
+ ".syntax divided");
+}
+
+__attribute__((naked))
+void MultiplyPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
+{
+ asm(".syntax unified\n"
+ "\tpush {r4-r6,lr}\n"
+ "\tmov r6, r8\n"
+ "\tpush {r6}\n"
+ "\tlsls r0, 16\n"
+ "\tlsls r1, 24\n"
+ "\tlsrs r1, 24\n"
+ "\tlsls r2, 24\n"
+ "\tlsrs r2, 24\n"
+ "\tlsls r3, 24\n"
+ "\tlsrs r3, 24\n"
+ "\tldr r4, _08085D78 @ =gPlttBufferUnfaded\n"
+ "\tlsrs r0, 15\n"
+ "\tadds r4, r0, r4\n"
+ "\tldrh r4, [r4]\n"
+ "\tmovs r5, 0x1F\n"
+ "\tmov r8, r5\n"
+ "\tmov r6, r8\n"
+ "\tands r6, r4\n"
+ "\tmov r8, r6\n"
+ "\tmovs r5, 0xF8\n"
+ "\tlsls r5, 2\n"
+ "\tands r5, r4\n"
+ "\tlsrs r5, 5\n"
+ "\tmovs r6, 0xF8\n"
+ "\tlsls r6, 7\n"
+ "\tands r4, r6\n"
+ "\tlsrs r4, 10\n"
+ "\tmov r6, r8\n"
+ "\tmuls r6, r1\n"
+ "\tadds r1, r6, 0\n"
+ "\tasrs r1, 4\n"
+ "\tmov r6, r8\n"
+ "\tsubs r6, r1\n"
+ "\tadds r1, r5, 0\n"
+ "\tmuls r1, r2\n"
+ "\tasrs r1, 4\n"
+ "\tsubs r5, r1\n"
+ "\tadds r1, r4, 0\n"
+ "\tmuls r1, r3\n"
+ "\tasrs r1, 4\n"
+ "\tsubs r4, r1\n"
+ "\tlsls r6, 16\n"
+ "\tlsls r5, 21\n"
+ "\torrs r5, r6\n"
+ "\tlsls r4, 26\n"
+ "\torrs r4, r5\n"
+ "\tlsrs r4, 16\n"
+ "\tldr r1, _08085D7C @ =gPlttBufferFaded\n"
+ "\tadds r0, r1\n"
+ "\tstrh r4, [r0]\n"
+ "\tpop {r3}\n"
+ "\tmov r8, r3\n"
+ "\tpop {r4-r6}\n"
+ "\tpop {r0}\n"
+ "\tbx r0\n"
+ "\t.align 2, 0\n"
+ "_08085D78: .4byte gPlttBufferUnfaded\n"
+ "_08085D7C: .4byte gPlttBufferFaded\n"
+ ".syntax divided");
+}
+#endif
+
+void Task_PokecenterHeal(u8 taskId);
+u8 CreatePokeballGlowSprite(s16, s16, s16, u16);
+u8 PokecenterHealEffectHelper(s16, s16);
+
+bool8 FldEff_PokecenterHeal(void)
+{
+ u8 nPokemon;
+ struct Task *task;
+
+ nPokemon = CalculatePlayerPartyCount();
+ task = &gTasks[CreateTask(Task_PokecenterHeal, 0xff)];
+ task->data[1] = nPokemon;
+ task->data[2] = 0x5d;
+ task->data[3] = 0x24;
+ task->data[4] = 0x7c;
+ task->data[5] = 0x18;
+ return FALSE;
+}
+
+void Task_PokecenterHeal(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ gUnknown_0839F268[task->data[0]](task);
+}
+
+void PokecenterHealEffect_0(struct Task *task)
+{
+ task->data[0]++;
+ task->data[6] = CreatePokeballGlowSprite(task->data[1], task->data[2], task->data[3], 1);
+ task->data[7] = PokecenterHealEffectHelper(task->data[4], task->data[5]);
+}
+
+void PokecenterHealEffect_1(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 1)
+ {
+ gSprites[task->data[7]].data0++;
+ task->data[0]++;
+ }
+}
+
+void PokecenterHealEffect_2(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 4)
+ {
+ task->data[0]++;
+ }
+}
+
+void PokecenterHealEffect_3(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 6)
+ {
+ DestroySprite(&gSprites[task->data[6]]);
+ FieldEffectActiveListRemove(FLDEFF_POKECENTER_HEAL);
+ DestroyTask(FindTaskIdByFunc(Task_PokecenterHeal));
+ }
+}
+
+void Task_HallOfFameRecord(u8 taskId);
+void HallOfFameRecordEffectHelper(s16, s16, s16, u8);
+
+bool8 FldEff_HallOfFameRecord(void)
+{
+ u8 nPokemon;
+ struct Task *task;
+
+ nPokemon = CalculatePlayerPartyCount();
+ task = &gTasks[CreateTask(Task_HallOfFameRecord, 0xff)];
+ task->data[1] = nPokemon;
+ task->data[2] = 0x75;
+ task->data[3] = 0x34;
+ return FALSE;
+}
+
+void Task_HallOfFameRecord(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ gUnknown_0839F278[task->data[0]](task);
+}
+
+void HallOfFameRecordEffect_0(struct Task *task)
+{
+ u8 taskId;
+ task->data[0]++;
+ task->data[6] = CreatePokeballGlowSprite(task->data[1], task->data[2], task->data[3], 0);
+ taskId = FindTaskIdByFunc(Task_HallOfFameRecord);
+ HallOfFameRecordEffectHelper(taskId, 0x78, 0x18, 0);
+ HallOfFameRecordEffectHelper(taskId, 0x28, 0x08, 1);
+ HallOfFameRecordEffectHelper(taskId, 0x48, 0x08, 1);
+ HallOfFameRecordEffectHelper(taskId, 0xa8, 0x08, 1);
+ HallOfFameRecordEffectHelper(taskId, 0xc8, 0x08, 1);
+}
+
+void HallOfFameRecordEffect_1(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 1)
+ {
+ task->data[15]++; // was this ever initialized? is this ever used?
+ task->data[0]++;
+ }
+}
+
+void HallOfFameRecordEffect_2(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 4)
+ {
+ task->data[0]++;
+ }
+}
+
+void HallOfFameRecordEffect_3(struct Task *task)
+{
+ if (gSprites[task->data[6]].data0 > 6)
+ {
+ DestroySprite(&gSprites[task->data[6]]);
+ FieldEffectActiveListRemove(FLDEFF_HALL_OF_FAME_RECORD);
+ DestroyTask(FindTaskIdByFunc(Task_HallOfFameRecord));
+ }
+}
+
+void SpriteCB_PokeballGlowEffect(struct Sprite *);
+
+u8 CreatePokeballGlowSprite(s16 data6, s16 x, s16 y, u16 data5)
+{
+ u8 spriteId;
+ struct Sprite *sprite;
+ spriteId = CreateInvisibleSprite(SpriteCB_PokeballGlowEffect);
+ sprite = &gSprites[spriteId];
+ sprite->pos2.x = x;
+ sprite->pos2.y = y;
+ sprite->data5 = data5;
+ sprite->data6 = data6;
+ sprite->data7 = spriteId;
+ return spriteId;
+}
+
+void SpriteCB_PokeballGlowEffect(struct Sprite *sprite)
+{
+ gUnknown_0839F288[sprite->data0](sprite);
+}
+
+void PokeballGlowEffect_0(struct Sprite *sprite)
+{
+ u8 endSpriteId;
+ if (sprite->data1 == 0 || (--sprite->data1) == 0)
+ {
+ sprite->data1 = 25;
+ endSpriteId = CreateSpriteAtEnd(&gSpriteTemplate_839F208, gUnknown_0839F2A8[sprite->data2].x + sprite->pos2.x, gUnknown_0839F2A8[sprite->data2].y + sprite->pos2.y, 0);
+ gSprites[endSpriteId].oam.priority = 2;
+ gSprites[endSpriteId].data0 = sprite->data7;
+ sprite->data2++;
+ sprite->data6--;
+ PlaySE(SE_BOWA);
+ }
+ if (sprite->data6 == 0)
+ {
+ sprite->data1 = 32;
+ sprite->data0++;
+ }
+}
+
+void PokeballGlowEffect_1(struct Sprite *sprite)
+{
+ if ((--sprite->data1) == 0)
+ {
+ sprite->data0++;
+ sprite->data1 = 8;
+ sprite->data2 = 0;
+ sprite->data3 = 0;
+ if (sprite->data5)
+ {
+ PlayFanfare(BGM_ME_ASA);
+ }
+ }
+}
+
+void PokeballGlowEffect_2(struct Sprite *sprite)
+{
+ u8 phase;
+ if ((--sprite->data1) == 0)
+ {
+ sprite->data1 = 8;
+ sprite->data2++;
+ sprite->data2 &= 3;
+ if (sprite->data2 == 0)
+ {
+ sprite->data3++;
+ }
+ }
+ phase = (sprite->data2 + 3) & 3;
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x108, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ phase = (sprite->data2 + 2) & 3;
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x106, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ phase = (sprite->data2 + 1) & 3;
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x102, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ phase = sprite->data2;
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x105, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x103, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ if (sprite->data3 > 2)
+ {
+ sprite->data0++;
+ sprite->data1 = 8;
+ sprite->data2 = 0;
+ }
+}
+
+void PokeballGlowEffect_3(struct Sprite *sprite)
+{
+ u8 phase;
+ if ((--sprite->data1) == 0)
+ {
+ sprite->data1 = 8;
+ sprite->data2++;
+ sprite->data2 &= 3;
+ if (sprite->data2 == 3)
+ {
+ sprite->data0++;
+ sprite->data1 = 30;
+ }
+ }
+ phase = sprite->data2;
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x108, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x106, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x102, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x105, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+ MultiplyInvertedPaletteRGBComponents((IndexOfSpritePaletteTag(0x1007) << 4) + 0x103, gUnknown_0839F2C0[phase], gUnknown_0839F2C4[phase], gUnknown_0839F2C8[phase]);
+}
+
+void PokeballGlowEffect_4(struct Sprite *sprite)
+{
+ if ((--sprite->data1) == 0)
+ {
+ sprite->data0++;
+ }
+}
+
+void PokeballGlowEffect_5(struct Sprite *sprite)
+{
+ sprite->data0++;
+}
+
+void PokeballGlowEffect_6(struct Sprite *sprite)
+{
+ if (sprite->data5 == 0 || IsFanfareTaskInactive())
+ {
+ sprite->data0++;
+ }
+}
+
+void PokeballGlowEffect_7(struct Sprite *sprite)
+{
+}
+
+void SpriteCB_PokeballGlow(struct Sprite *sprite)
+{
+ if (gSprites[sprite->data0].data0 > 4)
+ {
+ FieldEffectFreeGraphicsResources(sprite);
+ }
+}
+
+u8 PokecenterHealEffectHelper(s16 x, s16 y)
+{
+ u8 spriteIdAtEnd;
+ struct Sprite *sprite;
+ spriteIdAtEnd = CreateSpriteAtEnd(&gSpriteTemplate_839F220, x, y, 0);
+ sprite = &gSprites[spriteIdAtEnd];
+ sprite->oam.priority = 2;
+ sprite->invisible = 1;
+ SetSubspriteTables(sprite, &gUnknown_0839F1A0);
+ return spriteIdAtEnd;
+}
+
+void SpriteCB_PokecenterMonitor(struct Sprite *sprite)
+{
+ if (sprite->data0 != 0)
+ {
+ sprite->data0 = 0;
+ sprite->invisible = 0;
+ StartSpriteAnim(sprite, 1);
+ }
+ if (sprite->animEnded)
+ {
+ FieldEffectFreeGraphicsResources(sprite);
+ }
+}
+
+void HallOfFameRecordEffectHelper(s16 a0, s16 a1, s16 a2, u8 a3)
+{
+ u8 spriteIdAtEnd;
+ if (!a3)
+ {
+ spriteIdAtEnd = CreateSpriteAtEnd(&gSpriteTemplate_839F238, a1, a2, 0);
+ SetSubspriteTables(&gSprites[spriteIdAtEnd], &gUnknown_0839F1C8);
+ } else
+ {
+ spriteIdAtEnd = CreateSpriteAtEnd(&gSpriteTemplate_839F250, a1, a2, 0);
+ }
+ gSprites[spriteIdAtEnd].invisible = 1;
+ gSprites[spriteIdAtEnd].data0 = a0;
+}
+
+void SpriteCB_HallOfFameMonitor(struct Sprite *sprite)
+{
+ if (gTasks[sprite->data0].data[15])
+ {
+ if (sprite->data1 == 0 || (--sprite->data1) == 0)
+ {
+ sprite->data1 = 16;
+ sprite->invisible ^= 1;
+ }
+ sprite->data2++;
+ }
+ if (sprite->data2 > 127)
+ {
+ FieldEffectFreeGraphicsResources(sprite);
+ }
+}
+
+void mapldr_080842E8(void);
+void mapldr_08084390(void);
+void task00_8084310(u8);
+void c3_080843F8(u8);
+
+void sub_80865BC(void)
+{
+ SetMainCallback2(c2_exit_to_overworld_2_switch);
+ gFieldCallback = mapldr_080842E8;
+}
+
+void mapldr_080842E8(void)
+{
+ pal_fill_black();
+ CreateTask(task00_8084310, 0);
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ gFieldCallback = NULL;
+}
+
+void task00_8084310(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ if (!task->data[0])
+ {
+ if (!sub_807D770())
+ {
+ return;
+ }
+ gUnknown_0202FF84[0] = gLastFieldPokeMenuOpened;
+ if ((int)gUnknown_0202FF84[0] > 5)
+ {
+ gUnknown_0202FF84[0] = 0;
+ }
+ FieldEffectStart(FLDEFF_USE_FLY);
+ task->data[0]++;
+ }
+ if (!FieldEffectActiveListContains(FLDEFF_USE_FLY))
+ {
+ flag_var_implications_of_teleport_();
+ warp_in();
+ SetMainCallback2(CB2_LoadMap);
+ gFieldCallback = mapldr_08084390;
+ DestroyTask(taskId);
+ }
+}
+
+void mapldr_08084390(void)
+{
+ sub_8053E90();
+ pal_fill_black();
+ CreateTask(c3_080843F8, 0);
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 1;
+ if (gPlayerAvatar.flags & 0x08)
+ {
+ FieldObjectTurn(&gMapObjects[gPlayerAvatar.mapObjectId], DIR_WEST);
+ }
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ gFieldCallback = NULL;
+}
+
+void c3_080843F8(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ if (task->data[0] == 0)
+ {
+ if (gPaletteFade.active)
+ {
+ return;
+ }
+ FieldEffectStart(FLDEFF_FLY_IN);
+ task->data[0]++;
+ }
+ if (!FieldEffectActiveListContains(FLDEFF_FLY_IN))
+ {
+ ScriptContext2_Disable();
+ UnfreezeMapObjects();
+ DestroyTask(taskId);
+ }
+}
+
+extern void pal_fill_for_map_transition(void);
+void sub_8086774(u8);
+extern void CameraObjectReset2(void);
+extern void CameraObjectReset1(void);
+
+void sub_8086748(void)
+{
+ sub_8053E90();
+ pal_fill_for_map_transition();
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ CreateTask(sub_8086774, 0);
+ gFieldCallback = NULL;
+}
+
+void sub_8086774(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ while (gUnknown_0839F2CC[task->data[0]](task)); // return code signifies whether to continue blocking here
+}
+
+bool8 sub_80867AC(struct Task *task) // gUnknown_0839F2CC[0]
+{
+ struct MapObject *playerObject;
+ struct Sprite *playerSprite;
+ playerObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ playerSprite = &gSprites[gPlayerAvatar.spriteId];
+ CameraObjectReset2();
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 1;
+ gPlayerAvatar.unk6 = 1;
+ FieldObjectSetSpecialAnim(playerObject, GetFaceDirectionAnimId(player_get_direction_lower_nybble()));
+ task->data[4] = playerSprite->subspriteMode;
+ playerObject->mapobj_bit_26 = 1;
+ playerSprite->oam.priority = 1;
+ playerSprite->subspriteMode = 2;
+ task->data[0]++;
+ return TRUE;
+}
+
+bool8 sub_8086854(struct Task *task) // gUnknown_0839F2CC[1]
+{
+ if (sub_807D770())
+ {
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_8086870(struct Task *task) // gUnknown_0839F2CC[2]
+{
+ struct Sprite *sprite;
+ s16 centerToCornerVecY;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ centerToCornerVecY = -(sprite->centerToCornerVecY << 1);
+ sprite->pos2.y = -(sprite->pos1.y + sprite->centerToCornerVecY + gSpriteCoordOffsetY + centerToCornerVecY);
+ task->data[1] = 1;
+ task->data[2] = 0;
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 0;
+ PlaySE(SE_RU_HYUU);
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_80868E4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ struct Sprite *sprite;
+
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.y += task->data[1];
+ if (task->data[1] < 8)
+ {
+ task->data[2] += task->data[1];
+ if (task->data[2] & 0xf)
+ {
+ task->data[1] <<= 1;
+ }
+ }
+ if (task->data[3] == 0 && sprite->pos2.y >= -16)
+ {
+ task->data[3]++;
+ mapObject->mapobj_bit_26 = 0;
+ sprite->subspriteMode = task->data[4];
+ mapObject->mapobj_bit_2 = 1;
+ }
+ if (sprite->pos2.y >= 0)
+ {
+ PlaySE(SE_W070);
+ mapObject->mapobj_bit_3 = 1;
+ mapObject->mapobj_bit_5 = 1;
+ sprite->pos2.y = 0;
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_808699C(struct Task *task)
+{
+ task->data[0]++;
+ task->data[1] = 4;
+ task->data[2] = 0;
+ SetCameraPanningCallback(NULL);
+ return TRUE;
+}
+
+bool8 sub_80869B8(struct Task *task)
+{
+ SetCameraPanning(0, task->data[1]);
+ task->data[1] = -task->data[1];
+ task->data[2]++;
+ if ((task->data[2] & 3) == 0)
+ {
+ task->data[1] >>= 1;
+ }
+ if (task->data[1] == 0)
+ {
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_80869F8(struct Task *task)
+{
+ gPlayerAvatar.unk6 = 0;
+ ScriptContext2_Disable();
+ CameraObjectReset1();
+ UnfreezeMapObjects();
+ InstallCameraPanAheadCallback();
+ DestroyTask(FindTaskIdByFunc(sub_8086774));
+ return FALSE;
+}
+
+void sub_8086A68(u8);
+extern void sub_80B4824(u8);
+extern void sub_8053FF8(void);
+extern void fade_8080918(void);
+
+void sub_8086B98(struct Task *);
+void sub_8086BE4(struct Task *);
+void sub_8086C30(void);
+void sub_8086C40(void);
+bool8 sub_8054034(void);
+void sub_8086C94(void);
+void sub_80B483C(void);
+void sub_8086CBC(u8);
+
+void sub_8086A2C(u8 a0, u8 priority)
+{
+ u8 taskId;
+ taskId = CreateTask(sub_8086A68, priority);
+ gTasks[taskId].data[1] = 0;
+ if (a0 == 0x6a)
+ {
+ gTasks[taskId].data[1] = 1;
+ }
+}
+
+void sub_8086A68(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ while (gUnknown_0839F2E8[task->data[0]](task));
+}
+
+bool8 sub_8086AA0(struct Task *task)
+{
+ FreezeMapObjects();
+ CameraObjectReset2();
+ sub_80B4824(task->data[1]);
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_8086AC0(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) || FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ FieldObjectSetSpecialAnim(mapObject, GetFaceDirectionAnimId(player_get_direction_lower_nybble()));
+ task->data[0]++;
+ task->data[2] = 0;
+ task->data[3] = 0;
+ if ((u8)task->data[1] == 0)
+ {
+ task->data[0] = 4;
+ }
+ PlaySE(SE_ESUKA);
+ }
+ return FALSE;
+}
+
+bool8 sub_8086B30(struct Task *task)
+{
+ sub_8086B98(task);
+ if (task->data[2] > 3)
+ {
+ sub_8086C30();
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_8086B54(struct Task *task)
+{
+ sub_8086B98(task);
+ sub_8086C40();
+ return FALSE;
+}
+
+bool8 sub_8086B64(struct Task *task)
+{
+ sub_8086BE4(task);
+ if (task->data[2] > 3)
+ {
+ sub_8086C30();
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_8086B88(struct Task *task)
+{
+ sub_8086BE4(task);
+ sub_8086C40();
+ return FALSE;
+}
+
+void sub_8086B98(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x84, task->data[2]);
+ sprite->pos2.y = Sin(0x94, task->data[2]);
+ task->data[3]++;
+ if (task->data[3] & 1)
+ {
+ task->data[2]++;
+ }
+}
+
+void sub_8086BE4(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x7c, task->data[2]);
+ sprite->pos2.y = Sin(0x76, task->data[2]);
+ task->data[3]++;
+ if (task->data[3] & 1)
+ {
+ task->data[2]++;
+ }
+}
+
+void sub_8086C30(void)
+{
+ sub_8053FF8();
+ fade_8080918();
+}
+
+void sub_8086C40(void)
+{
+ if (!gPaletteFade.active && sub_8054034() == TRUE)
+ {
+ sub_80B483C();
+ warp_in();
+ gFieldCallback = sub_8086C94;
+ SetMainCallback2(CB2_LoadMap);
+ DestroyTask(FindTaskIdByFunc(sub_8086A68));
+ }
+}
+
+void sub_8086C94(void)
+{
+ sub_8053E90();
+ pal_fill_for_map_transition();
+ ScriptContext2_Enable();
+ CreateTask(sub_8086CBC, 0);
+ gFieldCallback = NULL;
+}
+
+void sub_8086CBC(u8 taskId)
+{
+ struct Task *task;
+ task = &gTasks[taskId];
+ while (gUnknown_0839F300[task->data[0]](task));
+}
+
+bool8 sub_8086CF4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ s16 x;
+ s16 y;
+ u8 behavior;
+ CameraObjectReset2();
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ FieldObjectSetSpecialAnim(mapObject, GetFaceDirectionAnimId(DIR_EAST));
+ PlayerGetDestCoords(&x, &y);
+ behavior = MapGridGetMetatileBehaviorAt(x, y);
+ task->data[0]++;
+ task->data[1] = 16;
+ if (behavior == 0x6b)
+ {
+ behavior = 1;
+ task->data[0] = 3;
+ } else
+ {
+ behavior = 0;
+ }
+ sub_80B4824(behavior);
+ return TRUE;
+}
+
+bool8 sub_8086D70(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x84, task->data[1]);
+ sprite->pos2.y = Sin(0x94, task->data[1]);
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_8086DB0(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x84, task->data[1]);
+ sprite->pos2.y = Sin(0x94, task->data[1]);
+ task->data[2]++;
+ if (task->data[2] & 1)
+ {
+ task->data[1]--;
+ }
+ if (task->data[1] == 0)
+ {
+ sprite->pos2.x = 0;
+ sprite->pos2.y = 0;
+ task->data[0] = 5;
+ }
+ return FALSE;
+}
+
+bool8 sub_8086E10(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x7c, task->data[1]);
+ sprite->pos2.y = Sin(0x76, task->data[1]);
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_8086E50(struct Task *task)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.x = Cos(0x7c, task->data[1]);
+ sprite->pos2.y = Sin(0x76, task->data[1]);
+ task->data[2]++;
+ if (task->data[2] & 1)
+ {
+ task->data[1]--;
+ }
+ if (task->data[1] == 0)
+ {
+ sprite->pos2.x = 0;
+ sprite->pos2.y = 0;
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+extern bool8 sub_80B4850(void);
+
+bool8 sub_8086EB0(struct Task *task)
+{
+ if (sub_80B4850())
+ {
+ return FALSE;
+ }
+ sub_80B483C();
+ task->data[0]++;
+ return TRUE;
+}
+
+bool8 sub_8086ED4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ CameraObjectReset1();
+ ScriptContext2_Disable();
+ FieldObjectSetSpecialAnim(mapObject, GetGoSpeed0AnimId(DIR_EAST));
+ DestroyTask(FindTaskIdByFunc(sub_8086CBC));
+ }
+ return FALSE;
+}
+
+void sub_8086F64(u8);
+
+bool8 FldEff_UseWaterfall(void)
+{
+ u8 taskId;
+ taskId = CreateTask(sub_8086F64, 0xff);
+ gTasks[taskId].data[1] = gUnknown_0202FF84[0];
+ sub_8086F64(taskId);
+ return FALSE;
+}
+
+void sub_8086F64(u8 taskId)
+{
+ while (gUnknown_0839F31C[gTasks[taskId].data[0]](&gTasks[taskId], &gMapObjects[gPlayerAvatar.mapObjectId]));
+}
+
+bool8 sub_8086FB0(struct Task *task, struct MapObject *mapObject)
+{
+ ScriptContext2_Enable();
+ gPlayerAvatar.unk6 = 1;
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 waterfall_1_do_anim_probably(struct Task *task, struct MapObject *mapObject)
+{
+ ScriptContext2_Enable();
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject))
+ {
+ FieldObjectClearAnimIfSpecialAnimFinished(mapObject);
+ gUnknown_0202FF84[0] = task->data[1];
+ FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT);
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 waterfall_2_wait_anim_finish_probably(struct Task *task, struct MapObject *mapObject)
+{
+ if (FieldEffectActiveListContains(FLDEFF_FIELD_MOVE_SHOW_MON))
+ {
+ return FALSE;
+ }
+ task->data[0]++;
+ return TRUE;
+}
+
+bool8 sub_8087030(struct Task *task, struct MapObject *mapObject)
+{
+ FieldObjectSetSpecialAnim(mapObject, GetSimpleGoAnimId(DIR_NORTH));
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_8087058(struct Task *task, struct MapObject *mapObject)
+{
+ if (!FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ return FALSE;
+ }
+ if (MetatileBehavior_IsWaterfall(mapObject->mapobj_unk_1E))
+ {
+ task->data[0] = 3;
+ return TRUE;
+ }
+ ScriptContext2_Disable();
+ gPlayerAvatar.unk6 = 0;
+ DestroyTask(FindTaskIdByFunc(sub_8086F64));
+ FieldEffectActiveListRemove(FLDEFF_USE_WATERFALL);
+ return FALSE;
+}
+
+void Task_Dive(u8);
+extern int dive_warp(struct MapPosition *, u16);
+
+bool8 FldEff_UseDive(void)
+{
+ u8 taskId;
+ taskId = CreateTask(Task_Dive, 0xff);
+ gTasks[taskId].data[15] = gUnknown_0202FF84[0];
+ gTasks[taskId].data[14] = gUnknown_0202FF84[1];
+ Task_Dive(taskId);
+ return FALSE;
+}
+
+void Task_Dive(u8 taskId)
+{
+ while (gUnknown_0839F330[gTasks[taskId].data[0]](&gTasks[taskId]));
+}
+
+bool8 sub_8087124(struct Task *task)
+{
+ gPlayerAvatar.unk6 = 1;
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 dive_2_unknown(struct Task *task)
+{
+ ScriptContext2_Enable();
+ gUnknown_0202FF84[0] = task->data[15];
+ FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT);
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 dive_3_unknown(struct Task *task)
+{
+ struct MapPosition mapPosition;
+ PlayerGetDestCoords(&mapPosition.x, &mapPosition.y);
+ if (!FieldEffectActiveListContains(FLDEFF_FIELD_MOVE_SHOW_MON))
+ {
+ dive_warp(&mapPosition, gMapObjects[gPlayerAvatar.mapObjectId].mapobj_unk_1E);
+ DestroyTask(FindTaskIdByFunc(Task_Dive));
+ FieldEffectActiveListRemove(FLDEFF_USE_DIVE);
+ }
+ return FALSE;
+}
+
+void sub_80871D0(u8);
+void mapldr_080851BC(void);
+
+void sub_80871B8(u8 priority)
+{
+ CreateTask(sub_80871D0, priority);
+}
+
+void sub_80871D0(u8 taskId)
+{
+ while (gUnknown_0839F33C[gTasks[taskId].data[0]](&gTasks[taskId], &gMapObjects[gPlayerAvatar.mapObjectId], &gSprites[gPlayerAvatar.spriteId]));
+}
+
+bool8 sub_808722C(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ FreezeMapObjects();
+ CameraObjectReset2();
+ SetCameraPanningCallback(NULL);
+ gPlayerAvatar.unk6 = 1;
+ mapObject->mapobj_bit_26 = 1;
+ task->data[1] = 1;
+ task->data[0]++;
+ return TRUE;
+}
+
+bool8 sub_8087264(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ SetCameraPanning(0, task->data[1]);
+ task->data[1] = -task->data[1];
+ task->data[2]++;
+ if (task->data[2] > 7)
+ {
+ task->data[2] = 0;
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_8087298(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ sprite->pos2.y = 0;
+ task->data[3] = 1;
+ gUnknown_0202FF84[0] = mapObject->coords2.x;
+ gUnknown_0202FF84[1] = mapObject->coords2.y;
+ gUnknown_0202FF84[2] = sprite->subpriority - 1;
+ gUnknown_0202FF84[3] = sprite->oam.priority;
+ FieldEffectStart(FLDEFF_LAVARIDGE_GYM_WARP);
+ PlaySE(SE_W153);
+ task->data[0]++;
+ return TRUE;
+}
+
+bool8 sub_80872E4(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ s16 centerToCornerVecY;
+ SetCameraPanning(0, task->data[1]);
+ if (task->data[1] = -task->data[1], ++task->data[2] <= 17)
+ {
+ if (!(task->data[2] & 1) && (task->data[1] <= 3))
+ {
+ task->data[1] <<= 1;
+ }
+ } else if (!(task->data[2] & 4) && (task->data[1] > 0))
+ {
+ task->data[1] >>= 1;
+ }
+ if (task->data[2] > 6)
+ {
+ centerToCornerVecY = -(sprite->centerToCornerVecY << 1);
+ if (sprite->pos2.y > -(sprite->pos1.y + sprite->centerToCornerVecY + gSpriteCoordOffsetY + centerToCornerVecY))
+ {
+ sprite->pos2.y -= task->data[3];
+ if (task->data[3] <= 7)
+ {
+ task->data[3]++;
+ }
+ } else
+ {
+ task->data[4] = 1;
+ }
+ }
+ if (task->data[5] == 0 && sprite->pos2.y < -0x10)
+ {
+ task->data[5]++;
+ mapObject->mapobj_bit_26 = 1;
+ sprite->oam.priority = 1;
+ sprite->subspriteMode = 2;
+ }
+ if (task->data[1] == 0 && task->data[4] != 0)
+ {
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_80873D8(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ sub_8053FF8();
+ fade_8080918();
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_80873F4(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (!gPaletteFade.active && sub_8054034() == TRUE)
+ {
+ warp_in();
+ gFieldCallback = mapldr_080851BC;
+ SetMainCallback2(CB2_LoadMap);
+ DestroyTask(FindTaskIdByFunc(sub_80871D0));
+ }
+ return FALSE;
+}
+
+void sub_8087470(u8);
+extern u8 sub_80608A4(u8);
+
+void mapldr_080851BC(void)
+{
+ sub_8053E90();
+ pal_fill_for_map_transition();
+ ScriptContext2_Enable();
+ gFieldCallback = NULL;
+ CreateTask(sub_8087470, 0);
+}
+
+void sub_8087470(u8 taskId)
+{
+ while (gUnknown_0839F354[gTasks[taskId].data[0]](&gTasks[taskId], &gMapObjects[gPlayerAvatar.mapObjectId], &gSprites[gPlayerAvatar.spriteId]));
+}
+
+bool8 sub_80874CC(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ CameraObjectReset2();
+ FreezeMapObjects();
+ gPlayerAvatar.unk6 = 1;
+ mapObject->mapobj_bit_13 = 1;
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_80874FC(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (sub_807D770())
+ {
+ gUnknown_0202FF84[0] = mapObject->coords2.x;
+ gUnknown_0202FF84[1] = mapObject->coords2.y;
+ gUnknown_0202FF84[2] = sprite->subpriority - 1;
+ gUnknown_0202FF84[3] = sprite->oam.priority;
+ task->data[1] = FieldEffectStart(FLDEFF_POP_OUT_OF_ASH);
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_8087548(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ sprite = &gSprites[task->data[1]];
+ if (sprite->animCmdIndex > 1)
+ {
+ task->data[0]++;
+ mapObject->mapobj_bit_13 = 0;
+ CameraObjectReset1();
+ PlaySE(SE_W091);
+ FieldObjectSetSpecialAnim(mapObject, sub_80608A4(DIR_EAST));
+ }
+ return FALSE;
+}
+
+bool8 sub_808759C(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ gPlayerAvatar.unk6 = 0;
+ ScriptContext2_Disable();
+ UnfreezeMapObjects();
+ DestroyTask(FindTaskIdByFunc(sub_8087470));
+ }
+ return FALSE;
+}
+
+extern void sub_8060470(s16 *x, s16 *y, s16 dx, s16 dy);
+extern const struct SpriteTemplate *const gFieldEffectObjectTemplatePointers[36];
+
+u8 FldEff_LavaridgeGymWarp(void)
+{
+ u8 spriteId;
+ sub_8060470((s16 *)&gUnknown_0202FF84[0], (s16 *)&gUnknown_0202FF84[1], 8, 8);
+ spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[33], gUnknown_0202FF84[0], gUnknown_0202FF84[1], gUnknown_0202FF84[2]);
+ gSprites[spriteId].oam.priority = gUnknown_0202FF84[3];
+ gSprites[spriteId].coordOffsetEnabled = 1;
+ return spriteId;
+}
+
+void sub_8087638(struct Sprite *sprite)
+{
+ if (sprite->animEnded)
+ {
+ FieldEffectStop(sprite, FLDEFF_LAVARIDGE_GYM_WARP);
+ }
+}
+
+void sub_808766C(u8);
+
+void sub_8087654(u8 priority)
+{
+ CreateTask(sub_808766C, priority);
+}
+
+void sub_808766C(u8 taskId)
+{
+ while(gUnknown_0839F364[gTasks[taskId].data[0]](&gTasks[taskId], &gMapObjects[gPlayerAvatar.mapObjectId], &gSprites[gPlayerAvatar.spriteId]));
+}
+
+bool8 sub_80876C8(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ FreezeMapObjects();
+ CameraObjectReset2();
+ gPlayerAvatar.unk6 = 1;
+ mapObject->mapobj_bit_26 = 1;
+ task->data[0]++;
+ return FALSE;
+}
+
+bool8 sub_80876F8(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ if (task->data[1] > 3)
+ {
+ gUnknown_0202FF84[0] = mapObject->coords2.x;
+ gUnknown_0202FF84[1] = mapObject->coords2.y;
+ gUnknown_0202FF84[2] = sprite->subpriority - 1;
+ gUnknown_0202FF84[3] = sprite->oam.priority;
+ task->data[1] = FieldEffectStart(FLDEFF_POP_OUT_OF_ASH);
+ task->data[0]++;
+ } else
+ {
+ task->data[1]++;
+ FieldObjectSetSpecialAnim(mapObject, GetStepInPlaceDelay4AnimId(mapObject->mapobj_unk_18));
+ PlaySE(SE_FU_ZUZUZU);
+ }
+ }
+ return FALSE;
+}
+
+bool8 sub_8087774(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (gSprites[task->data[1]].animCmdIndex == 2)
+ {
+ mapObject->mapobj_bit_13 = 1;
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+bool8 sub_80877AC(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (!FieldEffectActiveListContains(FLDEFF_POP_OUT_OF_ASH))
+ {
+ sub_8053FF8();
+ fade_8080918();
+ task->data[0]++;
+ }
+ return FALSE;
+}
+
+void sub_80878C4(u8);
+void mapldr_080859D4(void);
+
+bool8 sub_80877D4(struct Task *task, struct MapObject *mapObject, struct Sprite *sprite)
+{
+ if (!gPaletteFade.active && sub_8054034() == TRUE)
+ {
+ warp_in();
+ gFieldCallback = sub_8086748;
+ SetMainCallback2(CB2_LoadMap);
+ DestroyTask(FindTaskIdByFunc(sub_808766C));
+ }
+ return FALSE;
+}
+
+u8 FldEff_PopOutOfAsh(void)
+{
+ u8 spriteId;
+ sub_8060470((s16 *)&gUnknown_0202FF84[0], (s16 *)&gUnknown_0202FF84[1], 8, 8);
+ spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[32], gUnknown_0202FF84[0], gUnknown_0202FF84[1], gUnknown_0202FF84[2]);
+ gSprites[spriteId].oam.priority = gUnknown_0202FF84[3];
+ gSprites[spriteId].coordOffsetEnabled = 1;
+ return spriteId;
+}
+
+void sub_808788C(struct Sprite *sprite)
+{
+ if (sprite->animEnded)
+ {
+ FieldEffectStop(sprite, FLDEFF_POP_OUT_OF_ASH);
+ }
+}
+
+void sub_80878A8(void)
+{
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ CreateTask(sub_80878C4, 0x50);
+}
+
+void sub_80878C4(u8 taskId)
+{
+ gUnknown_0839F378[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_80878F4(struct Task *task)
+{
+ task->data[0]++;
+ task->data[14] = 64;
+ task->data[15] = player_get_direction_lower_nybble();
+}
+
+void sub_8087914(struct Task *task)
+{
+ struct MapObject *mapObject;
+ u8 unknown_0839F380[5];
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ if (task->data[14] != 0 && (--task->data[14]) == 0)
+ {
+ sub_8053FF8();
+ fade_8080918();
+ }
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) || FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ if (task->data[14] == 0 && !gPaletteFade.active && sub_8054034() == TRUE)
+ {
+ FieldObjectSetDirection(mapObject, task->data[15]);
+ sub_8053678();
+ warp_in();
+ gFieldCallback = mapldr_080859D4;
+ SetMainCallback2(CB2_LoadMap);
+ DestroyTask(FindTaskIdByFunc(sub_80878C4));
+ } else if (task->data[1] == 0 || (--task->data[1]) == 0)
+ {
+ FieldObjectSetSpecialAnim(mapObject, GetFaceDirectionAnimId(unknown_0839F380[mapObject->mapobj_unk_18]));
+ if (task->data[2] < 12)
+ {
+ task->data[2]++;
+ }
+ task->data[1] = 8 >> (task->data[2] >> 2);
+ }
+ }
+}
+
+void sub_8087A74(u8);
+
+void mapldr_080859D4(void)
+{
+ sub_8053E90();
+ pal_fill_for_map_transition();
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ gFieldCallback = NULL;
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 1;
+ CreateTask(sub_8087A74, 0);
+}
+
+void sub_8087A74(u8 taskId)
+{
+ gUnknown_0839F388[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8087AA4(struct Task *task)
+{
+ if (sub_807D770())
+ {
+ task->data[0]++;
+ task->data[15] = player_get_direction_lower_nybble();
+ }
+}
+
+void sub_8087AC8(struct Task *task)
+{
+ struct MapObject *mapObject;
+ u8 unknown_0839F380[5];
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (task->data[1] == 0 || (--task->data[1]) == 0)
+ {
+ if (FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) && !FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ return;
+ }
+ if (task->data[2] >= 32 && task->data[15] == player_get_direction_lower_nybble())
+ {
+ mapObject->mapobj_bit_13 = 0;
+ ScriptContext2_Disable();
+ UnfreezeMapObjects();
+ DestroyTask(FindTaskIdByFunc(sub_8087A74));
+ return;
+ }
+ FieldObjectSetSpecialAnim(mapObject, GetFaceDirectionAnimId(unknown_0839F380[mapObject->mapobj_unk_18]));
+ if (task->data[2] < 32)
+ {
+ task->data[2]++;
+ }
+ task->data[1] = task->data[2] >> 2;
+ }
+ mapObject->mapobj_bit_13 ^= 1;
+}
+
+void sub_8087BBC(u8);
+void mapldr_08085D88(void);
+
+void sub_8087BA8(void)
+{
+ CreateTask(sub_8087BBC, 0);
+}
+
+void sub_8087BBC(u8 taskId)
+{
+ gUnknown_0839F390[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8087BEC(struct Task *task)
+{
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ CameraObjectReset2();
+ task->data[15] = player_get_direction_lower_nybble();
+ task->data[0]++;
+}
+
+void sub_8087C14(struct Task *task)
+{
+ struct MapObject *mapObject;
+ u8 unknown_0839F380[5];
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (task->data[1] == 0 || (--task->data[1]) == 0)
+ {
+ FieldObjectTurn(mapObject, unknown_0839F380[mapObject->mapobj_unk_18]);
+ task->data[1] = 8;
+ task->data[2]++;
+ }
+ if (task->data[2] > 7 && task->data[15] == mapObject->mapobj_unk_18)
+ {
+ task->data[0]++;
+ task->data[1] = 4;
+ task->data[2] = 8;
+ task->data[3] = 1;
+ PlaySE(SE_TK_WARPIN);
+ }
+}
+
+void sub_8087CA4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ struct Sprite *sprite;
+ u8 unknown_0839F380[5];
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ if ((--task->data[1]) <= 0)
+ {
+ task->data[1] = 4;
+ FieldObjectTurn(mapObject, unknown_0839F380[mapObject->mapobj_unk_18]);
+ }
+ sprite->pos1.y -= task->data[3];
+ task->data[4] += task->data[3];
+ if ((--task->data[2]) <= 0 && (task->data[2] = 4, task->data[3] < 8))
+ {
+ task->data[3] <<= 1;
+ }
+ if (task->data[4] > 8 && (sprite->oam.priority = 1, sprite->subspriteMode != 0))
+ {
+ sprite->subspriteMode = 2;
+ }
+ if (task->data[4] >= 0xa8)
+ {
+ task->data[0]++;
+ sub_8053FF8();
+ fade_8080918();
+ }
+}
+
+void sub_8087D78(struct Task *task)
+{
+ if (!gPaletteFade.active && sub_8054034() == TRUE)
+ {
+ sub_8053570();
+ warp_in();
+ SetMainCallback2(CB2_LoadMap);
+ gFieldCallback = mapldr_08085D88;
+ DestroyTask(FindTaskIdByFunc(sub_8087BBC));
+ }
+}
+
+void sub_8087E1C(u8);
+
+void mapldr_08085D88(void)
+{
+ sub_8053E90();
+ pal_fill_for_map_transition();
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ gFieldCallback = NULL;
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 1;
+ CameraObjectReset2();
+ CreateTask(sub_8087E1C, 0);
+}
+
+void sub_8087E1C(u8 taskId)
+{
+ gUnknown_0839F3A0[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8087E4C(struct Task *task)
+{
+ struct Sprite *sprite;
+ s16 centerToCornerVecY;
+ if (sub_807D770())
+ {
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ centerToCornerVecY = -(sprite->centerToCornerVecY << 1);
+ sprite->pos2.y = -(sprite->pos1.y + sprite->centerToCornerVecY + gSpriteCoordOffsetY + centerToCornerVecY);
+ gMapObjects[gPlayerAvatar.mapObjectId].mapobj_bit_13 = 0;
+ task->data[0]++;
+ task->data[1] = 8;
+ task->data[2] = 1;
+ task->data[14] = sprite->subspriteMode;
+ task->data[15] = player_get_direction_lower_nybble();
+ PlaySE(SE_TK_WARPIN);
+ }
+}
+
+void sub_8087ED8(struct Task *task)
+{
+ u8 unknown_0839F380[5];
+ struct MapObject *mapObject;
+ struct Sprite *sprite;
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ if ((sprite->pos2.y += task->data[1]) >= -8)
+ {
+ if (task->data[13] == 0)
+ {
+ task->data[13]++;
+ mapObject->mapobj_bit_2 = 1;
+ sprite->subspriteMode = task->data[14];
+ }
+ } else
+ {
+ sprite->oam.priority = 1;
+ if (sprite->subspriteMode != 0)
+ {
+ sprite->subspriteMode = 2;
+ }
+ }
+ if (sprite->pos2.y >= -0x30 && task->data[1] > 1 && !(sprite->pos2.y & 1))
+ {
+ task->data[1]--;
+ }
+ if ((--task->data[2]) == 0)
+ {
+ task->data[2] = 4;
+ FieldObjectTurn(mapObject, unknown_0839F380[mapObject->mapobj_unk_18]);
+ }
+ if (sprite->pos2.y >= 0)
+ {
+ sprite->pos2.y = 0;
+ task->data[0]++;
+ task->data[1] = 1;
+ task->data[2] = 0;
+ }
+}
+
+void sub_8087FDC(struct Task *task)
+{
+ u8 unknown_0839F380[5];
+ struct MapObject *mapObject;
+ memcpy(unknown_0839F380, gUnknown_0839F380, sizeof gUnknown_0839F380);
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if ((--task->data[1]) == 0)
+ {
+ FieldObjectTurn(mapObject, unknown_0839F380[mapObject->mapobj_unk_18]);
+ task->data[1] = 8;
+ if ((++task->data[2]) > 4 && task->data[14] == mapObject->mapobj_unk_18)
+ {
+ ScriptContext2_Disable();
+ CameraObjectReset1();
+ UnfreezeMapObjects();
+ DestroyTask(FindTaskIdByFunc(sub_8087E1C));
+ }
+ }
+}
+
+void sub_8088120(u8);
+void sub_808847C(u8);
+u8 sub_8088830(u32, u32, u32);
+void sub_80883DC(void);
+void sub_808843C(u16);
+void sub_8088890(struct Sprite *);
+
+bool8 FldEff_FieldMoveShowMon(void)
+{
+ u8 taskId;
+ if (is_light_level_1_2_3_5_or_6(sav1_map_get_light_level()) == TRUE)
+ {
+ taskId = CreateTask(sub_8088120, 0xff);
+ } else
+ {
+ taskId = CreateTask(sub_808847C, 0xff);
+ }
+ gTasks[taskId].data[15] = sub_8088830(gUnknown_0202FF84[0], gUnknown_0202FF84[1], gUnknown_0202FF84[2]);
+ return FALSE;
+}
+
+bool8 FldEff_FieldMoveShowMonInit(void)
+{
+ struct Pokemon *pokemon;
+ u32 flag = gUnknown_0202FF84[0] & 0x80000000;
+ pokemon = &gPlayerParty[(u8)gUnknown_0202FF84[0]];
+ gUnknown_0202FF84[0] = GetMonData(pokemon, MON_DATA_SPECIES);
+ gUnknown_0202FF84[1] = GetMonData(pokemon, MON_DATA_OT_ID);
+ gUnknown_0202FF84[2] = GetMonData(pokemon, MON_DATA_PERSONALITY);
+ gUnknown_0202FF84[0] |= flag;
+ FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON);
+ FieldEffectActiveListRemove(FLDEFF_FIELD_MOVE_SHOW_MON_INIT);
+ return FALSE;
+}
+
+void sub_8088120(u8 taskId)
+{
+ gUnknown_0839F3AC[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8088150(struct Task *task)
+{
+ task->data[11] = REG_WININ;
+ task->data[12] = REG_WINOUT;
+ StoreWordInTwoHalfwords(&task->data[13], (u32)gMain.vblankCallback);
+ task->data[1] = 0xf0f1;
+ task->data[2] = 0x5051;
+ task->data[3] = 0x3f;
+ task->data[4] = 0x3e;
+ REG_WIN0H = task->data[1];
+ REG_WIN0V = task->data[2];
+ REG_WININ = task->data[3];
+ REG_WINOUT = task->data[4];
+ SetVBlankCallback(sub_80883DC);
+ task->data[0]++;
+}
+
+void sub_80881C0(struct Task *task)
+{
+ u16 offset;
+ u16 delta;
+ offset = ((REG_BG0CNT >> 2) << 14);
+ delta = ((REG_BG0CNT >> 8) << 11);
+ CpuCopy16(gFieldMoveStreaksTiles, (void *)(VRAM + offset), 0x200);
+ CpuFill32(0, (void *)(VRAM + delta), 0x800);
+ LoadPalette(gFieldMoveStreaksPalette, 0xf0, 0x20);
+ sub_808843C(delta);
+ task->data[0]++;
+}
+
+void sub_8088228(struct Task *task)
+{
+ s16 v0;
+ s16 v2;
+ s16 v3;
+ task->data[5] -= 16;
+ v0 = ((u16)task->data[1] >> 8);
+ v2 = ((u16)task->data[2] >> 8);
+ v3 = ((u16)task->data[2] & 0xff);
+ v0 -= 16;
+ v2 -= 2;
+ v3 += 2;
+ if (v0 < 0)
+ {
+ v0 = 0;
+ }
+ if (v2 < 0x28)
+ {
+ v2 = 0x28;
+ }
+ if (v3 > 0x78)
+ {
+ v3 = 0x78;
+ }
+ task->data[1] = (v0 << 8) | (task->data[1] & 0xff);
+ task->data[2] = (v2 << 8) | v3;
+ if (v0 == 0 && v2 == 0x28 && v3 == 0x78)
+ {
+ gSprites[task->data[15]].callback = sub_8088890;
+ task->data[0]++;
+ }
+}
+
+void sub_80882B4(struct Task *task)
+{
+ task->data[5] -= 16;
+ if (gSprites[task->data[15]].data7)
+ {
+ task->data[0]++;
+ }
+}
+
+void sub_80882E4(struct Task *task)
+{
+ s16 v2;
+ s16 v3;
+ task->data[5] -= 16;
+ v2 = (task->data[2] >> 8);
+ v3 = (task->data[2] & 0xff);
+ v2 += 6;
+ v3 -= 6;
+ if (v2 > 0x50)
+ {
+ v2 = 0x50;
+ }
+ if (v3 < 0x51)
+ {
+ v3 = 0x51;
+ }
+ task->data[2] = (v2 << 8) | v3;
+ if (v2 == 0x50 && v3 == 0x51)
+ {
+ task->data[0]++;
+ }
+}
+
+void sub_8088338(struct Task *task)
+{
+ u16 bg0cnt;
+ bg0cnt = (REG_BG0CNT >> 8) << 11;
+ CpuFill32(0, (void *)VRAM + bg0cnt, 0x800);
+ task->data[1] = 0xf1;
+ task->data[2] = 0xa1;
+ task->data[3] = task->data[11];
+ task->data[4] = task->data[12];
+ task->data[0]++;
+}
+
+void sub_8088380(struct Task *task)
+{
+ IntrCallback callback;
+ LoadWordFromTwoHalfwords((u16 *)&task->data[13], (u32 *)&callback);
+ SetVBlankCallback(callback);
+ SetUpWindowConfig(&gWindowConfig_81E6CE4);
+ InitMenuWindow(&gWindowConfig_81E6CE4);
+ FreeResourcesAndDestroySprite(&gSprites[task->data[15]]);
+ FieldEffectActiveListRemove(FLDEFF_FIELD_MOVE_SHOW_MON);
+ DestroyTask(FindTaskIdByFunc(sub_8088120));
+}
+
+void sub_80883DC(void)
+{
+ struct Task *task;
+ IntrCallback callback;
+ task = &gTasks[FindTaskIdByFunc(sub_8088120)];
+ LoadWordFromTwoHalfwords((u16 *)&task->data[13], (u32 *)&callback);
+ callback();
+ REG_WIN0H = task->data[1];
+ REG_WIN0V = task->data[2];
+ REG_WININ = task->data[3];
+ REG_WINOUT = task->data[4];
+ REG_BG0HOFS = task->data[5];
+ REG_BG0VOFS = task->data[6];
+}
+
+void sub_808843C(u16 offs)
+{
+ u16 i;
+ u16 *dest;
+ dest = (u16 *)(VRAM + 0x140 + offs);
+ for (i=0; i<0x140; i++, dest++)
+ {
+ *dest = gFieldMoveStreaksTilemap[i] | 0xf000;
+ }
+}
+
+void sub_80886B0(void);
+bool8 sub_8088708(struct Task *);
+void sub_80886F8(struct Task *);
+bool8 sub_80887C0(struct Task *);
+
+void sub_808847C(u8 taskId)
+{
+ gUnknown_0839F3C8[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_80884AC(struct Task *task)
+{
+ REG_BG0HOFS = task->data[1];
+ REG_BG0VOFS = task->data[2];
+ StoreWordInTwoHalfwords((u16 *)&task->data[13], (u32)gMain.vblankCallback);
+ SetVBlankCallback(sub_80886B0);
+ task->data[0]++;
+}
+
+void sub_80884E8(struct Task *task)
+{
+ u16 offset;
+ u16 delta;
+ offset = ((REG_BG0CNT >> 2) << 14);
+ delta = ((REG_BG0CNT >> 8) << 11);
+ task->data[12] = delta;
+ CpuCopy16(gDarknessFieldMoveStreaksTiles, (void *)(VRAM + offset), 0x80);
+ CpuFill32(0, (void *)(VRAM + delta), 0x800);
+ LoadPalette(gDarknessFieldMoveStreaksPalette, 0xf0, 0x20);
+ task->data[0]++;
+}
+
+void sub_8088554(struct Task *task)
+{
+ if (sub_8088708(task))
+ {
+ REG_WIN1H = 0x00f0;
+ REG_WIN1V = 0x2878;
+ gSprites[task->data[15]].callback = sub_8088890;
+ task->data[0]++;
+ }
+ sub_80886F8(task);
+}
+
+void sub_80885A8(struct Task *task)
+{
+ sub_80886F8(task);
+ if (gSprites[task->data[15]].data7)
+ {
+ task->data[0]++;
+ }
+}
+
+void sub_80885D8(struct Task *task)
+{
+ sub_80886F8(task);
+ task->data[3] = task->data[1] & 7;
+ task->data[4] = 0;
+ REG_WIN1H = 0xffff;
+ REG_WIN1V = 0xffff;
+ task->data[0]++;
+}
+
+void sub_808860C(struct Task *task)
+{
+ sub_80886F8(task);
+ if (sub_80887C0(task))
+ {
+ task->data[0]++;
+ }
+}
+
+void sub_808862C(struct Task *task)
+{
+ IntrCallback intrCallback;
+ u16 bg0cnt;
+ bg0cnt = (REG_BG0CNT >> 8) << 11;
+ CpuFill32(0, (void *)VRAM + bg0cnt, 0x800);
+ LoadWordFromTwoHalfwords((u16 *)&task->data[13], (u32 *)&intrCallback);
+ SetVBlankCallback(intrCallback);
+ SetUpWindowConfig(&gWindowConfig_81E6CE4);
+ InitMenuWindow(&gWindowConfig_81E6CE4);
+ FreeResourcesAndDestroySprite(&gSprites[task->data[15]]);
+ FieldEffectActiveListRemove(FLDEFF_FIELD_MOVE_SHOW_MON);
+ DestroyTask(FindTaskIdByFunc(sub_808847C));
+}
+
+void sub_80886B0(void)
+{
+ IntrCallback intrCallback;
+ struct Task *task;
+ task = &gTasks[FindTaskIdByFunc(sub_808847C)];
+ LoadWordFromTwoHalfwords((u16 *)&task->data[13], (u32 *)&intrCallback);
+ intrCallback();
+ REG_BG0HOFS = task->data[1];
+ REG_BG0VOFS = task->data[2];
+}
+
+void sub_80886F8(struct Task *task)
+{
+ task->data[1] -= 16;
+ task->data[3] += 16;
+}
+
+#ifdef NONMATCHING
+bool8 sub_8088708(struct Task *task)
+{
+ u16 i;
+ u16 srcOffs;
+ u16 dstOffs;
+ u16 *dest;
+ if (task->data[4] >= 32)
+ {
+ return TRUE;
+ }
+ dstOffs = (task->data[3] >> 3) & 0x1f;
+ if (dstOffs >= task->data[4])
+ {
+ dstOffs = (32 - dstOffs) & 0x1f;
+ srcOffs = (32 - task->data[4]) & 0x1f;
+ dest = (u16 *)(VRAM + 0x140 + (u16)task->data[12]);
+ for (i=0; i<10; i++)
+ {
+ dest[dstOffs + i * 32] = gDarknessFieldMoveStreaksTilemap[srcOffs + i * 32] | 0xf000;
+ dest[((dstOffs + 1) & 0x1f) + i * 32] = gDarknessFieldMoveStreaksTilemap[((srcOffs + 1) & 0x1f) + i * 32] | 0xf000;
+ }
+ task->data[4] += 2;
+ }
+ return FALSE;
+}
+#else
+__attribute__((naked))
+bool8 sub_8088708(struct Task *task)
+{
+ asm_unified("\tpush {r4-r7,lr}\n"
+ "\tmov r7, r10\n"
+ "\tmov r6, r9\n"
+ "\tmov r5, r8\n"
+ "\tpush {r5-r7}\n"
+ "\tsub sp, 0x4\n"
+ "\tadds r5, r0, 0\n"
+ "\tldrh r2, [r5, 0x10]\n"
+ "\tmovs r1, 0x10\n"
+ "\tldrsh r0, [r5, r1]\n"
+ "\tcmp r0, 0x1F\n"
+ "\tble _08088724\n"
+ "\tmovs r0, 0x1\n"
+ "\tb _080887A8\n"
+ "_08088724:\n"
+ "\tldrh r0, [r5, 0xE]\n"
+ "\tlsls r0, 16\n"
+ "\tasrs r3, r0, 19\n"
+ "\tmovs r1, 0x1F\n"
+ "\tands r3, r1\n"
+ "\tmovs r4, 0x10\n"
+ "\tldrsh r0, [r5, r4]\n"
+ "\tcmp r3, r0\n"
+ "\tblt _080887A6\n"
+ "\tmovs r0, 0x20\n"
+ "\tsubs r3, r0, r3\n"
+ "\tands r3, r1\n"
+ "\tsubs r0, r2\n"
+ "\tmov r12, r0\n"
+ "\tmov r7, r12\n"
+ "\tands r7, r1\n"
+ "\tmov r12, r7\n"
+ "\tldrh r0, [r5, 0x20]\n"
+ "\tldr r1, _080887B8 @ =0x06000140\n"
+ "\tadds r1, r0\n"
+ "\tmov r8, r1\n"
+ "\tmovs r4, 0\n"
+ "\tldr r7, _080887BC @ =gDarknessFieldMoveStreaksTilemap\n"
+ "\tmov r10, r7\n"
+ "\tmovs r0, 0xF0\n"
+ "\tlsls r0, 8\n"
+ "\tmov r9, r0\n"
+ "\tadds r1, r3, 0x1\n"
+ "\tmovs r0, 0x1F\n"
+ "\tands r1, r0\n"
+ "\tstr r1, [sp]\n"
+ "\tmov r6, r12\n"
+ "\tadds r6, 0x1\n"
+ "\tands r6, r0\n"
+ "_08088768:\n"
+ "\tlsls r1, r4, 5\n"
+ "\tadds r2, r1, r3\n"
+ "\tlsls r2, 1\n"
+ "\tadd r2, r8\n"
+ "\tmov r7, r12\n"
+ "\tadds r0, r7, r1\n"
+ "\tlsls r0, 1\n"
+ "\tadd r0, r10\n"
+ "\tldrh r0, [r0]\n"
+ "\tmov r7, r9\n"
+ "\torrs r0, r7\n"
+ "\tstrh r0, [r2]\n"
+ "\tldr r0, [sp]\n"
+ "\tadds r2, r1, r0\n"
+ "\tlsls r2, 1\n"
+ "\tadd r2, r8\n"
+ "\tadds r1, r6, r1\n"
+ "\tlsls r1, 1\n"
+ "\tadd r1, r10\n"
+ "\tldrh r0, [r1]\n"
+ "\tmov r1, r9\n"
+ "\torrs r0, r1\n"
+ "\tstrh r0, [r2]\n"
+ "\tadds r0, r4, 0x1\n"
+ "\tlsls r0, 16\n"
+ "\tlsrs r4, r0, 16\n"
+ "\tcmp r4, 0x9\n"
+ "\tbls _08088768\n"
+ "\tldrh r0, [r5, 0x10]\n"
+ "\tadds r0, 0x2\n"
+ "\tstrh r0, [r5, 0x10]\n"
+ "_080887A6:\n"
+ "\tmovs r0, 0\n"
+ "_080887A8:\n"
+ "\tadd sp, 0x4\n"
+ "\tpop {r3-r5}\n"
+ "\tmov r8, r3\n"
+ "\tmov r9, r4\n"
+ "\tmov r10, r5\n"
+ "\tpop {r4-r7}\n"
+ "\tpop {r1}\n"
+ "\tbx r1\n"
+ "\t.align 2, 0\n"
+ "_080887B8: .4byte 0x06000140\n"
+ "_080887BC: .4byte gDarknessFieldMoveStreaksTilemap");
+}
+#endif
+
+bool8 sub_80887C0(struct Task *task)
+{
+ u16 i;
+ u16 dstOffs;
+ u16 *dest;
+ if (task->data[4] >= 32)
+ {
+ return TRUE;
+ }
+ dstOffs = task->data[3] >> 3;
+ if (dstOffs >= task->data[4])
+ {
+ dstOffs = (task->data[1] >> 3) & 0x1f;
+ dest = (u16 *)(VRAM + 0x140 + (u16)task->data[12]);
+ for (i=0; i<10; i++)
+ {
+ dest[dstOffs + i * 32] = 0xf000;
+ dest[((dstOffs + 1) & 0x1f) + i * 32] = 0xf000;
+ }
+ task->data[4] += 2;
+ }
+ return FALSE;
+}
+
+u8 sub_8088830(u32 a0, u32 a1, u32 a2)
+{
+ u16 v0;
+ u8 monSprite;
+ struct Sprite *sprite;
+ v0 = (a0 & 0x80000000) >> 16;
+ a0 &= 0x7fffffff;
+ monSprite = CreateMonSprite_FieldMove(a0, a1, a2, 0x140, 0x50, 0);
+ sprite = &gSprites[monSprite];
+ sprite->callback = SpriteCallbackDummy;
+ sprite->oam.priority = 0;
+ sprite->data0 = a0;
+ sprite->data6 = v0;
+ return monSprite;
+}
+
+void sub_80888D4(struct Sprite *);
+
+void sub_8088890(struct Sprite *sprite)
+{
+ if ((sprite->pos1.x -= 20) <= 0x78)
+ {
+ sprite->pos1.x = 0x78;
+ sprite->data1 = 30;
+ sprite->callback = sub_80888D4;
+ if (sprite->data6)
+ {
+ PlayCry2(sprite->data0, 0, 0x7d, 0xa);
+ } else
+ {
+ PlayCry1(sprite->data0, 0);
+ }
+ }
+}
+
+void sub_80888F0(struct Sprite *);
+
+void sub_80888D4(struct Sprite *sprite)
+{
+ if ((--sprite->data1) == 0)
+ {
+ sprite->callback = sub_80888F0;
+ }
+}
+
+void sub_80888F0(struct Sprite *sprite)
+{
+ if (sprite->pos1.x < -0x40)
+ {
+ sprite->data7 = 1;
+ } else
+ {
+ sprite->pos1.x -= 20;
+ }
+}
+
+void sub_8088954(u8);
+
+u8 FldEff_UseSurf(void)
+{
+ u8 taskId;
+ taskId = CreateTask(sub_8088954, 0xff);
+ gTasks[taskId].data[15] = gUnknown_0202FF84[0];
+ sav1_reset_battle_music_maybe();
+ sub_8053FB0(0x016d);
+ return FALSE;
+}
+
+void sub_8088954(u8 taskId)
+{
+ gUnknown_0839F3E4[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8088984(struct Task *task)
+{
+ ScriptContext2_Enable();
+ FreezeMapObjects();
+ gPlayerAvatar.unk6 = 1;
+ SetPlayerAvatarStateMask(8);
+ PlayerGetDestCoords(&task->data[1], &task->data[2]);
+ MoveCoords(gMapObjects[gPlayerAvatar.mapObjectId].placeholder18, &task->data[1], &task->data[2]);
+ task->data[0]++;
+}
+
+void sub_80889E4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) || FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ sub_8059BF4();
+ FieldObjectSetSpecialAnim(mapObject, 0x39);
+ task->data[0]++;
+ }
+}
+
+void sub_8088A30(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (FieldObjectCheckIfSpecialAnimFinishedOrInactive(mapObject))
+ {
+ gUnknown_0202FF84[0] = task->data[15] | 0x80000000;
+ FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT);
+ task->data[0]++;
+ }
+}
+
+void sub_8088A78(struct Task *task)
+{
+ struct MapObject *mapObject;
+ if (!FieldEffectActiveListContains(FLDEFF_FIELD_MOVE_SHOW_MON))
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sub_805B980(mapObject, GetPlayerAvatarGraphicsIdByStateId(3));
+ FieldObjectClearAnimIfSpecialAnimFinished(mapObject);
+ FieldObjectSetSpecialAnim(mapObject, sub_80608D0(mapObject->placeholder18));
+ gUnknown_0202FF84[0] = task->data[1];
+ gUnknown_0202FF84[1] = task->data[2];
+ gUnknown_0202FF84[2] = gPlayerAvatar.mapObjectId;
+ mapObject->mapobj_unk_1A = FieldEffectStart(FLDEFF_SURF_BLOB);
+ task->data[0]++;
+ }
+}
+
+void sub_8088AF4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ gPlayerAvatar.unk6 = 0;
+ gPlayerAvatar.flags &= 0xdf;
+ FieldObjectSetSpecialAnim(mapObject, GetFaceDirectionAnimId(mapObject->placeholder18));
+ sub_8127ED0(mapObject->mapobj_unk_1A, 1);
+ UnfreezeMapObjects();
+ ScriptContext2_Disable();
+ FieldEffectActiveListRemove(FLDEFF_USE_SURF);
+ DestroyTask(FindTaskIdByFunc(sub_8088954));
+ }
+}
+
+void sub_8088BC4(struct Sprite *);
+
+u8 FldEff_NPCFlyOut(void)
+{
+ u8 spriteId;
+ struct Sprite *sprite;
+ spriteId = CreateSprite(gFieldEffectObjectTemplatePointers[26], 0x78, 0, 1);
+ sprite = &gSprites[spriteId];
+ sprite->oam.paletteNum = 0;
+ sprite->oam.priority = 1;
+ sprite->callback = sub_8088BC4;
+ sprite->data1 = gUnknown_0202FF84[0];
+ PlaySE(SE_W019);
+ return spriteId;
+}
+
+void sub_8088BC4(struct Sprite *sprite)
+{
+ struct Sprite *npcSprite;
+ sprite->pos2.x = Cos(sprite->data2, 0x8c);
+ sprite->pos2.y = Sin(sprite->data2, 0x48);
+ sprite->data2 = (sprite->data2 + 4) & 0xff;
+ if (sprite->data0)
+ {
+ npcSprite = &gSprites[sprite->data1];
+ npcSprite->coordOffsetEnabled = 0;
+ npcSprite->pos1.x = sprite->pos1.x + sprite->pos2.x;
+ npcSprite->pos1.y = sprite->pos1.y + sprite->pos2.y - 8;
+ npcSprite->pos2.x = 0;
+ npcSprite->pos2.y = 0;
+ }
+ if (sprite->data2 >= 0x80)
+ {
+ FieldEffectStop(sprite, FLDEFF_NPCFLY_OUT);
+ }
+}
+
+void sub_8088C70(u8);
+extern void sub_8127EFC(u8, u8);
+u8 sub_8088F60(void);
+bool8 sub_8088FA4(u8);
+void sub_8088FC0(u8);
+void sub_8088FFC(u8, u8);
+void sub_8089018(struct Sprite *);
+void sub_80890D8(struct Sprite *);
+
+u8 FldEff_UseFly(void)
+{
+ u8 taskId;
+ taskId = CreateTask(sub_8088C70, 0xfe);
+ gTasks[taskId].data[1] = gUnknown_0202FF84[0];
+ return 0;
+}
+
+void sub_8088C70(u8 taskId)
+{
+ gUnknown_0839F3F8[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_8088CA0(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) || FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ task->data[15] = gPlayerAvatar.flags;
+ gPlayerAvatar.unk6 = 0x01;
+ SetPlayerAvatarStateMask(1);
+ sub_8059BF4();
+ FieldObjectSetSpecialAnim(mapObject, 0x39);
+ task->data[0]++;
+ }
+}
+
+void sub_8088CF8(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ task->data[0]++;
+ gUnknown_0202FF84[0] = task->data[1];
+ FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT);
+ }
+}
+
+void sub_8088D3C(struct Task *task)
+{
+ struct MapObject *mapObject;
+ if (!FieldEffectActiveListContains(FLDEFF_FIELD_MOVE_SHOW_MON))
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (task->data[15] & 0x08)
+ {
+ sub_8127ED0(mapObject->mapobj_unk_1A, 2);
+ sub_8127EFC(mapObject->mapobj_unk_1A, 0);
+ }
+ task->data[1] = sub_8088F60();
+ task->data[0]++;
+ }
+}
+
+void sub_8088D94(struct Task *task)
+{
+ if (sub_8088FA4(task->data[1]))
+ {
+ task->data[0]++;
+ task->data[2] = 16;
+ SetPlayerAvatarTransitionFlags(0x01);
+ FieldObjectSetSpecialAnim(&gMapObjects[gPlayerAvatar.mapObjectId], 0x02);
+ }
+}
+
+void sub_8088DD8(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if ((task->data[2] == 0 || (--task->data[2]) == 0) && FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ task->data[0]++;
+ PlaySE(SE_W019);
+ sub_8088FC0(task->data[1]);
+ }
+}
+
+void sub_8088E2C(struct Task *task)
+{
+ struct MapObject *mapObject;
+ if ((++task->data[2]) >= 8)
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sub_805B980(mapObject, GetPlayerAvatarGraphicsIdByStateId(0x03));
+ StartSpriteAnim(&gSprites[mapObject->spriteId], 0x16);
+ mapObject->mapobj_bit_12 = 1;
+ FieldObjectSetSpecialAnim(mapObject, 0x48);
+ if (task->data[15] & 0x08)
+ {
+ DestroySprite(&gSprites[mapObject->mapobj_unk_1A]);
+ }
+ task->data[0]++;
+ task->data[2] = 0;
+ }
+}
+
+void sub_8088EB4(struct Task *task)
+{
+ struct MapObject *mapObject;
+ if ((++task->data[2]) >= 10)
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ FieldObjectClearAnimIfSpecialAnimActive(mapObject);
+ mapObject->mapobj_bit_12 = 0;
+ mapObject->mapobj_bit_22 = 0;
+ sub_8088FFC(task->data[1], mapObject->spriteId);
+ CameraObjectReset2();
+ task->data[0]++;
+ }
+}
+
+void sub_8088F10(struct Task *task)
+{
+ if (sub_8088FA4(task->data[1]))
+ {
+ fade_8080918();
+ task->data[0]++;
+ }
+}
+
+void sub_8088F30(struct Task *task)
+{
+ if (!gPaletteFade.active)
+ {
+ FieldEffectActiveListRemove(FLDEFF_USE_FLY);
+ DestroyTask(FindTaskIdByFunc(sub_8088C70));
+ }
+}
+
+u8 sub_8088F60(void)
+{
+ u8 spriteId;
+ struct Sprite *sprite;
+ spriteId = CreateSprite(gFieldEffectObjectTemplatePointers[26], 0xff, 0xb4, 0x1);
+ sprite = &gSprites[spriteId];
+ sprite->oam.paletteNum = 0;
+ sprite->oam.priority = 1;
+ sprite->callback = sub_8089018;
+ return spriteId;
+}
+
+u8 sub_8088FA4(u8 spriteId)
+{
+ return gSprites[spriteId].data7;
+}
+
+void sub_8088FC0(u8 spriteId)
+{
+ struct Sprite *sprite;
+ sprite = &gSprites[spriteId];
+ sprite->callback = sub_80890D8;
+ sprite->pos1.x = 0x78;
+ sprite->pos1.y = 0x00;
+ sprite->pos2.x = 0;
+ sprite->pos2.y = 0;
+ memset(&sprite->data0, 0, 8 * sizeof(u16) /* zero all data cells */);
+ sprite->data6 = 0x40;
+}
+
+void sub_8088FFC(u8 a0, u8 a1)
+{
+ gSprites[a0].data6 = a1;
+}
+
+void sub_8089018(struct Sprite *sprite)
+{
+ if (sprite->data7 == 0)
+ {
+ if (sprite->data0 == 0)
+ {
+ sprite->oam.affineMode = 3;
+ sprite->affineAnims = gSpriteAffineAnimTable_0839F44C;
+ InitSpriteAffineAnim(sprite);
+ StartSpriteAffineAnim(sprite, 0);
+ sprite->pos1.x = 0x76;
+ sprite->pos1.y = -0x30;
+ sprite->data0++;
+ sprite->data1 = 0x40;
+ sprite->data2 = 0x100;
+ }
+ sprite->data1 += (sprite->data2 >> 8);
+ sprite->pos2.x = Cos(sprite->data1, 0x78);
+ sprite->pos2.y = Sin(sprite->data1, 0x78);
+ if (sprite->data2 < 0x800)
+ {
+ sprite->data2 += 0x60;
+ }
+ if (sprite->data1 > 0x81)
+ {
+ sprite->data7++;
+ sprite->oam.affineMode = 0;
+ FreeOamMatrix(sprite->oam.matrixNum);
+ CalcCenterToCornerVec(sprite, sprite->oam.shape, sprite->oam.size, 0);
+ }
+ }
+}
+
+void sub_80890D8(struct Sprite *sprite)
+{
+ struct Sprite *sprite1;
+ sprite->pos2.x = Cos(sprite->data2, 0x8c);
+ sprite->pos2.y = Sin(sprite->data2, 0x48);
+ sprite->data2 = (sprite->data2 + 4) & 0xff;
+ if (sprite->data6 != 0x40)
+ {
+ sprite1 = &gSprites[sprite->data6];
+ sprite1->coordOffsetEnabled = 0;
+ sprite1->pos1.x = sprite->pos1.x + sprite->pos2.x;
+ sprite1->pos1.y = sprite->pos1.y + sprite->pos2.y - 8;
+ sprite1->pos2.x = 0;
+ sprite1->pos2.y = 0;
+ }
+ if (sprite->data2 >= 0x80)
+ {
+ sprite->data7 = 1;
+ }
+}
+
+void sub_808914C(struct Sprite *sprite)
+{
+ if (sprite->data7 == 0)
+ {
+ if (sprite->data0 == 0)
+ {
+ sprite->oam.affineMode = 3;
+ sprite->affineAnims = gSpriteAffineAnimTable_0839F44C;
+ InitSpriteAffineAnim(sprite);
+ StartSpriteAffineAnim(sprite, 1);
+ sprite->pos1.x = 0x5e;
+ sprite->pos1.y = -0x20;
+ sprite->data0++;
+ sprite->data1 = 0xf0;
+ sprite->data2 = 0x800;
+ sprite->data4 = 0x80;
+ }
+ sprite->data1 += sprite->data2 >> 8;
+ sprite->data3 += sprite->data2 >> 8;
+ sprite->data1 &= 0xff;
+ sprite->pos2.x = Cos(sprite->data1, 0x20);
+ sprite->pos2.y = Sin(sprite->data1, 0x78);
+ if (sprite->data2 > 0x100)
+ {
+ sprite->data2 -= sprite->data4;
+ }
+ if (sprite->data4 < 0x100)
+ {
+ sprite->data4 += 24;
+ }
+ if (sprite->data2 < 0x100)
+ {
+ sprite->data2 = 0x100;
+ }
+ if (sprite->data3 >= 60)
+ {
+ sprite->data7++;
+ sprite->oam.affineMode = 0;
+ FreeOamMatrix(sprite->oam.matrixNum);
+ sprite->invisible = 1;
+ }
+ }
+}
+
+void sub_8089230(u8 spriteId)
+{
+ sub_8088FC0(spriteId);
+ gSprites[spriteId].callback = sub_808914C;
+}
+
+void sub_8089270(u8);
+
+u8 FldEff_FlyIn(void)
+{
+ CreateTask(sub_8089270, 0xfe);
+ return 0;
+}
+
+void sub_8089270(u8 taskId)
+{
+ gUnknown_0839F454[gTasks[taskId].data[0]](&gTasks[taskId]);
+}
+
+void sub_80892A0(struct Task *task)
+{
+ struct MapObject *mapObject;
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject) || FieldObjectClearAnimIfSpecialAnimFinished(mapObject))
+ {
+ task->data[0]++;
+ task->data[2] = 17;
+ task->data[15] = gPlayerAvatar.flags;
+ gPlayerAvatar.unk6 = 1;
+ SetPlayerAvatarStateMask(0x01);
+ if (task->data[15] & 0x08)
+ {
+ sub_8127ED0(mapObject->mapobj_unk_1A, 0);
+ }
+ sub_805B980(mapObject, GetPlayerAvatarGraphicsIdByStateId(0x3));
+ CameraObjectReset2();
+ FieldObjectTurn(mapObject, DIR_WEST);
+ StartSpriteAnim(&gSprites[mapObject->spriteId], 0x16);
+ mapObject->mapobj_bit_13 = 0;
+ task->data[1] = sub_8088F60();
+ sub_8088FC0(task->data[1]);
+ sub_8088FFC(task->data[1], mapObject->spriteId);
+ }
+}
+
+void sub_8089354(struct Task *task)
+{
+ struct MapObject *mapObject;
+ struct Sprite *sprite;
+ if (task->data[2] == 0 || (--task->data[2]) == 0)
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sprite = &gSprites[mapObject->spriteId];
+ sub_8088FFC(task->data[1], 0x40);
+ sprite->pos1.x += sprite->pos2.x;
+ sprite->pos1.y += sprite->pos2.y;
+ sprite->pos2.x = 0;
+ sprite->pos2.y = 0;
+ task->data[0]++;
+ task->data[2] = 0;
+ }
+}
+
+void sub_80893C0(struct Task *task)
+{
+ s16 unknown_0839F470[18];
+ struct Sprite *sprite;
+ memcpy(unknown_0839F470, gUnknown_0839F470, sizeof gUnknown_0839F470);
+ sprite = &gSprites[gPlayerAvatar.spriteId];
+ sprite->pos2.y = unknown_0839F470[task->data[2]];
+ if ((++task->data[2]) >= 18)
+ {
+ task->data[0]++;
+ }
+}
+
+void sub_8089414(struct Task *task)
+{
+ struct MapObject *mapObject;
+ struct Sprite *sprite;
+ if (sub_8088FA4(task->data[1]))
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ sprite = &gSprites[mapObject->spriteId];
+ mapObject->mapobj_bit_12 = 0;
+ sub_805C058(mapObject, mapObject->coords2.x, mapObject->coords2.y);
+ sprite->pos2.x = 0;
+ sprite->pos2.y = 0;
+ sprite->coordOffsetEnabled = 1;
+ sub_8059BF4();
+ FieldObjectSetSpecialAnim(mapObject, 0x39);
+ task->data[0]++;
+ }
+}
+
+void sub_808948C(struct Task *task)
+{
+ if (FieldObjectClearAnimIfSpecialAnimFinished(&gMapObjects[gPlayerAvatar.mapObjectId]))
+ {
+ task->data[0]++;
+ sub_8089230(task->data[1]);
+ }
+}
+
+void sub_80894C4(struct Task *task)
+{
+ if (sub_8088FA4(task->data[1]))
+ {
+ DestroySprite(&gSprites[task->data[1]]);
+ task->data[0]++;
+ task->data[1] = 0x10;
+ }
+}
+
+void fishE(struct Task *task)
+{
+ u8 state;
+ struct MapObject *mapObject;
+ if ((--task->data[1]) == 0)
+ {
+ mapObject = &gMapObjects[gPlayerAvatar.mapObjectId];
+ state = 0;
+ if (task->data[15] & 0x08)
+ {
+ state = 3;
+ sub_8127ED0(mapObject->mapobj_unk_1A, 1);
+ }
+ sub_805B980(mapObject, GetPlayerAvatarGraphicsIdByStateId(state));
+ FieldObjectTurn(mapObject, DIR_SOUTH);
+ gPlayerAvatar.flags = task->data[15];
+ gPlayerAvatar.unk6 = 0;
+ FieldEffectActiveListRemove(FLDEFF_FLY_IN);
+ DestroyTask(FindTaskIdByFunc(sub_8089270));
+ }
+}
diff --git a/src/field_fadetransition.c b/src/field_fadetransition.c
index b5e6c1039..364d55e51 100644
--- a/src/field_fadetransition.c
+++ b/src/field_fadetransition.c
@@ -1,25 +1,15 @@
#include "global.h"
#include "gba/syscall.h"
+#include "field_fadetransition.h"
+#include "field_player_avatar.h"
#include "field_weather.h"
+#include "fldeff_flash.h"
#include "global.fieldmap.h"
+#include "rom4.h"
#include "script.h"
#include "task.h"
-void palette_bg_fill_white(void);
-void palette_bg_fill_black(void);
-void pal_fill_black(void);
-void task0A_asap_script_env_2_enable_and_set_ctx_running(u8);
-
-extern u8 get_map_light_from_warp0(void);
-extern u8 sav1_map_get_light_level(void);
-extern u8 fade_type_for_given_maplight_pair(u8, u8);
extern u16 gPlttBufferFaded[];
-extern struct MapHeader * warp1_get_mapheader(void);
-extern void sub_8059B88(u8);
-extern void sub_8053E90(void);
-
-extern u8 sub_810CDB8(u8, u8);
-extern int sub_8080E70(void);
void palette_bg_fill_white(void)
{
diff --git a/src/field_ground_effect.c b/src/field_ground_effect.c
index 1aea8f52e..42862d0ff 100644
--- a/src/field_ground_effect.c
+++ b/src/field_ground_effect.c
@@ -1,26 +1,10 @@
#include "global.h"
-#include "asm_fieldmap.h"
+#include "field_ground_effect.h"
+#include "fieldmap.h"
#include "metatile_behavior.h"
extern u32 gUnknown_08376008[];
-void FieldObjectUpdateMetatileBehaviors(struct MapObject *);
-void GetGroundEffectFlags_Reflection(struct MapObject *, u32 *);
-void GetGroundEffectFlags_TallGrassOnSpawn(struct MapObject *, u32 *);
-void GetGroundEffectFlags_TallGrassOnBeginStep(struct MapObject *, u32 *);
-void GetGroundEffectFlags_LongGrassOnSpawn(struct MapObject *, u32 *);
-void GetGroundEffectFlags_LongGrassOnBeginStep(struct MapObject *, u32 *);
-void GetGroundEffectFlags_Tracks(struct MapObject *, u32 *);
-void GetGroundEffectFlags_SandPile(struct MapObject *, u32 *);
-void GetGroundEffectFlags_ShallowFlowingWater(struct MapObject *, u32 *);
-void GetGroundEffectFlags_Puddle(struct MapObject *, u32 *);
-void GetGroundEffectFlags_Ripple(struct MapObject *, u32 *);
-void GetGroundEffectFlags_ShortGrass(struct MapObject *, u32 *);
-void GetGroundEffectFlags_HotSprings(struct MapObject *, u32 *);
-void GetGroundEffectFlags_Seaweed(struct MapObject *, u32 *);
-void GetGroundEffectFlags_JumpLanding(struct MapObject *, u32 *);
-u8 FieldObjectCheckForReflectiveSurface(struct MapObject *);
-
void GetAllGroundEffectFlags_OnSpawn(struct MapObject *mapObj, u32 *flags)
{
FieldObjectUpdateMetatileBehaviors(mapObj);
diff --git a/src/field_map_obj.c b/src/field_map_obj.c
index 26cd1de02..ade72923d 100644
--- a/src/field_map_obj.c
+++ b/src/field_map_obj.c
@@ -1,49 +1,24 @@
#include "global.h"
#include "field_map_obj.h"
-#include "field_map_obj_helpers.h"
-#include "fieldmap.h"
-#include "asm.h"
#include "berry.h"
#include "event_data.h"
-#include "field_player_avatar.h"
+#include "field_camera.h"
#include "field_effect.h"
+#include "field_effect_helpers.h"
#include "field_ground_effect.h"
+#include "field_map_obj_helpers.h"
+#include "field_player_avatar.h"
+#include "fieldmap.h"
#include "palette.h"
-#include "rom4.h"
#include "rng.h"
+#include "rom4.h"
#include "sprite.h"
-#include "field_camera.h"
#include "metatile_behavior.h"
#include "map_constants.h"
#include "trainer_see.h"
-#include "field_effect_helpers.h"
extern const struct SpriteTemplate *const gFieldEffectObjectTemplatePointers[36];
-
-extern void strange_npc_table_clear(void);
-extern void ClearPlayerAvatarInfo(void);
-extern void npc_load_two_palettes__no_record(u16, u8);
-extern void npc_load_two_palettes__and_record(u16, u8);
-extern void sub_8060388(s16, s16, s16 *, s16 *);
-void sub_80634D0(struct MapObject *, struct Sprite *);
-extern void pal_patch_for_npc(u16, u16);
-extern void CameraObjectReset1(void);
-
-void sub_805AAB0(void);
-u8 GetFieldObjectIdByLocalId(u8);
-u8 GetFieldObjectIdByLocalIdAndMapInternal(u8, u8, u8);
-u8 GetAvailableFieldObjectSlot(u16, u8, u8, u8 *);
-void FieldObjectHandleDynamicGraphicsId(struct MapObject *);
-void RemoveFieldObjectInternal(struct MapObject *);
-u16 GetFieldObjectFlagIdByFieldObjectId(u8);
-void MakeObjectTemplateFromFieldObjectTemplate(struct MapObjectTemplate *mapObjTemplate, struct SpriteTemplate *sprTemplate, struct SubspriteTable **subspriteTables);
-struct MapObjectTemplate *GetFieldObjectTemplateByLocalIdAndMap(u8, u8, u8);
-void GetFieldObjectMovingCameraOffset(s16 *, s16 *);
-void sub_805BDF8(u16);
-u8 sub_805BE58(const struct SpritePalette *);
-u8 FindFieldObjectPaletteIndexByTag(u16);
-
struct PairedPalettes
{
u16 tag;
diff --git a/src/field_map_obj_helpers.c b/src/field_map_obj_helpers.c
index afc3c680c..17584c96a 100644
--- a/src/field_map_obj_helpers.c
+++ b/src/field_map_obj_helpers.c
@@ -1,14 +1,14 @@
#include "global.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
+#include "field_map_obj_helpers.h"
#include "field_effect.h"
+#include "field_ground_effect.h"
+#include "field_map_obj.h"
#include "sprite.h"
typedef void (*SpriteStepFunc)(struct Sprite *sprite, u8 dir);
extern u32 gUnknown_0202FF84[];
-extern struct UCoords16 gDirectionToVector[];
extern s16 gUnknown_08376194[];
extern SpriteStepFunc *gUnknown_08376180[];
extern s8 *gUnknown_083761D0[];
@@ -76,26 +76,26 @@ void Step1(struct Sprite *sprite, u8 dir)
void Step2(struct Sprite *sprite, u8 dir)
{
- sprite->pos1.x += 2 * gDirectionToVector[dir].x;
- sprite->pos1.y += 2 * gDirectionToVector[dir].y;
+ sprite->pos1.x += 2 * (u16) gDirectionToVector[dir].x;
+ sprite->pos1.y += 2 * (u16) gDirectionToVector[dir].y;
}
void Step3(struct Sprite *sprite, u8 dir)
{
- sprite->pos1.x += 2 * gDirectionToVector[dir].x + gDirectionToVector[dir].x;
- sprite->pos1.y += 2 * gDirectionToVector[dir].y + gDirectionToVector[dir].y;
+ sprite->pos1.x += 2 * (u16) gDirectionToVector[dir].x + (u16) gDirectionToVector[dir].x;
+ sprite->pos1.y += 2 * (u16) gDirectionToVector[dir].y + (u16) gDirectionToVector[dir].y;
}
void Step4(struct Sprite *sprite, u8 dir)
{
- sprite->pos1.x += 4 * gDirectionToVector[dir].x;
- sprite->pos1.y += 4 * gDirectionToVector[dir].y;
+ sprite->pos1.x += 4 * (u16) gDirectionToVector[dir].x;
+ sprite->pos1.y += 4 * (u16) gDirectionToVector[dir].y;
}
void Step8(struct Sprite *sprite, u8 dir)
{
- sprite->pos1.x += 8 * gDirectionToVector[dir].x;
- sprite->pos1.y += 8 * gDirectionToVector[dir].y;
+ sprite->pos1.x += 8 * (u16) gDirectionToVector[dir].x;
+ sprite->pos1.y += 8 * (u16) gDirectionToVector[dir].y;
}
void oamt_npc_ministep_reset(struct Sprite *sprite, u8 a2, u8 a3)
diff --git a/src/field_message_box.c b/src/field_message_box.c
index 798725540..2cd2e66ab 100644
--- a/src/field_message_box.c
+++ b/src/field_message_box.c
@@ -1,14 +1,12 @@
#include "global.h"
#include "field_message_box.h"
+#include "menu.h"
#include "string_util.h"
#include "task.h"
#include "text.h"
#include "text_window.h"
extern struct Window gFieldMessageBoxWindow;
-extern u16 gMenuTextWindowContentTileOffset;
-
-extern u16 gMenuTextTileOffset;
static u8 sMessageBoxMode;
diff --git a/src/field_player_avatar.c b/src/field_player_avatar.c
index 1e1162350..3cdb45584 100644
--- a/src/field_player_avatar.c
+++ b/src/field_player_avatar.c
@@ -1,23 +1,27 @@
#include "global.h"
#include "field_player_avatar.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
#include "bike.h"
#include "event_data.h"
#include "field_effect.h"
+#include "field_effect_helpers.h"
+#include "field_ground_effect.h"
#include "field_map_obj.h"
#include "field_map_obj_helpers.h"
+#include "fieldmap.h"
#include "main.h"
#include "map_object_constants.h"
#include "menu.h"
#include "metatile_behavior.h"
+#include "party_menu.h"
#include "rng.h"
#include "rom4.h"
+#include "rotating_gate.h"
#include "script.h"
#include "songs.h"
#include "sound.h"
#include "strings2.h"
#include "task.h"
+#include "tv.h"
#include "wild_encounter.h"
extern u32 gUnknown_0202FF84[];
@@ -29,41 +33,14 @@ static void MovePlayerAvatarUsingKeypadInput(u8 a, u16 b, u16 c);
static void PlayerAllowForcedMovementIfMovingSameDirection(void);
static u8 TryDoMetatileBehaviorForcedMovement(void);
static u8 GetForcedMovementByMetatileBehavior(void);
-u8 ForcedMovement_None(void);
-u8 ForcedMovement_Slip(void);
-u8 sub_8058AAC(void);
-u8 sub_8058AC4(void);
-u8 sub_8058ADC(void);
-u8 sub_8058AF4(void);
-u8 sub_8058B0C(void);
-u8 sub_8058B24(void);
-u8 sub_8058B3C(void);
-u8 sub_8058B54(void);
-u8 ForcedMovement_SlideSouth(void);
-u8 ForcedMovement_SlideNorth(void);
-u8 ForcedMovement_SlideWest(void);
-u8 ForcedMovement_SlideEast(void);
-u8 sub_8058C04(void);
-u8 sub_8058C10(void);
-u8 ForcedMovement_MuddySlope(void);
static void MovePlayerNotOnBike(u8 a, u16 b);
static u8 CheckMovementInputNotOnBike(u8 a);
-void PlayerNotOnBikeNotMoving(u8 direction, u16 heldKeys);
-void PlayerNotOnBikeTurningInPlace(u8 direction, u16 heldKeys);
-void sub_8058D0C(u8 direction, u16 heldKeys);
static u8 CheckForPlayerAvatarCollision(u8 a);
static u8 sub_8058EF0(s16 a, s16 b, u8 c);
static bool8 ShouldJumpLedge(s16 a, s16 b, u8 c);
static u8 sub_8058F6C(s16 a, s16 b, u8 c);
static void check_acro_bike_metatile(int unused1, int unused2, u8 c, u8 *d);
static void DoPlayerAvatarTransition(void);
-void nullsub_49(struct MapObject *a);
-void PlayerAvatarTransition_Normal(struct MapObject *a);
-void PlayerAvatarTransition_MachBike(struct MapObject *a);
-void PlayerAvatarTransition_AcroBike(struct MapObject *a);
-void PlayerAvatarTransition_Surfing(struct MapObject *a);
-void PlayerAvatarTransition_Underwater(struct MapObject *a);
-void sub_80591F4(struct MapObject *a);
static bool8 player_is_anim_in_certain_ranges(void);
static bool8 sub_80592A4(void);
static bool8 PlayerIsAnimActive(void);
@@ -72,32 +49,8 @@ static void PlayerNotOnBikeCollide(u8 a);
static void PlayCollisionSoundIfNotFacingWarp(u8 a);
static void sub_8059D60(struct MapObject *a);
static void StartStrengthAnim(u8 a, u8 b);
-u8 sub_8059E84(struct Task *task, struct MapObject *b, struct MapObject *c);
-u8 sub_8059EA4(struct Task *task, struct MapObject *b, struct MapObject *c);
-u8 sub_8059F40(struct Task *task, struct MapObject *b, struct MapObject *c);
static void sub_8059F94(void);
-u8 sub_805A000(struct Task *task, struct MapObject *mapObject);
static void sub_805A06C(void);
-u8 sub_805A0D8(struct Task *task, struct MapObject *mapObject);
-u8 sub_805A100(struct Task *task, struct MapObject *mapObject);
-u8 sub_805A178(struct Task *task, struct MapObject *mapObject);
-u8 sub_805A1B8(struct Task *task, struct MapObject *mapObject);
-u8 Fishing1(struct Task *task);
-u8 Fishing2(struct Task *task);
-u8 Fishing3(struct Task *task);
-u8 Fishing4(struct Task *task);
-u8 Fishing5(struct Task *task);
-u8 Fishing6(struct Task *task);
-u8 Fishing7(struct Task *task);
-u8 Fishing8(struct Task *task);
-u8 Fishing9(struct Task *task);
-u8 Fishing10(struct Task *task);
-u8 Fishing11(struct Task *task);
-u8 Fishing12(struct Task *task);
-u8 Fishing13(struct Task *task);
-u8 Fishing14(struct Task *task);
-u8 Fishing15(struct Task *task);
-u8 Fishing16(struct Task *task);
static bool8 (*const gUnknown_0830FB58[])(u8) =
{
diff --git a/src/field_poison.c b/src/field_poison.c
index 4d4d4b975..8c9e029e1 100644
--- a/src/field_poison.c
+++ b/src/field_poison.c
@@ -1,13 +1,14 @@
#include "global.h"
-#include "asm.h"
+#include "field_poison.h"
#include "field_message_box.h"
+#include "fldeff_80C5CD4.h"
#include "pokemon.h"
+#include "pokemon_summary_screen.h"
#include "script.h"
#include "string_util.h"
#include "task.h"
#include "text.h"
-extern struct Pokemon gPlayerParty[6];
extern u16 gScriptResult;
extern u8 fieldPoisonText_PokemonFainted[];
diff --git a/src/field_region_map.c b/src/field_region_map.c
index 66e3d968c..58b0e37bc 100644
--- a/src/field_region_map.c
+++ b/src/field_region_map.c
@@ -1,17 +1,12 @@
#include "global.h"
-#include "asm.h"
+#include "field_region_map.h"
#include "main.h"
#include "menu.h"
#include "palette.h"
+#include "region_map.h"
#include "sprite.h"
-#include "text.h"
#include "strings2.h"
-
-extern void sub_80FA8EC(u32, u8);
-extern void sub_80FAB10(void);
-extern u8 sub_80FAB60(void);
-extern void sub_80FBCF0(u32, u8);
-extern void sub_80FBB3C(u16, u16);
+#include "text.h"
struct RegionMapStruct
{
@@ -30,12 +25,6 @@ struct UnkStruct
extern struct UnkStruct unk_2000000;
-void CB2_FieldInitRegionMap(void);
-void CB2_FieldRegionMap(void);
-void VBlankCB_FieldRegionMap(void);
-void sub_813EFDC(void);
-void sub_813F0C8(void);
-
void FieldInitRegionMap(MainCallback callback)
{
SetVBlankCallback(NULL);
diff --git a/src/field_special_scene.c b/src/field_special_scene.c
index 9e06ede81..c88ac8f65 100644
--- a/src/field_special_scene.c
+++ b/src/field_special_scene.c
@@ -1,11 +1,16 @@
#include "global.h"
#include "field_special_scene.h"
-#include "asm.h"
#include "event_data.h"
#include "field_camera.h"
+#include "field_fadetransition.h"
+#include "field_map_obj.h"
+#include "field_specials.h"
+#include "fieldmap.h"
+#include "main.h"
#include "palette.h"
#include "rom4.h"
#include "script.h"
+#include "script_movement.h"
#include "songs.h"
#include "sound.h"
#include "sprite.h"
diff --git a/src/field_specials.c b/src/field_specials.c
index 9f5a314e2..2cb2cf795 100644
--- a/src/field_specials.c
+++ b/src/field_specials.c
@@ -1,5 +1,6 @@
#include "global.h"
-#include "asm.h"
+#include "field_specials.h"
+#include "diploma.h"
#include "event_data.h"
#include "field_player_avatar.h"
#include "main.h"
diff --git a/src/field_weather.c b/src/field_weather.c
index ff5d5b507..5ff2eddf9 100644
--- a/src/field_weather.c
+++ b/src/field_weather.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "field_weather.h"
-#include "asm.h"
#include "palette.h"
#include "sprite.h"
#include "task.h"
diff --git a/src/fieldmap.c b/src/fieldmap.c
index 2ed2266f5..e573ec13a 100644
--- a/src/fieldmap.c
+++ b/src/fieldmap.c
@@ -1,14 +1,10 @@
#include "global.h"
#include "fieldmap.h"
#include "palette.h"
-
-extern struct MapHeader * const get_mapheader_by_bank_and_number(u8, u8);
-extern void mapheader_run_script_with_tag_x1(void);
-extern void sub_80BB970(struct MapEvents *);
-extern void sub_80BBCCC();
-extern void sub_8056670();
-extern void UpdateTVScreensOnMap();
-extern void sub_80538F0(u8 mapGroup, u8 mapNum);
+#include "rom4.h"
+#include "script.h"
+#include "secret_base.h"
+#include "tv.h"
struct ConnectionFlags
{
@@ -24,8 +20,6 @@ struct Coords32
s32 y;
};
-extern const struct Coords32 gUnknown_0821664C[];
-
EWRAM_DATA static u16 gUnknown_02029828[0x2800] = {0};
EWRAM_DATA struct MapHeader gMapHeader = {0};
EWRAM_DATA struct Camera gUnknown_0202E844 = {0};
@@ -33,17 +27,6 @@ EWRAM_DATA static struct ConnectionFlags gUnknown_0202E850 = {0};
static const struct ConnectionFlags sDummyConnectionFlags = {0};
-void mapheader_copy_mapdata_with_padding(struct MapHeader *mapHeader);
-void sub_80560AC(struct MapHeader *);
-void map_copy_with_padding(u16 *map, u16 width, u16 height);
-void fillSouthConnection(struct MapHeader *, struct MapHeader *, s32);
-void fillNorthConnection(struct MapHeader *, struct MapHeader *, s32);
-void fillWestConnection(struct MapHeader *, struct MapHeader *, s32);
-void fillEastConnection(struct MapHeader *, struct MapHeader *, s32);
-struct MapConnection *sub_8056A64(u8 direction, int x, int y);
-bool8 sub_8056ABC(u8 direction, int x, int y, struct MapConnection *connection);
-bool8 sub_8056B20(int x, int src_width, int dest_width, int offset);
-
struct MapHeader *mapconnection_get_mapheader(struct MapConnection *connection)
{
return get_mapheader_by_bank_and_number(connection->mapGroup, connection->mapNum);
@@ -352,7 +335,7 @@ union Block
u16 value;
};
-u16 MapGridGetZCoordAt(int x, int y)
+u8 MapGridGetZCoordAt(int x, int y)
{
u16 block;
int i;
@@ -378,7 +361,7 @@ u16 MapGridGetZCoordAt(int x, int y)
return block >> 12;
}
-u16 MapGridIsImpassableAt(int x, int y)
+u8 MapGridIsImpassableAt(int x, int y)
{
u16 block;
int i;
@@ -404,7 +387,7 @@ u16 MapGridIsImpassableAt(int x, int y)
return (block & 0xc00) >> 10;
}
-u16 MapGridGetMetatileIdAt(int x, int y)
+u32 MapGridGetMetatileIdAt(int x, int y)
{
u16 block;
int i;
@@ -444,7 +427,7 @@ u32 MapGridGetMetatileBehaviorAt(int x, int y)
return GetBehaviorByMetatileId(metatile) & 0xff;
}
-u16 MapGridGetMetatileLayerTypeAt(int x, int y)
+u8 MapGridGetMetatileLayerTypeAt(int x, int y)
{
u16 metatile;
metatile = MapGridGetMetatileIdAt(x, y);
diff --git a/src/fldeff_cut.c b/src/fldeff_cut.c
index 8fde74852..e837dbd45 100644
--- a/src/fldeff_cut.c
+++ b/src/fldeff_cut.c
@@ -1,22 +1,25 @@
#include "global.h"
-#include "asm.h"
+#include "fldeff_cut.h"
#include "field_camera.h"
#include "field_effect.h"
#include "field_player_avatar.h"
+#include "fieldmap.h"
#include "map_obj_lock.h"
#include "metatile_behavior.h"
#include "metatile_behaviors.h"
+#include "pokemon_menu.h"
#include "rom4.h"
#include "rom6.h"
#include "script.h"
#include "songs.h"
#include "sound.h"
#include "sprite.h"
+#include "task.h"
#include "trig.h"
extern u8 gCutGrassSpriteArray[8]; // seems to be an array of 8 sprite IDs
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern void (*gUnknown_03005CE4)(void);
extern struct SpriteTemplate gSpriteTemplate_CutGrass;
@@ -28,18 +31,6 @@ extern u32 gUnknown_0202FF84[];
extern u8 UseCutScript;
-extern void sub_808AB90(void); // unknown args
-extern void sub_805BCC0(s16 x, s16 y);
-
-void sub_80A2634(void);
-void sub_80A25E8(void);
-void sub_80A2684(void);
-void sub_80A27A8(s16, s16);
-void sub_80A28F4(s16, s16);
-void objc_8097BBC(struct Sprite *sprite);
-void sub_80A2AB8(void);
-void sub_80A2B00(void); // unknown args
-
bool8 SetUpFieldMove_Cut(void)
{
s16 x, y;
@@ -48,7 +39,7 @@ bool8 SetUpFieldMove_Cut(void)
if(npc_before_player_of_type(0x52) == TRUE) // is in front of tree?
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_80A2634;
return TRUE;
}
@@ -67,7 +58,7 @@ bool8 SetUpFieldMove_Cut(void)
if(MetatileBehavior_IsPokeGrass(tileBehavior) == TRUE
|| MetatileBehavior_IsAshGrass(tileBehavior) == TRUE)
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_80A25E8;
return TRUE;
}
diff --git a/src/fldeff_softboiled.c b/src/fldeff_softboiled.c
index d0ee712af..45f319c62 100644
--- a/src/fldeff_softboiled.c
+++ b/src/fldeff_softboiled.c
@@ -1,7 +1,9 @@
#include "global.h"
-#include "asm.h"
+#include "fldeff_softboiled.h"
#include "menu.h"
+#include "party_menu.h"
#include "pokemon.h"
+#include "pokemon_menu.h"
#include "songs.h"
#include "sound.h"
#include "sprite.h"
@@ -62,10 +64,6 @@ extern u8 gLastFieldPokeMenuOpened;
extern u8 unk_2000000[];
extern u8 gUnknown_0202E8F4;
-// Public
-bool8 SetUpFieldMove_SoftBoiled(void);
-void sub_8133D28(u8 taskid);
-
// Static
static void sub_8133D50(u8 taskId);
static void sub_8133E74(u8 taskId);
diff --git a/src/fldeff_strength.c b/src/fldeff_strength.c
index f9db40a67..1edae09d4 100644
--- a/src/fldeff_strength.c
+++ b/src/fldeff_strength.c
@@ -1,8 +1,9 @@
#include "global.h"
-#include "asm.h"
#include "braille_puzzles.h"
#include "field_effect.h"
+#include "party_menu.h"
#include "pokemon.h"
+#include "pokemon_menu.h"
#include "rom6.h"
#include "script.h"
#include "task.h"
@@ -16,7 +17,7 @@ extern u32 gUnknown_0202FF84[];
extern u8 gLastFieldPokeMenuOpened;
extern u16 gScriptResult;
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern void (*gUnknown_03005CE4)(void);
extern u8 UseStrengthScript[];
@@ -26,7 +27,7 @@ bool8 SetUpFieldMove_Strength(void)
if (ShouldDoBrailleStrengthEffect())
{
gScriptResult = gLastFieldPokeMenuOpened;
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_811AA38;
}
else
@@ -34,7 +35,7 @@ bool8 SetUpFieldMove_Strength(void)
if (npc_before_player_of_type(87) != TRUE)
return 0;
gScriptResult = gLastFieldPokeMenuOpened;
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_811AA18;
}
diff --git a/src/fldeff_sweetscent.c b/src/fldeff_sweetscent.c
index 4e8214b07..6e782f4ac 100644
--- a/src/fldeff_sweetscent.c
+++ b/src/fldeff_sweetscent.c
@@ -1,8 +1,8 @@
#include "global.h"
-#include "asm.h"
#include "field_effect.h"
#include "field_player_avatar.h"
#include "palette.h"
+#include "pokemon_menu.h"
#include "rom6.h"
#include "script.h"
#include "sound.h"
@@ -18,14 +18,14 @@ static void sub_812C118(u8);
extern u32 gUnknown_0202FF84[];
extern u8 gLastFieldPokeMenuOpened;
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern void (*gUnknown_03005CE4)(void);
extern u8 SweetScentNothingHereScript[];
bool8 SetUpFieldMove_SweetScent(void)
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_812BFD4;
return TRUE;
}
diff --git a/src/fldeff_teleport.c b/src/fldeff_teleport.c
index 0e6933649..df12d3072 100644
--- a/src/fldeff_teleport.c
+++ b/src/fldeff_teleport.c
@@ -1,26 +1,23 @@
#include "global.h"
-#include "asm.h"
+#include "fldeff_teleport.h"
#include "field_effect.h"
#include "field_player_avatar.h"
+#include "pokemon_menu.h"
#include "rom4.h"
#include "rom6.h"
-
-extern void sub_8087BA8(void);
+#include "task.h"
extern u32 gUnknown_0202FF84[];
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern u8 gLastFieldPokeMenuOpened;
extern void (*gUnknown_03005CE4)(void);
-void hm_teleport_run_dp02scr(void);
-void sub_814A404(void);
-
bool8 SetUpFieldMove_Teleport(void)
{
if (is_light_level_1_2_3_or_6(gMapHeader.mapType) == TRUE)
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = hm_teleport_run_dp02scr;
return TRUE;
}
diff --git a/src/hof_pc.c b/src/hof_pc.c
index fcbc3f7e1..4646d171c 100644
--- a/src/hof_pc.c
+++ b/src/hof_pc.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "hall_of_fame.h"
#include "main.h"
#include "palette.h"
#include "rom4.h"
@@ -6,7 +7,7 @@
#include "script_menu.h"
#include "task.h"
-extern void sub_81428CC(void);
+extern void (*gFieldCallback)(void);
extern void (*gUnknown_0300485C)(void);
static void ReshowPCMenuAfterHallOfFamePC(void);
@@ -21,7 +22,7 @@ void AccessHallOfFamePC(void)
void ReturnFromHallOfFamePC(void)
{
SetMainCallback2(c2_exit_to_overworld_2_switch);
- gUnknown_0300485C = ReshowPCMenuAfterHallOfFamePC;
+ gFieldCallback = ReshowPCMenuAfterHallOfFamePC;
}
static void ReshowPCMenuAfterHallOfFamePC(void)
diff --git a/src/intro.c b/src/intro.c
index ba2197ae7..f13bd04e6 100644
--- a/src/intro.c
+++ b/src/intro.c
@@ -1,9 +1,10 @@
#include "global.h"
#include "gba/m4a_internal.h"
#include "intro.h"
-#include "asm.h"
#include "data2.h"
#include "decompress.h"
+#include "hall_of_fame.h"
+#include "intro_credits_graphics.h"
#include "libgncmultiboot.h"
#include "link.h"
#include "m4a.h"
@@ -18,9 +19,7 @@
#include "task.h"
#include "title_screen.h"
#include "trig.h"
-
-extern void *species_and_otid_get_pal(/*TODO: arg types*/);
-extern void sub_8143680(int, u8);
+#include "unknown_task.h"
extern struct SpriteTemplate gUnknown_02024E8C;
extern u16 gUnknown_02039318;
@@ -33,16 +32,9 @@ extern u16 gSaveFileStatus;
extern u8 gReservedSpritePaletteCount;
extern const u8 gInterfaceGfx_PokeBall[];
extern const u16 gInterfacePal_PokeBall[];
-extern const struct SpriteSheet gIntro2BrendanSpriteSheet;
-extern const struct SpriteSheet gIntro2MaySpriteSheet;
-extern const struct SpriteSheet gIntro2BicycleSpriteSheet;
-extern const struct SpriteSheet gIntro2LatiosSpriteSheet;
-extern const struct SpriteSheet gIntro2LatiasSpriteSheet;
-extern const struct SpritePalette gIntro2SpritePalettes[];
extern const u8 gIntroCopyright_Gfx[];
extern const u16 gIntroCopyright_Pal[];
extern const u16 gIntroCopyright_Tilemap[];
-extern const u16 gUnknown_08393E64[];
extern void *const gUnknown_0840B5A0[];
//--------------------------------------------------
@@ -1780,7 +1772,7 @@ void sub_813CE30(u16 scrX, u16 scrY, u16 zoom, u16 alpha)
static u16 sub_813CE88(u16 species, s16 x, s16 y, u16 d, u8 front)
{
- void *pal;
+ const u16 *pal;
u8 spriteId;
if (front)
diff --git a/src/item.c b/src/item.c
index ad2b9aed3..920670e8f 100644
--- a/src/item.c
+++ b/src/item.c
@@ -1,10 +1,9 @@
#include "global.h"
#include "item.h"
+#include "berry.h"
#include "string_util.h"
#include "strings.h"
-extern struct Berry *GetBerryInfo(u8 berry);
-
extern u8 gUnknown_02038560;
extern struct Item gItems[];
diff --git a/src/item_use.c b/src/item_use.c
index d1c1dbf2a..269c847a5 100644
--- a/src/item_use.c
+++ b/src/item_use.c
@@ -1,15 +1,19 @@
#include "global.h"
-#include "asm.h"
+#include "item_use.h"
#include "battle.h"
#include "berry.h"
+#include "bike.h"
#include "coins.h"
#include "data2.h"
#include "event_data.h"
+#include "field_effect.h"
+#include "field_fadetransition.h"
#include "field_map_obj_helpers.h"
#include "field_player_avatar.h"
#include "field_weather.h"
#include "fieldmap.h"
#include "item.h"
+#include "item_menu.h"
#include "items.h"
#include "mail.h"
#include "main.h"
@@ -18,7 +22,12 @@
#include "menu_helpers.h"
#include "metatile_behavior.h"
#include "palette.h"
+#include "party_menu.h"
+#include "pokeblock.h"
+#include "pokemon_item_effect.h"
+#include "pokemon_menu.h"
#include "rom4.h"
+#include "rom_8094928.h"
#include "script.h"
#include "songs.h"
#include "sound.h"
@@ -28,8 +37,9 @@
#include "vars.h"
extern void (* gUnknown_03005D00)(u8);
+extern void (* gFieldCallback)(void);
extern void (* gUnknown_0300485C)(void);
-extern void (* gUnknown_03004AE4)(u8);
+extern void (* gUnknown_03004AE4)(u8, u16, TaskFunc);
extern u8 gUnknown_02038561;
extern u8 gLastFieldPokeMenuOpened;
@@ -40,62 +50,9 @@ extern u8 gUnknown_081A168F[];
extern u16 gUnknown_02024A6A[];
-extern void HandleItemMenuPaletteFade(u8);
-extern void ExecuteItemUseFromBlackPalette(void);
-extern void DisplayItemMessageOnField(u8, const u8 *, TaskFunc, u16);
-extern void CleanUpItemMenuMessage(u8);
-extern void CleanUpOverworldMessage(u8);
-extern void ItemUseOnFieldCB_Bike(u8);
-extern void ItemUseOnFieldCB_Rod(u8);
-extern void ItemUseOnFieldCB_Itemfinder(u8);
-extern void sub_80A5D04(void);
-extern bool8 IsBikingDisallowedByPlayer(void);
-extern void GetOnOffBike(u8);
-extern struct MapConnection *sub_8056BA0(s16 x, s16 y); // fieldmap.c
-extern void sub_810BA7C(u8);
-extern void sub_8080E28(void);
-extern void UseMedicine(u8);
-extern void sub_8070048(u8);
-extern void DoPPRecoveryItemEffect(u8);
-extern void DoPPUpItemEffect(u8);
-extern void DoRareCandyItemEffect(u8);
-extern void DoEvolutionStoneItemEffect(u8);
-extern u16 ItemIdToBattleMoveId(u16);
-extern void sub_80A3FA0(u16 *, u32, u32, u32, u32, u32);
-extern void sub_80A3E0C(void);
-extern void TeachMonTMMove(u8);
-extern void sub_80878A8(void);
-extern void sub_8053014(void);
-extern void sub_80A7094(u8);
-extern bool8 ExecuteTableBasedItemEffect_(struct Pokemon *mon, u16, u8, u16);
-extern void sub_8094E4C(void);
-extern u8 ExecuteTableBasedItemEffect__(u8 u8, u16 u16, int i);
-extern u8 GetItemEffectType();
-extern void sub_808B020(void);
-extern void sub_810B96C(void);
-
extern u16 gScriptItemId;
extern u16 gBattleTypeFlags;
-bool8 ItemfinderCheckForHiddenItems(struct MapEvents *events, u8 taskId);
-void RunItemfinderResults(u8);
-void ExitItemfinder(u8);
-void sub_80C9720(u8);
-void sub_80C9838(u8, s16, s16);
-u8 GetPlayerDirectionTowardsHiddenItem(s16, s16);
-void SetPlayerDirectionTowardsItem(u8);
-void DisplayItemRespondingMessageAndExitItemfinder(u8);
-void RotatePlayerAndExitItemfinder(u8);
-void sub_80C9D00(u8);
-void sub_80C9D74(u8);
-void sub_80C9EE4(u8);
-void sub_80C9F10(u8);
-void sub_80C9F80(u8);
-void sub_80C9FC0(u8);
-void ItemUseOutOfBattle_TMHM(u8);
-void ItemUseOutOfBattle_EvolutionStone(u8);
-void ItemUseOutOfBattle_CannotUse(u8);
-
static const u8 gSSTidalBetaString[] = _("この チケットで ふねに のりほうだい\nはやく のってみたいな");
static const u8 gSSTidalBetaString2[] = _("この チケットで ふねに のりほうだい\nはやく のってみたいな");
@@ -150,7 +107,7 @@ void SetUpItemUseOnFieldCallback(u8 taskId)
{
if (gTasks[taskId].data[2] != 1)
{
- gUnknown_0300485C = (void *)ExecuteItemUseFromBlackPalette;
+ gFieldCallback = (void *)ExecuteItemUseFromBlackPalette;
ItemMenu_ConfirmNormalFade(taskId);
}
else
@@ -772,7 +729,7 @@ void ItemUseOutOfBattle_PokeblockCase(u8 taskId)
}
else
{
- gUnknown_0300485C = (void *)sub_8080E28;
+ gFieldCallback = (void *)sub_8080E28;
sub_810BA7C(1);
ItemMenu_ConfirmComplexFade(taskId);
}
@@ -825,7 +782,7 @@ void sub_80C9C7C(u8 taskId)
if(IsPlayerFacingPlantedBerryTree() == TRUE)
{
gUnknown_03005D00 = sub_80C9D00;
- gUnknown_0300485C = ExecuteItemUseFromBlackPalette;
+ gFieldCallback = ExecuteItemUseFromBlackPalette;
gTasks[taskId].data[8] = (u32)c2_exit_to_overworld_2_switch >> 16;
gTasks[taskId].data[9] = (u32)c2_exit_to_overworld_2_switch;
gTasks[taskId].func = HandleItemMenuPaletteFade;
@@ -944,7 +901,7 @@ void sub_80C9F80(u8 var)
{
DisplayYesNoMenu(7, 7, 1);
sub_80A3FA0(gBGTilemapBuffers[1], 8, 8, 5, 4, 1);
- sub_80F914C(var, &gUnknown_083D61F4);
+ DoYesNoFuncWithChoice(var, &gUnknown_083D61F4);
}
void sub_80C9FC0(u8 var)
diff --git a/src/link.c b/src/link.c
index 17e78e0a5..5f6c32370 100644
--- a/src/link.c
+++ b/src/link.c
@@ -1,7 +1,9 @@
#include "global.h"
#include "link.h"
-#include "asm.h"
#include "battle.h"
+#include "berry.h"
+#include "berry_blender.h"
+#include "hall_of_fame.h"
#include "main.h"
#include "menu.h"
#include "palette.h"
@@ -75,6 +77,7 @@ static void sub_80083E0(void);
static void sub_8008454(void);
static void sub_80084C8(void);
static void sub_80084F4(void);
+
static void CheckErrorStatus(void);
static void CB2_PrintErrorMessage(void);
static u8 IsSioMultiMaster(void);
diff --git a/src/load_save.c b/src/load_save.c
index 0add1b0e3..0630f060c 100644
--- a/src/load_save.c
+++ b/src/load_save.c
@@ -1,7 +1,6 @@
#include "global.h"
#include "gba/flash_internal.h"
#include "load_save.h"
-#include "asm.h"
#include "main.h"
#include "pokemon.h"
#include "rom4.h"
diff --git a/src/lottery_corner.c b/src/lottery_corner.c
index 66e1238ef..c2c25b9ac 100644
--- a/src/lottery_corner.c
+++ b/src/lottery_corner.c
@@ -9,7 +9,6 @@
extern u16 gScriptResult;
extern u16 gSpecialVar_0x8004;
-extern struct Pokemon gPlayerParty[6];
extern struct PokemonStorage gPokemonStorage;
extern u16 gSpecialVar_0x8005;
extern u16 gSpecialVar_0x8006;
diff --git a/src/mail.c b/src/mail.c
index 4ec107011..658d37976 100644
--- a/src/mail.c
+++ b/src/mail.c
@@ -1,16 +1,20 @@
#include "global.h"
#include "mail.h"
-#include "asm.h"
+#include "easy_chat.h"
#include "items.h"
+#include "mail_data.h"
#include "menu.h"
+#include "menu_helpers.h"
#include "name_string_util.h"
#include "palette.h"
+#include "pokemon_icon.h"
#include "rom4.h"
#include "sprite.h"
#include "string_util.h"
#include "strings2.h"
#include "task.h"
#include "text.h"
+#include "unknown_task.h"
struct UnkMailStruct
{
@@ -84,7 +88,7 @@ static void sub_80F8FB4(void);
void HandleReadMail(struct MailStruct *arg0, MainCallback arg1, bool8 arg2)
{
u16 mailDesign;
- u8 buffer[4];
+ u16 buffer[2];
ewram0.varFF = GAME_LANGUAGE;
ewram0.var100 = 1;
diff --git a/src/mail_data.c b/src/mail_data.c
index 23d22e21f..ae3f4b3e8 100644
--- a/src/mail_data.c
+++ b/src/mail_data.c
@@ -1,15 +1,12 @@
#include "global.h"
+#include "mail_data.h"
#include "items.h"
#include "name_string_util.h"
#include "pokemon.h"
+#include "pokemon_icon.h"
#include "species.h"
#include "text.h"
-void ClearMailStruct(struct MailStruct *);
-u16 SpeciesToMailSpecies(u16, u32);
-bool8 ItemIsMail(u16);
-u16 GetUnownLetterByPersonality(u32);
-
void ClearMailData(void)
{
u8 i;
diff --git a/src/main.c b/src/main.c
index 19891459c..afaa0e77a 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2,17 +2,18 @@
#include "gba/flash_internal.h"
#include "gba/m4a_internal.h"
#include "main.h"
-#include "asm.h"
#include "intro.h"
#include "link.h"
#include "load_save.h"
#include "m4a.h"
#include "play_time.h"
#include "rng.h"
+#include "rom3.h"
#include "rom4.h"
#include "rtc.h"
#include "siirtc.h"
#include "sound.h"
+#include "unknown_task.h"
extern struct SoundInfo gSoundInfo;
extern u32 IntrMain[];
diff --git a/src/main_menu.c b/src/main_menu.c
index b2d08698b..09fd06d9e 100644
--- a/src/main_menu.c
+++ b/src/main_menu.c
@@ -1,14 +1,15 @@
#include "global.h"
#include "main_menu.h"
-#include "asm.h"
#include "data2.h"
#include "decompress.h"
#include "event_data.h"
+#include "field_effect.h"
#include "menu.h"
#include "mystery_event_menu.h"
#include "naming_screen.h"
#include "option_menu.h"
#include "palette.h"
+#include "pokeball.h"
#include "rom4.h"
#include "rtc.h"
#include "save_menu_util.h"
@@ -20,6 +21,7 @@
#include "task.h"
#include "text.h"
#include "title_screen.h"
+#include "unknown_task.h"
#define BirchSpeechUpdateWindowText() ((u8)MenuUpdateWindowText_OverrideLineLength(24))
@@ -945,14 +947,14 @@ static void Task_NewGameSpeech16(u8 taskId)
switch (GenderMenuProcessInput())
{
case MALE:
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
gSaveBlock2.playerGender = MALE;
MenuZeroFillWindowRect(2, 4, 8, 9);
gTasks[taskId].func = Task_NewGameSpeech19;
break;
case FEMALE:
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
gSaveBlock2.playerGender = FEMALE;
MenuZeroFillWindowRect(2, 4, 8, 9);
@@ -1048,7 +1050,7 @@ static void Task_NewGameSpeech21(u8 taskId)
case 2:
case 3:
case 4:
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
MenuZeroFillWindowRect(2, 1, 22, 12);
SetPresetPlayerName(selection);
@@ -1060,7 +1062,7 @@ static void Task_NewGameSpeech21(u8 taskId)
gTasks[taskId].func = Task_NewGameSpeech22;
break;
case -1: //B button
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
MenuZeroFillWindowRect(2, 1, 22, 12);
gTasks[taskId].func = Task_NewGameSpeech14; //Go back to gender menu
diff --git a/src/map_name_popup.c b/src/map_name_popup.c
index c10a3f9de..303cc3d07 100644
--- a/src/map_name_popup.c
+++ b/src/map_name_popup.c
@@ -1,7 +1,8 @@
#include "global.h"
-#include "asm.h"
+#include "map_name_popup.h"
#include "event_data.h"
#include "menu.h"
+#include "region_map.h"
#include "task.h"
EWRAM_DATA static u8 sTaskId = 0;
diff --git a/src/map_obj_lock.c b/src/map_obj_lock.c
index 713ca03f9..bd40bcacc 100644
--- a/src/map_obj_lock.c
+++ b/src/map_obj_lock.c
@@ -1,8 +1,9 @@
#include "global.h"
#include "map_obj_lock.h"
-#include "asm.h"
+#include "field_map_obj.h"
#include "field_map_obj_helpers.h"
#include "field_player_avatar.h"
+#include "script_movement.h"
#include "task.h"
extern u16 gScriptFacing;
diff --git a/src/matsuda_debug_menu.c b/src/matsuda_debug_menu.c
index 018e36567..3665cabd8 100644
--- a/src/matsuda_debug_menu.c
+++ b/src/matsuda_debug_menu.c
@@ -1,7 +1,8 @@
#include "global.h"
#include "matsuda_debug_menu.h"
-#include "asm.h"
#include "contest.h"
+#include "contest_link_80C2020.h"
+#include "contest_link_80C857C.h"
#include "data2.h"
#include "link.h"
#include "main.h"
@@ -13,6 +14,7 @@
#include "string_util.h"
#include "task.h"
#include "text.h"
+#include "unknown_task.h"
extern u8 gUnknown_0203856C;
extern u8 gUnknown_0203857D[][64];
@@ -27,8 +29,6 @@ extern u8 gContestPlayerMonIndex;
extern u16 gScriptContestCategory;
extern u16 gScriptContestRank;
-extern struct Window gMenuWindow;
-
extern u16 gUnknown_030042A4;
extern u16 gUnknown_030042A0;
extern u16 gUnknown_030042C0;
@@ -84,8 +84,6 @@ static void sub_80AA10C(void);
static void sub_80AA5BC(u8);
static void sub_80AA614(u8, u8);
static void sub_80AAD08(struct Sprite *, s8);
-extern void sub_80AB47C(void);
-extern int sub_80B2A7C(u8); //Don't know return type size
u8 unref_sub_80A9B28(void)
{
diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c
index d6fb33917..93684fc60 100644
--- a/src/mauville_old_man.c
+++ b/src/mauville_old_man.c
@@ -1,20 +1,16 @@
#include "global.h"
-#include "asm.h"
+#include "mauville_old_man.h"
+#include "easy_chat.h"
#include "menu.h"
#include "rng.h"
#include "script.h"
#include "string_util.h"
#include "strings.h"
+#include "trader.h"
extern u16 gScriptResult;
extern u16 gSpecialVar_0x8004;
-extern void sub_80F83F8(void);
-extern void sub_81099CC(void);
-extern void sub_80F83D0(void);
-extern void sub_80F7F80(u8);
-extern u16 sub_80EB8EC(void);
-extern void sub_80F7DC0(void);
extern u32 gUnknown_083E5388[];
extern u32 gUnknown_083E53A8[];
diff --git a/src/menu.c b/src/menu.c
index 3acac88a0..d84a4c3c5 100644
--- a/src/menu.c
+++ b/src/menu.c
@@ -54,7 +54,7 @@ void CloseMenu(void)
MenuZeroFillScreen();
sub_8064E2C();
ScriptContext2_Disable();
- sub_8072DEC();
+ HandleDestroyMenuCursors();
}
void AppendToList(u8 *list, u8 *pindex, u32 value)
@@ -270,14 +270,14 @@ s8 ProcessMenuInput(void)
{
PlaySE(SE_SELECT);
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
return gMenu.cursorPos;
}
if (gMain.newKeys & B_BUTTON)
{
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
return -1;
}
@@ -305,14 +305,14 @@ s8 ProcessMenuInputNoWrap(void)
{
PlaySE(SE_SELECT);
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
return gMenu.cursorPos;
}
if (gMain.newKeys & B_BUTTON)
{
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
return -1;
}
@@ -517,7 +517,7 @@ s8 sub_80727CC(void)
if (gMain.newKeys & A_BUTTON)
{
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
return GetMenuCursorPos();
}
@@ -525,7 +525,7 @@ s8 sub_80727CC(void)
if (gMain.newKeys & B_BUTTON)
{
if (gMenu.menu_field_7)
- sub_8072DEC();
+ HandleDestroyMenuCursors();
return -1;
}
@@ -629,7 +629,7 @@ void MenuPrint_RightAligned(u8 *str, u8 left, u8 top)
sub_8004D38(gMenuWindowPtr, str, gMenuTextTileOffset, left, top);
}
-void sub_8072B80(u8 *a1, u8 a2, u8 a3, u8 *a4)
+void sub_8072B80(const u8 *a1, u8 a2, u8 a3, const u8 *a4)
{
u8 buffer[64];
u8 width = GetStringWidth(gMenuWindowPtr, a4);
@@ -731,7 +731,7 @@ void sub_8072DDC(u8 a1)
sub_8072DCC(8 * a1);
}
-void sub_8072DEC(void)
+void HandleDestroyMenuCursors(void)
{
- sub_814A7FC();
+ DestroyMenuCursor();
}
diff --git a/src/menu_cursor.c b/src/menu_cursor.c
index fa28332df..cfb38ca47 100644
--- a/src/menu_cursor.c
+++ b/src/menu_cursor.c
@@ -45,7 +45,7 @@ u8 sub_814A5C0(u8 a1, u16 a2, u8 a3, u16 a4, u8 a5)
struct Sprite *v10;
if (gUnknown_0203A3D0 != 0x40 || gUnknown_0203A3D1 != 0x40)
- sub_814A7FC();
+ DestroyMenuCursor();
v9 = 1;
if (a2 == 0xFFFF)
@@ -120,7 +120,7 @@ u8 unref_sub_814A7AC(u8 a1, u16 a2, u8 a3)
return sub_814A758(a1, val1, val2, a3);
}
-void sub_814A7FC(void)
+void DestroyMenuCursor(void)
{
if (gUnknown_0203A3D0 != 0x40)
{
diff --git a/src/metatile_behavior.c b/src/metatile_behavior.c
index befd6f20d..d05ba0b89 100644
--- a/src/metatile_behavior.c
+++ b/src/metatile_behavior.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "metatile_behavior.h"
#include "metatile_behaviors.h"
#define TILE_ATTRIBUTES(three, two, one) (((one) ? 1 : 0) | ((two) ? 2 : 0) | ((three) ? 4 : 0))
@@ -247,8 +248,6 @@ static const u8 sTileBitAttributes[] =
TILE_ATTRIBUTES(FALSE, FALSE, FALSE)
};
-bool8 MetatileBehavior_IsWaterfall(u8);
-
// only used as default case for checking jump landing in field_ground_effect.
bool8 MetatileBehavior_IsATile(u8 var)
{
diff --git a/src/mori_debug_menu.c b/src/mori_debug_menu.c
index 18c65b7e6..ba79261c0 100644
--- a/src/mori_debug_menu.c
+++ b/src/mori_debug_menu.c
@@ -1,10 +1,12 @@
#include "global.h"
#include "mori_debug_menu.h"
-#include "asm.h"
#include "data2.h"
+#include "daycare.h"
+#include "learn_move.h"
#include "link.h"
#include "main.h"
#include "menu.h"
+#include "pokeblock.h"
#include "start_menu.h"
#include "string_util.h"
diff --git a/src/mystery_event_menu.c b/src/mystery_event_menu.c
index 77c959b07..4be5dec1c 100644
--- a/src/mystery_event_menu.c
+++ b/src/mystery_event_menu.c
@@ -1,9 +1,9 @@
#include "global.h"
#include "mystery_event_menu.h"
-#include "asm.h"
#include "link.h"
#include "main.h"
#include "menu.h"
+#include "mystery_event_script.h"
#include "palette.h"
#include "save.h"
#include "songs.h"
diff --git a/src/mystery_event_script.c b/src/mystery_event_script.c
index 515a0722f..e3d533d28 100644
--- a/src/mystery_event_script.c
+++ b/src/mystery_event_script.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "mystery_event_script.h"
#include "script.h"
#include "string_util.h"
#include "text.h"
@@ -16,8 +17,6 @@ extern ScrCmdFunc gScriptFuncs_End[];
extern u8 gOtherText_DataCannotUseVersion[];
-void sub_8126160(u32 val);
-
bool32 sub_8126098(u16 a1, u32 a2, u16 a3, u32 a4)
{
if (!(a1 & 0x2))
diff --git a/src/name_string_util.c b/src/name_string_util.c
index a1812d5e9..f1a935453 100644
--- a/src/name_string_util.c
+++ b/src/name_string_util.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "name_string_util.h"
#include "string_util.h"
#include "text.h"
diff --git a/src/naming_screen.c b/src/naming_screen.c
index 53ee5ff19..88059e669 100644
--- a/src/naming_screen.c
+++ b/src/naming_screen.c
@@ -1,10 +1,13 @@
#include "global.h"
#include "naming_screen.h"
-#include "asm.h"
#include "data2.h"
+#include "field_effect.h"
+#include "field_map_obj.h"
+#include "field_player_avatar.h"
#include "main.h"
#include "menu.h"
#include "palette.h"
+#include "pokemon_icon.h"
#include "songs.h"
#include "sound.h"
#include "sprite.h"
@@ -13,11 +16,7 @@
#include "task.h"
#include "text.h"
#include "trig.h"
-
-extern u8 GetRivalAvatarGraphicsIdByStateIdAndGender(u8, u8);
-extern u8 CreateMonIcon();
-extern void sub_809D51C(void);
-extern void MultiplyInvertedPaletteRGBComponents(u16, u8, u8, u8);
+#include "util.h"
extern u16 gKeyRepeatStartDelay;
@@ -51,7 +50,6 @@ extern const struct SpriteTemplate gSpriteTemplate_83CE688;
extern const struct SpriteSheet gUnknown_083CE6A0[];
extern const struct SpritePalette gUnknown_083CE708[];
extern const u8 gNamingScreenMenu_Gfx[];
-extern u16 gMenuMessageBoxContentTileOffset;
extern const u16 gNamingScreenPalettes[];
extern const u16 gUnknown_083CE748[];
extern const u16 gUnknown_083CEBF8[];
diff --git a/src/new_game.c b/src/new_game.c
index 12e04a4ef..33aacd10a 100644
--- a/src/new_game.c
+++ b/src/new_game.c
@@ -1,18 +1,30 @@
#include "global.h"
#include "new_game.h"
-#include "asm.h"
+#include "battle_records.h"
#include "berry.h"
+#include "contest.h"
+#include "decoration_inventory.h"
#include "dewford_trend.h"
+#include "easy_chat.h"
#include "event_data.h"
+#include "field_specials.h"
+#include "item_menu.h"
#include "lottery_corner.h"
+#include "mail_data.h"
+#include "mauville_old_man.h"
#include "play_time.h"
+#include "player_pc.h"
+#include "pokeblock.h"
#include "pokedex.h"
#include "pokemon_size_record.h"
+#include "pokemon_storage_system.h"
#include "rng.h"
#include "roamer.h"
#include "rom4.h"
#include "rtc.h"
#include "script.h"
+#include "secret_base.h"
+#include "tv.h"
extern u8 gDifferentSaveFile;
diff --git a/src/palette.c b/src/palette.c
index 165eb2eae..94a4f8092 100644
--- a/src/palette.c
+++ b/src/palette.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "palette.h"
-#include "asm.h"
#include "blend_palette.h"
#include "decompress.h"
@@ -615,7 +614,7 @@ static u8 UpdateFastPaletteFade(void)
if (b < b0)
b = b0;
- gPlttBufferFaded[i] = r | (g << 5) | (b << 10);
+ gPlttBufferFaded[i] = RGB(r, g, b);
}
break;
case FAST_FADE_OUT_TO_WHTIE:
@@ -633,7 +632,7 @@ static u8 UpdateFastPaletteFade(void)
if (b > 31)
b = 31;
- gPlttBufferFaded[i] = r | (g << 5) | (b << 10);
+ gPlttBufferFaded[i] = RGB(r, g, b);
}
break;
case FAST_FADE_IN_FROM_BLACK:
@@ -659,7 +658,7 @@ static u8 UpdateFastPaletteFade(void)
if (b > b0)
b = b0;
- gPlttBufferFaded[i] = r | (g << 5) | (b << 10);
+ gPlttBufferFaded[i] = RGB(r, g, b);
}
break;
case FAST_FADE_OUT_TO_BLACK:
@@ -677,7 +676,7 @@ static u8 UpdateFastPaletteFade(void)
if (b < 0)
b = 0;
- gPlttBufferFaded[i] = r | (g << 5) | (b << 10);
+ gPlttBufferFaded[i] = RGB(r, g, b);
}
}
diff --git a/src/party_menu.c b/src/party_menu.c
index ee6bcf2a9..be0db4dc4 100644
--- a/src/party_menu.c
+++ b/src/party_menu.c
@@ -1,20 +1,28 @@
#include "global.h"
-#include "asm.h"
+#include "party_menu.h"
+#include "battle.h"
+#include "battle_interface.h"
+#include "battle_party_menu.h"
#include "data2.h"
+#include "event_data.h"
+#include "item.h"
+#include "mail_data.h"
+#include "main.h"
#include "menu.h"
+#include "palette.h"
#include "pokemon.h"
+#include "pokemon_item_effect.h"
+#include "pokemon_menu.h"
+#include "pokemon_summary_screen.h"
+#include "rom_8077ABC.h"
+#include "rom_8094928.h"
#include "songs.h"
#include "sound.h"
+#include "species.h"
+#include "sprite.h"
#include "string_util.h"
#include "strings.h"
#include "task.h"
-#include "sprite.h"
-#include "palette.h"
-#include "event_data.h"
-#include "main.h"
-#include "item.h"
-#include "battle_interface.h"
-#include "species.h"
#define DATA_COUNT (6)
@@ -31,7 +39,7 @@ struct Unk201B000
u8 unk260;
u8 unk261;
u8 filler262[2];
- s16 unk264[DATA_COUNT * 2];
+ s16 unk264[DATA_COUNT * 2]; // This may be a union
u8 filler27C[2];
s16 unk27E;
s16 unk280;
@@ -88,75 +96,8 @@ extern const u16 gUnknown_08376504[];
extern void (*const gUnknown_08376B54[])(u8);
extern const u8 *const gUnknown_08376D04[DATA_COUNT];
extern const struct UnknownStruct5 gUnknown_08376BB4[][6];
-extern const u8 *const gItemEffectTable[];
-
-extern bool8 IsDoubleBattle(void);
-extern void SetUpBattlePokemonMenu(u8);
-extern void sub_808B0C0(u8);
-extern u8 GiveMailToMon(struct Pokemon *, u16);
-extern bool8 ItemIsMail(u16);
-extern void ClearMailStruct(struct MailStruct *);
-extern u8 GiveMailToMon2(struct Pokemon *, struct MailStruct *);
-extern void TakeMailFromMon(struct Pokemon *);
-extern u8 TakeMailFromMon2(struct Pokemon *);
-extern u32 CanMonLearnTMHM(struct Pokemon *, u8);
-extern void sub_809D9F0(struct Pokemon *, u8, u8, void *, u32);
-extern void sub_808B564();
-extern u8 sub_809FA30(void);
-extern void sub_808B508(u8);
-extern void sub_8032638();
-extern u8 sub_8094C20();
-extern bool8 ExecuteTableBasedItemEffect_();
-extern u8 GetMonStatusAndPokerus();
-
-u8 sub_806CA38(u8);
-void task_pc_turn_off();
-static void sub_806E884(u8 taskId);
-void sub_806F8AC(u8 taskId);
-void sub_806FB0C(u8 taskId);
-void PartyMenuUpdateLevelOrStatus(struct Pokemon *, u8);
-bool8 ExecuteTableBasedItemEffect__(u8, u16, u8);
-void sub_80701DC(u8 taskId);
-void DoRecoverPP(u8);
-void Task_RareCandy1(u8);
-void Task_RareCandy2(u8);
-void Task_RareCandy3(u8);
-void sub_806D538();
-void sub_806D5A4(void);
-void sub_806E8D0(u8 taskId, u16 b, TaskFunc c);
-void GetMedicineItemEffectMessage(u16);
-void sub_8070A20();
-void sub_8070848(u8 taskId);
-void sub_8070968();
-void party_menu_link_mon_held_item_object(u8);
-void Task_ConfirmGiveHeldItem(u8);
-void DisplayGiveHeldItemMessage(u8, u16, u8);
-void SetHeldItemIconVisibility();
-void DisplayTakeHeldItemMessage(u8, u16, u8);
-void Task_ConfirmTakeHeldMail(u8);
-void Task_TeamMonTMMove(u8);
-void Task_TeamMonTMMove2(u8);
-void Task_TeamMonTMMove3(u8);
-void Task_TeamMonTMMove4(u8);
-void sub_806F358(u8);
-void sub_806F390(u8);
-void sub_806F44C(u8);
-void TMMoveUpdateMoveSlot(u8);
-void StopTryingToTeachMove_806F614(u8);
-void StopTryingToTeachMove_806F67C(u8);
-void StopTryingToTeachMove_806F6B4(u8);
-void sub_806FB44(u8);
-void sub_8070C54();
-void SetMonIconAnim();
-u8 GetMonIconSpriteId_maybe();
-void PartyMenuDoPrintHP(u8, int, u16, u16);
-void PartyMenuClearLevelStatusTilemap();
-void PartyMenuPrintMonLevelOrStatus();
-u8 GetItemEffectType();
-bool8 IsBlueYellowRedFlute(u16);
-void TryPrintPartyMenuMonNickname();
-void sub_8070088(u8);
+static void sub_806E884(u8 taskId);
/*
void sub_806AEDC(void)
@@ -1286,7 +1227,7 @@ void DoPPRecoveryItemEffect(u8 taskId, u16 b, TaskFunc c)
void ItemUseMoveMenu_HandleMoveSelection(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(19, 10, 29, 19);
sub_806D5A4();
gTasks[taskId].data[11] = GetMenuCursorPos();
@@ -1295,7 +1236,7 @@ void ItemUseMoveMenu_HandleMoveSelection(u8 taskId)
void ItemUseMoveMenu_HandleCancel(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(19, 10, 29, 19);
if (gMain.inBattle)
gTasks[ewram1C000.unk4].func = SetUpBattlePokemonMenu;
diff --git a/src/player_pc.c b/src/player_pc.c
index c012afb02..9cb395432 100644
--- a/src/player_pc.c
+++ b/src/player_pc.c
@@ -1,7 +1,10 @@
#include "global.h"
-#include "asm.h"
+#include "player_pc.h"
+#include "decoration.h"
+#include "field_fadetransition.h"
#include "field_weather.h"
#include "item.h"
+#include "item_menu.h"
#include "items.h"
#include "main.h"
#include "menu.h"
@@ -12,36 +15,172 @@
#include "string_util.h"
#include "strings.h"
#include "task.h"
-
-#define NEW_GAME_PC_ITEMS(i, type) ((u16)(gNewGamePCItems + type)[i * 2])
-
-// type as in define above
-enum
-{
- ITEM_ID,
- QUANTITY,
-};
+#include "songs.h"
+#include "name_string_util.h"
+#include "mail.h"
+#include "rom4.h"
+#include "player_pc.h"
extern void DisplayItemMessageOnField(u8, const u8*, TaskFunc, u16);
extern void DoPlayerPCDecoration(u8);
extern void BuyMenuFreeMemory(void);
extern void DestroyVerticalScrollIndicator(u8);
-extern u8 sub_813AF3C(void);
-extern void sub_813AF78(void);
-extern void sub_813B108(u8);
-extern void sub_813B174(u8);
-extern void sub_80A6A30(void);
+extern void PauseVerticalScrollIndicator(u8);
+extern void StartVerticalScrollIndicators(int);
+extern void LoadScrollIndicatorPalette(void);
+extern void ClearMailStruct(struct MailStruct *);
extern u8 sub_807D770(void);
-extern void sub_813AE6C(u8, u8);
-extern void sub_813AD58(u16);
-extern void sub_813AE0C(u8);
-extern void sub_80F996C(u8);
-extern void sub_80A418C(u16, enum StringConvertMode, int, int, int);
-extern void sub_80F98DC(int);
+extern void sub_808B020(void);
extern void sub_80A4164(u8 *, u16, enum StringConvertMode, u8);
-extern void CreateVerticalScrollIndicators(u32, u32, u32); // unknown args
+extern void sub_80A418C(u16, enum StringConvertMode, int, int, int);
+extern void sub_80A6A30(void);
+extern void sub_80F944C(void);
+
+extern u8 *gPcItemMenuOptionOrder;
+extern u8 gPcItemMenuOptionsNum;
+
+extern u8 gUnknown_02038561;
+
+// event scripts
+extern u8 gBrendanHouse_TurnPCOff[];
+extern u8 gMayHouse_TurnPCOff[];
+
+extern void (*gFieldCallback)(void);
+
+static void InitPlayerPCMenu(u8 taskId);
+static void PlayerPCProcessMenuInput(u8 taskId);
+static void InitItemStorageMenu(u8);
+static void ItemStorageMenuPrint(const u8 *);
+static void ItemStorageMenuProcessInput(u8);
+static void ItemStorage_ProcessInput(u8);
+static void ItemStorage_SetItemAndMailCount(u8);
+static void ItemStorage_DoItemAction(u8);
+static void ItemStorage_GoBackToPlayerPCMenu(u8);
+static void ItemStorage_HandleQuantityRolling(u8);
+static void ItemStorage_DoItemWithdraw(u8);
+static void ItemStorage_DoItemToss(u8);
+static void ItemStorage_HandleRemoveItem(u8);
+static void ItemStorage_WaitPressHandleResumeProcessInput(u8);
+static void ItemStorage_HandleResumeProcessInput(u8);
+static void ItemStorage_DoItemSwap(u8, bool8);
+static void ItemStorage_DrawItemList(u8);
+static void ItemStorage_PrintItemPcResponse(u16);
+static void ItemStorage_DrawBothListAndDescription(u8);
+static void ItemStorage_GoBackToItemPCMenu(u8, u8);
+static void ItemStorage_LoadPalette(void);
+static u8 GetMailboxMailCount(void);
+static void Mailbox_UpdateMailList(void);
+static void Mailbox_DrawMailboxMenu(u8);
+static void Mailbox_ProcessInput(u8);
+static void Mailbox_CloseScrollIndicators(void);
+static void Mailbox_PrintWhatToDoWithPlayerMailText(u8);
+static void Mailbox_TurnOff(u8);
+static void Mailbox_PrintMailOptions(u8);
+static void Mailbox_MailOptionsProcessInput(u8);
+static void Mailbox_FadeAndReadMail(u8);
+static void Mailbox_ReturnToFieldFromReadMail(void);
+static void Mailbox_DrawYesNoBeforeMove(u8);
+static void Mailbox_DoGiveMailPokeMenu(u8);
+static void Mailbox_NoPokemonForMail(u8);
+static void Mailbox_Cancel(u8);
+static void Mailbox_DrawMailMenuAndDoProcessInput(u8);
+static void PlayerPC_ItemStorage(u8 taskId);
+static void PlayerPC_Mailbox(u8 taskId);
+static void PlayerPC_Decoration(u8 var);
+static void PlayerPC_TurnOff(u8 taskId);
+static void ItemStorage_Withdraw(u8);
+static void ItemStorage_Deposit(u8);
+static void ItemStorage_Toss(u8);
+static void ItemStorage_Exit(u8);
+static void ItemStorage_ResumeInputFromYesToss(u8);
+static void ItemStorage_ResumeInputFromNoToss(u8);
+static void Mailbox_DoMailMoveToBag(u8);
+static void Mailbox_ReturnToInputAfterNo(u8);
+static void Mailbox_DoMailRead(u8);
+static void Mailbox_MoveToBag(u8);
+static void Mailbox_Give(u8);
+static void Mailbox_Cancel(u8);
+
+static const struct TextStruct gPCText_OptionDescList[] =
+{
+ PCText_TakeOutItems,
+ PCText_StoreItems,
+ PCText_ThrowAwayItems,
+ gMenuText_GoBackToPrev
+};
+
+static const struct MenuAction2 gPCText_PlayerPCOptionsText[] =
+{
+ { SecretBaseText_ItemStorage, PlayerPC_ItemStorage },
+ { gPCText_Mailbox, PlayerPC_Mailbox },
+ { SecretBaseText_Decoration, PlayerPC_Decoration },
+ { SecretBaseText_TurnOff, PlayerPC_TurnOff }
+};
+
+static const u8 gBedroomPC_OptionOrder[] =
+{
+ PLAYERPC_MENU_ITEMSTORAGE,
+ PLAYERPC_MENU_MAILBOX,
+ PLAYERPC_MENU_DECORATION,
+ PLAYERPC_MENU_TURNOFF
+};
+
+static const u8 gPlayerPC_OptionOrder[] =
+{
+ PLAYERPC_MENU_ITEMSTORAGE,
+ PLAYERPC_MENU_MAILBOX,
+ PLAYERPC_MENU_TURNOFF
+};
+
+static const struct MenuAction2 gPCText_ItemPCOptionsText[] =
+{
+ { PCText_WithdrawItem, ItemStorage_Withdraw },
+ { PCText_DepositItem, ItemStorage_Deposit },
+ { PCText_TossItem, ItemStorage_Toss },
+ { gUnknownText_Exit, ItemStorage_Exit }
+};
+
+static const struct YesNoFuncTable ResumeFromTossYesNoFuncList[] = // ResumeFromTossYesNoFuncList
+{
+ ItemStorage_ResumeInputFromYesToss,
+ ItemStorage_ResumeInputFromNoToss
+};
+
+static const struct YesNoFuncTable ResumeFromWithdrawYesNoFuncList[] = // ResumeFromWithdrawYesNoFuncList
+{
+ Mailbox_DoMailMoveToBag,
+ Mailbox_ReturnToInputAfterNo
+};
+
+// the use of this struct is meant to be an ItemSlot struct, but NewGameInitPCItems refuses to match without a weird pointer access.
+static const struct ItemSlot gNewGamePCItems[] =
+{
+ { ITEM_POTION, 1 },
+ { ITEM_NONE, 0 }
+};
+
+static const struct MenuAction2 gMailboxMailOptions[] =
+{
+ { OtherText_Read, Mailbox_DoMailRead },
+ { gOtherText_MoveToBag, Mailbox_MoveToBag },
+ { OtherText_Give, Mailbox_Give },
+ { gOtherText_CancelNoTerminator, Mailbox_Cancel }
+};
+
+static const u8 gNonSelectedItemFormattedText[] = _("{STR_VAR_1}{CLEAR_TO 80}");
+static const u8 gSelectedItemFormattedText[] = _("{COLOR RED}{STR_VAR_1}{CLEAR_TO 80}");
+static const u8 gNonSelectedItemQuantityFormatText[] = _("{STR_VAR_1}");
+static const u8 gSelectedItemQuantityFormatText[] = _("{COLOR RED}{STR_VAR_1}");
+static const u8 gUnknown_08406330[] = _("{CLEAR_TO 32}");
+
+static const u16 gUnknown_08406334[3] =
+{
+ 0x5294,
+ 0x6B5A,
+ 0x7FFF
+};
-extern u16 gNewGamePCItems[];
+static const u8 gHighlightedMoveToBagFormatText[] = _("{COLOR RED}{STR_VAR_1}");
extern u8 *gUnknown_02039314;
extern struct MenuAction gUnknown_08406298[];
@@ -50,7 +189,6 @@ extern u8 gUnknown_084062B8[];
extern u8 gUnknown_084062BC[];
extern u8 gUnknown_0840632A[];
extern u8 gUnknown_08406327[];
-extern u8 gUnknown_08406330[];
extern u8 gUnknown_0840631E[];
extern u8 gUnknown_08406318[];
@@ -64,24 +202,6 @@ extern u32 gUnknown_08406288[];
extern const struct MenuAction gUnknown_084062C0[];
extern const struct YesNoFuncTable gUnknown_084062E0;
-void InitPlayerPCMenu(u8 taskId);
-void PlayerPCProcessMenuInput(u8 taskId);
-void InitItemStorageMenu(u8);
-void ItemStorageMenuPrint(u8 *);
-void ItemStorageMenuProcessInput(u8);
-void sub_813A280(u8);
-void sub_813A240(u8);
-void sub_813A4B4(u8);
-void sub_813A468(u8);
-void HandleQuantityRolling(u8);
-void sub_813A6FC(u8);
-void sub_813A794(u8);
-void sub_813A8F0(u8);
-void sub_813A984(u8);
-void sub_813A9EC(u8);
-void sub_813AA30(u8, u8);
-void sub_813ABE8(u8);
-
void NewGameInitPCItems(void)
{
u8 i;
@@ -94,55 +214,49 @@ void NewGameInitPCItems(void)
void BedroomPC(void)
{
- u8 taskId;
-
- gUnknown_02039314 = gUnknown_084062B8;
- gUnknown_030007B4 = 4;
- taskId = CreateTask(TaskDummy, 0);
- DisplayItemMessageOnField(taskId, gOtherText_WhatWillYouDo, InitPlayerPCMenu, 0);
+ gPcItemMenuOptionOrder = (u8 *)gBedroomPC_OptionOrder;
+ gPcItemMenuOptionsNum = 4;
+ DisplayItemMessageOnField(CreateTask(TaskDummy, 0), gOtherText_WhatWillYouDo, InitPlayerPCMenu, 0);
}
void PlayerPC(void)
{
- u8 taskId;
-
- gUnknown_02039314 = gUnknown_084062BC;
- gUnknown_030007B4 = 3;
- taskId = CreateTask(TaskDummy, 0);
- DisplayItemMessageOnField(taskId, gOtherText_WhatWillYouDo, InitPlayerPCMenu, 0);
+ gPcItemMenuOptionOrder = (u8 *)gPlayerPC_OptionOrder;
+ gPcItemMenuOptionsNum = 3;
+ DisplayItemMessageOnField(CreateTask(TaskDummy, 0), gOtherText_WhatWillYouDo, InitPlayerPCMenu, 0);
}
-void InitPlayerPCMenu(u8 taskId)
+static void InitPlayerPCMenu(u8 taskId)
{
- MenuDrawTextWindow(0, 0, 10, gUnknown_030007B4 * 2 + 1);
- PrintMenuItemsReordered(1, 1, gUnknown_030007B4, gUnknown_08406298, gUnknown_02039314);
- InitMenu(0, 1, 1, gUnknown_030007B4, 0, 9);
- gTasks[taskId].func = PlayerPCProcessMenuInput;
+ MenuDrawTextWindow(0, 0, 10, gPcItemMenuOptionsNum * 2 + 1);
+ PrintMenuItemsReordered(1, 1, gPcItemMenuOptionsNum, (struct MenuAction *)gPCText_PlayerPCOptionsText, gPcItemMenuOptionOrder);
+ InitMenu(0, 1, 1, gPcItemMenuOptionsNum, 0, 9);
+ TASK.FUNC = PlayerPCProcessMenuInput;
}
-void PlayerPCProcessMenuInput(u8 taskId)
+static void PlayerPCProcessMenuInput(u8 taskId)
{
- if (gMain.newAndRepeatedKeys & 0x40)
+ if (gMain.newAndRepeatedKeys & DPAD_UP)
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MoveMenuCursor(-1);
}
- else if (gMain.newAndRepeatedKeys & 0x80)
+ else if (gMain.newAndRepeatedKeys & DPAD_DOWN)
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MoveMenuCursor(1);
}
- else if (gMain.newKeys & 0x1)
+ else if (gMain.newKeys & A_BUTTON)
{
- sub_8072DEC();
- PlaySE(5);
- gUnknown_08406298[gUnknown_02039314[GetMenuCursorPos()]].func(taskId);
+ HandleDestroyMenuCursors();
+ PlaySE(SE_SELECT);
+ gPCText_PlayerPCOptionsText[gPcItemMenuOptionOrder[GetMenuCursorPos()]].func(taskId);
}
- else if (gMain.newKeys & 0x2)
+ else if (gMain.newKeys & B_BUTTON)
{
- sub_8072DEC();
- PlaySE(5);
- gUnknown_08406298[gUnknown_030007B4[gUnknown_02039314 - 1]].func(taskId);
+ HandleDestroyMenuCursors();
+ PlaySE(SE_SELECT);
+ gPCText_PlayerPCOptionsText[gPcItemMenuOptionsNum[gPcItemMenuOptionOrder - 1]].func(taskId); // run EXIT.
}
}
@@ -151,44 +265,46 @@ void ReshowPlayerPC(u8 var)
DisplayItemMessageOnField(var, gOtherText_WhatWillYouDo, InitPlayerPCMenu, 0);
}
-void PlayerPC_ItemStorage(u8 taskId)
+static void PlayerPC_ItemStorage(u8 taskId)
{
- InitItemStorageMenu(0);
- gTasks[taskId].func = ItemStorageMenuProcessInput;
+ InitItemStorageMenu(ITEMPC_MENU_WITHDRAW);
+ TASK.FUNC = ItemStorageMenuProcessInput;
}
-void PlayerPC_Mailbox(u8 taskId)
+static void PlayerPC_Mailbox(u8 taskId)
{
MenuZeroFillWindowRect(0, 0, 10, 9);
- unk_201FE00[3] = sub_813AF3C();
- if (!unk_201FE00[3])
+ gMailboxInfo.count = GetMailboxMailCount();
+
+ if (gMailboxInfo.count == 0)
DisplayItemMessageOnField(taskId, gOtherText_NoMailHere, ReshowPlayerPC, 0);
else
{
- unk_201FE00[0] = 0;
- unk_201FE00[2] = 0;
- sub_813AF78();
- sub_813A240(taskId);
- sub_813B108(taskId);
- gTasks[taskId].func = sub_813B174;
+ gMailboxInfo.cursorPos = 0;
+ gMailboxInfo.itemsAbove = 0;
+ Mailbox_UpdateMailList();
+ ItemStorage_SetItemAndMailCount(taskId);
+ Mailbox_DrawMailboxMenu(taskId);
+ TASK.FUNC = Mailbox_ProcessInput;
}
}
-void PlayerPC_Decoration(u8 var)
+static void PlayerPC_Decoration(u8 var)
{
MenuZeroFillWindowRect(0, 0, 10, 9);
DoPlayerPCDecoration(var);
}
-void PlayerPC_TurnOff(u8 taskId)
+static void PlayerPC_TurnOff(u8 taskId)
{
- if (gUnknown_030007B4 == 4)
+ if (gPcItemMenuOptionsNum == 4) // if the option count is 4, we are at the bedroom PC and not player PC, so do gender specific handling.
{
MenuZeroFillWindowRect(0, 0, 0x1D, 0x13);
- if (!gSaveBlock2.playerGender)
- ScriptContext1_SetupScript(&gUnknown_08152850); // male
+
+ if (gSaveBlock2.playerGender == MALE)
+ ScriptContext1_SetupScript(gBrendanHouse_TurnPCOff);
else
- ScriptContext1_SetupScript(&gUnknown_08152C75); // female
+ ScriptContext1_SetupScript(gMayHouse_TurnPCOff);
}
else
{
@@ -198,49 +314,49 @@ void PlayerPC_TurnOff(u8 taskId)
DestroyTask(taskId);
}
-void InitItemStorageMenu(u8 var)
+static void InitItemStorageMenu(u8 var)
{
MenuZeroFillWindowRect(0, 0, 10, 9);
MenuDrawTextWindow(0, 0, 11, 9);
- PrintMenuItems(1, 1, 4, gUnknown_084062C0);
+ PrintMenuItems(1, 1, 4, (struct MenuAction *)gPCText_ItemPCOptionsText);
InitMenu(0, 1, 1, 4, var, 10);
- ItemStorageMenuPrint((u8 *)gUnknown_08406288[var]);
+ ItemStorageMenuPrint(gPCText_OptionDescList[var].text);
}
-void ItemStorageMenuPrint(u8 *textPtr)
+static void ItemStorageMenuPrint(const u8 *textPtr)
{
MenuFillWindowRectWithBlankTile(2, 15, 27, 18);
MenuPrint(textPtr, 2, 15);
}
-void ItemStorageMenuProcessInput(u8 var)
+static void ItemStorageMenuProcessInput(u8 var)
{
- if (gMain.newAndRepeatedKeys & 0x40)
+ if (gMain.newAndRepeatedKeys & DPAD_UP)
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MoveMenuCursor(-1);
- ItemStorageMenuPrint((u8 *)gUnknown_08406288[GetMenuCursorPos()]);
+ ItemStorageMenuPrint(gPCText_OptionDescList[GetMenuCursorPos()].text);
}
- else if (gMain.newAndRepeatedKeys & 0x80)
+ else if (gMain.newAndRepeatedKeys & DPAD_DOWN)
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MoveMenuCursor(1);
- ItemStorageMenuPrint((u8 *)gUnknown_08406288[GetMenuCursorPos()]);
+ ItemStorageMenuPrint(gPCText_OptionDescList[GetMenuCursorPos()].text);
}
- else if (gMain.newKeys & 0x1)
+ else if (gMain.newKeys & A_BUTTON)
{
- PlaySE(5);
- gUnknown_084062C0[GetMenuCursorPos()].func(var);
+ PlaySE(SE_SELECT);
+ gPCText_ItemPCOptionsText[GetMenuCursorPos()].func(var);
}
- else if (gMain.newKeys & 0x2)
+ else if (gMain.newKeys & B_BUTTON)
{
- sub_8072DEC();
- PlaySE(5);
- gUnknown_084062C0[3].func(var);
+ HandleDestroyMenuCursors();
+ PlaySE(SE_SELECT);
+ gPCText_ItemPCOptionsText[ITEMPC_MENU_EXIT].func(var);
}
}
-void Task_ItemStorage_Deposit(u8 taskId)
+static void Task_ItemStorage_Deposit(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -249,547 +365,544 @@ void Task_ItemStorage_Deposit(u8 taskId)
}
}
-void ItemStorage_Deposit(u8 taskId)
+static void ItemStorage_Deposit(u8 taskId)
{
- gTasks[taskId].func = Task_ItemStorage_Deposit;
+ TASK.FUNC = Task_ItemStorage_Deposit;
fade_screen(1, 0);
}
-void sub_813A0C8(u8 taskId)
+static void ItemStorage_HandleReturnToProcessInput(u8 taskId)
{
- if (sub_807D770() == 1)
- gTasks[taskId].func = ItemStorageMenuProcessInput;
+ if (sub_807D770() == TRUE)
+ TASK.FUNC = ItemStorageMenuProcessInput;
}
-void sub_813A0F8(void)
+void ItemStorage_ReturnToMenuAfterDeposit(void)
{
MenuDisplayMessageBox();
- InitItemStorageMenu(1);
- CreateTask(sub_813A0C8, 0);
+ InitItemStorageMenu(ITEMPC_MENU_DEPOSIT);
+ CreateTask(ItemStorage_HandleReturnToProcessInput, 0);
pal_fill_black();
}
-void ItemStorage_Withdraw(u8 taskId)
+static void ItemStorage_Withdraw(u8 taskId)
{
- u8 var;
- u16 * data = gTasks[taskId].data;
+ s16 *data = TASK.data;
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 11, 9);
- var = CountUsedPCItemSlots();
- data[2] = var;
+ NUM_ITEMS = CountUsedPCItemSlots();
- if (var)
+ if (NUM_ITEMS != 0)
{
MenuZeroFillWindowRect(0, 14, 29, 19);
- data[6] = 0;
- data[0] = 0;
- data[1] = 0;
- sub_813A240(taskId);
- sub_813AE6C(taskId, 0);
- gTasks[taskId].func = sub_813A280;
+ CURRENT_ITEM_STORAGE_MENU = ITEMPC_MENU_WITHDRAW;
+ PAGE_INDEX = 0;
+ ITEMS_ABOVE_TOP = 0;
+ ItemStorage_SetItemAndMailCount(taskId);
+ ItemStorage_GoBackToItemPCMenu(taskId, 0);
+ TASK.FUNC = ItemStorage_ProcessInput;
}
else
DisplayItemMessageOnField(taskId, gOtherText_NoItems, PlayerPC_ItemStorage, 0);
}
-void ItemStorage_Toss(u8 taskId)
+static void ItemStorage_Toss(u8 taskId)
{
- u8 var;
- u16 * data = gTasks[taskId].data;
+ s16 *data = TASK.data;
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 11, 9);
- var = CountUsedPCItemSlots();
- data[2] = var;
+ NUM_ITEMS = CountUsedPCItemSlots();
- if (var)
+ if (NUM_ITEMS)
{
MenuZeroFillWindowRect(0, 14, 29, 19);
- data[6] = 2;
- data[0] = 0;
- data[1] = 0;
- sub_813A240(taskId);
- sub_813AE6C(taskId, 2);
- gTasks[taskId].func = sub_813A280;
+ CURRENT_ITEM_STORAGE_MENU = ITEMPC_MENU_TOSS;
+ PAGE_INDEX = 0;
+ ITEMS_ABOVE_TOP = 0;
+ ItemStorage_SetItemAndMailCount(taskId);
+ ItemStorage_GoBackToItemPCMenu(taskId, 2);
+ TASK.FUNC = ItemStorage_ProcessInput;
}
else
DisplayItemMessageOnField(taskId, gOtherText_NoItems, PlayerPC_ItemStorage, 0);
}
-void ItemStorage_Exit(u8 var)
+static void ItemStorage_Exit(u8 var)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 11, 9);
ReshowPlayerPC(var);
}
-void sub_813A240(u8 taskId)
+static void ItemStorage_SetItemAndMailCount(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
+ s16 *data = TASK.data;
- if (data[2] > 7)
- data[4] = 8;
+ if (NUM_ITEMS > 7) // we have a full page, so set the num of page items appropriately.
+ NUM_PAGE_ITEMS = 8;
else
- data[4] = data[2] + 1;
+ NUM_PAGE_ITEMS = NUM_ITEMS + 1; // there are not enough items to fill a full page; take the # of items and add 1 for the cancel button.
- if (unk_201FE00[3] > 7)
- unk_201FE00[1] = 8;
+ if (gMailboxInfo.count > 7)
+ gMailboxInfo.pageItems = 8;
else
- unk_201FE00[1] = unk_201FE00[3] + 1;
+ gMailboxInfo.pageItems = gMailboxInfo.count + 1;
}
-void sub_813A280(u8 taskId)
+static void ItemStorage_ProcessInput(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- s16 var;
+ s16 *data = TASK.data;
+ s16 trueIndex;
if (gMain.newAndRepeatedKeys & DPAD_UP)
{
- if(data[0])
+ if(PAGE_INDEX != 0) // did the cursor move physically upwards?
{
- PlaySE(5);
- data[0] = MoveMenuCursor(-1);
- var = data[1] + data[0];
- if (!data[9])
+ PlaySE(SE_SELECT);
+ PAGE_INDEX = MoveMenuCursor(-1);
+ trueIndex = ITEMS_ABOVE_TOP + PAGE_INDEX;
+ if (SWITCH_MODE_ACTIVE == FALSE) // are we not currently switching items?
{
- if (var == data[2])
+ if (trueIndex == NUM_ITEMS) // if the cursor is on top of cancel, print the go back to prev description.
{
- sub_813AD58(0xFFFF);
+ ItemStorage_PrintItemPcResponse(ITEMPC_GO_BACK_TO_PREV);
}
else
{
- sub_813AD58(gSaveBlock1.pcItems[var].itemId);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[trueIndex].itemId);
}
}
}
- else // _0813A2E4
+ else // the page cursor is at the top. but we may not be at the top of the true index list, so do another check.
{
- if (!data[1])
+ if (ITEMS_ABOVE_TOP == 0) // did the cursor not move due to being at the top of the list?
return;
- PlaySE(5);
- data[1]--;
- sub_813AE0C(taskId);
- // probably further down
- if (data[9])
- MoveMenuCursor(0);
+
+ PlaySE(SE_SELECT);
+ ITEMS_ABOVE_TOP--;
+ ItemStorage_DrawBothListAndDescription(taskId);
+
+ if (SWITCH_MODE_ACTIVE != FALSE)
+ MoveMenuCursor(0); // don't move the cursor. it's at the top of the page index, but not the true index.
}
}
else if(gMain.newAndRepeatedKeys & DPAD_DOWN) // _0813A306
{
- if(data[0] != data[4] - 1)
+ if(PAGE_INDEX != NUM_PAGE_ITEMS - 1)
{
- PlaySE(5);
- data[0] = MoveMenuCursor(1);
- var = data[1] + data[0];
+ PlaySE(SE_SELECT);
+ PAGE_INDEX = MoveMenuCursor(1);
+ trueIndex = ITEMS_ABOVE_TOP + PAGE_INDEX;
- if(data[9])
+ if(SWITCH_MODE_ACTIVE != FALSE)
return;
- if (var == data[2])
- sub_813AD58(0xFFFF); // probably further down
+ if (trueIndex == NUM_ITEMS)
+ ItemStorage_PrintItemPcResponse(ITEMPC_GO_BACK_TO_PREV); // probably further down
else
- sub_813AD58(gSaveBlock1.pcItems[var].itemId);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[trueIndex].itemId);
}
- else if(data[1] + data[0] != data[2])
+ else if(ITEMS_ABOVE_TOP + PAGE_INDEX != NUM_ITEMS)
{
- PlaySE(5);
- data[1]++;
- sub_813AE0C(taskId);
+ PlaySE(SE_SELECT);
+ ITEMS_ABOVE_TOP++;
+ ItemStorage_DrawBothListAndDescription(taskId);
- if (data[9])
+ if (SWITCH_MODE_ACTIVE != FALSE)
MoveMenuCursor(0);
}
}
else if(gMain.newKeys & SELECT_BUTTON) // _0813A3A0
{
- if (!data[9])
+ if (SWITCH_MODE_ACTIVE == FALSE)
{
- if (data[0] + data[1] != data[2])
+ if (PAGE_INDEX + ITEMS_ABOVE_TOP != NUM_ITEMS) // you cannot swap the Cancel button.
{
- PlaySE(5);
- data[9] = 1;
- data[8] = data[1] + data[0];
- sub_813AD58(0xFFF7);
+ PlaySE(SE_SELECT);
+ SWITCH_MODE_ACTIVE = TRUE;
+ SWAP_ITEM_INDEX = ITEMS_ABOVE_TOP + PAGE_INDEX;
+ ItemStorage_PrintItemPcResponse(ITEMPC_SWITCH_WHICH_ITEM);
}
// _0813A3DC
- sub_813ABE8(taskId);
+ ItemStorage_DrawItemList(taskId);
}
else // _0813A3E8
{
- PlaySE(5); // merging?
- sub_813AA30(taskId, 0);
- sub_813AE0C(taskId);
+ PlaySE(SE_SELECT);
+ ItemStorage_DoItemSwap(taskId, FALSE);
+ ItemStorage_DrawBothListAndDescription(taskId);
}
}
else if(gMain.newKeys & A_BUTTON)
{
- PlaySE(5);
- if(!data[9])
+ PlaySE(SE_SELECT);
+ if(SWITCH_MODE_ACTIVE == FALSE)
{
- if(data[1] + data[0] != data[2])
+ if(ITEMS_ABOVE_TOP + PAGE_INDEX != NUM_ITEMS)
{
- sub_813A4B4(taskId);
+ ItemStorage_DoItemAction(taskId);
}
else
{
- sub_813A468(taskId);
+ ItemStorage_GoBackToPlayerPCMenu(taskId);
}
}
else
{
- sub_813AA30(taskId, 0);
- sub_813AE0C(taskId);
+ ItemStorage_DoItemSwap(taskId, FALSE);
+ ItemStorage_DrawBothListAndDescription(taskId);
}
}
else if(gMain.newKeys & B_BUTTON)
{
- PlaySE(5);
- if(!data[9])
+ PlaySE(SE_SELECT);
+ if(SWITCH_MODE_ACTIVE == FALSE)
{
- sub_8072DEC();
- sub_813A468(taskId);
+ HandleDestroyMenuCursors();
+ ItemStorage_GoBackToPlayerPCMenu(taskId);
}
else
{
- sub_813AA30(taskId, 1);
- sub_813AE0C(taskId);
+ ItemStorage_DoItemSwap(taskId, TRUE);
+ ItemStorage_DrawBothListAndDescription(taskId);
}
}
}
-void sub_813A468(u8 taskId)
+static void ItemStorage_GoBackToPlayerPCMenu(u8 taskId)
{
BuyMenuFreeMemory();
DestroyVerticalScrollIndicator(0);
DestroyVerticalScrollIndicator(1);
MenuZeroFillWindowRect(0, 0, 29, 19);
MenuDisplayMessageBox();
- InitItemStorageMenu(gTasks[taskId].data[6]);
- gTasks[taskId].func = ItemStorageMenuProcessInput;
+ InitItemStorageMenu(TASK.CURRENT_ITEM_STORAGE_MENU);
+ TASK.FUNC = ItemStorageMenuProcessInput;
}
-void sub_813A4B4(u8 taskId)
+static void ItemStorage_DoItemAction(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u8 var = data[0] + data[1];
+ s16 *data = TASK.data;
+ u8 trueIndex = PAGE_INDEX + ITEMS_ABOVE_TOP;
- sub_80F996C(0);
- sub_80F996C(1);
+ PauseVerticalScrollIndicator(0);
+ PauseVerticalScrollIndicator(1); // PauseVerticalScrollIndicator
- if(!data[6])
+ if(CURRENT_ITEM_STORAGE_MENU == ITEMPC_MENU_WITHDRAW)
{
- if(gSaveBlock1.pcItems[var].quantity == 1)
+ if(gSaveBlock1.pcItems[trueIndex].quantity == 1)
{
- data[3] = 1;
- sub_813A6FC(taskId);
+ NUM_QUANTITY_ROLLER = 1;
+ ItemStorage_DoItemWithdraw(taskId);
return;
}
else // _0813A50C
{
- sub_813AD58(0xFFFE);
+ ItemStorage_PrintItemPcResponse(ITEMPC_HOW_MANY_TO_WITHDRAW);
}
}
- else if(gSaveBlock1.pcItems[var].quantity == 1) // _0813A518
+ else if(gSaveBlock1.pcItems[trueIndex].quantity == 1) // _0813A518
{
- data[3] = 1;
- sub_813A794(taskId);
+ NUM_QUANTITY_ROLLER = 1;
+ ItemStorage_DoItemToss(taskId);
return;
}
else
{
- sub_813AD58(0xFFFC);
+ ItemStorage_PrintItemPcResponse(ITEMPC_HOW_MANY_TO_TOSS);
}
- data[3] = 1;
+ NUM_QUANTITY_ROLLER = 1;
MenuDrawTextWindow(6, 8, 13, 11);
- sub_80A418C(data[3], STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3);
- gTasks[taskId].func = HandleQuantityRolling;
+ sub_80A418C(NUM_QUANTITY_ROLLER, STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3);
+ TASK.FUNC = ItemStorage_HandleQuantityRolling;
}
-void HandleQuantityRolling(u8 taskId)
+static void ItemStorage_HandleQuantityRolling(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u8 var = data[0] + data[1];
+ s16 *data = TASK.data;
+ u8 trueIndex = PAGE_INDEX + ITEMS_ABOVE_TOP;
if(gMain.newAndRepeatedKeys & DPAD_UP)
{
- if(data[3] != gSaveBlock1.pcItems[var].quantity)
- data[3]++;
+ if(NUM_QUANTITY_ROLLER != gSaveBlock1.pcItems[trueIndex].quantity)
+ NUM_QUANTITY_ROLLER++;
else
- data[3] = 1; // you are at the max amount of items you have when you press Up, set your quantity back to 1.
+ NUM_QUANTITY_ROLLER = 1; // you are at the max amount of items you have when you press Up, set your quantity back to 1.
- sub_80A418C(data[3], STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
+ sub_80A418C(NUM_QUANTITY_ROLLER, STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
}
else if(gMain.newAndRepeatedKeys & DPAD_DOWN)
{
- if(data[3] != 1)
- data[3]--;
+ if(NUM_QUANTITY_ROLLER != 1)
+ NUM_QUANTITY_ROLLER--;
else
- data[3] = gSaveBlock1.pcItems[var].quantity; // you are at 0 when you press down, set your quantity to the amount you have.
+ NUM_QUANTITY_ROLLER = gSaveBlock1.pcItems[trueIndex].quantity; // you are at 0 when you press down, set your quantity to the amount you have.
- sub_80A418C(data[3], STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
+ sub_80A418C(NUM_QUANTITY_ROLLER, STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
}
else if(gMain.newAndRepeatedKeys & DPAD_LEFT) // reduce by 10.
{
- data[3] -= 10;
+ NUM_QUANTITY_ROLLER -= 10;
- if(data[3] <= 0)
- data[3] = 1; // dont underflow or allow 0!
+ if(NUM_QUANTITY_ROLLER <= 0)
+ NUM_QUANTITY_ROLLER = 1; // dont underflow or allow 0!
- sub_80A418C(data[3], STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
+ sub_80A418C(NUM_QUANTITY_ROLLER, STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
}
else if(gMain.newAndRepeatedKeys & DPAD_RIGHT) // add 10.
{
- data[3] += 10;
+ NUM_QUANTITY_ROLLER += 10;
- if(data[3] > gSaveBlock1.pcItems[var].quantity)
- data[3] = gSaveBlock1.pcItems[var].quantity; // dont overflow!
+ if(NUM_QUANTITY_ROLLER > gSaveBlock1.pcItems[trueIndex].quantity)
+ NUM_QUANTITY_ROLLER = gSaveBlock1.pcItems[trueIndex].quantity; // dont overflow!
- sub_80A418C(data[3], STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
+ sub_80A418C(NUM_QUANTITY_ROLLER, STR_CONV_MODE_RIGHT_ALIGN, 8, 9, 3); // print quantity?
}
else if(gMain.newKeys & A_BUTTON) // confirm quantity.
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MenuZeroFillWindowRect(6, 6, 0xD, 0xB);
- if(!data[6])
- sub_813A6FC(taskId);
+ if(CURRENT_ITEM_STORAGE_MENU == ITEMPC_MENU_WITHDRAW)
+ ItemStorage_DoItemWithdraw(taskId);
else
- sub_813A794(taskId);
+ ItemStorage_DoItemToss(taskId);
}
else if(gMain.newKeys & B_BUTTON) // cancel quantity.
{
- PlaySE(5);
+ PlaySE(SE_SELECT);
MenuZeroFillWindowRect(6, 6, 0xD, 0xB);
- sub_80F98DC(0);
- sub_80F98DC(1);
- sub_813AD58(gSaveBlock1.pcItems[data[1] + data[0]].itemId); // why not use var?
- gTasks[taskId].func = sub_813A280;
+ StartVerticalScrollIndicators(0);
+ StartVerticalScrollIndicators(1);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[ITEMS_ABOVE_TOP + PAGE_INDEX].itemId); // why not use trueIndex?
+ TASK.FUNC = ItemStorage_ProcessInput;
}
}
-void sub_813A6FC(u8 taskId)
+static void ItemStorage_DoItemWithdraw(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u8 var = data[0] + data[1];
+ s16 *data = TASK.data;
+ u8 trueIndex = PAGE_INDEX + ITEMS_ABOVE_TOP;
- if(AddBagItem(gSaveBlock1.pcItems[var].itemId, data[3]) == TRUE) // add item works.
+ if(AddBagItem(gSaveBlock1.pcItems[trueIndex].itemId, NUM_QUANTITY_ROLLER) == TRUE) // add item works.
{
- CopyItemName(gSaveBlock1.pcItems[var].itemId, gStringVar1);
- ConvertIntToDecimalStringN(gStringVar2, data[3], 0, 3);
- sub_813AD58(0xFFFD);
- gTasks[taskId].func = sub_813A8F0;
+ CopyItemName(gSaveBlock1.pcItems[trueIndex].itemId, gStringVar1);
+ ConvertIntToDecimalStringN(gStringVar2, NUM_QUANTITY_ROLLER, 0, 3);
+ ItemStorage_PrintItemPcResponse(ITEMPC_WITHDREW_THING);
+ TASK.FUNC = ItemStorage_HandleRemoveItem;
}
- else // cannot add item. inventory full?
+ else
{
- data[3] = 0;
- sub_813AD58(0xFFFA);
- gTasks[taskId].func = sub_813A984;
+ NUM_QUANTITY_ROLLER = 0;
+ ItemStorage_PrintItemPcResponse(ITEMPC_NO_MORE_ROOM);
+ TASK.FUNC = ItemStorage_WaitPressHandleResumeProcessInput;
}
}
-void sub_813A794(u8 taskId)
+static void ItemStorage_DoItemToss(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u8 var = data[0] + data[1];
+ s16 *data = TASK.data;
+ u8 var = PAGE_INDEX + ITEMS_ABOVE_TOP;
if(ItemId_GetImportance(gSaveBlock1.pcItems[var].itemId) == FALSE)
{
CopyItemName(gSaveBlock1.pcItems[var].itemId, gStringVar1);
- ConvertIntToDecimalStringN(gStringVar2, data[3], 0, 3);
- sub_813AD58(65528);
+ ConvertIntToDecimalStringN(gStringVar2, NUM_QUANTITY_ROLLER, 0, 3);
+ ItemStorage_PrintItemPcResponse(ITEMPC_OKAY_TO_THROW_AWAY);
DisplayYesNoMenu(7, 6, 1);
- sub_80F914C(taskId, &gUnknown_084062E0);
+ DoYesNoFuncWithChoice(taskId, (struct YesNoFuncTable *)&ResumeFromTossYesNoFuncList);
}
else
{
- data[3] = 0;
- sub_813AD58(65529);
- gTasks[taskId].func = sub_813A8F0;
+ NUM_QUANTITY_ROLLER = 0;
+ ItemStorage_PrintItemPcResponse(ITEMPC_TOO_IMPORTANT);
+ TASK.FUNC = ItemStorage_HandleRemoveItem;
}
}
-void sub_813A83C(u8 taskId)
+static void ItemStorage_ResumeInputFromYesToss(u8 taskId)
{
MenuZeroFillWindowRect(0x6, 0x6, 0xD, 0xB);
- sub_813AD58(0xFFFB);
- gTasks[taskId].func = sub_813A8F0;
+ ItemStorage_PrintItemPcResponse(ITEMPC_THREW_AWAY_ITEM);
+ TASK.FUNC = ItemStorage_HandleRemoveItem;
}
-void sub_813A878(u8 taskId)
+static void ItemStorage_ResumeInputFromNoToss(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
+ s16 *data = TASK.data;
MenuZeroFillWindowRect(0x6, 0x6, 0xD, 0xB);
- InitMenu(0, 16, 2, data[4], data[0], 0xD);
- sub_80F98DC(0);
- sub_80F98DC(1);
- sub_813AD58(gSaveBlock1.pcItems[data[1] + data[0]].itemId);
- gTasks[taskId].func = sub_813A280;
+ InitMenu(0, 16, 2, NUM_PAGE_ITEMS, PAGE_INDEX, 0xD);
+ StartVerticalScrollIndicators(0);
+ StartVerticalScrollIndicators(1);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[ITEMS_ABOVE_TOP + PAGE_INDEX].itemId);
+ TASK.FUNC = ItemStorage_ProcessInput;
}
-void sub_813A8F0(u8 taskId)
+static void ItemStorage_HandleRemoveItem(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u16 var;
- u8 usedItemSlots;
+ s16 *data = TASK.data;
+ s16 oldNumItems;
- if(gMain.newKeys & 0x1 || gMain.newKeys == 0x2)
+ if(gMain.newKeys & A_BUTTON || gMain.newKeys == B_BUTTON)
{
- RemovePCItem(data[0] + data[1], data[3]);
- var = data[2];
- usedItemSlots = CountUsedPCItemSlots();
- data[2] = usedItemSlots;
+ RemovePCItem(PAGE_INDEX + ITEMS_ABOVE_TOP, NUM_QUANTITY_ROLLER);
+ oldNumItems = NUM_ITEMS;
+ NUM_ITEMS = CountUsedPCItemSlots();
- if((s16)var != usedItemSlots && (s16)var < data[4] + data[1] && data[1] != 0)
- data[1]--;
+ if(oldNumItems != NUM_ITEMS && oldNumItems < NUM_PAGE_ITEMS + ITEMS_ABOVE_TOP && ITEMS_ABOVE_TOP != 0)
+ ITEMS_ABOVE_TOP--;
- sub_813A240(taskId);
- sub_813A9EC(taskId);
- InitMenu(0, 16, 2, data[4], data[0], 0xD);
+ ItemStorage_SetItemAndMailCount(taskId);
+ ItemStorage_HandleResumeProcessInput(taskId);
+ InitMenu(0, 16, 2, NUM_PAGE_ITEMS, PAGE_INDEX, 0xD);
}
}
-void sub_813A984(u8 taskId)
+static void ItemStorage_WaitPressHandleResumeProcessInput(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
+ s16 *data = TASK.data;
- if(gMain.newKeys & 0x1 || gMain.newKeys == 2)
+ if(gMain.newKeys & A_BUTTON || gMain.newKeys == B_BUTTON)
{
- sub_813AD58(gSaveBlock1.pcItems[data[1] + data[0]].itemId);
- sub_80F98DC(0);
- sub_80F98DC(1);
- gTasks[taskId].func = sub_813A280;
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[ITEMS_ABOVE_TOP + PAGE_INDEX].itemId);
+ StartVerticalScrollIndicators(0);
+ StartVerticalScrollIndicators(1);
+ TASK.FUNC = ItemStorage_ProcessInput;
}
}
-void sub_813A9EC(u8 taskId)
+static void ItemStorage_HandleResumeProcessInput(u8 taskId)
{
MenuZeroFillWindowRect(0x6, 0x6, 0xD, 0xB);
- sub_80F98DC(0);
- sub_80F98DC(1);
- sub_813AE0C(taskId);
- gTasks[taskId].func = sub_813A280;
+ StartVerticalScrollIndicators(0);
+ StartVerticalScrollIndicators(1);
+ ItemStorage_DrawBothListAndDescription(taskId);
+ TASK.FUNC = ItemStorage_ProcessInput;
}
-void sub_813AA30(u8 taskId, u8 arg)
+static void ItemStorage_DoItemSwap(u8 taskId, bool8 switchModeDisabled)
{
- s16 *data = gTasks[taskId].data;
- u8 var = data[1] + data[0];
+ s16 *data = TASK.data;
+ u8 trueIndex = ITEMS_ABOVE_TOP + PAGE_INDEX;
- data[9] = 0;
+ SWITCH_MODE_ACTIVE = FALSE;
- if((u8)data[2] > var && (u8)data[8] != var && arg == 0)
+ if((u8)NUM_ITEMS > trueIndex && (u8)SWAP_ITEM_INDEX != trueIndex && switchModeDisabled == FALSE)
{
- struct ItemSlot itemSlot = gSaveBlock1.pcItems[data[8]]; // backup the itemSlot before swapping the two.
+ struct ItemSlot itemSlot = gSaveBlock1.pcItems[SWAP_ITEM_INDEX]; // backup the itemSlot before swapping the two.
- gSaveBlock1.pcItems[data[8]] = gSaveBlock1.pcItems[var];
- gSaveBlock1.pcItems[var] = itemSlot;
+ gSaveBlock1.pcItems[SWAP_ITEM_INDEX] = gSaveBlock1.pcItems[trueIndex];
+ gSaveBlock1.pcItems[trueIndex] = itemSlot;
return;
}
- else if(var == data[2])
+ else if(trueIndex == NUM_ITEMS)
{
- sub_813AD58(0xFFFF);
+ ItemStorage_PrintItemPcResponse(ITEMPC_GO_BACK_TO_PREV);
}
else
{
- sub_813AD58(gSaveBlock1.pcItems[var].itemId);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[trueIndex].itemId);
}
/*
THEORY: This check produces essentially dead code, but it might have been working in an earlier build
in which case it allows a programmer to easily duplicate items without the use of a debug menu.
+ This gets the page index of the swap index for some reason. It is currently unknown what it would have been used
+ for, but perhaps it was used to increase the quantity of the item without a debug menu.
With the removal of a lot of the debug menus close to release, a programmer may have added this to
help test things with a low key (such as planting a lot of duplicated berries, which requires this lazy "cheat")
without bringing the relevent debug menus back. The commented out line is intentionally left in below to show
what it may have looked like.
*/
- if(data[8] - data[1] > 0) { // this check is arbitrary and used to generate the correct assembly using the subtraction, which is what matters. the 0 check doesn't.
- //gSaveBlock1.pcItems[data[8]].quantity += 100;
- gSaveBlock1.pcItems[data[8]].quantity += 0; // do not enforce item cap.
+ if(SWAP_ITEM_INDEX - ITEMS_ABOVE_TOP <= 0) { // this check is arbitrary and used to generate the correct assembly using the subtraction, which is what matters. the 0 check doesn't.
+ //gSaveBlock1.pcItems[SWAP_ITEM_INDEX].quantity += 100;
+ gSaveBlock1.pcItems[SWAP_ITEM_INDEX].quantity += 0; // do not enforce item cap.
}
}
-void sub_813AAC4(u16 arg1, enum StringConvertMode arg2, u8 arg3, u8 arg4, int arg5)
+static void ItemStorage_DrawItemQuantity(u16 arg1, enum StringConvertMode arg2, u8 arg3, u8 arg4, int isSwapSelected)
{
sub_80A4164(gStringVar1, arg1, arg2, arg4);
- if(arg5)
- MenuPrint(gUnknown_0840632A, 0x1A, arg3);
+ if(isSwapSelected != FALSE)
+ MenuPrint(gSelectedItemQuantityFormatText, 0x1A, arg3);
else
- MenuPrint(gUnknown_08406327, 0x1A, arg3);
+ MenuPrint(gNonSelectedItemQuantityFormatText, 0x1A, arg3);
}
-void sub_813AB10(u8 var)
+static void ItemStorage_DrawItemVoidQuantity(u8 var)
{
MenuPrint(gUnknown_08406330, 0x19, var);
}
-void sub_813AB28(struct ItemSlot *itemSlot, u8 var, int var2)
+static void ItemStorage_DrawItemName(struct ItemSlot *itemSlot, u8 var, int isSwapSelected)
{
CopyItemName(itemSlot->itemId, gStringVar1);
- if(var2)
- MenuPrint(gUnknown_0840631E, 16, var);
+ if(isSwapSelected != FALSE)
+ MenuPrint(gSelectedItemFormattedText, 16, var);
else
- MenuPrint(gUnknown_08406318, 16, var);
+ MenuPrint(gNonSelectedItemFormattedText, 16, var);
}
-void sub_813AB64(struct ItemSlot *itemSlot, u8 var, int var2)
+static void ItemStorage_DrawNormalItemEntry(struct ItemSlot *itemSlot, u8 var, int var2)
{
- sub_813AB28(itemSlot, var, var2);
- sub_813AAC4(itemSlot->quantity, STR_CONV_MODE_RIGHT_ALIGN, var, 3, var2);
+ ItemStorage_DrawItemName(itemSlot, var, var2);
+ ItemStorage_DrawItemQuantity(itemSlot->quantity, STR_CONV_MODE_RIGHT_ALIGN, var, 3, var2);
}
-void sub_813AB90(struct ItemSlot *itemSlot, u8 var, int var2)
+static void ItemStorage_DrawKeyItemEntry(struct ItemSlot *itemSlot, u8 var, int var2)
{
- sub_813AB28(itemSlot, var, var2);
- sub_813AB10(var);
+ ItemStorage_DrawItemName(itemSlot, var, var2);
+ ItemStorage_DrawItemVoidQuantity(var);
}
-void sub_813ABAC(struct ItemSlot *itemSlot, u8 var, int var2)
+static void ItemStorage_DrawTMHMEntry(struct ItemSlot *itemSlot, u8 var, int var2)
{
- sub_813AB28(itemSlot, var, var2);
+ ItemStorage_DrawItemName(itemSlot, var, var2);
if(itemSlot->itemId < ITEM_HM01)
- sub_813AAC4(itemSlot->quantity, STR_CONV_MODE_RIGHT_ALIGN, var, 3, var2);
+ ItemStorage_DrawItemQuantity(itemSlot->quantity, STR_CONV_MODE_RIGHT_ALIGN, var, 3, var2);
else
- sub_813AB10(var); // key items do not have a quantity.
+ ItemStorage_DrawItemVoidQuantity(var); // HMs do not have a quantity.
}
-void sub_813ABE8(u8 taskId)
+static void ItemStorage_DrawItemList(u8 taskId)
{
- s16 *data = gTasks[taskId].data;
- u16 i;
+ s16 *data = TASK.data;
int tempArg;
- u16 j = 0;
+ u16 i;
+ u16 yCoord = 0;
// r5 is i and is unsigned 16-bit.
- for(i = data[1]; i < data[1] + data[4]; i++)
+ for(i = ITEMS_ABOVE_TOP; i < ITEMS_ABOVE_TOP + NUM_PAGE_ITEMS; i++)
{
- j = (i - data[1]) * 2;
+ yCoord = (i - ITEMS_ABOVE_TOP) * 2;
- if(i != data[2])
+ if(i != NUM_ITEMS)
{
tempArg = 0;
- if(data[9] != 0 && i == data[8])
+ if(SWITCH_MODE_ACTIVE != FALSE && i == SWAP_ITEM_INDEX)
tempArg = 1;
switch(GetPocketByItemId(gSaveBlock1.pcItems[i].itemId) - 1)
{
- case 0:
- case 1:
- case 3:
- sub_813AB64((struct ItemSlot *)&gSaveBlock1.pcItems[i], j + 2, tempArg);
- break;
- case 4:
- sub_813AB90((struct ItemSlot *)&gSaveBlock1.pcItems[i], j + 2, tempArg);
- break;
- case 2:
- sub_813ABAC((struct ItemSlot *)&gSaveBlock1.pcItems[i], j + 2, tempArg);
- break;
+ case 0:
+ case 1:
+ case 3:
+ ItemStorage_DrawNormalItemEntry((struct ItemSlot *)&gSaveBlock1.pcItems[i], yCoord + 2, tempArg);
+ break;
+ case 4:
+ ItemStorage_DrawKeyItemEntry((struct ItemSlot *)&gSaveBlock1.pcItems[i], yCoord + 2, tempArg);
+ break;
+ case 2:
+ ItemStorage_DrawTMHMEntry((struct ItemSlot *)&gSaveBlock1.pcItems[i], yCoord + 2, tempArg);
+ break;
}
}
else
@@ -799,24 +912,460 @@ void sub_813ABE8(u8 taskId)
}
beforeLabel:
- if(i - data[1] < 8)
- MenuFillWindowRectWithBlankTile(16, j + 4, 0x1C, 0x12);
+ if(i - ITEMS_ABOVE_TOP < 8)
+ MenuFillWindowRectWithBlankTile(16, yCoord + 4, 0x1C, 0x12);
- switch(data[1])
+ switch(ITEMS_ABOVE_TOP)
{
default:
CreateVerticalScrollIndicators(0, 0xB8, 8);
break;
weirdCase:
- sub_8072A18(gOtherText_CancelNoTerminator, 0x80, (j + 2) * 8, 0x68, 1);
+ sub_8072A18(gOtherText_CancelNoTerminator, 0x80, (yCoord + 2) * 8, 0x68, 1);
goto beforeLabel;
case 0:
DestroyVerticalScrollIndicator(0);
break;
}
- if(data[1] + data[4] <= data[2])
+ if(ITEMS_ABOVE_TOP + NUM_PAGE_ITEMS <= NUM_ITEMS)
CreateVerticalScrollIndicators(1, 0xB8, 0x98);
else
DestroyVerticalScrollIndicator(1);
}
+
+static void ItemStorage_PrintItemPcResponse(u16 itemId)
+{
+ u8 *string;
+
+ switch(itemId)
+ {
+ case ITEMPC_GO_BACK_TO_PREV:
+ string = (u8 *)gMenuText_GoBackToPrev;
+ break;
+ case ITEMPC_HOW_MANY_TO_WITHDRAW:
+ string = (u8 *)gOtherText_HowManyToWithdraw;
+ break;
+ case ITEMPC_WITHDREW_THING:
+ string = (u8 *)gOtherText_WithdrewThing;
+ break;
+ case ITEMPC_HOW_MANY_TO_TOSS:
+ string = (u8 *)gOtherText_HowManyToToss;
+ break;
+ case ITEMPC_THREW_AWAY_ITEM:
+ string = (u8 *)gOtherText_ThrewAwayItem;
+ break;
+ case ITEMPC_NO_MORE_ROOM:
+ string = (u8 *)gOtherText_NoMoreRoom;
+ break;
+ case ITEMPC_TOO_IMPORTANT:
+ string = (u8 *)gOtherText_TooImportant;
+ break;
+ case ITEMPC_OKAY_TO_THROW_AWAY:
+ string = (u8 *)gOtherText_OkayToThrowAwayPrompt;
+ break;
+ case ITEMPC_SWITCH_WHICH_ITEM:
+ string = (u8 *)gOtherText_SwitchWhichItem;
+ break;
+ default:
+ string = ItemId_GetDescription(itemId);
+ break;
+ }
+
+ sub_8072AB0(string, 8, 0x68, 0x68, 0x30, 1);
+}
+
+static void ItemStorage_DrawBothListAndDescription(u8 taskId)
+{
+ s16 *data = TASK.data;
+ s16 trueIndex = ITEMS_ABOVE_TOP + PAGE_INDEX;
+
+ ItemStorage_DrawItemList(taskId);
+
+ if(SWITCH_MODE_ACTIVE == FALSE)
+ {
+ if(trueIndex == NUM_ITEMS)
+ ItemStorage_PrintItemPcResponse(ITEMPC_GO_BACK_TO_PREV);
+ else
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[trueIndex].itemId);
+ }
+}
+
+static void ItemStorage_GoBackToItemPCMenu(u8 taskId, u8 var)
+{
+ s16 *data = TASK.data;
+
+ sub_80F944C();
+ LoadScrollIndicatorPalette();
+ ItemStorage_LoadPalette();
+ MenuDrawTextWindow(0xF, 0, 0x1D, 0x13);
+ MenuDrawTextWindow(0, 0xC, 0xE, 0x13);
+ MenuDrawTextWindow(0, 0, 0xB, 3);
+ ItemStorage_PrintItemPcResponse(gSaveBlock1.pcItems[0].itemId);
+ MenuPrint(gPCText_ItemPCOptionsText[var].text, 1, 1);
+ ItemStorage_DrawItemList(taskId);
+ InitMenu(0, 0x10, 2, NUM_PAGE_ITEMS, PAGE_INDEX, 0xD);
+}
+
+static void ItemStorage_LoadPalette(void)
+{
+ u16 arr[3];
+
+ memcpy(arr, gUnknown_08406334, sizeof(arr));
+ LoadPalette(&arr[2], 0xDF, 2);
+ LoadPalette(&arr[1], 0xD1, 2);
+ LoadPalette(&arr[0], 0xD8, 2);
+}
+
+static u8 GetMailboxMailCount(void)
+{
+ u8 i, j;
+
+ for(i = 0, j = 6; j < 16; j++)
+ if(gSaveBlock1.mail[j].itemId != 0)
+ i++;
+
+ return i;
+}
+
+static void Mailbox_UpdateMailList(void)
+{
+ struct MailStruct mailBuffer;
+ u8 i, j;
+
+ for (i=6; i<15; i++)
+ {
+ for (j=i+1; j<16; j++)
+ {
+ if (gSaveBlock1.mail[i].itemId == 0)
+ {
+ mailBuffer = gSaveBlock1.mail[i];
+ gSaveBlock1.mail[i] = gSaveBlock1.mail[j];
+ gSaveBlock1.mail[j] = mailBuffer;
+ }
+ }
+ }
+}
+
+// WWHHHHHYYYYYYYY SOMEBODY PLEASE FIX THIS
+static void Mailbox_DrawMailList(u8 taskId) // taskId is unused
+{
+ u16 yCoord = 0;
+ u16 i = gMailboxInfo.itemsAbove;
+ register struct MailboxStruct *tempMailbox asm("r1") = &gMailboxInfo;
+ register struct MailboxStruct *mailbox asm("r6");
+
+ if(i < i + tempMailbox->pageItems)
+ {
+ mailbox = tempMailbox;
+ goto forJump;
+ for(; i < mailbox->itemsAbove + mailbox->pageItems; i++)
+ {
+ forJump:
+ yCoord = (i - mailbox->itemsAbove) * 2;
+ MenuFillWindowRectWithBlankTile(0x15, yCoord + 2, 0x1C, yCoord + 3);
+
+ if(i != mailbox->count)
+ {
+ StringCopy(gStringVar1, (u8 *)gSaveBlock1.mail[i + 6].playerName);
+ SanitizeNameString(gStringVar1);
+ MenuPrint(gStringVar1, 0x15, yCoord + 2);
+ }
+ else
+ {
+ goto weirdCase; // again, what???
+ }
+ }
+ }
+
+beforeLabel:
+ if(i - gMailboxInfo.itemsAbove != 8)
+ MenuFillWindowRectWithBlankTile(0x15, yCoord + 4, 0x1C, 0x12);
+
+ switch(gMailboxInfo.itemsAbove)
+ {
+ default:
+ CreateVerticalScrollIndicators(0, 0xC8, 8);
+ break;
+weirdCase:
+ MenuPrint(gOtherText_CancelNoTerminator, 0x15, yCoord + 2);
+ goto beforeLabel;
+ case 0:
+ DestroyVerticalScrollIndicator(0);
+ break;
+ }
+
+ if(gMailboxInfo.itemsAbove + gMailboxInfo.pageItems <= gMailboxInfo.count)
+ CreateVerticalScrollIndicators(1, 0xC8, 0x98);
+ else
+ DestroyVerticalScrollIndicator(1);
+}
+
+static void Mailbox_DrawMailboxMenu(u8 taskId)
+{
+ sub_80F944C();
+ LoadScrollIndicatorPalette();
+ MenuZeroFillWindowRect(0, 0, 0x1D, 0x13);
+ MenuDrawTextWindow(0, 0, 0x8, 0x3);
+ MenuPrint(gPCText_Mailbox, 1, 1);
+ MenuDrawTextWindow(0x14, 0, 0x1D, 0x13);
+ Mailbox_DrawMailList(taskId);
+ InitMenu(0, 0x15, 2, gMailboxInfo.pageItems, gMailboxInfo.cursorPos, 8);
+}
+
+// Mailbox_ProcessInput
+static void Mailbox_ProcessInput(u8 taskId)
+{
+ if(!gPaletteFade.active)
+ {
+ if(gMain.newAndRepeatedKeys & DPAD_UP)
+ {
+ if(gMailboxInfo.cursorPos != 0)
+ {
+ PlaySE(SE_SELECT);
+ gMailboxInfo.cursorPos = MoveMenuCursor(-1);
+ }
+ else if(gMailboxInfo.itemsAbove != 0)
+ {
+ PlaySE(SE_SELECT);
+ gMailboxInfo.itemsAbove--;
+ Mailbox_DrawMailList(taskId);
+ }
+ }
+ else if(gMain.newAndRepeatedKeys & DPAD_DOWN)
+ {
+ if(gMailboxInfo.cursorPos != gMailboxInfo.pageItems - 1)
+ {
+ PlaySE(SE_SELECT);
+ gMailboxInfo.cursorPos = MoveMenuCursor(1);
+ }
+ else if(gMailboxInfo.itemsAbove + gMailboxInfo.cursorPos != gMailboxInfo.count)
+ {
+ PlaySE(SE_SELECT);
+ gMailboxInfo.itemsAbove++;
+ Mailbox_DrawMailList(taskId);
+ }
+ }
+ else if(gMain.newKeys & A_BUTTON)
+ {
+ HandleDestroyMenuCursors();
+ PlaySE(SE_SELECT);
+
+ if(gMailboxInfo.itemsAbove + gMailboxInfo.cursorPos == gMailboxInfo.count)
+ {
+ Mailbox_TurnOff(taskId);
+ }
+ else
+ {
+ Mailbox_CloseScrollIndicators();
+ TASK.FUNC = Mailbox_PrintWhatToDoWithPlayerMailText;
+ }
+ }
+ else if(gMain.newKeys & B_BUTTON)
+ {
+ HandleDestroyMenuCursors();
+ PlaySE(SE_SELECT);
+ Mailbox_TurnOff(taskId);
+ }
+ }
+}
+
+static void Mailbox_CloseScrollIndicators(void)
+{
+ BuyMenuFreeMemory();
+ DestroyVerticalScrollIndicator(0);
+ DestroyVerticalScrollIndicator(1);
+}
+
+static void Mailbox_PrintWhatToDoWithPlayerMailText(u8 taskId)
+{
+ MenuZeroFillWindowRect(0, 0, 0x1D, 0x13);
+ StringCopy(gStringVar1, gSaveBlock1.mail[gMailboxInfo.itemsAbove + 6 + gMailboxInfo.cursorPos].playerName);
+ SanitizeNameString(gStringVar1);
+ StringExpandPlaceholders(gStringVar4, gOtherText_WhatWillYouDoMail);
+ DisplayItemMessageOnField(taskId, gStringVar4, Mailbox_PrintMailOptions, 0);
+}
+
+static void Mailbox_ReturnToPlayerPC(u8 taskId)
+{
+ MenuZeroFillWindowRect(0, 0, 0x1D, 0x13);
+ ReshowPlayerPC(taskId);
+}
+
+static void Mailbox_TurnOff(u8 taskId)
+{
+ Mailbox_CloseScrollIndicators();
+ TASK.FUNC = Mailbox_ReturnToPlayerPC;
+}
+
+static void Mailbox_PrintMailOptions(u8 taskId) // Mailbox_PrintMailOptions
+{
+ MenuDrawTextWindow(0, 0, 0xC, 0x9);
+ PrintMenuItems(1, 1, 4, (struct MenuAction *)gMailboxMailOptions);
+ InitMenu(0, 1, 1, 4, 0, 0xB);
+ TASK.FUNC = Mailbox_MailOptionsProcessInput;
+}
+
+static void Mailbox_MailOptionsProcessInput(u8 taskId)
+{
+ if(gMain.newAndRepeatedKeys & DPAD_UP)
+ {
+ PlaySE(SE_SELECT);
+ MoveMenuCursor(-1);
+ }
+ else if(gMain.newAndRepeatedKeys & DPAD_DOWN)
+ {
+ PlaySE(SE_SELECT);
+ MoveMenuCursor(1);
+ }
+ else if(gMain.newKeys & A_BUTTON)
+ {
+ PlaySE(SE_SELECT);
+ gMailboxMailOptions[GetMenuCursorPos()].func(taskId);
+ }
+ else if(gMain.newKeys & B_BUTTON)
+ {
+ PlaySE(SE_SELECT);
+ Mailbox_Cancel(taskId);
+ }
+}
+
+static void Mailbox_DoMailRead(u8 taskId)
+{
+ fade_screen(1, 0);
+ TASK.FUNC = Mailbox_FadeAndReadMail;
+}
+
+static void Mailbox_FadeAndReadMail(u8 taskId)
+{
+ if(!gPaletteFade.active)
+ {
+ HandleReadMail(&gSaveBlock1.mail[gMailboxInfo.itemsAbove + 6 + gMailboxInfo.cursorPos], Mailbox_ReturnToFieldFromReadMail, 1);
+ DestroyTask(taskId);
+ }
+}
+
+static void Mailbox_HandleReturnToProcessInput(u8 taskId) // Mailbox_HandleReturnToProcessInput
+{
+ if(sub_807D770() == TRUE) // is black fade finished? why not gPaletteFade.active?
+ TASK.FUNC = Mailbox_ProcessInput;
+}
+
+static void Mailbox_DoRedrawMailboxMenuAfterReturn(void)
+{
+ Mailbox_DrawMailboxMenu(CreateTask(Mailbox_HandleReturnToProcessInput, 0));
+ pal_fill_black();
+}
+
+static void Mailbox_ReturnToFieldFromReadMail(void)
+{
+ gFieldCallback = Mailbox_DoRedrawMailboxMenuAfterReturn;
+ SetMainCallback2(c2_exit_to_overworld_2_switch);
+}
+
+static void Mailbox_MoveToBag(u8 taskId)
+{
+ HandleDestroyMenuCursors();
+ StringCopy(gStringVar1, gOtherText_MoveToBag);
+ MenuPrint(gHighlightedMoveToBagFormatText, 1, 3); // gHighlightedMoveToBagFormatText
+ DisplayItemMessageOnField(taskId, gOtherText_MessageWillBeLost, Mailbox_DrawYesNoBeforeMove, 0);
+}
+
+static void Mailbox_DrawYesNoBeforeMove(u8 taskId)
+{
+ DisplayYesNoMenu(0x14, 0x8, 0x1);
+ DoYesNoFuncWithChoice(taskId, (struct YesNoFuncTable *)&ResumeFromWithdrawYesNoFuncList);
+}
+
+static void Mailbox_DoMailMoveToBag(u8 taskId)
+{
+ struct MailStruct *mail = &gSaveBlock1.mail[gMailboxInfo.itemsAbove + 6 + gMailboxInfo.cursorPos];
+
+ MenuZeroFillWindowRect(0x14, 8, 0x1A, 0xD);
+
+ if(AddBagItem(mail->itemId, 1) == FALSE)
+ {
+ DisplayItemMessageOnField(taskId, gOtherText_BagIsFull, Mailbox_DrawMailMenuAndDoProcessInput, 0);
+ }
+ else
+ {
+ DisplayItemMessageOnField(taskId, gOtherText_MailWasReturned, Mailbox_DrawMailMenuAndDoProcessInput, 0);
+ ClearMailStruct(mail);
+ Mailbox_UpdateMailList();
+
+ gMailboxInfo.count--;
+
+ if(gMailboxInfo.count < gMailboxInfo.pageItems + gMailboxInfo.itemsAbove && gMailboxInfo.itemsAbove != 0)
+ gMailboxInfo.itemsAbove--;
+
+ ItemStorage_SetItemAndMailCount(taskId);
+ }
+}
+
+static void Mailbox_ReturnToInputAfterNo(u8 taskId) // Mailbox_ReturnToInputAfterNo
+{
+ MenuZeroFillWindowRect(0x14, 0x8, 0x1A, 0xD);
+ Mailbox_DrawMailMenuAndDoProcessInput(taskId);
+}
+
+static void Mailbox_Give(u8 taskId)
+{
+ if(CalculatePlayerPartyCount() == 0)
+ Mailbox_NoPokemonForMail(taskId); // cannot be reached normally
+ else
+ {
+ fade_screen(1, 0);
+ TASK.FUNC = Mailbox_DoGiveMailPokeMenu;
+ }
+}
+
+static void Mailbox_DoGiveMailPokeMenu(u8 taskId) // Mailbox_DoGiveMailPokeMenu
+{
+ if(!gPaletteFade.active)
+ {
+ SetMainCallback2(sub_808B020);
+ gUnknown_02038561 = 3;
+ DestroyTask(taskId);
+ }
+}
+
+static void Mailbox_UpdateMailListAfterDeposit(void)
+{
+ u8 taskId = CreateTask(Mailbox_HandleReturnToProcessInput, 0);
+ u8 oldCount = gMailboxInfo.count;
+
+ gMailboxInfo.count = GetMailboxMailCount();
+ Mailbox_UpdateMailList();
+
+ if(oldCount != gMailboxInfo.count && gMailboxInfo.count < gMailboxInfo.pageItems + gMailboxInfo.itemsAbove && gMailboxInfo.itemsAbove != 0) // did the count update?
+ gMailboxInfo.itemsAbove--;
+
+ ItemStorage_SetItemAndMailCount(taskId);
+ Mailbox_DrawMailboxMenu(taskId);
+ pal_fill_black();
+}
+
+void Mailbox_ReturnToMailListAfterDeposit(void)
+{
+ gFieldCallback = Mailbox_UpdateMailListAfterDeposit;
+ SetMainCallback2(c2_exit_to_overworld_2_switch);
+}
+
+// you always have at least 1 POKeMON and you cannot receive mail before you leave Littleroot: therefore this function cannot be reached normally.
+static void Mailbox_NoPokemonForMail(u8 taskId)
+{
+ DisplayItemMessageOnField(taskId, gOtherText_NoPokemon, Mailbox_DrawMailMenuAndDoProcessInput, 0);
+}
+
+static void Mailbox_Cancel(u8 taskId)
+{
+ HandleDestroyMenuCursors();
+ MenuZeroFillWindowRect(0, 0, 0xC, 0x9);
+ Mailbox_DrawMailMenuAndDoProcessInput(taskId);
+}
+
+static void Mailbox_DrawMailMenuAndDoProcessInput(u8 taskId)
+{
+ Mailbox_DrawMailboxMenu(taskId);
+ TASK.FUNC = Mailbox_ProcessInput;
+}
diff --git a/src/pokedex.c b/src/pokedex.c
index 97bac3390..8674c3d2b 100644
--- a/src/pokedex.c
+++ b/src/pokedex.c
@@ -1,29 +1,84 @@
+
#include "global.h"
#include "gba/m4a_internal.h"
#include "pokedex.h"
-#include "asm.h"
+#include "battle.h"
+#include "data2.h"
#include "decompress.h"
#include "event_data.h"
+#include "graphics.h"
#include "m4a.h"
#include "main.h"
#include "menu.h"
+#include "menu_cursor.h"
#include "palette.h"
+#include "pokedex_area_screen.h"
+#include "pokedex_cry_screen.h"
+#include "pokemon.h"
#include "rng.h"
+#include "rom4.h"
#include "songs.h"
#include "sound.h"
+#include "species.h"
#include "string_util.h"
#include "strings.h"
#include "task.h"
#include "trig.h"
+#include "unknown_task.h"
+
+#define NATIONAL_DEX_COUNT 386
+
+struct PokedexListItem
+{
+ u16 dexNum;
+ u16 seen:1;
+ u16 owned:1;
+};
-// I'm #define-ing these just for now so I can keep using the old unkXXX member names
-#define unk60E selectedPokemon
-#define unk612 dexMode
-#define unk616 dexOrder
-#define unk64D selectedScreen
-#define unk650 menuIsOpen
-#define unk652 menuCursorPos
-#define unk654 menuY
+struct PokedexView
+{
+ struct PokedexListItem unk0[NATIONAL_DEX_COUNT];
+ u16 unk608;
+ u8 unk60A_1:1;
+ u8 unk60A_2:1;
+ u8 unk60B;
+ u16 pokemonListCount;
+ u16 selectedPokemon;
+ u16 unk610;
+ u16 dexMode;
+ u16 unk614;
+ u16 dexOrder;
+ u16 unk618;
+ u16 unk61A;
+ u16 unk61C;
+ u16 unk61E[4];
+ u16 selectedMonSpriteId;
+ u16 unk628;
+ u16 unk62A;
+ u8 unk62C;
+ u8 unk62D;
+ u8 unk62E;
+ u8 unk62F;
+ s16 unk630;
+ s16 unk632;
+ u16 unk634;
+ u16 unk636;
+ u16 unk638;
+ u16 unk63A[4];
+ u8 filler642[8];
+ u8 unk64A;
+ u8 unk64B;
+ u8 unk64C_1:1;
+ u8 selectedScreen;
+ u8 descriptionPageNum;
+ u8 unk64F;
+ u8 menuIsOpen; //menuIsOpen
+ u8 unk651;
+ u16 menuCursorPos; //Menu cursor position
+ s16 menuY; //Menu Y position (inverted because we use REG_BG0VOFS for this)
+ u8 unk656[8];
+ u8 unk65E[8];
+};
enum
{
@@ -44,8 +99,8 @@ struct PokedexEntry
/*0x00*/ u8 categoryName[12];
/*0x0C*/ u16 height; //in decimeters
/*0x0E*/ u16 weight; //in hectograms
- /*0x10*/ u8 *descriptionPage1;
- /*0x14*/ u8 *descriptionPage2;
+ /*0x10*/ const u8 *descriptionPage1;
+ /*0x14*/ const u8 *descriptionPage2;
/*0x18*/ u16 unused;
/*0x1A*/ u16 pokemonScale;
/*0x1C*/ u16 pokemonOffset;
@@ -53,61 +108,1188 @@ struct PokedexEntry
/*0x20*/ u16 trainerOffset;
}; /*size = 0x24*/
+struct UnknownStruct2
+{
+ const u8 *text1;
+ const u8 *text2;
+};
+
+struct UnknownStruct1
+{
+ const struct UnknownStruct2 *unk0;
+ u8 unk4;
+ u8 unk5;
+ u16 unk6;
+};
+
+struct UnknownStruct3
+{
+ const u8 *text;
+ u8 unk4;
+ u8 unk5;
+ u8 unk6;
+};
+
+struct UnknownStruct4
+{
+ const u8 *text;
+ u8 unk4;
+ u8 unk5;
+ u8 unk6;
+ u8 unk7;
+ u8 unk8;
+ u8 unk9;
+};
+
extern struct MusicPlayerInfo gMPlay_BGM;
extern u8 gReservedSpritePaletteCount;
extern struct PokedexView *gPokedexView;
+extern struct SpriteTemplate gUnknown_02024E8C;
extern u16 gUnknown_0202FFB8;
extern u8 gUnknown_0202FFBA;
-extern u8 gUnknown_03005CE8;
-extern u8 gPokedexMenu_Gfx[];
-extern u8 gUnknown_08E96738[];
-extern u8 gUnknown_08E9C6DC[];
-extern u8 gUnknown_08E96888[];
-extern u8 gUnknown_08E96994[];
-extern struct SpriteSheet gUnknown_083A05CC;
-extern struct SpritePalette gUnknown_083A05DC[];
-extern u8 gUnknown_0839FA7C[];
-extern u8 gUnknown_0839F67C[];
-extern u8 gPokedexMenu_Pal[];
-extern u8 gUnknown_0839F73C[];
-extern u8 gUnknown_083A05EC[];
-extern u8 gUnknown_083A05F1[];
-extern struct SpriteTemplate gSpriteTemplate_83A053C;
-extern struct SpriteTemplate gSpriteTemplate_83A0524;
-extern struct SpriteTemplate gSpriteTemplate_83A0554;
-extern struct SpriteTemplate gSpriteTemplate_83A056C;
-extern struct SpriteTemplate gSpriteTemplate_83A0584;
-extern struct SpriteTemplate gSpriteTemplate_83A059C;
-extern struct SpriteTemplate gSpriteTemplate_83A05B4;
extern struct PokedexListItem *gUnknown_0202FFBC;
+extern u8 gUnknown_03005CE8;
extern IntrCallback gUnknown_03005CEC;
-extern u8 gUnknown_08E96BD4[];
-extern u8 gUnknown_083A05F8[];
-extern u8 gUnknown_0839F8A0[];
-extern u8 gUnknown_0839F988[];
extern u8 gUnknown_03005E98;
-extern u8 gUnknown_083B4EC4[];
-extern u8 gUnknown_08E96ACC[];
-extern u8 gUnknown_08E96B58[];
-
-extern struct PokedexEntry gPokedexEntries[];
-
-extern void m4aMPlayVolumeControl(struct MusicPlayerInfo *mplayInfo, u16 trackBits, u16 volume);
-extern bool8 BeginNormalPaletteFade(u32, s8, u8, u8, u16);
-extern void remove_some_task(void);
-extern u8 sub_8091E3C(void);
-extern void DisableNationalPokedex(void);
-extern void sub_805469C(void);
-extern u16 HoennToNationalOrder(u16);
-extern u16 NationalToHoennOrder(u16);
-extern u16 gPokedexOrder_Alphabetical[];
-extern u16 gPokedexOrder_Weight[];
-extern u16 gPokedexOrder_Height[];
-
-u16 NationalPokedexNumToSpecies(u16);
+extern const u8 gPokedexMenu_Gfx[];
+extern const u8 gUnknown_08E96738[];
+extern const u8 gUnknown_08E96888[];
+extern const u8 gUnknown_08E96994[];
+extern const u8 gUnknown_08E9C6DC[];
+extern const u8 gUnknown_08D00524[];
+extern const u8 gUnknown_08E96BD4[];
+extern const u8 gUnknown_08E96ACC[];
+extern const u8 gUnknown_08E96B58[];
+extern const u16 gPokedexMenu_Pal[];
+extern const u16 gPokedexMenu2_Pal[];
+extern const struct SpriteSheet gTrainerFrontPicTable[];
+extern const struct MonCoords gTrainerFrontPicCoords[];
+extern const struct PokedexEntry gPokedexEntries[];
+extern const u8 gPokedexMenuSearch_Gfx[];
+extern const u8 gUnknown_08E96D2C[];
+extern const u16 gPokedexMenuSearch_Pal[];
+extern const u8 gTypeNames[][7];
+extern const u8 gPokedexMenu2_Gfx[];
+
+static u8 sub_8091E3C(void);
+
+static const u16 sPokedexSearchPalette[] = INCBIN_U16("graphics/pokedex/search.gbapal");
+static const u16 sNationalPokedexPalette[] = INCBIN_U16("graphics/pokedex/national.gbapal");
+const u8 gEmptySpacce_839F7FC[0xA4] = {0};
+static const u8 gUnknown_0839F8A0[] = INCBIN_U8("graphics/pokedex/pokedex_cry_layout.bin.lz");
+static const u8 gUnknown_0839F988[] = INCBIN_U8("graphics/pokedex/pokedex_size_layout.bin.lz");
+static const u8 gUnknown_0839FA7C[] = INCBIN_U8("graphics/pokedex/noball.4bpp.lz");
+#include "data/pokedex_orders.h"
+static const struct OamData gOamData_83A0404 =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 0,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 0,
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const struct OamData gOamData_83A040C =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 1,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 0,
+ .tileNum = 0,
+ .priority = 0,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const struct OamData gOamData_83A0414 =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 1,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 3,
+ .tileNum = 0,
+ .priority = 0,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const struct OamData gOamData_83A041C =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 2,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 0,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 2,
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const struct OamData gOamData_83A0424 =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 1,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 3,
+ .tileNum = 0,
+ .priority = 0,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const struct OamData gOamData_83A042C =
+{
+ .y = 160,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 2,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 0,
+ .tileNum = 0,
+ .priority = 0,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static const union AnimCmd gSpriteAnim_83A0434[] =
+{
+ ANIMCMD_FRAME(3, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A043C[] =
+{
+ ANIMCMD_FRAME(1, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0444[] =
+{
+ ANIMCMD_FRAME(16, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A044C[] =
+{
+ ANIMCMD_FRAME(32, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0454[] =
+{
+ ANIMCMD_FRAME(64, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A045C[] =
+{
+ ANIMCMD_FRAME(96, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0464[] =
+{
+ ANIMCMD_FRAME(128, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A046C[] =
+{
+ ANIMCMD_FRAME(160, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0474[] =
+{
+ ANIMCMD_FRAME(192, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A047C[] =
+{
+ ANIMCMD_FRAME(224, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0484[] =
+{
+ ANIMCMD_FRAME(226, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A048C[] =
+{
+ ANIMCMD_FRAME(228, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A0494[] =
+{
+ ANIMCMD_FRAME(230, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A049C[] =
+{
+ ANIMCMD_FRAME(232, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04A4[] =
+{
+ ANIMCMD_FRAME(234, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04AC[] =
+{
+ ANIMCMD_FRAME(236, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04B4[] =
+{
+ ANIMCMD_FRAME(238, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04BC[] =
+{
+ ANIMCMD_FRAME(240, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04C4[] =
+{
+ ANIMCMD_FRAME(242, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd gSpriteAnim_83A04CC[] =
+{
+ ANIMCMD_FRAME(4, 30),
+ ANIMCMD_END,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04D4[] =
+{
+ gSpriteAnim_83A0434,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04D8[] =
+{
+ gSpriteAnim_83A043C,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04DC[] =
+{
+ gSpriteAnim_83A0444,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04E0[] =
+{
+ gSpriteAnim_83A044C,
+ gSpriteAnim_83A0454,
+ gSpriteAnim_83A045C,
+ gSpriteAnim_83A0464,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04F0[] =
+{
+ gSpriteAnim_83A046C,
+ gSpriteAnim_83A0474,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A04F8[] =
+{
+ gSpriteAnim_83A047C,
+ gSpriteAnim_83A0484,
+ gSpriteAnim_83A048C,
+ gSpriteAnim_83A0494,
+ gSpriteAnim_83A049C,
+ gSpriteAnim_83A04A4,
+ gSpriteAnim_83A04AC,
+ gSpriteAnim_83A04B4,
+ gSpriteAnim_83A04BC,
+ gSpriteAnim_83A04C4,
+};
+static const union AnimCmd *const gSpriteAnimTable_83A0520[] =
+{
+ gSpriteAnim_83A04CC,
+};
+static void sub_808EF38(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A0524 =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A0404,
+ .anims = gSpriteAnimTable_83A04D4,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808EF38,
+};
+static void sub_808EF8C(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A053C =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A040C,
+ .anims = gSpriteAnimTable_83A04D8,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808EF8C,
+};
+static void sub_808F08C(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A0554 =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A0414,
+ .anims = gSpriteAnimTable_83A04E0,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808F08C,
+};
+static void sub_808F0B4(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A056C =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A041C,
+ .anims = gSpriteAnimTable_83A04DC,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808F0B4,
+};
+static void sub_808ED94(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A0584 =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A0424,
+ .anims = gSpriteAnimTable_83A04F0,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808ED94,
+};
+static const struct SpriteTemplate gSpriteTemplate_83A059C =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A042C,
+ .anims = gSpriteAnimTable_83A04F8,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808ED94,
+};
+static void sub_808F168(struct Sprite *);
+static const struct SpriteTemplate gSpriteTemplate_83A05B4 =
+{
+ .tileTag = 4096,
+ .paletteTag = 4096,
+ .oam = &gOamData_83A042C,
+ .anims = gSpriteAnimTable_83A0520,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_808F168,
+};
+static const struct SpriteSheet gUnknown_083A05CC[] =
+{
+ {gPokedexMenu2_Gfx, 0x1F00, 0x1000},
+ {NULL, 0, 0},
+};
+static const struct SpritePalette gUnknown_083A05DC[] =
+{
+ {gPokedexMenu_Pal, 0x1000},
+ {NULL, 0},
+};
+static const u8 gUnknown_083A05EC[] = {2, 4, 8, 16, 32};
+static const u8 gUnknown_083A05F1[] = {16, 8, 4, 2, 1};
+const u8 gEmptySpacce_83A05F6[] = {0, 0}; // Padding, maybe?
+static const u8 gUnknown_083A05F8[] = _("");
+// TODO: include German entries
+#include "data/pokedex_entries_en.h"
+static const u16 gUnknown_083B4EC4[16] = {0};
+static const u8 *const sMonFootprintTable[] =
+{
+ gMonFootprint_Bulbasaur,
+ gMonFootprint_Bulbasaur,
+ gMonFootprint_Ivysaur,
+ gMonFootprint_Venusaur,
+ gMonFootprint_Charmander,
+ gMonFootprint_Charmeleon,
+ gMonFootprint_Charizard,
+ gMonFootprint_Squirtle,
+ gMonFootprint_Wartortle,
+ gMonFootprint_Blastoise,
+ gMonFootprint_Caterpie,
+ gMonFootprint_Metapod,
+ gMonFootprint_Butterfree,
+ gMonFootprint_Weedle,
+ gMonFootprint_Kakuna,
+ gMonFootprint_Beedrill,
+ gMonFootprint_Pidgey,
+ gMonFootprint_Pidgeotto,
+ gMonFootprint_Pidgeot,
+ gMonFootprint_Rattata,
+ gMonFootprint_Raticate,
+ gMonFootprint_Spearow,
+ gMonFootprint_Fearow,
+ gMonFootprint_Ekans,
+ gMonFootprint_Arbok,
+ gMonFootprint_Pikachu,
+ gMonFootprint_Raichu,
+ gMonFootprint_Sandshrew,
+ gMonFootprint_Sandslash,
+ gMonFootprint_NidoranF,
+ gMonFootprint_Nidorina,
+ gMonFootprint_Nidoqueen,
+ gMonFootprint_NidoranM,
+ gMonFootprint_Nidorino,
+ gMonFootprint_Nidoking,
+ gMonFootprint_Clefairy,
+ gMonFootprint_Clefable,
+ gMonFootprint_Vulpix,
+ gMonFootprint_Ninetales,
+ gMonFootprint_Jigglypuff,
+ gMonFootprint_Wigglytuff,
+ gMonFootprint_Zubat,
+ gMonFootprint_Golbat,
+ gMonFootprint_Oddish,
+ gMonFootprint_Gloom,
+ gMonFootprint_Vileplume,
+ gMonFootprint_Paras,
+ gMonFootprint_Parasect,
+ gMonFootprint_Venonat,
+ gMonFootprint_Venomoth,
+ gMonFootprint_Diglett,
+ gMonFootprint_Dugtrio,
+ gMonFootprint_Meowth,
+ gMonFootprint_Persian,
+ gMonFootprint_Psyduck,
+ gMonFootprint_Golduck,
+ gMonFootprint_Mankey,
+ gMonFootprint_Primeape,
+ gMonFootprint_Growlithe,
+ gMonFootprint_Arcanine,
+ gMonFootprint_Poliwag,
+ gMonFootprint_Poliwhirl,
+ gMonFootprint_Poliwrath,
+ gMonFootprint_Abra,
+ gMonFootprint_Kadabra,
+ gMonFootprint_Alakazam,
+ gMonFootprint_Machop,
+ gMonFootprint_Machoke,
+ gMonFootprint_Machamp,
+ gMonFootprint_Bellsprout,
+ gMonFootprint_Weepinbell,
+ gMonFootprint_Victreebel,
+ gMonFootprint_Tentacool,
+ gMonFootprint_Tentacruel,
+ gMonFootprint_Geodude,
+ gMonFootprint_Graveler,
+ gMonFootprint_Golem,
+ gMonFootprint_Ponyta,
+ gMonFootprint_Rapidash,
+ gMonFootprint_Slowpoke,
+ gMonFootprint_Slowbro,
+ gMonFootprint_Magnemite,
+ gMonFootprint_Magneton,
+ gMonFootprint_Farfetchd,
+ gMonFootprint_Doduo,
+ gMonFootprint_Dodrio,
+ gMonFootprint_Seel,
+ gMonFootprint_Dewgong,
+ gMonFootprint_Grimer,
+ gMonFootprint_Muk,
+ gMonFootprint_Shellder,
+ gMonFootprint_Cloyster,
+ gMonFootprint_Gastly,
+ gMonFootprint_Haunter,
+ gMonFootprint_Gengar,
+ gMonFootprint_Onix,
+ gMonFootprint_Drowzee,
+ gMonFootprint_Hypno,
+ gMonFootprint_Krabby,
+ gMonFootprint_Kingler,
+ gMonFootprint_Voltorb,
+ gMonFootprint_Electrode,
+ gMonFootprint_Exeggcute,
+ gMonFootprint_Exeggutor,
+ gMonFootprint_Cubone,
+ gMonFootprint_Marowak,
+ gMonFootprint_Hitmonlee,
+ gMonFootprint_Hitmonchan,
+ gMonFootprint_Lickitung,
+ gMonFootprint_Koffing,
+ gMonFootprint_Weezing,
+ gMonFootprint_Rhyhorn,
+ gMonFootprint_Rhydon,
+ gMonFootprint_Chansey,
+ gMonFootprint_Tangela,
+ gMonFootprint_Kangaskhan,
+ gMonFootprint_Horsea,
+ gMonFootprint_Seadra,
+ gMonFootprint_Goldeen,
+ gMonFootprint_Seaking,
+ gMonFootprint_Staryu,
+ gMonFootprint_Starmie,
+ gMonFootprint_Mrmime,
+ gMonFootprint_Scyther,
+ gMonFootprint_Jynx,
+ gMonFootprint_Electabuzz,
+ gMonFootprint_Magmar,
+ gMonFootprint_Pinsir,
+ gMonFootprint_Tauros,
+ gMonFootprint_Magikarp,
+ gMonFootprint_Gyarados,
+ gMonFootprint_Lapras,
+ gMonFootprint_Ditto,
+ gMonFootprint_Eevee,
+ gMonFootprint_Vaporeon,
+ gMonFootprint_Jolteon,
+ gMonFootprint_Flareon,
+ gMonFootprint_Porygon,
+ gMonFootprint_Omanyte,
+ gMonFootprint_Omastar,
+ gMonFootprint_Kabuto,
+ gMonFootprint_Kabutops,
+ gMonFootprint_Aerodactyl,
+ gMonFootprint_Snorlax,
+ gMonFootprint_Articuno,
+ gMonFootprint_Zapdos,
+ gMonFootprint_Moltres,
+ gMonFootprint_Dratini,
+ gMonFootprint_Dragonair,
+ gMonFootprint_Dragonite,
+ gMonFootprint_Mewtwo,
+ gMonFootprint_Mew,
+ gMonFootprint_Chikorita,
+ gMonFootprint_Bayleef,
+ gMonFootprint_Meganium,
+ gMonFootprint_Cyndaquil,
+ gMonFootprint_Quilava,
+ gMonFootprint_Typhlosion,
+ gMonFootprint_Totodile,
+ gMonFootprint_Croconaw,
+ gMonFootprint_Feraligatr,
+ gMonFootprint_Sentret,
+ gMonFootprint_Furret,
+ gMonFootprint_Hoothoot,
+ gMonFootprint_Noctowl,
+ gMonFootprint_Ledyba,
+ gMonFootprint_Ledian,
+ gMonFootprint_Spinarak,
+ gMonFootprint_Ariados,
+ gMonFootprint_Crobat,
+ gMonFootprint_Chinchou,
+ gMonFootprint_Lanturn,
+ gMonFootprint_Pichu,
+ gMonFootprint_Cleffa,
+ gMonFootprint_Igglybuff,
+ gMonFootprint_Togepi,
+ gMonFootprint_Togetic,
+ gMonFootprint_Natu,
+ gMonFootprint_Xatu,
+ gMonFootprint_Mareep,
+ gMonFootprint_Flaaffy,
+ gMonFootprint_Ampharos,
+ gMonFootprint_Bellossom,
+ gMonFootprint_Marill,
+ gMonFootprint_Azumarill,
+ gMonFootprint_Sudowoodo,
+ gMonFootprint_Politoed,
+ gMonFootprint_Hoppip,
+ gMonFootprint_Skiploom,
+ gMonFootprint_Jumpluff,
+ gMonFootprint_Aipom,
+ gMonFootprint_Sunkern,
+ gMonFootprint_Sunflora,
+ gMonFootprint_Yanma,
+ gMonFootprint_Wooper,
+ gMonFootprint_Quagsire,
+ gMonFootprint_Espeon,
+ gMonFootprint_Umbreon,
+ gMonFootprint_Murkrow,
+ gMonFootprint_Slowking,
+ gMonFootprint_Misdreavus,
+ gMonFootprint_Unown,
+ gMonFootprint_Wobbuffet,
+ gMonFootprint_Girafarig,
+ gMonFootprint_Pineco,
+ gMonFootprint_Forretress,
+ gMonFootprint_Dunsparce,
+ gMonFootprint_Gligar,
+ gMonFootprint_Steelix,
+ gMonFootprint_Snubbull,
+ gMonFootprint_Granbull,
+ gMonFootprint_Qwilfish,
+ gMonFootprint_Scizor,
+ gMonFootprint_Shuckle,
+ gMonFootprint_Heracross,
+ gMonFootprint_Sneasel,
+ gMonFootprint_Teddiursa,
+ gMonFootprint_Ursaring,
+ gMonFootprint_Slugma,
+ gMonFootprint_Magcargo,
+ gMonFootprint_Swinub,
+ gMonFootprint_Piloswine,
+ gMonFootprint_Corsola,
+ gMonFootprint_Remoraid,
+ gMonFootprint_Octillery,
+ gMonFootprint_Delibird,
+ gMonFootprint_Mantine,
+ gMonFootprint_Skarmory,
+ gMonFootprint_Houndour,
+ gMonFootprint_Houndoom,
+ gMonFootprint_Kingdra,
+ gMonFootprint_Phanpy,
+ gMonFootprint_Donphan,
+ gMonFootprint_Porygon2,
+ gMonFootprint_Stantler,
+ gMonFootprint_Smeargle,
+ gMonFootprint_Tyrogue,
+ gMonFootprint_Hitmontop,
+ gMonFootprint_Smoochum,
+ gMonFootprint_Elekid,
+ gMonFootprint_Magby,
+ gMonFootprint_Miltank,
+ gMonFootprint_Blissey,
+ gMonFootprint_Raikou,
+ gMonFootprint_Entei,
+ gMonFootprint_Suicune,
+ gMonFootprint_Larvitar,
+ gMonFootprint_Pupitar,
+ gMonFootprint_Tyranitar,
+ gMonFootprint_Lugia,
+ gMonFootprint_HoOh,
+ gMonFootprint_Celebi,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_QuestionMark,
+ gMonFootprint_Treecko,
+ gMonFootprint_Grovyle,
+ gMonFootprint_Sceptile,
+ gMonFootprint_Torchic,
+ gMonFootprint_Combusken,
+ gMonFootprint_Blaziken,
+ gMonFootprint_Mudkip,
+ gMonFootprint_Marshtomp,
+ gMonFootprint_Swampert,
+ gMonFootprint_Poochyena,
+ gMonFootprint_Mightyena,
+ gMonFootprint_Zigzagoon,
+ gMonFootprint_Linoone,
+ gMonFootprint_Wurmple,
+ gMonFootprint_Silcoon,
+ gMonFootprint_Beautifly,
+ gMonFootprint_Cascoon,
+ gMonFootprint_Dustox,
+ gMonFootprint_Lotad,
+ gMonFootprint_Lombre,
+ gMonFootprint_Ludicolo,
+ gMonFootprint_Seedot,
+ gMonFootprint_Nuzleaf,
+ gMonFootprint_Shiftry,
+ gMonFootprint_Nincada,
+ gMonFootprint_Ninjask,
+ gMonFootprint_Shedinja,
+ gMonFootprint_Taillow,
+ gMonFootprint_Swellow,
+ gMonFootprint_Shroomish,
+ gMonFootprint_Breloom,
+ gMonFootprint_Spinda,
+ gMonFootprint_Wingull,
+ gMonFootprint_Pelipper,
+ gMonFootprint_Surskit,
+ gMonFootprint_Masquerain,
+ gMonFootprint_Wailmer,
+ gMonFootprint_Wailord,
+ gMonFootprint_Skitty,
+ gMonFootprint_Delcatty,
+ gMonFootprint_Kecleon,
+ gMonFootprint_Baltoy,
+ gMonFootprint_Claydol,
+ gMonFootprint_Nosepass,
+ gMonFootprint_Torkoal,
+ gMonFootprint_Sableye,
+ gMonFootprint_Barboach,
+ gMonFootprint_Whiscash,
+ gMonFootprint_Luvdisc,
+ gMonFootprint_Corphish,
+ gMonFootprint_Crawdaunt,
+ gMonFootprint_Feebas,
+ gMonFootprint_Milotic,
+ gMonFootprint_Carvanha,
+ gMonFootprint_Sharpedo,
+ gMonFootprint_Trapinch,
+ gMonFootprint_Vibrava,
+ gMonFootprint_Flygon,
+ gMonFootprint_Makuhita,
+ gMonFootprint_Hariyama,
+ gMonFootprint_Electrike,
+ gMonFootprint_Manectric,
+ gMonFootprint_Numel,
+ gMonFootprint_Camerupt,
+ gMonFootprint_Spheal,
+ gMonFootprint_Sealeo,
+ gMonFootprint_Walrein,
+ gMonFootprint_Cacnea,
+ gMonFootprint_Cacturne,
+ gMonFootprint_Snorunt,
+ gMonFootprint_Glalie,
+ gMonFootprint_Lunatone,
+ gMonFootprint_Solrock,
+ gMonFootprint_Azurill,
+ gMonFootprint_Spoink,
+ gMonFootprint_Grumpig,
+ gMonFootprint_Plusle,
+ gMonFootprint_Minun,
+ gMonFootprint_Mawile,
+ gMonFootprint_Meditite,
+ gMonFootprint_Medicham,
+ gMonFootprint_Swablu,
+ gMonFootprint_Altaria,
+ gMonFootprint_Wynaut,
+ gMonFootprint_Duskull,
+ gMonFootprint_Dusclops,
+ gMonFootprint_Roselia,
+ gMonFootprint_Slakoth,
+ gMonFootprint_Vigoroth,
+ gMonFootprint_Slaking,
+ gMonFootprint_Gulpin,
+ gMonFootprint_Swalot,
+ gMonFootprint_Tropius,
+ gMonFootprint_Whismur,
+ gMonFootprint_Loudred,
+ gMonFootprint_Exploud,
+ gMonFootprint_Clamperl,
+ gMonFootprint_Huntail,
+ gMonFootprint_Gorebyss,
+ gMonFootprint_Absol,
+ gMonFootprint_Shuppet,
+ gMonFootprint_Banette,
+ gMonFootprint_Seviper,
+ gMonFootprint_Zangoose,
+ gMonFootprint_Relicanth,
+ gMonFootprint_Aron,
+ gMonFootprint_Lairon,
+ gMonFootprint_Aggron,
+ gMonFootprint_Castform,
+ gMonFootprint_Volbeat,
+ gMonFootprint_Illumise,
+ gMonFootprint_Lileep,
+ gMonFootprint_Cradily,
+ gMonFootprint_Anorith,
+ gMonFootprint_Armaldo,
+ gMonFootprint_Ralts,
+ gMonFootprint_Kirlia,
+ gMonFootprint_Gardevoir,
+ gMonFootprint_Bagon,
+ gMonFootprint_Shelgon,
+ gMonFootprint_Salamence,
+ gMonFootprint_Beldum,
+ gMonFootprint_Metang,
+ gMonFootprint_Metagross,
+ gMonFootprint_Regirock,
+ gMonFootprint_Regice,
+ gMonFootprint_Registeel,
+ gMonFootprint_Kyogre,
+ gMonFootprint_Groudon,
+ gMonFootprint_Rayquaza,
+ gMonFootprint_Latias,
+ gMonFootprint_Latios,
+ gMonFootprint_Jirachi,
+ gMonFootprint_Deoxys,
+ gMonFootprint_Chimecho,
+ gMonFootprint_Bulbasaur,
+};
+static const u8 gUnknown_083B5558[] = _("{CLEAR_TO 0}");
+const u8 gUnknown_083B555C[] = INCBIN_U8("graphics/unknown/unknown_3B555C.bin");
+static const struct OamData gOamData_83B557C =
+{
+ .y = 0,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = 0,
+ .x = 0,
+ .matrixNum = 0,
+ .size = 3,
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+static void *const gUnknown_083B5584[] =
+{
+ (void *)0x02008000,
+ (void *)0x0200C000,
+ (void *)0x02010000,
+ (void *)0x02014000,
+};
+static const struct SpriteFrameImage gSpriteImageTable_83B5594[] =
+{
+ {(u8 *)0x02008000, 0x800},
+ {(u8 *)0x02008800, 0x800},
+ {(u8 *)0x02009000, 0x800},
+ {(u8 *)0x02009800, 0x800},
+ {(u8 *)0x0200A000, 0x800},
+ {(u8 *)0x0200A800, 0x800},
+ {(u8 *)0x0200B000, 0x800},
+ {(u8 *)0x0200B800, 0x800},
+ {(u8 *)0x0200C000, 0x800},
+ {(u8 *)0x0200C800, 0x800},
+ {(u8 *)0x0200D000, 0x800},
+ {(u8 *)0x0200D800, 0x800},
+ {(u8 *)0x0200E000, 0x800},
+ {(u8 *)0x0200E800, 0x800},
+ {(u8 *)0x0200F000, 0x800},
+ {(u8 *)0x0200F800, 0x800},
+};
+static const struct SpriteFrameImage gSpriteImageTable_83B5614[] =
+{
+ {(u8 *)0x0200C000, 0x800},
+ {(u8 *)0x0200C800, 0x800},
+ {(u8 *)0x0200D000, 0x800},
+ {(u8 *)0x0200D800, 0x800},
+ {(u8 *)0x0200E000, 0x800},
+ {(u8 *)0x0200E800, 0x800},
+ {(u8 *)0x0200F000, 0x800},
+ {(u8 *)0x0200F800, 0x800},
+ {(u8 *)0x02010000, 0x800},
+ {(u8 *)0x02010800, 0x800},
+ {(u8 *)0x02011000, 0x800},
+ {(u8 *)0x02011800, 0x800},
+ {(u8 *)0x02012000, 0x800},
+ {(u8 *)0x02012800, 0x800},
+ {(u8 *)0x02013000, 0x800},
+ {(u8 *)0x02013800, 0x800},
+};
+static const struct SpriteFrameImage gSpriteImageTable_83B5694[] =
+{
+ {(u8 *)0x02010000, 0x800},
+ {(u8 *)0x02010800, 0x800},
+ {(u8 *)0x02011000, 0x800},
+ {(u8 *)0x02011800, 0x800},
+ {(u8 *)0x02012000, 0x800},
+ {(u8 *)0x02012800, 0x800},
+ {(u8 *)0x02013000, 0x800},
+ {(u8 *)0x02013800, 0x800},
+ {(u8 *)0x02014000, 0x800},
+ {(u8 *)0x02014800, 0x800},
+ {(u8 *)0x02015000, 0x800},
+ {(u8 *)0x02015800, 0x800},
+ {(u8 *)0x02016000, 0x800},
+ {(u8 *)0x02016800, 0x800},
+ {(u8 *)0x02017000, 0x800},
+ {(u8 *)0x02017800, 0x800},
+};
+static const struct SpriteFrameImage gSpriteImageTable_83B5714[] =
+{
+ {(u8 *)0x02014000, 0x800},
+ {(u8 *)0x02014800, 0x800},
+ {(u8 *)0x02015000, 0x800},
+ {(u8 *)0x02015800, 0x800},
+ {(u8 *)0x02016000, 0x800},
+ {(u8 *)0x02016800, 0x800},
+ {(u8 *)0x02017000, 0x800},
+ {(u8 *)0x02017800, 0x800},
+ {(u8 *)0x02018000, 0x800},
+ {(u8 *)0x02018800, 0x800},
+ {(u8 *)0x02019000, 0x800},
+ {(u8 *)0x02019800, 0x800},
+ {(u8 *)0x0201A000, 0x800},
+ {(u8 *)0x0201A800, 0x800},
+ {(u8 *)0x0201B000, 0x800},
+ {(u8 *)0x0201B800, 0x800},
+};
+static const struct SpriteFrameImage *const gUnknown_083B5794[] =
+{
+ gSpriteImageTable_83B5594,
+ gSpriteImageTable_83B5614,
+ gSpriteImageTable_83B5694,
+ gSpriteImageTable_83B5714,
+};
+static void nullsub_59(struct Sprite *);
+static const struct SpriteTemplate gUnknown_083B57A4 =
+{
+ .tileTag = 0xFFFF,
+ .paletteTag = 0,
+ .oam = &gOamData_83B557C,
+ .anims = NULL,
+ .images = gSpriteImageTable_83B5594,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = nullsub_59,
+};
+static const u8 gUnknown_083B57BC[][4] =
+{
+ {0, 0, 0, 0},
+ {CHAR_A, 3, CHAR_a, 3},
+ {CHAR_D, 3, CHAR_d, 3},
+ {CHAR_G, 3, CHAR_g, 3},
+ {CHAR_J, 3, CHAR_j, 3},
+ {CHAR_M, 3, CHAR_m, 3},
+ {CHAR_P, 3, CHAR_p, 3},
+ {CHAR_S, 3, CHAR_s, 3},
+ {CHAR_V, 3, CHAR_v, 3},
+ {CHAR_Y, 2, CHAR_y, 2},
+};
+static const struct UnknownStruct3 gUnknown_083B57E4[] =
+{
+ {DexText_SearchForPoke, 0, 0, 5},
+ {DexText_SwitchDex, 6, 0, 5},
+ {DexText_ReturnToDex, 12, 0, 5},
+};
+static const struct UnknownStruct4 gUnknown_083B57FC[] =
+{
+ {DexText_ListByABC, 0, 2, 5, 5, 2, 12},
+ {DexText_ListByColor, 0, 4, 5, 5, 4, 12},
+ {DexText_ListByType, 0, 6, 5, 5, 6, 6},
+ {DexText_ListByType, 0, 6, 5, 11, 6, 6},
+ {DexText_SelectDexList, 0, 8, 5, 5, 8, 12},
+ {DexText_SelectDexMode, 0, 10, 5, 5, 10, 12},
+ {DexText_ExecuteSearchSwitch, 0, 12, 5, 0, 0, 0},
+};
+static const u8 gUnknown_083B5850[][4] =
+{
+ {0xFF, 0xFF, 0xFF, 1},
+ {0xFF, 0xFF, 0, 2},
+ {0xFF, 3, 1, 4},
+ { 2, 0xFF, 1, 4},
+ {0xFF, 0xFF, 2, 5},
+ {0xFF, 0xFF, 4, 6},
+ {0xFF, 0xFF, 5, 0xFF},
+};
+static const u8 gUnknown_083B586C[][4] =
+{
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 5},
+ {0xFF, 0xFF, 4, 6},
+ {0xFF, 0xFF, 5, 0xFF},
+};
+static const u8 gUnknown_083B5888[][4] =
+{
+ {0xFF, 0xFF, 0xFF, 1},
+ {0xFF, 0xFF, 0, 2},
+ {0xFF, 3, 1, 4},
+ { 2, 0xFF, 1, 4},
+ {0xFF, 0xFF, 2, 6},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 4, 0xFF},
+};
+static const u8 gUnknown_083B58A4[][4] =
+{
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 0xFF, 6},
+ {0xFF, 0xFF, 0xFF, 0xFF},
+ {0xFF, 0xFF, 4, 0xFF},
+};
+static const struct UnknownStruct2 gUnknown_083B58C0[] =
+{
+ {DexText_HoennDex2, DexText_HoennDex},
+ {DexText_NationalDex2, DexText_NationalDex},
+ {NULL, NULL},
+};
+static const struct UnknownStruct2 gUnknown_083B58D8[] =
+{
+ {DexText_ListByNumber, DexText_NumericalMode},
+ {DexText_ListByABC2, DexText_ABCMode},
+ {DexText_ListByHeavyToLightest, DexText_HeaviestMode},
+ {DexText_ListByLightToHeaviest, DexText_LightestMode},
+ {DexText_ListByTallToSmallest, DexText_TallestMode},
+ {DexText_ListBySmallToTallest, DexText_SmallestMode},
+ {NULL, NULL},
+};
+static const struct UnknownStruct2 gUnknown_083B5910[] =
+{
+ {DexText_Terminator5, DexText_DontSpecify},
+ {DexText_Terminator5, DexText_ABC},
+ {DexText_Terminator5, DexText_DEF},
+ {DexText_Terminator5, DexText_GHI},
+ {DexText_Terminator5, DexText_JKL},
+ {DexText_Terminator5, DexText_MNO},
+ {DexText_Terminator5, DexText_PQR},
+ {DexText_Terminator5, DexText_STU},
+ {DexText_Terminator5, DexText_VWX},
+ {DexText_Terminator5, DexText_YZ},
+ {NULL, NULL},
+};
+static const struct UnknownStruct2 gUnknown_083B5968[] =
+{
+ {DexText_Terminator5, DexText_DontSpecify},
+ {DexText_Terminator5, DexText_Red},
+ {DexText_Terminator5, DexText_Blue},
+ {DexText_Terminator5, DexText_Yellow},
+ {DexText_Terminator5, DexText_Green},
+ {DexText_Terminator5, DexText_Black},
+ {DexText_Terminator5, DexText_Brown},
+ {DexText_Terminator5, DexText_Purple},
+ {DexText_Terminator5, DexText_Gray},
+ {DexText_Terminator5, DexText_White},
+ {DexText_Terminator5, DexText_Pink},
+ {NULL, NULL},
+};
+static const struct UnknownStruct2 gUnknown_083B59C8[] =
+{
+ {DexText_Terminator5, DexText_None},
+ {DexText_Terminator5, gTypeNames[TYPE_NORMAL]},
+ {DexText_Terminator5, gTypeNames[TYPE_FIGHTING]},
+ {DexText_Terminator5, gTypeNames[TYPE_FLYING]},
+ {DexText_Terminator5, gTypeNames[TYPE_POISON]},
+ {DexText_Terminator5, gTypeNames[TYPE_GROUND]},
+ {DexText_Terminator5, gTypeNames[TYPE_ROCK]},
+ {DexText_Terminator5, gTypeNames[TYPE_BUG]},
+ {DexText_Terminator5, gTypeNames[TYPE_GHOST]},
+ {DexText_Terminator5, gTypeNames[TYPE_STEEL]},
+ {DexText_Terminator5, gTypeNames[TYPE_FIRE]},
+ {DexText_Terminator5, gTypeNames[TYPE_WATER]},
+ {DexText_Terminator5, gTypeNames[TYPE_GRASS]},
+ {DexText_Terminator5, gTypeNames[TYPE_ELECTRIC]},
+ {DexText_Terminator5, gTypeNames[TYPE_PSYCHIC]},
+ {DexText_Terminator5, gTypeNames[TYPE_ICE]},
+ {DexText_Terminator5, gTypeNames[TYPE_DRAGON]},
+ {DexText_Terminator5, gTypeNames[TYPE_DARK]},
+ {NULL, NULL},
+};
+static const u8 gUnknown_083B5A60[] = {0, 1};
+static const u8 gUnknown_083B5A62[] = {0, 1, 2, 3, 4, 5};
+static const u8 gUnknown_083B5A68[] = {0xFF, 0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17};
+static const struct UnknownStruct1 gUnknown_083B5A7C[] =
+{
+ {gUnknown_083B5910, 6, 7, 10},
+ {gUnknown_083B5968, 8, 9, 11},
+ {gUnknown_083B59C8, 10, 11, 18},
+ {gUnknown_083B59C8, 12, 13, 18},
+ {gUnknown_083B58D8, 4, 5, 6},
+ {gUnknown_083B58C0, 2, 3, 2},
+};
+static const u8 gUnknown_083B5AAC[] = _("{STR_VAR_1}{CLEAR_TO 43}");
+static const u8 gUnknown_083B5AB2[] = _("{STR_VAR_1}{CLEAR_TO 96}");
+
+static void MainCB(void);
+static void Task_PokedexShowMainScreen(u8 taskId);
+static void Task_PokedexMainScreen(u8 taskId);
+static void sub_808C898(u8 taskId);
+static void Task_PokedexMainScreenMenu(u8 taskId);
+static void sub_808CA64(u8 taskId);
+static void sub_808CAE4(u8 taskId);
+static void sub_808CB8C(u8 taskId);
+static void Task_ClosePokedex(u8 taskId);
+static void sub_808CCC4(u8 taskId);
+static void Task_PokedexResultsScreen(u8 taskId);
+static void sub_808CEF8(u8 taskId);
+static void Task_PokedexResultsScreenMenu(u8 taskId);
+static void sub_808D118(u8 taskId);
+static void sub_808D198(u8 taskId);
+static void Task_PokedexResultsScreenReturnToMainScreen(u8 taskId);
+static void Task_PokedexResultsScreenExitPokedex(u8 taskId);
+static bool8 sub_808D344(u8 a);
+static void sub_808D640(void);
+static void SortPokedex(u8 dexMode, u8 sortMode);
+static void sub_808DEB0(u16 a, u8 b, u8 c, u16 d);
+static void sub_808DF88(u16 a, u8 b, u8 c, u16 d);
+static u8 sub_808DFE4(u16 num, u8 b, u8 c);
+static void sub_808E090(u8 a, u8 b, u16 c);
+static void sub_808E0CC(u16 a, u16 b);
+static bool8 sub_808E208(u8 a, u8 b, u8 c);
+static u16 sub_808E48C(u16 a, u16 b);
+static void sub_808E6BC(void);
+static u8 sub_808E71C(void);
+static u8 sub_808E82C(void);
+static u16 sub_808E888(u16 a1);
+static u32 sub_808E8C8(u16 a, s16 b, s16 c);
+static void sub_808E978(u8 a);
+static void sub_808EDB8(struct Sprite *sprite);
+static void sub_808EE28(struct Sprite *sprite);
+static u8 sub_808F210(struct PokedexListItem *, u8);
+static bool8 sub_808F250(u8 taskId);
+static u8 sub_808F284(struct PokedexListItem *, u8);
+static void Task_InitPageScreenMultistep(u8 taskId);
+static void Task_PageScreenProcessInput(u8 taskId);
+static void sub_808F888(u8 taskId);
+static void Task_ClosePageScreen(u8 taskId);
+static void Task_InitAreaScreenMultistep(u8 taskId);
+static void Task_AreaScreenProcessInput(u8 taskId);
+static void sub_808FA00(u8 taskId);
+static void Task_InitCryScreenMultistep(u8 taskId);
+static void Task_CryScreenProcessInput(u8 taskId);
+static void sub_808FFBC(u8 taskId);
+static void sub_8090040(u8 a);
+static void Task_InitSizeScreenMultistep(u8 taskId);
+static void Task_SizeScreenProcessInput(u8 taskId);
+static void sub_8090498(u8 taskId);
+static void sub_80904FC(u16 a);
+static void sub_8090540(u16 a);
+static void sub_8090584(u8 a, u16 b);
+static void sub_8090644(u8 a, u16 b);
+static void sub_8090750(u8);
+static void sub_8090A3C(u8);
+static void sub_8090B8C(u8);
+static void sub_8090C28(struct Sprite *);
+static void sub_8090C68(void);
+static void sub_8091060(u16);
+static void sub_8091154(u16 order, u8, u8);
+static u8 sub_80911C8(u16 num, u8, u8);
+static u8 sub_8091260(u16 num, u8, u8, u8);
+static void sub_8091304(const u8 *name, u8, u8);
+static void sub_8091458(u16 height, u8 i, u8 i1);
+static void sub_8091564(u16 weight, u8 i, u8 i1);
+static void sub_8091738(u16, u16, u16);
+static void sub_80917CC(u16 i, u16 i1);
+static u16 sub_8091818(u8, u16, u16, u16);
+static u16 sub_80918EC(u16 a, s16 b, s16 c, u16 d);
+static u8 sub_8091A4C(u16 gender, s16, s16, u16);
+static void sub_8091E54(u8);
+static void sub_809204C(u8);
+static void sub_809207C(u8);
+static void sub_809217C(u8);
+static void sub_80921B0(u8);
+static void sub_80923FC(u8);
+static void sub_80924A4(u8);
+static void sub_8092508(u8);
+static void sub_80925CC(u8);
+static void sub_8092644(u8);
+static void sub_80927B8(u8);
+static void sub_80927F0(u8);
+static void sub_8092AB0(u8);
+static void sub_8092AD4(u8, u8);
+static void sub_8092B68(u8);
+static void sub_8092C8C(u8);
+static void sub_8092D78(u8);
+static u8 sub_8092E10(u8, u8);
+static void sub_8092EB0(u8);
+static void sub_809308C(u8);
-// asm/pokedex_area_screen
-void ShowPokedexAreaScreen(u16 species, u8 *string);
void ResetPokedex(void)
{
@@ -139,18 +1321,18 @@ void sub_808C0A0(void)
gUnknown_0202FFBA = 0x40;
}
-void sub_808C0B8(void)
+static void sub_808C0B8(void)
{
LoadOam();
ProcessSpriteCopyRequests();
TransferPlttBuffer();
}
-void ClearPokedexView(struct PokedexView *pokedexView)
+static void ClearPokedexView(struct PokedexView *pokedexView)
{
u16 i;
- for (i = 0; i <= 385; i++)
+ for (i = 0; i < NATIONAL_DEX_COUNT; i++)
{
pokedexView->unk0[i].dexNum |= 0xFFFF;
pokedexView->unk0[i].seen = 0;
@@ -159,7 +1341,7 @@ void ClearPokedexView(struct PokedexView *pokedexView)
pokedexView->unk608 = 0;
pokedexView->unk60A_1 = 0;
pokedexView->unk60A_2 = 0;
- pokedexView->unk60C = 0;
+ pokedexView->pokemonListCount = 0;
pokedexView->selectedPokemon = 0;
pokedexView->unk610 = 0;
pokedexView->dexMode = 0;
@@ -203,30 +1385,30 @@ void CB2_InitPokedex(void)
{
case 0:
default:
- {
- u8 *addr;
- u32 size;
+ {
+ u8 *addr;
+ u32 size;
- SetVBlankCallback(NULL);
- sub_8091060(0);
- addr = (u8 *)VRAM;
- size = VRAM_SIZE;
- while (1)
- {
- DmaFill16(3, 0, addr, 0x1000);
- addr += 0x1000;
- size -= 0x1000;
- if (size <= 0x1000)
+ SetVBlankCallback(NULL);
+ sub_8091060(0);
+ addr = (u8 *)VRAM;
+ size = VRAM_SIZE;
+ while (1)
{
- DmaFill16(3, 0, addr, size);
- break;
+ DmaFill16(3, 0, addr, 0x1000);
+ addr += 0x1000;
+ size -= 0x1000;
+ if (size <= 0x1000)
+ {
+ DmaFill16(3, 0, addr, size);
+ break;
+ }
}
+ DmaClear32(3, OAM, OAM_SIZE);
+ DmaClear16(3, PLTT, PLTT_SIZE);
+ gMain.state = 1;
}
- DmaClear32(3, OAM, OAM_SIZE);
- DmaClear16(3, PLTT, PLTT_SIZE);
- gMain.state = 1;
break;
- }
case 1:
remove_some_task();
ResetTasks();
@@ -264,7 +1446,7 @@ void CB2_InitPokedex(void)
gPokedexView->selectedPokemon = gUnknown_0202FFB8;
gPokedexView->unk62C = gUnknown_0202FFBA;
gPokedexView->selectedScreen = PAGE_SCREEN;
- gPokedexView->unk64E = 0;
+ gPokedexView->descriptionPageNum = 0;
if (!IsNationalPokedexEnabled())
{
gPokedexView->unk61A = GetHoennPokedexCount(0);
@@ -279,19 +1461,20 @@ void CB2_InitPokedex(void)
gMain.state++;
break;
case 3:
- {
- u16 savedIme;
-
- savedIme = REG_IME;
- REG_IME = 0;
- REG_IE |= 1;
- REG_IME = savedIme;
- REG_DISPSTAT |= 8;
- SetVBlankCallback(sub_808C0B8);
- SetMainCallback2(MainCB);
- SortPokedex(gPokedexView->dexMode, gPokedexView->dexOrder);
- m4aMPlayVolumeControl(&gMPlay_BGM, 0xFFFF, 0x80);
- }
+ {
+ u16 savedIme;
+
+ savedIme = REG_IME;
+ REG_IME = 0;
+ REG_IE |= 1;
+ REG_IME = savedIme;
+ REG_DISPSTAT |= 8;
+ SetVBlankCallback(sub_808C0B8);
+ SetMainCallback2(MainCB);
+ SortPokedex(gPokedexView->dexMode, gPokedexView->dexOrder);
+ m4aMPlayVolumeControl(&gMPlay_BGM, 0xFFFF, 0x80);
+ }
+ break;
}
}
@@ -320,7 +1503,7 @@ u8 unref_sub_808C540(void (*func)(u8))
return gTasks[taskId].data[0];
}
-void MainCB(void)
+static void MainCB(void)
{
RunTasks();
AnimateSprites();
@@ -328,13 +1511,11 @@ void MainCB(void)
UpdatePaletteFade();
}
-void Task_PokedexShowMainScreen(u8 taskId)
+static void Task_PokedexShowMainScreen(u8 taskId)
{
gPokedexView->unk64C_1 = 0;
if (sub_808D344(0))
- {
gTasks[taskId].func = Task_PokedexMainScreen;
- }
}
//Hide menu and process input on main screen
@@ -351,9 +1532,9 @@ void Task_PokedexMainScreen(u8 taskId)
{
sub_808E6BC();
BeginNormalPaletteFade(
- ~(1 << (gSprites[gPokedexView->unk626].oam.paletteNum + 16)),
+ ~(1 << (gSprites[gPokedexView->selectedMonSpriteId].oam.paletteNum + 16)),
0, 0, 0x10, 0);
- gSprites[gPokedexView->unk626].callback = sub_808EDB8;
+ gSprites[gPokedexView->selectedMonSpriteId].callback = sub_808EDB8;
gTasks[taskId].func = sub_808CA64;
PlaySE(SE_PIN);
}
@@ -395,16 +1576,14 @@ void Task_PokedexMainScreen(u8 taskId)
}
}
-void sub_808C898(u8 taskId)
+static void sub_808C898(u8 taskId)
{
if (sub_808E208(gPokedexView->unk62F, gPokedexView->unk634, gPokedexView->unk636))
- {
gTasks[taskId].func = Task_PokedexMainScreen;
- }
}
//Bring up menu and process menu input
-void Task_PokedexMainScreenMenu(u8 taskId)
+static void Task_PokedexMainScreenMenu(u8 taskId)
{
REG_BG0VOFS = gPokedexView->menuY;
@@ -429,8 +1608,8 @@ void Task_PokedexMainScreenMenu(u8 taskId)
gMain.newKeys |= START_BUTTON; //Exit menu
break;
case 2: //LIST BOTTOM
- gPokedexView->selectedPokemon = gPokedexView->unk60C - 1;
- gPokedexView->unk62C = gPokedexView->unk60C * 16 + 0x30;
+ gPokedexView->selectedPokemon = gPokedexView->pokemonListCount - 1;
+ gPokedexView->unk62C = gPokedexView->pokemonListCount * 16 + 0x30;
sub_808E82C();
sub_808E0CC(gPokedexView->selectedPokemon, 0xE);
gMain.newKeys |= START_BUTTON; //Exit menu
@@ -463,27 +1642,23 @@ void Task_PokedexMainScreenMenu(u8 taskId)
}
}
-void sub_808CA64(u8 taskId)
+static void sub_808CA64(u8 taskId)
{
- if (gSprites[gPokedexView->unk626].pos1.x == 0x30 &&
- gSprites[gPokedexView->unk626].pos1.y == 0x38)
+ if (gSprites[gPokedexView->selectedMonSpriteId].pos1.x == 48
+ && gSprites[gPokedexView->selectedMonSpriteId].pos1.y == 56)
{
gPokedexView->unk64B = gPokedexView->unk64A;
- gTasks[taskId].data[0] = sub_808F210(&gPokedexView->unk0[gPokedexView->selectedPokemon], gPokedexView->unk626);
+ gTasks[taskId].data[0] = sub_808F210(&gPokedexView->unk0[gPokedexView->selectedPokemon], gPokedexView->selectedMonSpriteId);
gTasks[taskId].func = sub_808CAE4;
}
}
-void sub_808CAE4(u8 taskId)
+static void sub_808CAE4(u8 taskId)
{
if (gTasks[gTasks[taskId].data[0]].isActive)
{
- if (gPokedexView->unk64A == 1 &&
- !sub_808F250(gTasks[taskId].data[0]) &&
- sub_808E71C())
- {
+ if (gPokedexView->unk64A == 1 && !sub_808F250(gTasks[taskId].data[0]) && sub_808E71C())
sub_808F284(&gPokedexView->unk0[gPokedexView->selectedPokemon], gTasks[taskId].data[0]);
- }
}
else
{
@@ -493,13 +1668,13 @@ void sub_808CAE4(u8 taskId)
}
}
-void sub_808CB8C(u8 taskId)
+static void sub_808CB8C(u8 taskId)
{
bool8 isActive = gTasks[gTasks[taskId].data[0]].isActive;
if (!isActive)
{
- if (gPokedexView->unk64F)
+ if (gPokedexView->unk64F != 0)
{
gPokedexView->selectedPokemon = isActive;
gPokedexView->unk62C = 0x40;
@@ -518,7 +1693,7 @@ void sub_808CB8C(u8 taskId)
}
}
-void Task_ClosePokedex(u8 taskId)
+static void Task_ClosePokedex(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -532,19 +1707,21 @@ void Task_ClosePokedex(u8 taskId)
}
}
-void sub_808CCC4(u8 taskId)
+static void sub_808CCC4(u8 taskId)
{
gPokedexView->unk64C_1 = 1;
if (sub_808D344(3))
gTasks[taskId].func = Task_PokedexResultsScreen;
}
-void Task_PokedexResultsScreen(u8 taskId)
+static void Task_PokedexResultsScreen(u8 taskId)
{
REG_BG0VOFS = gPokedexView->menuY;
if (gPokedexView->menuY)
+ {
gPokedexView->menuY -= 8;
+ }
else
{
if ((gMain.newKeys & A_BUTTON) && gPokedexView->unk0[gPokedexView->selectedPokemon].seen)
@@ -552,8 +1729,8 @@ void Task_PokedexResultsScreen(u8 taskId)
u32 a;
sub_808E6BC();
- a = (1 << (gSprites[gPokedexView->unk626].oam.paletteNum + 16));
- gSprites[gPokedexView->unk626].callback = sub_808EDB8;
+ a = (1 << (gSprites[gPokedexView->selectedMonSpriteId].oam.paletteNum + 16));
+ gSprites[gPokedexView->selectedMonSpriteId].callback = sub_808EDB8;
BeginNormalPaletteFade(~a, 0, 0, 0x10, 0);
gTasks[taskId].func = sub_808D118;
PlaySE(SE_PIN);
@@ -590,18 +1767,20 @@ void Task_PokedexResultsScreen(u8 taskId)
}
}
-void sub_808CEF8(u8 taskId)
+static void sub_808CEF8(u8 taskId)
{
if (sub_808E208(gPokedexView->unk62F, gPokedexView->unk634, gPokedexView->unk636))
gTasks[taskId].func = Task_PokedexResultsScreen;
}
-void Task_PokedexResultsScreenMenu(u8 taskId)
+static void Task_PokedexResultsScreenMenu(u8 taskId)
{
REG_BG0VOFS = gPokedexView->menuY;
- if (gPokedexView->menuY != 0x60)
+ if (gPokedexView->menuY != 96)
+ {
gPokedexView->menuY += 8;
+ }
else
{
if (gMain.newKeys & A_BUTTON)
@@ -620,8 +1799,8 @@ void Task_PokedexResultsScreenMenu(u8 taskId)
gMain.newKeys |= START_BUTTON;
break;
case 2: //LIST BOTTOM
- gPokedexView->selectedPokemon = gPokedexView->unk60C - 1;
- gPokedexView->unk62C = gPokedexView->unk60C * 16 + 0x30;
+ gPokedexView->selectedPokemon = gPokedexView->pokemonListCount - 1;
+ gPokedexView->unk62C = gPokedexView->pokemonListCount * 16 + 0x30;
sub_808E82C();
sub_808E0CC(gPokedexView->selectedPokemon, 0xE);
gMain.newKeys |= START_BUTTON;
@@ -659,27 +1838,23 @@ void Task_PokedexResultsScreenMenu(u8 taskId)
}
}
-void sub_808D118(u8 taskId)
+static void sub_808D118(u8 taskId)
{
- if (gSprites[gPokedexView->unk626].pos1.x == 0x30 &&
- gSprites[gPokedexView->unk626].pos1.y == 0x38)
+ if (gSprites[gPokedexView->selectedMonSpriteId].pos1.x == 48
+ && gSprites[gPokedexView->selectedMonSpriteId].pos1.y == 56)
{
gPokedexView->unk64B = gPokedexView->unk64A;
- gTasks[taskId].data[0] = sub_808F210(&gPokedexView->unk0[gPokedexView->selectedPokemon], gPokedexView->unk626);
+ gTasks[taskId].data[0] = sub_808F210(&gPokedexView->unk0[gPokedexView->selectedPokemon], gPokedexView->selectedMonSpriteId);
gTasks[taskId].func = sub_808D198;
}
}
-void sub_808D198(u8 taskId)
+static void sub_808D198(u8 taskId)
{
if (gTasks[gTasks[taskId].data[0]].isActive)
{
- if (gPokedexView->unk64A == 1 &&
- !sub_808F250(gTasks[taskId].data[0]) &&
- sub_808E71C())
- {
+ if (gPokedexView->unk64A == 1 && !sub_808F250(gTasks[taskId].data[0]) && sub_808E71C())
sub_808F284(&gPokedexView->unk0[gPokedexView->selectedPokemon], gTasks[taskId].data[0]);
- }
}
else
{
@@ -687,7 +1862,7 @@ void sub_808D198(u8 taskId)
}
}
-void Task_PokedexResultsScreenReturnToMainScreen(u8 taskId)
+static void Task_PokedexResultsScreenReturnToMainScreen(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -701,7 +1876,7 @@ void Task_PokedexResultsScreenReturnToMainScreen(u8 taskId)
}
}
-void Task_PokedexResultsScreenExitPokedex(u8 taskId)
+static void Task_PokedexResultsScreenExitPokedex(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -715,8 +1890,7 @@ void Task_PokedexResultsScreenExitPokedex(u8 taskId)
}
}
-
-bool8 sub_808D344(u8 a)
+static bool8 sub_808D344(u8 a)
{
switch (gMain.state)
{
@@ -724,7 +1898,6 @@ bool8 sub_808D344(u8 a)
default:
if (gPaletteFade.active)
return 0;
- //_0808D39E
SetVBlankCallback(NULL);
gPokedexView->unk64A = a;
sub_8091060(0);
@@ -749,7 +1922,7 @@ bool8 sub_808D344(u8 a)
ResetSpriteData();
FreeAllSpritePalettes();
gReservedSpritePaletteCount = 8;
- LoadCompressedObjectPic(&gUnknown_083A05CC);
+ LoadCompressedObjectPic(&gUnknown_083A05CC[0]);
LoadSpritePalettes(gUnknown_083A05DC);
sub_808E978(a);
gMain.state++;
@@ -793,30 +1966,29 @@ bool8 sub_808D344(u8 a)
if (!gPaletteFade.active)
{
gMain.state = 0;
- return 1;
+ return TRUE;
}
- else
- return 0;
+ break;
}
- return 0;
+ return FALSE;
}
-void sub_808D640(void)
+static void sub_808D640(void)
{
if (gPokedexView->unk64C_1)
- LoadPalette(gUnknown_0839F67C + 0x2, 1, 0xBE);
+ LoadPalette(sPokedexSearchPalette + 1, 1, sizeof(sPokedexSearchPalette) - sizeof(u16));
else if (!IsNationalPokedexEnabled())
- LoadPalette(gPokedexMenu_Pal + 0x2, 1, 0xBE);
+ LoadPalette(gPokedexMenu_Pal + 1, 1, 0xBE);
else
- LoadPalette(gUnknown_0839F73C + 0x2, 1, 0xBE);
+ LoadPalette(sNationalPokedexPalette + 1, 1, sizeof(sNationalPokedexPalette) - sizeof(u16));
}
-void SortPokedex(u8 dexMode, u8 sortMode)
+static void SortPokedex(u8 dexMode, u8 sortMode)
{
u16 vars[3]; //I have no idea why three regular variables are stored in an array, but whatever.
s16 i;
- gPokedexView->unk60C = 0;
+ gPokedexView->pokemonListCount = 0;
switch (dexMode)
{
@@ -828,7 +2000,7 @@ void SortPokedex(u8 dexMode, u8 sortMode)
case DEX_MODE_NATIONAL:
if (IsNationalPokedexEnabled())
{
- vars[0] = 386;
+ vars[0] = NATIONAL_DEX_COUNT;
vars[1] = 0;
}
else
@@ -842,17 +2014,16 @@ void SortPokedex(u8 dexMode, u8 sortMode)
switch (sortMode)
{
case 0:
- {
if (vars[1])
{
for (i = 0; i < vars[0]; i++)
{
vars[2] = HoennToNationalOrder(i + 1);
gPokedexView->unk0[i].dexNum = vars[2];
- gPokedexView->unk0[i].seen = sub_8090D90(vars[2], 0);
- gPokedexView->unk0[i].owned = sub_8090D90(vars[2], 1);
+ gPokedexView->unk0[i].seen = GetNationalPokedexFlag(vars[2], 0);
+ gPokedexView->unk0[i].owned = GetNationalPokedexFlag(vars[2], 1);
if (gPokedexView->unk0[i].seen)
- gPokedexView->unk60C = i + 1;
+ gPokedexView->pokemonListCount = i + 1;
}
}
else
@@ -864,94 +2035,94 @@ void SortPokedex(u8 dexMode, u8 sortMode)
for (i = 0; i < vars[0]; i++)
{
vars[2] = i + 1;
- if (sub_8090D90(vars[2], 0))
+ if (GetNationalPokedexFlag(vars[2], 0))
r10 = 1;
if (r10)
{
asm(""); //Needed to match for some reason
gPokedexView->unk0[r5].dexNum = vars[2];
- gPokedexView->unk0[r5].seen = sub_8090D90(vars[2], 0);
- gPokedexView->unk0[r5].owned = sub_8090D90(vars[2], 1);
+ gPokedexView->unk0[r5].seen = GetNationalPokedexFlag(vars[2], 0);
+ gPokedexView->unk0[r5].owned = GetNationalPokedexFlag(vars[2], 1);
if (gPokedexView->unk0[r5].seen)
- gPokedexView->unk60C = r5 + 1;
+ gPokedexView->pokemonListCount = r5 + 1;
r5++;
}
}
}
break;
- }
case 1:
for (i = 0; i < 411; i++)
{
vars[2] = gPokedexOrder_Alphabetical[i];
- if (NationalToHoennOrder(vars[2]) <= vars[0] && sub_8090D90(vars[2], 0))
+ if (NationalToHoennOrder(vars[2]) <= vars[0] && GetNationalPokedexFlag(vars[2], 0))
{
- gPokedexView->unk0[gPokedexView->unk60C].dexNum = vars[2];
- gPokedexView->unk0[gPokedexView->unk60C].seen = 1;
- gPokedexView->unk0[gPokedexView->unk60C].owned = sub_8090D90(vars[2], 1);
- gPokedexView->unk60C++;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].dexNum = vars[2];
+ gPokedexView->unk0[gPokedexView->pokemonListCount].seen = 1;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].owned = GetNationalPokedexFlag(vars[2], 1);
+ gPokedexView->pokemonListCount++;
}
}
break;
case 2:
- for (i = 385; i >= 0; i--)
+ for (i = NATIONAL_DEX_COUNT - 1; i >= 0; i--)
{
vars[2] = gPokedexOrder_Weight[i];
- if (NationalToHoennOrder(vars[2]) <= vars[0] && sub_8090D90(vars[2], 1))
+ if (NationalToHoennOrder(vars[2]) <= vars[0] && GetNationalPokedexFlag(vars[2], 1))
{
- gPokedexView->unk0[gPokedexView->unk60C].dexNum = vars[2];
- gPokedexView->unk0[gPokedexView->unk60C].seen = 1;
- gPokedexView->unk0[gPokedexView->unk60C].owned = 1;
- gPokedexView->unk60C++;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].dexNum = vars[2];
+ gPokedexView->unk0[gPokedexView->pokemonListCount].seen = 1;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].owned = 1;
+ gPokedexView->pokemonListCount++;
}
}
break;
case 3:
- for (i = 0; i < 386; i++)
+ for (i = 0; i < NATIONAL_DEX_COUNT; i++)
{
vars[2] = gPokedexOrder_Weight[i];
- if (NationalToHoennOrder(vars[2]) <= vars[0] && sub_8090D90(vars[2], 1))
+ if (NationalToHoennOrder(vars[2]) <= vars[0] && GetNationalPokedexFlag(vars[2], 1))
{
- gPokedexView->unk0[gPokedexView->unk60C].dexNum = vars[2];
- gPokedexView->unk0[gPokedexView->unk60C].seen = 1;
- gPokedexView->unk0[gPokedexView->unk60C].owned = 1;
- gPokedexView->unk60C++;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].dexNum = vars[2];
+ gPokedexView->unk0[gPokedexView->pokemonListCount].seen = 1;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].owned = 1;
+ gPokedexView->pokemonListCount++;
}
}
break;
case 4:
- for (i = 385; i >=0; i--)
+ for (i = NATIONAL_DEX_COUNT - 1; i >=0; i--)
{
vars[2] = gPokedexOrder_Height[i];
- if (NationalToHoennOrder(vars[2]) <= vars[0] && sub_8090D90(vars[2], 1))
+ if (NationalToHoennOrder(vars[2]) <= vars[0] && GetNationalPokedexFlag(vars[2], 1))
{
- gPokedexView->unk0[gPokedexView->unk60C].dexNum = vars[2];
- gPokedexView->unk0[gPokedexView->unk60C].seen = 1;
- gPokedexView->unk0[gPokedexView->unk60C].owned = 1;
- gPokedexView->unk60C++;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].dexNum = vars[2];
+ gPokedexView->unk0[gPokedexView->pokemonListCount].seen = 1;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].owned = 1;
+ gPokedexView->pokemonListCount++;
}
}
break;
case 5:
- for (i = 0; i < 386; i++)
+ for (i = 0; i < NATIONAL_DEX_COUNT; i++)
{
vars[2] = gPokedexOrder_Height[i];
- if (NationalToHoennOrder(vars[2]) <= vars[0] && sub_8090D90(vars[2], 1))
+ if (NationalToHoennOrder(vars[2]) <= vars[0] && GetNationalPokedexFlag(vars[2], 1))
{
- gPokedexView->unk0[gPokedexView->unk60C].dexNum = vars[2];
- gPokedexView->unk0[gPokedexView->unk60C].seen = 1;
- gPokedexView->unk0[gPokedexView->unk60C].owned = 1;
- gPokedexView->unk60C++;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].dexNum = vars[2];
+ gPokedexView->unk0[gPokedexView->pokemonListCount].seen = 1;
+ gPokedexView->unk0[gPokedexView->pokemonListCount].owned = 1;
+ gPokedexView->pokemonListCount++;
}
}
break;
}
- for (i = gPokedexView->unk60C; i < 386; i++)
+
+ for (i = gPokedexView->pokemonListCount; i < NATIONAL_DEX_COUNT; i++)
{
gPokedexView->unk0[i].dexNum |= 0xFFFF;
gPokedexView->unk0[i].seen = 0;
@@ -959,20 +2130,23 @@ void SortPokedex(u8 dexMode, u8 sortMode)
}
}
-void sub_808DBE8(u8 a, u16 b, u16 c)
+static void sub_808DBE8(u8 a, u16 b, u16 c)
{
+ s16 _b;
+ u16 i;
+ u16 r2;
+
switch (a)
{
case 0:
default:
- {
- u16 i;
- s16 _b = b - 5;
-
+ _b = b - 5;
for (i = 0; i <= 10; i++)
{
- if ((u16)_b > 385 || gPokedexView->unk0[_b].dexNum == 0xFFFF)
+ if (_b < 0 || _b >= NATIONAL_DEX_COUNT || gPokedexView->unk0[_b].dexNum == 0xFFFF)
+ {
sub_808E090(0x11, i * 2, c);
+ }
else
{
sub_808E090(0x11, i * 2, c);
@@ -992,13 +2166,12 @@ void sub_808DBE8(u8 a, u16 b, u16 c)
_b++;
}
break;
- }
case 1:
- {
- s16 _b = b - 5;
-
- if ((u16)_b > 385 || gPokedexView->unk0[_b].dexNum == 0xFFFF)
+ _b = b - 5;
+ if (_b < 0 || _b >= NATIONAL_DEX_COUNT || gPokedexView->unk0[_b].dexNum == 0xFFFF)
+ {
sub_808E090(0x11, gPokedexView->unk630 * 2, c);
+ }
else
{
sub_808E090(0x11, gPokedexView->unk630 * 2, c);
@@ -1016,15 +2189,12 @@ void sub_808DBE8(u8 a, u16 b, u16 c)
}
}
break;
- }
case 2:
- {
- s16 _b = b + 5;
- u16 r2 = gPokedexView->unk630 + 10;
-
+ _b = b + 5;
+ r2 = gPokedexView->unk630 + 10;
if (r2 > 15)
r2 -= 16;
- if ((u16)_b > 385 || gPokedexView->unk0[_b].dexNum == 0xFFFF)
+ if (_b < 0 || _b >= NATIONAL_DEX_COUNT || gPokedexView->unk0[_b].dexNum == 0xFFFF)
sub_808E090(0x11, r2 * 2, c);
else
{
@@ -1044,10 +2214,9 @@ void sub_808DBE8(u8 a, u16 b, u16 c)
}
break;
}
- }
}
-void sub_808DEB0(u16 a, u8 b, u8 c, u16 d)
+static void sub_808DEB0(u16 a, u8 b, u8 c, u16 d)
{
u8 text[4];
u16 unk[2];
@@ -1057,16 +2226,16 @@ void sub_808DEB0(u16 a, u8 b, u8 c, u16 d)
r7 = NationalToHoennOrder(r7);
unk[0] = 0x3FC;
unk[1] = 0x3FD;
- text[0] = r7 / 100 + 0xA1;
- text[1] = (r7 % 100) / 10 + 0xA1;
- text[2] = (r7 % 100) % 10 + 0xA1;
- text[3] = 0xFF;
+ text[0] = CHAR_0 + r7 / 100;
+ text[1] = CHAR_0 + (r7 % 100) / 10;
+ text[2] = CHAR_0 + (r7 % 100) % 10;
+ text[3] = EOS;
*(u16 *)(VRAM + d * 0x800 + c * 0x40 + b * 2) = unk[0];
- *(u16 *)(VRAM + 0x40 + d * 0x800 + c * 0x40 + b * 2) = unk[1];
+ *(u16 *)(VRAM + d * 0x800 + (c + 1) * 0x40 + b * 2) = unk[1];
MenuPrint(text, b - 15, c);
}
-void sub_808DF88(u16 a, u8 b, u8 c, u16 d)
+static void sub_808DF88(u16 a, u8 b, u8 c, u16 d)
{
u16 unk[2];
@@ -1081,152 +2250,57 @@ void sub_808DF88(u16 a, u8 b, u8 c, u16 d)
unk[1] = 0;
}
*(u16 *)(VRAM + d * 0x800 + c * 0x40 + b * 2) = unk[0];
- *(u16 *)(VRAM + 0x40 + d * 0x800 + c * 0x40 + b * 2) = unk[1];
+ *(u16 *)(VRAM + d * 0x800 + (c + 1) * 0x40 + b * 2) = unk[1];
}
-#ifdef NONMATCHING
-//FixMe
-u8 sub_808DFE4(u16 a, u8 b, u8 c)
+static u8 sub_808DFE4(u16 num, u8 b, u8 c)
{
u8 text[10];
u8 i;
- u32 species;
for (i = 0; i < 10; i++)
- text[i] = 0;
+ text[i] = CHAR_SPACE;
text[i] = EOS;
- species = NationalPokedexNumToSpecies(a);
- if (species)
- {
- for (i = 0; gSpeciesNames[species][i] != EOS && i < 10; i++)
- text[i] = gSpeciesNames[species][i];
- }
- else
+
+ num = NationalPokedexNumToSpecies(num);
+ switch (num)
{
+ default:
+ for (i = 0; gSpeciesNames[num][i] != EOS && i < 10; i++)
+ text[i] = gSpeciesNames[num][i];
+ break;
+ case 0:
for (i = 0; i < 10; i++)
- text[i] = 0xAE;
+ text[i] = CHAR_HYPHEN;
+ break;
}
MenuPrint_PixelCoords(text, (b - 0x11) * 8 + 0xFC, c * 8, 0);
+ return i;
}
-#else
-__attribute__((naked))
-u8 sub_808DFE4(u16 a, u8 b, u8 c)
-{
- asm(".syntax unified\n\
- push {r4-r6,lr}\n\
- sub sp, 0xC\n\
- lsls r0, 16\n\
- lsrs r3, r0, 16\n\
- lsls r1, 24\n\
- lsrs r5, r1, 24\n\
- lsls r2, 24\n\
- lsrs r6, r2, 24\n\
- movs r4, 0\n\
- movs r1, 0\n\
-_0808DFF8:\n\
- mov r2, sp\n\
- adds r0, r2, r4\n\
- strb r1, [r0]\n\
- adds r0, r4, 0x1\n\
- lsls r0, 24\n\
- lsrs r4, r0, 24\n\
- cmp r4, 0x9\n\
- bls _0808DFF8\n\
- adds r0, r2, r4\n\
- movs r1, 0xFF\n\
- strb r1, [r0]\n\
- adds r0, r3, 0\n\
- bl NationalPokedexNumToSpecies\n\
- adds r3, r0, 0\n\
- cmp r3, 0\n\
- beq _0808E058\n\
- movs r4, 0\n\
- ldr r2, _0808E054\n\
- movs r0, 0xB\n\
- adds r1, r3, 0\n\
- muls r1, r0\n\
- adds r0, r1, r2\n\
- ldrb r0, [r0]\n\
- subs r5, 0x11\n\
- lsls r6, 19\n\
- cmp r0, 0xFF\n\
- beq _0808E070\n\
- adds r3, r1, 0\n\
-_0808E032:\n\
- mov r0, sp\n\
- adds r1, r0, r4\n\
- adds r0, r4, r3\n\
- adds r0, r2\n\
- ldrb r0, [r0]\n\
- strb r0, [r1]\n\
- adds r0, r4, 0x1\n\
- lsls r0, 24\n\
- lsrs r4, r0, 24\n\
- adds r0, r4, r3\n\
- adds r0, r2\n\
- ldrb r0, [r0]\n\
- cmp r0, 0xFF\n\
- beq _0808E070\n\
- cmp r4, 0x9\n\
- bls _0808E032\n\
- b _0808E070\n\
- .align 2, 0\n\
-_0808E054: .4byte gSpeciesNames\n\
-_0808E058:\n\
- movs r4, 0\n\
- subs r5, 0x11\n\
- lsls r6, 19\n\
- movs r1, 0xAE\n\
-_0808E060:\n\
- mov r2, sp\n\
- adds r0, r2, r4\n\
- strb r1, [r0]\n\
- adds r0, r4, 0x1\n\
- lsls r0, 24\n\
- lsrs r4, r0, 24\n\
- cmp r4, 0x9\n\
- bls _0808E060\n\
-_0808E070:\n\
- lsls r1, r5, 27\n\
- movs r0, 0xFC\n\
- lsls r0, 24\n\
- adds r1, r0\n\
- lsrs r1, 24\n\
- lsrs r2, r6, 16\n\
- mov r0, sp\n\
- movs r3, 0\n\
- bl MenuPrint_PixelCoords\n\
- adds r0, r4, 0\n\
- add sp, 0xC\n\
- pop {r4-r6}\n\
- pop {r1}\n\
- bx r1\n\
- .syntax divided\n");
-}
-#endif
-void sub_808E090(u8 a, u8 b, u16 c)
+static void sub_808E090(u8 a, u8 b, u16 c)
{
u8 i;
for (i = 0; i < 12; i++)
{
*(u16 *)(VRAM + c * 0x800 + b * 64 + (a + i) * 2) = 0;
- *(u16 *)(VRAM + 0x40 + c * 0x800 + b * 64 + (a + i) * 2) = 0;
+ *(u16 *)(VRAM + c * 0x800 + (b + 1) * 64 + (a + i) * 2) = 0;
}
}
-void sub_808E0CC(u16 a, u16 b)
+static void sub_808E0CC(u16 a, u16 b)
{
u8 i;
u16 unk;
u8 spriteId;
for (i = 0; i < 4; i++)
- gPokedexView->unk61E[i] |= 0xFFFF;
- gPokedexView->unk626 = 0xFFFF;
+ gPokedexView->unk61E[i] = 0xFFFF;
+ gPokedexView->selectedMonSpriteId = 0xFFFF;
sub_808DBE8(0, a, b);
REG_BG2VOFS = gPokedexView->unk62D;
+
unk = sub_808E888(a - 1);
if (unk != 0xFFFF)
{
@@ -1234,6 +2308,7 @@ void sub_808E0CC(u16 a, u16 b)
gSprites[spriteId].callback = sub_808EE28;
gSprites[spriteId].data5 = -32;
}
+
unk = sub_808E888(a);
if (unk != 0xFFFF)
{
@@ -1241,6 +2316,7 @@ void sub_808E0CC(u16 a, u16 b)
gSprites[spriteId].callback = sub_808EE28;
gSprites[spriteId].data5 = 0;
}
+
unk = sub_808E888(a + 1);
if (unk != 0xFFFF)
{
@@ -1248,11 +2324,12 @@ void sub_808E0CC(u16 a, u16 b)
gSprites[spriteId].callback = sub_808EE28;
gSprites[spriteId].data5 = 32;
}
+
gPokedexView->unk630 = 0;
gPokedexView->unk632 = 0;
}
-bool8 sub_808E208(u8 a, u8 b, u8 c)
+static bool8 sub_808E208(u8 a, u8 b, u8 c)
{
u16 i;
u8 foo;
@@ -1283,17 +2360,16 @@ bool8 sub_808E208(u8 a, u8 b, u8 c)
gPokedexView->unk62C += gPokedexView->unk628;
break;
}
- return 0;
+ return FALSE;
}
- //_0808E36C
else
{
REG_BG2VOFS = gPokedexView->unk62D + gPokedexView->unk630 * 16;
- return 1;
+ return TRUE;
}
}
-void sub_808E398(u8 a, u16 b)
+static void sub_808E398(u8 a, u16 b)
{
u16 unk;
u8 spriteId;
@@ -1302,22 +2378,19 @@ void sub_808E398(u8 a, u16 b)
switch (a)
{
case 1:
- {
unk = sub_808E888(b - 1);
if (unk != 0xFFFF)
{
spriteId = sub_808E8C8(unk, 0x60, 0x50);
gSprites[spriteId].callback = sub_808EE28;
- gSprites[spriteId].data5 = 0xFFC0;
+ gSprites[spriteId].data5 = -64;
}
if (gPokedexView->unk630 > 0)
gPokedexView->unk630--;
else
- gPokedexView->unk630 = 0xF;
+ gPokedexView->unk630 = 15;
break;
- }
case 2:
- {
unk = sub_808E888(b + 1);
if (unk != 0xFFFF)
{
@@ -1331,370 +2404,90 @@ void sub_808E398(u8 a, u16 b)
gPokedexView->unk630 = 0;
break;
}
- }
}
-#ifdef NONMATCHING
-//This one's ridiculous. Fix later
-u16 sub_808E48C(u16 a, u16 b)
+
+// Ugly, ugly, ugly. I couldn't get it to match otherwise.
+static u16 sub_808E48C(u16 a, u16 b)
{
u8 r3;
u8 r5;
- u32 r10 = 0;
- if (!(gMain.heldKeys & 0x40) || a == 0)
- {
- u8 i;
- u16 r6;
+ u8 i;
+ u16 r6;
+ u8 r10 = 0;
+ if (!((gMain.heldKeys & 0x40) && (a > 0)))
+ {
//_0808E4B6
- if (gMain.heldKeys & 0x80)
- {
- if (a < gPokedexView->unk60C - 1)
- goto _0808E5C4;
- }
+ if (!((gMain.heldKeys & 0x80) && (a < gPokedexView->pokemonListCount - 1)))
//_0808E4CE
-
- if ((gMain.newKeys & 0x20) && a != 0)
{
- r6 = a;
- //_0808E4E0
- for (i = 0; i < 7; i++)
+ if ((gMain.newKeys & 0x20) && (a > 0))
{
- a = sub_8091818(1, a, 0, gPokedexView->unk60C - 1);
+ r6 = a;
+ //_0808E4E0
+ for (i = 0; i < 7; i++)
+ a = sub_8091818(1, a, 0, gPokedexView->pokemonListCount - 1);
+ gPokedexView->unk62C += 16 * (a - r6);
+ sub_808E82C();
+ sub_808E0CC(a, 0xE);
+ PlaySE(0x6D);
+ }
+ //_0808E53C
+ else if ((gMain.newKeys & 0x10) && (a < gPokedexView->pokemonListCount - 1))
+ {
+ r6 = a;
+ for (i = 0; i < 7; i++)
+ a = sub_8091818(0, a, 0, gPokedexView->pokemonListCount - 1);
+ gPokedexView->unk62C += (a - r6) * 16;
+ sub_808E82C();
+ sub_808E0CC(a, 0xE);
+ PlaySE(0x6D);
+ }
+ _0808E5A2:
+ if (r10 == 0)
+ {
+ gPokedexView->unk638 = 0;
+ return a;
}
-
- gPokedexView->unk62C += (a - r6) * 16;
- sub_808E82C();
- sub_808E0CC(a, 0xE);
- PlaySE(SE_Z_PAGE);
- goto _0808E5A2;
}
- //_0808E53C
- if (!(gMain.newKeys & 0x10) || a >= gPokedexView->unk60C - 1)
- goto _0808E5A2;
-
- r6 = a;
- for (i = 0; i < 7; i++)
+ else
{
- a = sub_8091818(0, a, 0, gPokedexView->unk60C - 1);
+ // to _0808E5C4
+ r10 = 2;
+ a = sub_8091818(0, a, 0, gPokedexView->pokemonListCount - 1);
+ sub_808E398(2, a);
+ //goto _0808E60E
+ sub_808DBE8(2, a, b);
+ PlaySE(0x6C);
+ goto _0808E5A2;
}
-
- gPokedexView->unk62C += (a - r6) * 16;
- sub_808E82C();
- sub_808E0CC(a, 0xE);
- PlaySE(SE_Z_PAGE);
- goto _0808E5A2;
-
- _0808E5A2:
- if (r10 != 0)
- goto _0808E628;
- gPokedexView->unk638 = r10;
- return a;
-
- _0808E5C4:
- r10 = 2;
- a = sub_8091818(0, a, 0, gPokedexView->unk60C - 1);
- sub_808E398(2, a);
- //goto _0808E60E
- sub_808DBE8(2, a, b);
- PlaySE(SE_Z_SCROLL);
}
- //_0808E5E4
else
{
+ //to _0808E5E4
r10 = 1;
- a = sub_8091818(1, a, 0, gPokedexView->unk60C - 1);
+ a = sub_8091818(1, a, 0, gPokedexView->pokemonListCount - 1);
sub_808E398(1, a);
//_0808E60E
sub_808DBE8(1, a, b);
- PlaySE(SE_Z_SCROLL);
+ PlaySE(0x6C);
+ goto _0808E5A2;
}
- //_0808E60E
- goto _0808E5A2;
-
- _0808E628:
+ //_0808E628
r5 = gUnknown_083A05EC[gPokedexView->unk638 / 4];
r3 = gUnknown_083A05F1[gPokedexView->unk638 / 4];
gPokedexView->unk62E = r3;
gPokedexView->unk636 = r3;
gPokedexView->unk634 = r5;
gPokedexView->unk62F = r10;
- gPokedexView->unk628 = r5;
+ gPokedexView->unk628 = r5 / 2;
sub_808E208(gPokedexView->unk62F, gPokedexView->unk634, gPokedexView->unk636);
if (gPokedexView->unk638 <= 0xB)
gPokedexView->unk638++;
return a;
}
-#else
-__attribute__((naked))
-u16 sub_808E48C(u16 a, u16 b)
-{
- asm(".syntax unified\n\
- push {r4-r7,lr}\n\
- mov r7, r10\n\
- mov r6, r9\n\
- mov r5, r8\n\
- push {r5-r7}\n\
- lsls r0, 16\n\
- lsrs r7, r0, 16\n\
- lsls r1, 16\n\
- lsrs r4, r1, 16\n\
- movs r0, 0\n\
- mov r10, r0\n\
- ldr r1, _0808E52C\n\
- ldrh r2, [r1, 0x2C]\n\
- movs r0, 0x40\n\
- ands r0, r2\n\
- adds r3, r1, 0\n\
- cmp r0, 0\n\
- beq _0808E4B6\n\
- cmp r7, 0\n\
- beq _0808E4B6\n\
- b _0808E5E4\n\
-_0808E4B6:\n\
- movs r0, 0x80\n\
- ands r0, r2\n\
- cmp r0, 0\n\
- beq _0808E4CE\n\
- ldr r0, _0808E530\n\
- ldr r0, [r0]\n\
- ldr r1, _0808E534\n\
- adds r0, r1\n\
- ldrh r0, [r0]\n\
- subs r0, 0x1\n\
- cmp r7, r0\n\
- blt _0808E5C4\n\
-_0808E4CE:\n\
- ldrh r1, [r3, 0x2E]\n\
- movs r0, 0x20\n\
- ands r0, r1\n\
- cmp r0, 0\n\
- beq _0808E53C\n\
- cmp r7, 0\n\
- beq _0808E53C\n\
- adds r6, r7, 0\n\
- movs r4, 0\n\
-_0808E4E0:\n\
- ldr r5, _0808E530\n\
- ldr r0, [r5]\n\
- ldr r2, _0808E534\n\
- adds r0, r2\n\
- ldrh r3, [r0]\n\
- subs r3, 0x1\n\
- lsls r3, 16\n\
- lsrs r3, 16\n\
- movs r0, 0x1\n\
- adds r1, r7, 0\n\
- movs r2, 0\n\
- bl sub_8091818\n\
- adds r7, r0, 0\n\
- adds r0, r4, 0x1\n\
- lsls r0, 24\n\
- lsrs r4, r0, 24\n\
- cmp r4, 0x6\n\
- bls _0808E4E0\n\
- ldr r1, [r5]\n\
- ldr r3, _0808E538\n\
- adds r1, r3\n\
- subs r0, r7, r6\n\
- lsls r0, 4\n\
- ldrb r2, [r1]\n\
- adds r0, r2\n\
- strb r0, [r1]\n\
- bl sub_808E82C\n\
- adds r0, r7, 0\n\
- movs r1, 0xE\n\
- bl sub_808E0CC\n\
- movs r0, 0x6D\n\
- bl PlaySE\n\
- b _0808E5A2\n\
- .align 2, 0\n\
-_0808E52C: .4byte gMain\n\
-_0808E530: .4byte gPokedexView\n\
-_0808E534: .4byte 0x0000060c\n\
-_0808E538: .4byte 0x0000062c\n\
-_0808E53C:\n\
- ldrh r1, [r3, 0x2E]\n\
- movs r0, 0x10\n\
- ands r0, r1\n\
- cmp r0, 0\n\
- beq _0808E5A2\n\
- ldr r0, _0808E5B8\n\
- ldr r0, [r0]\n\
- ldr r3, _0808E5BC\n\
- adds r0, r3\n\
- ldrh r0, [r0]\n\
- subs r0, 0x1\n\
- cmp r7, r0\n\
- bge _0808E5A2\n\
- adds r6, r7, 0\n\
- movs r4, 0\n\
-_0808E55A:\n\
- ldr r5, _0808E5B8\n\
- ldr r0, [r5]\n\
- ldr r1, _0808E5BC\n\
- adds r0, r1\n\
- ldrh r3, [r0]\n\
- subs r3, 0x1\n\
- lsls r3, 16\n\
- lsrs r3, 16\n\
- movs r0, 0\n\
- adds r1, r7, 0\n\
- movs r2, 0\n\
- bl sub_8091818\n\
- adds r7, r0, 0\n\
- adds r0, r4, 0x1\n\
- lsls r0, 24\n\
- lsrs r4, r0, 24\n\
- cmp r4, 0x6\n\
- bls _0808E55A\n\
- ldr r1, [r5]\n\
- ldr r2, _0808E5C0\n\
- adds r1, r2\n\
- subs r0, r7, r6\n\
- lsls r0, 4\n\
- ldrb r3, [r1]\n\
- adds r0, r3\n\
- strb r0, [r1]\n\
- bl sub_808E82C\n\
- adds r0, r7, 0\n\
- movs r1, 0xE\n\
- bl sub_808E0CC\n\
- movs r0, 0x6D\n\
- bl PlaySE\n\
-_0808E5A2:\n\
- mov r0, r10\n\
- cmp r0, 0\n\
- bne _0808E628\n\
- ldr r0, _0808E5B8\n\
- ldr r0, [r0]\n\
- movs r1, 0xC7\n\
- lsls r1, 3\n\
- adds r0, r1\n\
- mov r2, r10\n\
- strh r2, [r0]\n\
- b _0808E68E\n\
- .align 2, 0\n\
-_0808E5B8: .4byte gPokedexView\n\
-_0808E5BC: .4byte 0x0000060c\n\
-_0808E5C0: .4byte 0x0000062c\n\
-_0808E5C4:\n\
- movs r3, 0x2\n\
- mov r10, r3\n\
- lsls r3, r0, 16\n\
- lsrs r3, 16\n\
- movs r0, 0\n\
- adds r1, r7, 0\n\
- movs r2, 0\n\
- bl sub_8091818\n\
- adds r7, r0, 0\n\
- movs r0, 0x2\n\
- adds r1, r7, 0\n\
- bl sub_808E398\n\
- movs r0, 0x2\n\
- b _0808E60E\n\
-_0808E5E4:\n\
- movs r0, 0x1\n\
- mov r10, r0\n\
- ldr r0, _0808E620\n\
- ldr r0, [r0]\n\
- ldr r1, _0808E624\n\
- adds r0, r1\n\
- ldrh r3, [r0]\n\
- subs r3, 0x1\n\
- lsls r3, 16\n\
- lsrs r3, 16\n\
- movs r0, 0x1\n\
- adds r1, r7, 0\n\
- movs r2, 0\n\
- bl sub_8091818\n\
- adds r7, r0, 0\n\
- movs r0, 0x1\n\
- adds r1, r7, 0\n\
- bl sub_808E398\n\
- movs r0, 0x1\n\
-_0808E60E:\n\
- adds r1, r7, 0\n\
- adds r2, r4, 0\n\
- bl sub_808DBE8\n\
- movs r0, 0x6C\n\
- bl PlaySE\n\
- b _0808E5A2\n\
- .align 2, 0\n\
-_0808E620: .4byte gPokedexView\n\
-_0808E624: .4byte 0x0000060c\n\
-_0808E628:\n\
- ldr r1, _0808E6A0\n\
- ldr r6, _0808E6A4\n\
- ldr r2, [r6]\n\
- movs r3, 0xC7\n\
- lsls r3, 3\n\
- mov r9, r3\n\
- adds r0, r2, r3\n\
- ldrh r0, [r0]\n\
- lsrs r0, 2\n\
- adds r1, r0, r1\n\
- ldrb r5, [r1]\n\
- ldr r1, _0808E6A8\n\
- adds r0, r1\n\
- ldrb r3, [r0]\n\
- ldr r0, _0808E6AC\n\
- adds r2, r0\n\
- strb r3, [r2]\n\
- ldr r1, [r6]\n\
- ldr r2, _0808E6B0\n\
- mov r8, r2\n\
- adds r0, r1, r2\n\
- strh r3, [r0]\n\
- ldr r4, _0808E6B4\n\
- adds r0, r1, r4\n\
- strh r5, [r0]\n\
- ldr r3, _0808E6B8\n\
- adds r1, r3\n\
- mov r0, r10\n\
- strb r0, [r1]\n\
- ldr r2, [r6]\n\
- lsrs r5, 1\n\
- movs r1, 0xC5\n\
- lsls r1, 3\n\
- adds r0, r2, r1\n\
- strh r5, [r0]\n\
- adds r3, r2, r3\n\
- ldrb r0, [r3]\n\
- adds r4, r2, r4\n\
- ldrb r1, [r4]\n\
- add r2, r8\n\
- ldrb r2, [r2]\n\
- bl sub_808E208\n\
- ldr r0, [r6]\n\
- mov r2, r9\n\
- adds r1, r0, r2\n\
- ldrh r0, [r1]\n\
- cmp r0, 0xB\n\
- bhi _0808E68E\n\
- adds r0, 0x1\n\
- strh r0, [r1]\n\
-_0808E68E:\n\
- adds r0, r7, 0\n\
- pop {r3-r5}\n\
- mov r8, r3\n\
- mov r9, r4\n\
- mov r10, r5\n\
- pop {r4-r7}\n\
- pop {r1}\n\
- bx r1\n\
- .align 2, 0\n\
-_0808E6A0: .4byte gUnknown_083A05EC\n\
-_0808E6A4: .4byte gPokedexView\n\
-_0808E6A8: .4byte gUnknown_083A05F1\n\
-_0808E6AC: .4byte 0x0000062e\n\
-_0808E6B0: .4byte 0x00000636\n\
-_0808E6B4: .4byte 0x00000634\n\
-_0808E6B8: .4byte 0x0000062f\n\
- .syntax divided\n");
-}
-#endif
-void sub_808E6BC(void)
+static void sub_808E6BC(void)
{
u16 i;
@@ -1703,11 +2496,11 @@ void sub_808E6BC(void)
u16 spriteId = gPokedexView->unk61E[i];
if (gSprites[spriteId].pos2.x == 0 && gSprites[spriteId].pos2.y == 0 && spriteId != 0xFFFF)
- gPokedexView->unk626 = spriteId;
+ gPokedexView->selectedMonSpriteId = spriteId;
}
}
-u8 sub_808E71C(void)
+static u8 sub_808E71C(void)
{
u16 r2;
u16 r4 = gPokedexView->selectedPokemon;
@@ -1717,7 +2510,7 @@ u8 sub_808E71C(void)
r2 = r4;
while (r2 != 0)
{
- r2 = sub_8091818(1, r2, 0, gPokedexView->unk60C - 1);
+ r2 = sub_8091818(1, r2, 0, gPokedexView->pokemonListCount - 1);
if (gPokedexView->unk0[r2].seen)
{
@@ -1735,12 +2528,12 @@ u8 sub_808E71C(void)
return 1;
}
}
- else if ((gMain.newKeys & DPAD_DOWN) && r4 < gPokedexView->unk60C - 1)
+ else if ((gMain.newKeys & DPAD_DOWN) && r4 < gPokedexView->pokemonListCount - 1)
{
r2 = r4;
- while (r2 < gPokedexView->unk60C - 1)
+ while (r2 < gPokedexView->pokemonListCount - 1)
{
- r2 = sub_8091818(0, r2, 0, gPokedexView->unk60C - 1);
+ r2 = sub_8091818(0, r2, 0, gPokedexView->pokemonListCount - 1);
if (gPokedexView->unk0[r2].seen)
{
@@ -1761,7 +2554,7 @@ u8 sub_808E71C(void)
return 0;
}
-u8 sub_808E82C(void)
+static u8 sub_808E82C(void)
{
u16 i;
@@ -1776,9 +2569,9 @@ u8 sub_808E82C(void)
return 0;
}
-u16 sub_808E888(u16 a1)
+static u16 sub_808E888(u16 a1)
{
- if (a1 > 385 || gPokedexView->unk0[a1].dexNum == 0xFFFF)
+ if (a1 >= NATIONAL_DEX_COUNT || gPokedexView->unk0[a1].dexNum == 0xFFFF)
return 0xFFFF;
else if (gPokedexView->unk0[a1].seen)
return gPokedexView->unk0[a1].dexNum;
@@ -1786,7 +2579,7 @@ u16 sub_808E888(u16 a1)
return 0;
}
-u32 sub_808E8C8(u16 a, u16 b, u16 c)
+static u32 sub_808E8C8(u16 a, s16 b, s16 c)
{
u8 i;
@@ -1794,7 +2587,7 @@ u32 sub_808E8C8(u16 a, u16 b, u16 c)
{
if (gPokedexView->unk61E[i] == 0xFFFF)
{
- u8 spriteId = sub_80918EC(a, (s16)b, (s16)c, i);
+ u8 spriteId = sub_80918EC(a, b, c, i);
gSprites[spriteId].oam.affineMode = 1;
gSprites[spriteId].oam.priority = 3;
@@ -1808,38 +2601,38 @@ u32 sub_808E8C8(u16 a, u16 b, u16 c)
return 0xFFFF;
}
-void sub_808E978(u8 a)
+static void sub_808E978(u8 a)
{
u8 spriteId;
u16 r5;
- spriteId = CreateSprite(&gSpriteTemplate_83A053C, 0xB8, 4, 0);
+ spriteId = CreateSprite(&gSpriteTemplate_83A053C, 184, 4, 0);
gSprites[spriteId].data1 = 0;
- spriteId = CreateSprite(&gSpriteTemplate_83A053C, 0xB8, 0x9C, 0);
+ spriteId = CreateSprite(&gSpriteTemplate_83A053C, 184, 156, 0);
gSprites[spriteId].data1 = 1;
- gSprites[spriteId].vFlip = 1;
+ gSprites[spriteId].vFlip = TRUE;
- CreateSprite(&gSpriteTemplate_83A0524, 0xEA, 0x14, 0);
- CreateSprite(&gSpriteTemplate_83A0554, 0x10, 0x8A, 0);
+ CreateSprite(&gSpriteTemplate_83A0524, 234, 20, 0);
+ CreateSprite(&gSpriteTemplate_83A0554, 16, 138, 0);
- spriteId = CreateSprite(&gSpriteTemplate_83A0554, 0x30, 0x8A, 0);
+ spriteId = CreateSprite(&gSpriteTemplate_83A0554, 48, 138, 0);
StartSpriteAnim(&gSprites[spriteId], 3);
- spriteId = CreateSprite(&gSpriteTemplate_83A0554, 0x10, 0x9E, 0);
+ spriteId = CreateSprite(&gSpriteTemplate_83A0554, 16, 158, 0);
StartSpriteAnim(&gSprites[spriteId], 2);
gSprites[spriteId].data2 = 0x80;
- spriteId = CreateSprite(&gSpriteTemplate_83A0554, 0x30, 0x9E, 0);
+ spriteId = CreateSprite(&gSpriteTemplate_83A0554, 48, 158, 0);
StartSpriteAnim(&gSprites[spriteId], 1);
- spriteId = CreateSprite(&gSpriteTemplate_83A056C, 0, 0x50, 2);
+ spriteId = CreateSprite(&gSpriteTemplate_83A056C, 0, 80, 2);
gSprites[spriteId].oam.affineMode = 1;
gSprites[spriteId].oam.matrixNum = 30;
gSprites[spriteId].data0 = 0x1E;
gSprites[spriteId].data1 = 0;
- spriteId = CreateSprite(&gSpriteTemplate_83A056C, 0, 0x50, 2);
+ spriteId = CreateSprite(&gSpriteTemplate_83A056C, 0, 80, 2);
gSprites[spriteId].oam.affineMode = 1;
gSprites[spriteId].oam.matrixNum = 31;
gSprites[spriteId].data0 = 0x1F;
@@ -1849,95 +2642,97 @@ void sub_808E978(u8 a)
{
u32 _a;
- CreateSprite(&gSpriteTemplate_83A0584, 0x20, 0x28, 1);
+ CreateSprite(&gSpriteTemplate_83A0584, 32, 40, 1);
- spriteId = CreateSprite(&gSpriteTemplate_83A0584, 0x20, 0x48, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A0584, 32, 72, 1);
StartSpriteAnim(&gSprites[spriteId], 1);
_a = 0;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x1C, 0x30, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 28, 48, 1);
r5 = gPokedexView->unk61A / 100;
StartSpriteAnim(&gSprites[spriteId], r5);
if (r5 != 0)
_a = 1;
else
- gSprites[spriteId].invisible = 1;
+ gSprites[spriteId].invisible = TRUE;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x22, 0x30, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 34, 48, 1);
r5 = (gPokedexView->unk61A % 100) / 10;
if (r5 != 0 || _a != 0)
StartSpriteAnim(&gSprites[spriteId], r5);
else
- gSprites[spriteId].invisible = 1;
+ gSprites[spriteId].invisible = TRUE;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x28, 0x30, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 40, 48, 1);
r5 = (gPokedexView->unk61A % 100) % 10;
StartSpriteAnim(&gSprites[spriteId], r5);
_a = 0;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x1C, 0x50, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 28, 80, 1);
r5 = gPokedexView->unk61C / 100;
StartSpriteAnim(&gSprites[spriteId], r5);
if (r5 != 0)
_a = 1;
else
- gSprites[spriteId].invisible = 1;
+ gSprites[spriteId].invisible = TRUE;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x22, 0x50, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 34, 80, 1);
r5 = (gPokedexView->unk61C % 100) / 10;
if (r5 != 0 || _a != 0)
StartSpriteAnim(&gSprites[spriteId], r5);
else
- gSprites[spriteId].invisible = 1;
+ gSprites[spriteId].invisible = TRUE;
- spriteId = CreateSprite(&gSpriteTemplate_83A059C, 0x28, 0x50, 1);
+ spriteId = CreateSprite(&gSpriteTemplate_83A059C, 40, 80, 1);
r5 = (gPokedexView->unk61C % 100) % 10;
StartSpriteAnim(&gSprites[spriteId], r5);
- spriteId = CreateSprite(&gSpriteTemplate_83A05B4, 0x8C, 0x60, 1);
- gSprites[spriteId].invisible = 1;
+ spriteId = CreateSprite(&gSpriteTemplate_83A05B4, 140, 96, 1);
+ gSprites[spriteId].invisible = TRUE;
}
else
{
- spriteId = CreateSprite(&gSpriteTemplate_83A05B4, 0x8C, 0x50, 1);
- gSprites[spriteId].invisible = 1;
+ spriteId = CreateSprite(&gSpriteTemplate_83A05B4, 140, 80, 1);
+ gSprites[spriteId].invisible = TRUE;
}
}
-void nullsub_58(struct Sprite *sprite)
+static void nullsub_58(struct Sprite *sprite)
{
}
-void sub_808ED94(struct Sprite *sprite)
+static void sub_808ED94(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0)
DestroySprite(sprite);
}
//Move Pokemon into position for description page
-void sub_808EDB8(struct Sprite *sprite)
+static void sub_808EDB8(struct Sprite *sprite)
{
sprite->oam.priority = 0;
sprite->oam.affineMode = 0;
sprite->pos2.x = 0;
sprite->pos2.y = 0;
- if (sprite->pos1.x != 0x30 || sprite->pos1.y != 0x38)
+ if (sprite->pos1.x != 48 || sprite->pos1.y != 56)
{
- if (sprite->pos1.x > 0x30)
+ if (sprite->pos1.x > 48)
sprite->pos1.x--;
- if (sprite->pos1.x < 0x30)
+ if (sprite->pos1.x < 48)
sprite->pos1.x++;
- if (sprite->pos1.y > 0x38)
+
+ if (sprite->pos1.y > 56)
sprite->pos1.y--;
- if (sprite->pos1.y <0x38)
+ if (sprite->pos1.y < 56)
sprite->pos1.y++;
}
- //_0808EE1C
else
+ {
sprite->callback = nullsub_58;
+ }
}
-void sub_808EE28(struct Sprite *sprite)
+static void sub_808EE28(struct Sprite *sprite)
{
u8 data1 = sprite->data1;
@@ -1948,223 +2743,132 @@ void sub_808EE28(struct Sprite *sprite)
}
else
{
- //_0808EE58
- s32 var;
+ u32 var;
sprite->pos2.y = gSineTable[(u8)sprite->data5] * 76 / 256;
var = 0x10000 / gSineTable[sprite->data5 + 0x40];
- if ((u32)var > 0xFFFF)
+ if (var > 0xFFFF)
var = 0xFFFF;
SetOamMatrix(sprite->data1 + 1, 0x100, 0, 0, var);
sprite->oam.matrixNum = data1 + 1;
- //ToDo: clean up these inequalities
- if ((u16)(sprite->data5 + 0x3F) <= 0x7E)
+ if (sprite->data5 > -64 && sprite->data5 < 64)
{
- sprite->invisible = 0;
+ sprite->invisible = FALSE;
sprite->data0 = 1;
}
else
{
- sprite->invisible = 1;
+ sprite->invisible = TRUE;
}
- //_0808EEF8
- if ((u16)(sprite->data5 + 0x3F) > 0x7E && sprite->data0 != 0)
+
+ if ((sprite->data5 <= -64 || sprite->data5 >= 64) && sprite->data0 != 0)
{
DestroySprite(sprite);
gPokedexView->unk61E[data1] = 0xFFFF;
}
}
- //_0808EF16
}
-void sub_808EF38(struct Sprite *sprite)
+static void sub_808EF38(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0 && gPokedexView->unk64A != 3)
DestroySprite(sprite);
else
- sprite->pos2.y = gPokedexView->selectedPokemon * 120 / (gPokedexView->unk60C - 1);
+ sprite->pos2.y = gPokedexView->selectedPokemon * 120 / (gPokedexView->pokemonListCount - 1);
}
-void sub_808EF8C(struct Sprite *sprite)
+static void sub_808EF8C(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0 && gPokedexView->unk64A != 3)
+ {
DestroySprite(sprite);
+ }
else
{
u8 r0;
if (sprite->data1 != 0)
{
- if (gPokedexView->selectedPokemon == gPokedexView->unk60C - 1)
- sprite->invisible = 1;
+ if (gPokedexView->selectedPokemon == gPokedexView->pokemonListCount - 1)
+ sprite->invisible = TRUE;
else
- sprite->invisible = 0;
+ sprite->invisible = FALSE;
r0 = sprite->data2;
}
else
{
if (gPokedexView->selectedPokemon == 0)
- sprite->invisible = 1;
+ sprite->invisible = TRUE;
else
- sprite->invisible = 0;
- r0 = sprite->data2 - 0x80;
+ sprite->invisible = FALSE;
+ r0 = sprite->data2 - 128;
}
sprite->pos2.y = gSineTable[r0] / 64;
sprite->data2 = sprite->data2 + 8;
if (gPokedexView->menuIsOpen == 0 && gPokedexView->menuY == 0 && sprite->invisible == 0)
- sprite->invisible = 0;
+ sprite->invisible = FALSE;
else
- sprite->invisible = 1;
+ sprite->invisible = TRUE;
}
}
-void sub_808F08C(struct Sprite *sprite)
+static void sub_808F08C(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0 && gPokedexView->unk64A != 3)
DestroySprite(sprite);
}
-#ifdef NONMATCHING
-void sub_808F0B4(struct Sprite *sprite)
+static void sub_808F0B4(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0 && gPokedexView->unk64A != 3)
+ {
DestroySprite(sprite);
+ }
else
{
+ u8 val;
s16 r3;
+ s16 r0;
- u8 unk = gPokedexView->unk62C + sprite->data1;
- u16 foo = gSineTable[unk];
- //u8 unk2 = sprite->data0;
- //u16 bar = gSineTable[unk + 0x40];
-
- SetOamMatrix(sprite->data0, foo, gSineTable[unk + 0x40], (-(u16)foo) >> 16, gSineTable[unk + 0x40]);
+ val = gPokedexView->unk62C + sprite->data1;
+ r3 = gSineTable[val];
+ r0 = gSineTable[val + 0x40];
+ SetOamMatrix(sprite->data0, r0, r3, -r3, r0);
- r3 = gSineTable[sprite->data1 + gPokedexView->unk62C];
- sprite->pos2.x = gSineTable[sprite->data1 + gPokedexView->unk62C + 0x40] * 5 / 256;
+ val = gPokedexView->unk62C + (sprite->data1 + 0x40);
+ r3 = gSineTable[val];
+ r0 = gSineTable[val + 0x40];
+ sprite->pos2.x = r0 * 40 / 256;
sprite->pos2.y = r3 * 40 / 256;
}
}
-#else
-__attribute__((naked))
-void sub_808F0B4(struct Sprite *sprite)
-{
- asm(".syntax unified\n\
- push {r4-r7,lr}\n\
- sub sp, 0x4\n\
- adds r6, r0, 0\n\
- ldr r1, _0808F0D8 @ =gPokedexView\n\
- ldr r0, [r1]\n\
- ldr r2, _0808F0DC @ =0x0000064a\n\
- adds r0, r2\n\
- ldrb r0, [r0]\n\
- adds r7, r1, 0\n\
- cmp r0, 0\n\
- beq _0808F0E0\n\
- cmp r0, 0x3\n\
- beq _0808F0E0\n\
- adds r0, r6, 0\n\
- bl DestroySprite\n\
- b _0808F158\n\
- .align 2, 0\n\
-_0808F0D8: .4byte gPokedexView\n\
-_0808F0DC: .4byte 0x0000064a\n\
-_0808F0E0:\n\
- ldr r0, [r7]\n\
- ldr r5, _0808F160 @ =0x0000062c\n\
- adds r0, r5\n\
- ldrb r1, [r0]\n\
- ldrh r0, [r6, 0x30]\n\
- adds r1, r0\n\
- lsls r1, 24\n\
- lsrs r1, 24\n\
- ldr r4, _0808F164 @ =gSineTable\n\
- lsls r0, r1, 1\n\
- adds r0, r4\n\
- ldrh r3, [r0]\n\
- adds r1, 0x40\n\
- lsls r1, 1\n\
- adds r1, r4\n\
- ldrh r0, [r6, 0x2E]\n\
- lsls r0, 24\n\
- lsrs r0, 24\n\
- ldrh r1, [r1]\n\
- lsls r3, 16\n\
- lsrs r2, r3, 16\n\
- negs r3, r3\n\
- lsrs r3, 16\n\
- str r1, [sp]\n\
- bl SetOamMatrix\n\
- ldr r1, [r7]\n\
- adds r1, r5\n\
- ldrh r0, [r6, 0x30]\n\
- adds r0, 0x40\n\
- ldrb r1, [r1]\n\
- adds r0, r1\n\
- lsls r0, 24\n\
- lsrs r0, 24\n\
- lsls r1, r0, 1\n\
- adds r1, r4\n\
- ldrh r3, [r1]\n\
- adds r0, 0x40\n\
- lsls r0, 1\n\
- adds r0, r4\n\
- movs r2, 0\n\
- ldrsh r1, [r0, r2]\n\
- lsls r0, r1, 2\n\
- adds r0, r1\n\
- lsls r0, 3\n\
- cmp r0, 0\n\
- bge _0808F140\n\
- adds r0, 0xFF\n\
-_0808F140:\n\
- asrs r0, 8\n\
- strh r0, [r6, 0x24]\n\
- lsls r1, r3, 16\n\
- asrs r1, 16\n\
- lsls r0, r1, 2\n\
- adds r0, r1\n\
- lsls r0, 3\n\
- cmp r0, 0\n\
- bge _0808F154\n\
- adds r0, 0xFF\n\
-_0808F154:\n\
- asrs r0, 8\n\
- strh r0, [r6, 0x26]\n\
-_0808F158:\n\
- add sp, 0x4\n\
- pop {r4-r7}\n\
- pop {r0}\n\
- bx r0\n\
- .align 2, 0\n\
-_0808F160: .4byte 0x0000062c\n\
-_0808F164: .4byte gSineTable\n\
- .syntax divided\n");
-}
-#endif
-void sub_808F168(struct Sprite *sprite)
+static void sub_808F168(struct Sprite *sprite)
{
if (gPokedexView->unk64A != 0 && gPokedexView->unk64A != 3)
+ {
DestroySprite(sprite);
+ }
else
{
- u16 r1 = gPokedexView->unk64A == 0 ? 0x50 : 0x60;
+ u16 r1 = gPokedexView->unk64A == 0 ? 80 : 96;
if (gPokedexView->menuIsOpen != 0 && gPokedexView->menuY == r1)
{
- sprite->invisible = 0;
+ sprite->invisible = FALSE;
sprite->pos2.y = gPokedexView->menuCursorPos * 16;
sprite->pos2.x = gSineTable[(u8)sprite->data2] / 64;
sprite->data2 += 8;
}
else
- sprite->invisible = 1;
+ {
+ sprite->invisible = TRUE;
+ }
}
}
-u8 sub_808F210(struct PokedexListItem *item, u8 b)
+static u8 sub_808F210(struct PokedexListItem *item, u8 b)
{
u8 taskId;
@@ -2178,15 +2882,15 @@ u8 sub_808F210(struct PokedexListItem *item, u8 b)
return taskId;
}
-bool8 sub_808F250(u8 taskId)
+static bool8 sub_808F250(u8 taskId)
{
if (gTasks[taskId].data[0] == 0 && gTasks[taskId].func == Task_PageScreenProcessInput)
- return 0;
+ return FALSE;
else
- return 1;
+ return TRUE;
}
-u8 sub_808F284(struct PokedexListItem *item, u8 b)
+static u8 sub_808F284(struct PokedexListItem *item, u8 b)
{
gUnknown_0202FFBC = item;
gTasks[b].data[0] = 1;
@@ -2196,7 +2900,7 @@ u8 sub_808F284(struct PokedexListItem *item, u8 b)
return b;
}
-void Task_InitPageScreenMultistep(u8 taskId)
+static void Task_InitPageScreenMultistep(u8 taskId)
{
switch (gMain.state)
{
@@ -2207,7 +2911,7 @@ void Task_InitPageScreenMultistep(u8 taskId)
u16 r2;
gPokedexView->unk64A = 1;
- gPokedexView->unk64E = 0;
+ gPokedexView->descriptionPageNum = 0;
gUnknown_03005CEC = gMain.vblankCallback;
SetVBlankCallback(NULL);
r2 = 0;
@@ -2241,7 +2945,6 @@ void Task_InitPageScreenMultistep(u8 taskId)
sub_8091154(NationalToHoennOrder(gUnknown_0202FFBC->dexNum), 0xD, 3);
else
sub_8091154(gUnknown_0202FFBC->dexNum, 0xD, 3);
- //_0808F45A
sub_80911C8(gUnknown_0202FFBC->dexNum, 0x10, 3);
MenuPrint(gDexText_UnknownPoke, 11, 5);
MenuPrint(gDexText_UnknownHeight, 16, 7);
@@ -2254,7 +2957,6 @@ void Task_InitPageScreenMultistep(u8 taskId)
MenuPrint(gPokedexEntries[gUnknown_0202FFBC->dexNum].descriptionPage1, 2, 13);
sub_80917CC(14, 0x3FC);
}
- //_0808F50C
else
{
MenuPrint(gUnknown_083A05F8, 2, 13);
@@ -2265,27 +2967,24 @@ void Task_InitPageScreenMultistep(u8 taskId)
case 5:
if (gTasks[taskId].data[1] == 0)
{
- //_0808F540
gTasks[taskId].data[4] = (u16)sub_80918EC(gUnknown_0202FFBC->dexNum, 0x30, 0x38, 0);
gSprites[gTasks[taskId].data[4]].oam.priority = 0;
}
gMain.state++;
break;
case 6:
- {
- u32 r3 = 0;
-
- if (gTasks[taskId].data[2] != 0)
- r3 = 0x14;
- if (gTasks[taskId].data[1] != 0)
{
- r3 |= (1 << (gSprites[gTasks[taskId].data[4]].oam.paletteNum + 0x10));
+ u32 r3 = 0;
+
+ if (gTasks[taskId].data[2] != 0)
+ r3 = 0x14;
+ if (gTasks[taskId].data[1] != 0)
+ r3 |= (1 << (gSprites[gTasks[taskId].data[4]].oam.paletteNum + 16));
+ BeginNormalPaletteFade(~r3, 0, 16, 0, 0);
+ SetVBlankCallback(gUnknown_03005CEC);
+ gMain.state++;
}
- BeginNormalPaletteFade(~r3, 0, 0x10, 0, 0);
- SetVBlankCallback(gUnknown_03005CEC);
- gMain.state++;
break;
- }
case 7:
REG_BLDCNT = 0;
REG_BLDALPHA = 0;
@@ -2305,7 +3004,9 @@ void Task_InitPageScreenMultistep(u8 taskId)
PlayCry2(NationalPokedexNumToSpecies(gUnknown_0202FFBC->dexNum), 0, 0x7D, 0xA);
}
else
+ {
gMain.state++;
+ }
}
break;
case 9:
@@ -2323,21 +3024,23 @@ void Task_InitPageScreenMultistep(u8 taskId)
}
}
-void Task_PageScreenProcessInput(u8 taskId)
+static void Task_PageScreenProcessInput(u8 taskId)
{
if (gTasks[taskId].data[0] != 0)
{
- BeginNormalPaletteFade(-1, 0, 0, 0x10, 0);
+ BeginNormalPaletteFade(-1, 0, 0, 16, 0);
gTasks[taskId].func = sub_808F888;
PlaySE(SE_Z_SCROLL);
+ return;
}
- else if (gMain.newKeys & B_BUTTON)
+ if (gMain.newKeys & B_BUTTON)
{
- BeginNormalPaletteFade(-1, 0, 0, 0x10, 0);
+ BeginNormalPaletteFade(-1, 0, 0, 16, 0);
gTasks[taskId].func = Task_ClosePageScreen;
PlaySE(SE_PC_OFF);
+ return;
}
- else if (gMain.newKeys & A_BUTTON)
+ if (gMain.newKeys & A_BUTTON)
{
switch (gPokedexView->selectedScreen)
{
@@ -2356,7 +3059,9 @@ void Task_PageScreenProcessInput(u8 taskId)
break;
case SIZE_SCREEN:
if (!gUnknown_0202FFBC->owned)
+ {
PlaySE(SE_HAZURE);
+ }
else
{
BeginNormalPaletteFade(-0x15, 0, 0, 0x10, 0);
@@ -2365,38 +3070,41 @@ void Task_PageScreenProcessInput(u8 taskId)
}
break;
}
+ return;
}
- else if (((gMain.newKeys & DPAD_LEFT)
+ if (((gMain.newKeys & DPAD_LEFT)
|| ((gMain.newKeys & L_BUTTON) && gSaveBlock2.optionsButtonMode == OPTIONS_BUTTON_MODE_LR))
&& gPokedexView->selectedScreen > 0)
{
gPokedexView->selectedScreen--;
sub_8090584(gPokedexView->selectedScreen, 0xD);
PlaySE(SE_Z_PAGE);
+ return;
}
- else if (((gMain.newKeys & DPAD_RIGHT)
+ if (((gMain.newKeys & DPAD_RIGHT)
|| ((gMain.newKeys & R_BUTTON) && gSaveBlock2.optionsButtonMode == OPTIONS_BUTTON_MODE_LR))
&& gPokedexView->selectedScreen < 3)
{
gPokedexView->selectedScreen++;
sub_8090584(gPokedexView->selectedScreen, 0xD);
PlaySE(SE_Z_PAGE);
+ return;
}
}
-void sub_808F888(u8 taskId)
+static void sub_808F888(u8 taskId)
{
if (!gPaletteFade.active)
gTasks[taskId].func = Task_InitPageScreenMultistep;
}
-void Task_ClosePageScreen(u8 taskId)
+static void Task_ClosePageScreen(u8 taskId)
{
if (!gPaletteFade.active)
DestroyTask(taskId);
}
-void Task_InitAreaScreenMultistep(u8 taskId)
+static void Task_InitAreaScreenMultistep(u8 taskId)
{
switch (gMain.state)
{
@@ -2429,13 +3137,13 @@ void Task_InitAreaScreenMultistep(u8 taskId)
}
}
-void Task_AreaScreenProcessInput(u8 taskId)
+static void Task_AreaScreenProcessInput(u8 taskId)
{
if (gPokedexView->unk64F != 0)
gTasks[taskId].func = sub_808FA00;
}
-void sub_808FA00(u8 taskId)
+static void sub_808FA00(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -2452,7 +3160,7 @@ void sub_808FA00(u8 taskId)
}
}
-void Task_InitCryScreenMultistep(u8 taskId)
+static void Task_InitCryScreenMultistep(u8 taskId)
{
switch (gMain.state)
{
@@ -2499,36 +3207,34 @@ void Task_InitCryScreenMultistep(u8 taskId)
gMain.state++;
break;
case 6:
- {
- struct CryRelatedStruct sp8;
-
- sp8.unk0 = 0x4020;
- sp8.unk2 = 0x1F;
- sp8.paletteNo = 8;
- sp8.yPos = 0x1E;
- sp8.xPos = 0xC;
- if (sub_8119E3C(&sp8, 0) != 0)
{
- gMain.state++;
- gUnknown_03005E98 = 0;
+ struct CryRelatedStruct sp8;
+
+ sp8.unk0 = 0x4020;
+ sp8.unk2 = 0x1F;
+ sp8.paletteNo = 8;
+ sp8.yPos = 0x1E;
+ sp8.xPos = 0xC;
+ if (sub_8119E3C(&sp8, 0) != 0)
+ {
+ gMain.state++;
+ gUnknown_03005E98 = 0;
+ }
}
break;
- }
case 7:
- {
- struct CryRelatedStruct sp10;
-
- sp10.unk0 = 0x3000;
- sp10.unk2 = 0xE;
- sp10.paletteNo = 9;
- sp10.xPos = 0x12;
- sp10.yPos = 3;
- if (ShowPokedexCryScreen(&sp10, 1) != 0)
{
- gMain.state++;
+ struct CryRelatedStruct sp10;
+
+ sp10.unk0 = 0x3000;
+ sp10.unk2 = 0xE;
+ sp10.paletteNo = 9;
+ sp10.xPos = 0x12;
+ sp10.yPos = 3;
+ if (ShowPokedexCryScreen(&sp10, 1) != 0)
+ gMain.state++;
}
break;
- }
case 8:
BeginNormalPaletteFade(-0x15, 0, 0x10, 0, 0);
SetVBlankCallback(gUnknown_03005CEC);
@@ -2552,7 +3258,7 @@ void Task_InitCryScreenMultistep(u8 taskId)
}
}
-void Task_CryScreenProcessInput(u8 taskId)
+static void Task_CryScreenProcessInput(u8 taskId)
{
sub_8119F88(0);
@@ -2576,8 +3282,9 @@ void Task_CryScreenProcessInput(u8 taskId)
gPokedexView->unk64F = 1;
gTasks[taskId].func = sub_808FFBC;
PlaySE(SE_PC_OFF);
+ return;
}
- else if ((gMain.newKeys & DPAD_LEFT)
+ if ((gMain.newKeys & DPAD_LEFT)
|| ((gMain.newKeys & L_BUTTON) && gSaveBlock2.optionsButtonMode == OPTIONS_BUTTON_MODE_LR))
{
BeginNormalPaletteFade(-0x15, 0, 0, 0x10, 0);
@@ -2585,12 +3292,15 @@ void Task_CryScreenProcessInput(u8 taskId)
gPokedexView->unk64F = 2;
gTasks[taskId].func = sub_808FFBC;
PlaySE(SE_Z_PAGE);
+ return;
}
- else if ((gMain.newKeys & DPAD_RIGHT)
+ if ((gMain.newKeys & DPAD_RIGHT)
|| ((gMain.newKeys & R_BUTTON) && gSaveBlock2.optionsButtonMode == OPTIONS_BUTTON_MODE_LR))
{
if (!gUnknown_0202FFBC->owned)
+ {
PlaySE(SE_HAZURE);
+ }
else
{
BeginNormalPaletteFade(-0x15, 0, 0, 0x10, 0);
@@ -2599,11 +3309,12 @@ void Task_CryScreenProcessInput(u8 taskId)
gTasks[taskId].func = sub_808FFBC;
PlaySE(SE_Z_PAGE);
}
+ return;
}
}
}
-void sub_808FFBC(u8 taskId)
+static void sub_808FFBC(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -2619,11 +3330,12 @@ void sub_808FFBC(u8 taskId)
break;
case 3:
gTasks[taskId].func = Task_InitSizeScreenMultistep;
+ break;
}
}
}
-void sub_8090040(u8 a)
+static void sub_8090040(u8 a)
{
u16 unk;
@@ -2634,7 +3346,7 @@ void sub_8090040(u8 a)
LoadPalette(&unk, 0x5D, 2);
}
-void Task_InitSizeScreenMultistep(u8 taskId)
+static void Task_InitSizeScreenMultistep(u8 taskId)
{
u8 spriteId;
@@ -2664,40 +3376,40 @@ void Task_InitSizeScreenMultistep(u8 taskId)
gMain.state++;
break;
case 3:
- {
- u8 string[40]; //I hope this is the correct size
-
- SetUpWindowConfig(&gWindowConfig_81E702C);
- InitMenuWindow(&gWindowConfig_81E702C);
- string[0] = EOS;
- StringAppend(string, gDexText_SizeComparedTo);
- StringAppend(string, gSaveBlock2.playerName);
- sub_8072BD8(string, 3, 15, 0xC0);
- gMain.state++;
+ {
+ u8 string[40]; //I hope this is the correct size
+
+ SetUpWindowConfig(&gWindowConfig_81E702C);
+ InitMenuWindow(&gWindowConfig_81E702C);
+ string[0] = EOS;
+ StringAppend(string, gDexText_SizeComparedTo);
+ StringAppend(string, gSaveBlock2.playerName);
+ sub_8072BD8(string, 3, 15, 0xC0);
+ gMain.state++;
+ }
break;
- }
case 4:
ResetPaletteFade();
gMain.state++;
break;
case 5:
- spriteId = sub_8091A4C(gSaveBlock2.playerGender, 0x98, 0x38, 0);
+ spriteId = sub_8091A4C(gSaveBlock2.playerGender, 152, 56, 0);
gSprites[spriteId].oam.affineMode = 1;
gSprites[spriteId].oam.matrixNum = 1;
gSprites[spriteId].oam.priority = 0;
gSprites[spriteId].pos2.y = gPokedexEntries[gUnknown_0202FFBC->dexNum].trainerOffset;
SetOamMatrix(1, gPokedexEntries[gUnknown_0202FFBC->dexNum].trainerScale, 0, 0, gPokedexEntries[gUnknown_0202FFBC->dexNum].trainerScale);
- LoadPalette(gUnknown_083B4EC4, (gSprites[spriteId].oam.paletteNum + 16) * 16, 0x20);
+ LoadPalette(gUnknown_083B4EC4, (gSprites[spriteId].oam.paletteNum + 16) * 16, sizeof(gUnknown_083B4EC4));
gMain.state++;
break;
case 6:
- spriteId = sub_80918EC(gUnknown_0202FFBC->dexNum, 0x58, 0x38, 1);
+ spriteId = sub_80918EC(gUnknown_0202FFBC->dexNum, 88, 56, 1);
gSprites[spriteId].oam.affineMode = 1;
gSprites[spriteId].oam.matrixNum = 2;
gSprites[spriteId].oam.priority = 0;
gSprites[spriteId].pos2.y = gPokedexEntries[gUnknown_0202FFBC->dexNum].pokemonOffset;
SetOamMatrix(2, gPokedexEntries[gUnknown_0202FFBC->dexNum].pokemonScale, 0, 0, gPokedexEntries[gUnknown_0202FFBC->dexNum].pokemonScale);
- LoadPalette(gUnknown_083B4EC4, (gSprites[spriteId].oam.paletteNum + 16) * 16, 0x20);
+ LoadPalette(gUnknown_083B4EC4, (gSprites[spriteId].oam.paletteNum + 16) * 16, sizeof(gUnknown_083B4EC4));
gMain.state++;
break;
case 7:
@@ -2724,7 +3436,7 @@ void Task_InitSizeScreenMultistep(u8 taskId)
}
}
-void Task_SizeScreenProcessInput(u8 taskId)
+static void Task_SizeScreenProcessInput(u8 taskId)
{
if (gMain.newKeys & B_BUTTON)
{
@@ -2733,7 +3445,6 @@ void Task_SizeScreenProcessInput(u8 taskId)
gTasks[taskId].func = sub_8090498;
PlaySE(SE_PC_OFF);
}
- //_08090430
else if ((gMain.newKeys & DPAD_LEFT)
|| ((gMain.newKeys & L_BUTTON) && gSaveBlock2.optionsButtonMode == OPTIONS_BUTTON_MODE_LR))
{
@@ -2744,7 +3455,7 @@ void Task_SizeScreenProcessInput(u8 taskId)
}
}
-void sub_8090498(u8 taskId)
+static void sub_8090498(u8 taskId)
{
if (!gPaletteFade.active)
{
@@ -2761,20 +3472,20 @@ void sub_8090498(u8 taskId)
}
}
-void sub_80904FC(u16 a)
+static void sub_80904FC(u16 a)
{
LZ77UnCompVram(gUnknown_08E96ACC, (void *)(VRAM + a * 0x800));
DmaClear16(3, (void *)(VRAM + a * 0x800 + 0xC0), 0x440);
}
-void sub_8090540(u16 a)
+static void sub_8090540(u16 a)
{
LZ77UnCompVram(gUnknown_08E96B58, (void *)(VRAM + a * 0x800));
DmaClear16(3, (void *)(VRAM + a * 0x800 + 0xC0), 0x440);
}
#ifdef NONMATCHING
-void sub_8090584(u8 a, u16 b)
+static void sub_8090584(u8 a, u16 b)
{
u8 i; //r1
u8 j; //r3
@@ -2814,7 +3525,7 @@ void sub_8090584(u8 a, u16 b)
}
#else
__attribute__((naked))
-void sub_8090584(u8 a, u16 b)
+static void sub_8090584(u8 a, u16 b)
{
asm(".syntax unified\n\
push {r4-r7,lr}\n\
@@ -2920,7 +3631,7 @@ _08090640: .4byte 0x06000072\n\
//Nope, can't get this one to match, either.
#ifdef NONMATCHING
-void sub_8090644(u8 a, u16 b)
+static void sub_8090644(u8 a, u16 b)
{
u8 i;
u8 j;
@@ -2958,7 +3669,7 @@ void sub_8090644(u8 a, u16 b)
}
#else
__attribute__((naked))
-void sub_8090644(u8 a, u16 b)
+static void sub_8090644(u8 a, u16 b)
{
asm(".syntax unified\n\
push {r4-r7,lr}\n\
@@ -3081,15 +3792,16 @@ u8 sub_809070C(u16 dexNum, u32 b, u32 c)
return taskId;
}
-/*
-void sub_8090750(u8 taskId)
+static void sub_8090750(u8 taskId)
{
+ u8 spriteId;
u16 dexNum = gTasks[taskId].data[1];
+ u16 i;
switch (gTasks[taskId].data[0])
{
- default:
case 0:
+ default:
if (!gPaletteFade.active)
{
gUnknown_03005CEC = gMain.vblankCallback;
@@ -3099,19 +3811,20 @@ void sub_8090750(u8 taskId)
}
break;
case 1:
- {
- u16 i;
-
LZ77UnCompVram(gPokedexMenu_Gfx, (void *)(VRAM + 0x4000));
LZ77UnCompVram(gUnknown_08E96BD4, (void *)(VRAM + 0x7800));
for (i = 0; i < 0x280; i++)
- ((u16 *)(VRAM + 0x7800))[i] += 0x2000;
+ {
+#ifndef NONMATCHING
+ asm("");
+#endif
+ *(u16 *)(VRAM + 0x7800 + 2 * i) += 0x2000;
+ }
sub_8091738(gTasks[taskId].data[1], 2, 0x3FC);
ResetPaletteFade();
- LoadPalette(gPokedexMenu_Pal + 2, 0x21, 0x9E);
+ LoadPalette(gPokedexMenu_Pal + 1, 0x21, 0x9E);
gTasks[taskId].data[0]++;
break;
- }
case 2:
SetUpWindowConfig(&gWindowConfig_81E7064);
InitMenuWindow(&gWindowConfig_81E7064);
@@ -3128,7 +3841,7 @@ void sub_8090750(u8 taskId)
MenuPrint(gDexText_UnknownPoke, 11, 5);
MenuPrint(gDexText_UnknownHeight, 16, 7);
MenuPrint(gDexText_UnknownWeight, 16, 9);
- sub_8091304(&gPokedexEntries[dexNum], 11, 5);
+ sub_8091304(gPokedexEntries[dexNum].categoryName, 11, 5);
sub_8091458(gPokedexEntries[dexNum].height, 16, 7);
sub_8091564(gPokedexEntries[dexNum].weight, 16, 9);
MenuPrint(gPokedexEntries[dexNum].descriptionPage1, 2, 13);
@@ -3136,16 +3849,13 @@ void sub_8090750(u8 taskId)
gTasks[taskId].data[0]++;
break;
case 4:
- {
- u8 spriteId = sub_80918EC(dexNum, 0x30, 0x38, 0);
-
+ spriteId = sub_80918EC(dexNum, 0x30, 0x38, 0);
gSprites[spriteId].oam.priority = 0;
BeginNormalPaletteFade(-1, 0, 0x10, 0, 0);
SetVBlankCallback(gUnknown_03005CEC);
gTasks[taskId].data[3] = spriteId;
gTasks[taskId].data[0]++;
break;
- }
case 5:
REG_BLDCNT = 0;
REG_BLDALPHA = 0;
@@ -3165,4 +3875,1586 @@ void sub_8090750(u8 taskId)
break;
}
}
-*/
+
+static void sub_8090A3C(u8 taskId)
+{
+ if (gMain.newKeys & B_BUTTON)
+ {
+ BeginNormalPaletteFade(0x0000FFFC, 0, 0, 16, 0);
+ gSprites[gTasks[taskId].data[3]].callback = sub_8090C28;
+ gTasks[taskId].func = sub_8090B8C;
+ return;
+ }
+ else if (gMain.newKeys & A_BUTTON)
+ {
+ if (gTasks[taskId].data[4] == 0)
+ {
+ u16 r4 = gTasks[taskId].data[1];
+
+ MenuZeroFillWindowRect(2, 13, 27, 19);
+ MenuPrint(gPokedexEntries[r4].descriptionPage2, 2, 13);
+ (*(u16 *)(VRAM + 0x7ACA))++;
+ (*(u16 *)(VRAM + 0x7B0A))++;
+ gTasks[taskId].data[4] = 1;
+ PlaySE(SE_PIN);
+ }
+ else
+ {
+ BeginNormalPaletteFade(0x0000FFFC, 0, 0, 16, 0);
+ gSprites[gTasks[taskId].data[3]].callback = sub_8090C28;
+ gTasks[taskId].func = sub_8090B8C;
+ return;
+ }
+ }
+ gTasks[taskId].data[2]++;
+ if (gTasks[taskId].data[2] & 0x10)
+ LoadPalette(gPokedexMenu_Pal + 1, 0x51, 14);
+ else
+ LoadPalette(gPokedexMenu2_Pal + 1, 0x51, 14);
+}
+
+static void sub_8090B8C(u8 taskId)
+{
+ if (!gPaletteFade.active)
+ {
+ u16 species;
+ u32 otId;
+ u32 personality;
+ u8 paletteNum;
+ const u16 *palette;
+
+ REG_DISPCNT = DISPCNT_MODE_0 | DISPCNT_OBJ_1D_MAP | DISPCNT_BG0_ON | DISPCNT_BG3_ON | DISPCNT_OBJ_ON;
+ CpuCopy16(gUnknown_08D00524, (void *)(VRAM + 0xC000), 0x1000);
+ sub_800D74C();
+ species = NationalPokedexNumToSpecies(gTasks[taskId].data[1]);
+ otId = ((u16)gTasks[taskId].data[13] << 16) | (u16)gTasks[taskId].data[12];
+ personality = ((u16)gTasks[taskId].data[15] << 16) | (u16)gTasks[taskId].data[14];
+ paletteNum = gSprites[gTasks[taskId].data[3]].oam.paletteNum;
+ palette = species_and_otid_get_pal(species, otId, personality);
+ LoadCompressedPalette(palette, 0x100 | paletteNum * 16, 32);
+ DestroyTask(taskId);
+ }
+}
+
+static void sub_8090C28(struct Sprite *sprite)
+{
+ if (sprite->pos1.x < 0x78)
+ sprite->pos1.x += 2;
+ if (sprite->pos1.x > 0x78)
+ sprite->pos1.x -= 2;
+
+ if (sprite->pos1.y < 0x50)
+ sprite->pos1.y += 1;
+ if (sprite->pos1.y > 0x50)
+ sprite->pos1.y -= 1;
+}
+
+static void sub_8090C68(void)
+{
+ if (gUnknown_0202FFBC->owned)
+ {
+ if (gPokedexView->descriptionPageNum == 0)
+ {
+ MenuZeroFillWindowRect(2, 13, 27, 19);
+ MenuPrint(gPokedexEntries[gUnknown_0202FFBC->dexNum].descriptionPage2, 2, 13);
+ gPokedexView->descriptionPageNum = 1;
+ (*(u16 *)(VRAM + 0x7ACA))++;
+ (*(u16 *)(VRAM + 0x7B0A))++;
+ PlaySE(SE_PIN);
+ }
+ else
+ {
+ MenuZeroFillWindowRect(2, 13, 27, 19);
+ MenuPrint(gPokedexEntries[gUnknown_0202FFBC->dexNum].descriptionPage1, 2, 13);
+ gPokedexView->descriptionPageNum = 0;
+ (*(u16 *)(VRAM + 0x7ACA))--;
+ (*(u16 *)(VRAM + 0x7B0A))--;
+ PlaySE(SE_PIN);
+ }
+ }
+}
+
+const u8 *GetPokemonCategory(u16 dexNum)
+{
+ return gPokedexEntries[dexNum].categoryName;
+}
+
+u16 GetPokedexHeightWeight(u16 dexNum, u8 data)
+{
+ switch (data)
+ {
+ case 0: // height
+ return gPokedexEntries[dexNum].height;
+ case 1: // weight
+ return gPokedexEntries[dexNum].weight;
+ default:
+ return 1;
+ }
+}
+
+s8 GetNationalPokedexFlag(u16 a, u8 b)
+{
+ u8 index;
+ u8 bit;
+ u8 mask;
+ s8 retVal;
+
+ a--;
+ index = a / 8;
+ bit = a % 8;
+ mask = 1 << bit;
+ retVal = 0;
+ switch (b)
+ {
+ case 0:
+ if (gSaveBlock2.pokedex.seen[index] & mask)
+ {
+ if ((gSaveBlock2.pokedex.seen[index] & mask) == (gSaveBlock1.unk938[index] & mask)
+ && (gSaveBlock2.pokedex.seen[index] & mask) == (gSaveBlock1.unk3A8C[index] & mask))
+ retVal = 1;
+ else
+ {
+ gSaveBlock2.pokedex.seen[index] &= ~mask;
+ gSaveBlock1.unk938[index] &= ~mask;
+ gSaveBlock1.unk3A8C[index] &= ~mask;
+ retVal = 0;
+ }
+ }
+ break;
+ case 1:
+ if (gSaveBlock2.pokedex.owned[index] & mask)
+ {
+ if ((gSaveBlock2.pokedex.owned[index] & mask) == (gSaveBlock2.pokedex.seen[index] & mask)
+ && (gSaveBlock2.pokedex.owned[index] & mask) == (gSaveBlock1.unk938[index] & mask)
+ && (gSaveBlock2.pokedex.owned[index] & mask) == (gSaveBlock1.unk3A8C[index] & mask))
+ retVal = 1;
+ else
+ {
+ gSaveBlock2.pokedex.owned[index] &= ~mask;
+ gSaveBlock2.pokedex.seen[index] &= ~mask;
+ gSaveBlock1.unk938[index] &= ~mask;
+ gSaveBlock1.unk3A8C[index] &= ~mask;
+ retVal = 0;
+ }
+ }
+ break;
+ case 2:
+ gSaveBlock2.pokedex.seen[index] |= mask;
+ gSaveBlock1.unk938[index] |= mask;
+ gSaveBlock1.unk3A8C[index] |= mask;
+ break;
+ case 3:
+ gSaveBlock2.pokedex.owned[index] |= mask;
+ break;
+ }
+ return retVal;
+}
+
+u16 GetNationalPokedexCount(u8 a)
+{
+ u16 count = 0;
+ u16 i;
+
+ for (i = 0; i < NATIONAL_DEX_COUNT; i++)
+ {
+ switch (a)
+ {
+ case 0:
+ if (GetNationalPokedexFlag(i + 1, 0) != 0)
+ count++;
+ break;
+ case 1:
+ if (GetNationalPokedexFlag(i + 1, 1) != 0)
+ count++;
+ break;
+ }
+ }
+ return count;
+}
+
+u16 GetHoennPokedexCount(u8 a)
+{
+ u16 count = 0;
+ u16 i;
+
+ for (i = 0; i < 202; i++)
+ {
+ switch (a)
+ {
+ case 0:
+ if (GetNationalPokedexFlag(HoennToNationalOrder(i + 1), 0) != 0)
+ count++;
+ break;
+ case 1:
+ if (GetNationalPokedexFlag(HoennToNationalOrder(i + 1), 1) != 0)
+ count++;
+ break;
+ }
+ }
+ return count;
+}
+
+bool8 sub_8090FC0(void)
+{
+ u16 i;
+
+ for (i = 0; i < 200; i++)
+ {
+ if (GetNationalPokedexFlag(HoennToNationalOrder(i + 1), 1) == 0)
+ return FALSE;
+ }
+ return TRUE;
+}
+
+u16 sub_8090FF4(void)
+{
+ u16 i;
+
+ for (i = 0; i < 150; i++)
+ {
+ if (GetNationalPokedexFlag(i + 1, 1) == 0)
+ return 0;
+ }
+ for (i = 152; i < 250; i++)
+ {
+ if (GetNationalPokedexFlag(i + 1, 1) == 0)
+ return 0;
+ }
+ for (i = 252; i < 384; i++)
+ {
+ if (GetNationalPokedexFlag(i + 1, 1) == 0)
+ return 0;
+ }
+ return 1;
+}
+
+static void sub_8091060(u16 a)
+{
+ if (!(a & 0x100))
+ {
+ REG_DISPCNT &= 0xFEFF;
+ REG_BG0CNT = 0;
+ REG_BG0HOFS = 0;
+ REG_BG0VOFS = 0;
+ }
+ if (!(a & 0x200))
+ {
+ REG_DISPCNT &= 0xFDFF;
+ REG_BG1CNT = 0;
+ REG_BG1HOFS = 0;
+ REG_BG1VOFS = 0;
+ }
+ if (!(a & 0x400))
+ {
+ REG_DISPCNT &= 0xFBFF;
+ REG_BG2CNT = 0;
+ REG_BG2HOFS = 0;
+ REG_BG2VOFS = 0;
+ }
+ if (!(a & 0x800))
+ {
+ REG_DISPCNT &= 0xF7FF;
+ REG_BG3CNT = 0;
+ REG_BG3HOFS = 0;
+ REG_BG3VOFS = 0;
+ }
+ if (!(a & 0x1000))
+ {
+ REG_DISPCNT &= 0xEFFF;
+ ResetSpriteData();
+ FreeAllSpritePalettes();
+ gReservedSpritePaletteCount = 8;
+ }
+}
+
+static void sub_8091154(u16 order, u8 b, u8 c)
+{
+ u8 str[4];
+
+ str[0] = CHAR_0 + order / 100;
+ str[1] = CHAR_0 + (order % 100) / 10;
+ str[2] = CHAR_0 + (order % 100) % 10;
+ str[3] = EOS;
+ MenuPrint(str, b, c);
+}
+
+static u8 sub_80911C8(u16 num, u8 b, u8 c)
+{
+ u8 str[11];
+ u8 i;
+
+ for (i = 0; i < 11; i++)
+ str[i] = EOS;
+ num = NationalPokedexNumToSpecies(num);
+ switch (num)
+ {
+ default:
+ for (i = 0; gSpeciesNames[num][i] != EOS && i < 10; i++)
+ str[i] = gSpeciesNames[num][i];
+ break;
+ case 0:
+ for (i = 0; i < 10; i++)
+ str[i] = 0xAE;
+ break;
+ }
+ MenuPrint(str, b, c);
+ return i;
+}
+
+static u8 sub_8091260(u16 num, u8 b, u8 c, u8 d)
+{
+ u8 str[40];
+ u8 *end;
+ u8 i;
+
+ end = StringCopy(str, gUnknown_083B5558);
+ str[2] = d;
+ num = NationalPokedexNumToSpecies(num);
+ switch (num)
+ {
+ default:
+ for (i = 0; gSpeciesNames[num][i] != EOS && i < 10; i++)
+ end[i] = gSpeciesNames[num][i];
+ break;
+ case 0:
+ for (i = 0; i < 10; i++)
+ end[i] = 0xAE;
+ break;
+ }
+ end[i] = EOS;
+ MenuPrint(str, b, c);
+ return i;
+}
+
+static void sub_8091304(const u8 *name, u8 left, u8 top)
+{
+ u8 str[32];
+ u8 i;
+#if ENGLISH
+ u8 j;
+#endif
+
+ for (i = 0; name[i] != EOS && i < 11; i++)
+ str[i] = name[i];
+#if ENGLISH
+ for (j = 0; gDexText_UnknownPoke[j] == 0xAC || gDexText_UnknownPoke[j] == 0; j++)
+ ;
+ j--;
+ while (gDexText_UnknownPoke[j] != EOS)
+ str[i++] = gDexText_UnknownPoke[j++];
+#endif
+ str[i] = EOS;
+ sub_8072B80(str, left, top, gDexText_UnknownPoke);
+}
+
+void unref_sub_80913A4(u16 a, u8 left, u8 top)
+{
+ u8 str[6];
+ bool8 outputted = FALSE;
+ u8 result;
+
+ result = a / 1000;
+ if (result == 0)
+ {
+ str[0] = CHAR_SPACE;
+ outputted = FALSE;
+ }
+ else
+ {
+ str[0] = CHAR_0 + result;
+ outputted = TRUE;
+ }
+
+ result = (a % 1000) / 100;
+ if (result == 0 && !outputted)
+ {
+ str[1] = CHAR_SPACE;
+ outputted = FALSE;
+ }
+ else
+ {
+ str[1] = CHAR_0 + result;
+ outputted = TRUE;
+ }
+
+ str[2] = CHAR_0 + ((a % 1000) % 100) / 10;
+ str[3] = CHAR_PERIOD;
+ str[4] = CHAR_0 + ((a % 1000) % 100) % 10;
+ str[5] = EOS;
+ MenuPrint(str, left, top);
+}
+
+#ifdef UNITS_IMPERIAL
+#define CHAR_PRIME (0xB4)
+#define CHAR_DOUBLE_PRIME (0xB2)
+static void sub_8091458(u16 height, u8 left, u8 top)
+{
+ u8 buffer[16];
+ u32 inches, feet;
+ u8 i = 0;
+
+ inches = (height * 10000) / 254;
+ if (inches % 10 >= 5)
+ inches += 10;
+ feet = inches / 120;
+ inches = (inches - (feet * 120)) / 10;
+
+ buffer[i++] = EXT_CTRL_CODE_BEGIN;
+ buffer[i++] = 0x13;
+ if (feet / 10 == 0)
+ {
+ buffer[i++] = 18;
+ buffer[i++] = feet + CHAR_0;
+ }
+ else
+ {
+ buffer[i++] = 12;
+ buffer[i++] = feet / 10 + CHAR_0;
+ buffer[i++] = (feet % 10) + CHAR_0;
+ }
+ buffer[i++] = CHAR_PRIME;
+ buffer[i++] = (inches / 10) + CHAR_0;
+ buffer[i++] = (inches % 10) + CHAR_0;
+ buffer[i++] = CHAR_DOUBLE_PRIME;
+ buffer[i++] = EOS;
+ MenuPrint(buffer, left, top);
+}
+#else
+static void sub_8091458(u16 height, u8 left, u8 top)
+{
+ unref_sub_80913A4(height, left, top);
+}
+#endif
+
+#ifdef UNITS_IMPERIAL
+static void sub_8091564(u16 weight, u8 left, u8 top)
+{
+ u8 buffer[16];
+ u32 lbs;
+ u8 i = 0;
+ bool8 output;
+
+ lbs = (weight * 100000) / 4536;
+ if (lbs % 10 >= 5)
+ lbs += 10;
+ output = FALSE;
+
+ buffer[i] = (lbs / 100000) + CHAR_0;
+ if (buffer[i] == CHAR_0 && output == FALSE)
+ {
+ buffer[i++] = CHAR_SPACE;
+ buffer[i++] = CHAR_SPACE;
+ }
+ else
+ {
+ output = TRUE;
+ i++;
+ }
+
+ lbs = (lbs % 100000);
+ buffer[i] = (lbs / 10000) + CHAR_0;
+ if (buffer[i] == CHAR_0 && output == FALSE)
+ {
+ buffer[i++] = CHAR_SPACE;
+ buffer[i++] = CHAR_SPACE;
+ }
+ else
+ {
+ output = TRUE;
+ i++;
+ }
+
+ lbs = (lbs % 10000);
+ buffer[i] = (lbs / 1000) + CHAR_0;
+ if (buffer[i] == CHAR_0 && output == FALSE)
+ {
+ buffer[i++] = CHAR_SPACE;
+ buffer[i++] = CHAR_SPACE;
+ }
+ else
+ {
+ output = TRUE;
+ i++;
+ }
+ lbs = (lbs % 1000);
+ buffer[i++] = (lbs / 100) + CHAR_0;
+ lbs = (lbs % 100);
+ buffer[i++] = CHAR_PERIOD;
+ buffer[i++] = (lbs / 10) + CHAR_0;
+ buffer[i++] = CHAR_SPACE;
+ buffer[i++] = CHAR_l;
+ buffer[i++] = CHAR_b;
+ buffer[i++] = CHAR_s;
+ buffer[i++] = CHAR_PERIOD;
+ buffer[i++] = EOS;
+ MenuPrint(buffer, left, top);
+}
+#else
+static void sub_8091564(u16 arg0, u8 left, u8 top)
+{
+ unref_sub_80913A4(arg0, left, top);
+}
+#endif
+
+static void sub_8091738(u16 num, u16 b, u16 c)
+{
+ u8 arr[0x80];
+ u16 i;
+ u16 j;
+ const u8 *r12;
+ u16 r7;
+ u8 r3;
+
+ r12 = sMonFootprintTable[NationalPokedexNumToSpecies(num)];
+ for (r7 = 0, i = 0; i < 32; i++)
+ {
+ r3 = r12[i];
+ for (j = 0; j < 4; j++)
+ {
+ u32 r1 = j * 2;
+ s32 r2 = (r3 >> r1) & 1;
+
+ if (r3 & (2 << r1))
+ r2 |= 0x10;
+
+// Needed to match
+#ifndef NONMATCHING
+ asm("");asm("");asm("");asm("");asm("");
+#endif
+
+ arr[r7] = r2;
+ r7++;
+ }
+ }
+ CpuCopy16(arr, (u16 *)(VRAM + b * 0x4000 + c * 0x20), 0x80);
+}
+
+static void sub_80917CC(u16 a, u16 b)
+{
+ *(u16 *)(VRAM + a * 0x800 + 0x232) = 0xF000 + b + 0;
+ *(u16 *)(VRAM + a * 0x800 + 0x234) = 0xF000 + b + 1;
+ *(u16 *)(VRAM + a * 0x800 + 0x272) = 0xF000 + b + 2;
+ *(u16 *)(VRAM + a * 0x800 + 0x274) = 0xF000 + b + 3;
+}
+
+static u16 sub_8091818(u8 a, u16 b, u16 c, u16 d)
+{
+ switch (a)
+ {
+ case 1:
+ if (b > c)
+ b--;
+ break;
+ case 0:
+ if (b < d)
+ b++;
+ break;
+ case 3:
+ if (b > c)
+ b--;
+ else
+ b = d;
+ break;
+ case 2:
+ if (b < d)
+ b++;
+ else
+ b = c;
+ break;
+ }
+ return b;
+}
+
+static void nullsub_59(struct Sprite *sprite)
+{
+}
+
+static void sub_8091878(u16 a, u8 b)
+{
+ gUnknown_02024E8C = gUnknown_083B57A4;
+ gUnknown_02024E8C.paletteTag = a;
+ gUnknown_02024E8C.images = gUnknown_083B5794[b];
+ gUnknown_02024E8C.anims = gSpriteAnimTable_81E7C64;
+}
+
+static void sub_80918B0(u16 a, u8 b)
+{
+ gUnknown_02024E8C = gUnknown_083B57A4;
+ gUnknown_02024E8C.paletteTag = a;
+ gUnknown_02024E8C.images = gUnknown_083B5794[b];
+ gUnknown_02024E8C.anims = gUnknown_081EC2A4[0];
+}
+
+u16 sub_80918EC(u16 num, s16 x, s16 y, u16 paletteNum)
+{
+ u8 spriteId;
+
+ num = NationalPokedexNumToSpecies(num);
+ switch (num)
+ {
+ default:
+ DecompressPicFromTable_2(
+ &gMonFrontPicTable[num],
+ gMonFrontPicCoords[num].coords,
+ gMonFrontPicCoords[num].y_offset,
+ (void *)0x02000000,
+ gUnknown_083B5584[paletteNum],
+ num);
+ break;
+ case SPECIES_SPINDA:
+ LoadSpecialPokePic(
+ &gMonFrontPicTable[num],
+ gMonFrontPicCoords[num].coords,
+ gMonFrontPicCoords[num].y_offset,
+ 0x02000000,
+ gUnknown_083B5584[paletteNum],
+ num,
+ gSaveBlock2.pokedex.spindaPersonality,
+ 1);
+ break;
+ case SPECIES_UNOWN:
+ LoadSpecialPokePic(
+ &gMonFrontPicTable[num],
+ gMonFrontPicCoords[num].coords,
+ gMonFrontPicCoords[num].y_offset,
+ 0x02000000,
+ gUnknown_083B5584[paletteNum],
+ num,
+ gSaveBlock2.pokedex.unownPersonality,
+ 1);
+ break;
+ }
+ LoadCompressedPalette(gMonPaletteTable[num].data, 0x100 + paletteNum * 16, 32);
+ sub_8091878(paletteNum, paletteNum);
+ spriteId = CreateSprite(&gUnknown_02024E8C, x, y, 0);
+ gSprites[spriteId].oam.paletteNum = paletteNum;
+ return spriteId;
+}
+
+static u8 sub_8091A4C(u16 gender, s16 x, s16 y, u16 paletteNum)
+{
+ u8 spriteId;
+
+ DecompressPicFromTable_2(
+ &gTrainerFrontPicTable[gender],
+ gTrainerFrontPicCoords[gender].coords,
+ gTrainerFrontPicCoords[gender].y_offset,
+ (void *)0x02000000,
+ gUnknown_083B5584[0],
+ gender);
+ sub_80918B0(gender, 0);
+ spriteId = CreateSprite(&gUnknown_02024E8C, x, y, 0);
+ gSprites[spriteId].oam.paletteNum = paletteNum;
+ return spriteId;
+}
+
+int sub_8091AF8(u8 a, u8 b, u8 abcGroup, u8 bodyColor, u8 type1, u8 type2)
+{
+ u16 species;
+ u16 i;
+ u16 resultsCount;
+ u8 types[2];
+
+ SortPokedex(a, b);
+
+ for (i = 0, resultsCount = 0; i < NATIONAL_DEX_COUNT; i++)
+ {
+ if (gPokedexView->unk0[i].seen)
+ {
+ gPokedexView->unk0[resultsCount] = gPokedexView->unk0[i];
+ resultsCount++;
+ }
+ }
+ gPokedexView->pokemonListCount = resultsCount;
+
+ // Search by name
+ if (abcGroup != 0xFF)
+ {
+ for (i = 0, resultsCount = 0; i < gPokedexView->pokemonListCount; i++)
+ {
+ u8 r3;
+
+ species = NationalPokedexNumToSpecies(gPokedexView->unk0[i].dexNum);
+ r3 = gSpeciesNames[species][0];
+ if ((r3 >= gUnknown_083B57BC[abcGroup][0] && r3 < gUnknown_083B57BC[abcGroup][0] + gUnknown_083B57BC[abcGroup][1])
+ || (r3 >= gUnknown_083B57BC[abcGroup][2] && r3 < gUnknown_083B57BC[abcGroup][2] + gUnknown_083B57BC[abcGroup][3]))
+ {
+ gPokedexView->unk0[resultsCount] = gPokedexView->unk0[i];
+ resultsCount++;
+ }
+ }
+ gPokedexView->pokemonListCount = resultsCount;
+ }
+
+ // Search by body color
+ if (bodyColor != 0xFF)
+ {
+ for (i = 0, resultsCount = 0; i < gPokedexView->pokemonListCount; i++)
+ {
+ species = NationalPokedexNumToSpecies(gPokedexView->unk0[i].dexNum);
+
+ if (bodyColor == gBaseStats[species].bodyColor)
+ {
+ gPokedexView->unk0[resultsCount] = gPokedexView->unk0[i];
+ resultsCount++;
+ }
+ }
+ gPokedexView->pokemonListCount = resultsCount;
+ }
+
+ // Search by type
+ if (type1 != 0xFF || type2 != 0xFF)
+ {
+ if (type1 == 0xFF)
+ {
+ type1 = type2;
+ type2 = 0xFF;
+ }
+
+ if (type2 == 0xFF)
+ {
+ for (i = 0, resultsCount = 0; i < gPokedexView->pokemonListCount; i++)
+ {
+ if (gPokedexView->unk0[i].owned)
+ {
+ species = NationalPokedexNumToSpecies(gPokedexView->unk0[i].dexNum);
+
+ types[0] = gBaseStats[species].type1;
+ types[1] = gBaseStats[species].type2;
+ if (types[0] == type1 || types[1] == type1)
+ {
+ gPokedexView->unk0[resultsCount] = gPokedexView->unk0[i];
+ resultsCount++;
+ }
+ }
+ }
+ }
+ else
+ {
+ for (i = 0, resultsCount = 0; i < gPokedexView->pokemonListCount; i++)
+ {
+ if (gPokedexView->unk0[i].owned)
+ {
+ species = NationalPokedexNumToSpecies(gPokedexView->unk0[i].dexNum);
+
+ types[0] = gBaseStats[species].type1;
+ types[1] = gBaseStats[species].type2;
+ if ((types[0] == type1 && types[1] == type2) || (types[0] == type2 && types[1] == type1))
+ {
+ gPokedexView->unk0[resultsCount] = gPokedexView->unk0[i];
+ resultsCount++;
+ }
+ }
+ }
+ }
+ gPokedexView->pokemonListCount = resultsCount;
+ }
+
+ if (gPokedexView->pokemonListCount != 0)
+ {
+ for (i = gPokedexView->pokemonListCount; i < NATIONAL_DEX_COUNT; i++)
+ {
+ gPokedexView->unk0[i].dexNum = 0xFFFF;
+ gPokedexView->unk0[i].seen = FALSE;
+ gPokedexView->unk0[i].owned = FALSE;
+
+ }
+ }
+
+ return resultsCount;
+}
+
+void sub_8091E20(const u8 *str)
+{
+ sub_8072AB0(str, 9, 120, 208, 32, 1);
+}
+
+u8 sub_8091E3C(void)
+{
+ return CreateTask(sub_8091E54, 0);
+}
+
+static void sub_8091E54(u8 taskId)
+{
+ u16 i;
+
+ switch (gMain.state)
+ {
+ default:
+ case 0:
+ if (!gPaletteFade.active)
+ {
+ gPokedexView->unk64A = 2;
+ sub_8091060(0);
+ LZ77UnCompVram(gPokedexMenuSearch_Gfx, (void *)VRAM);
+ LZ77UnCompVram(gUnknown_08E96D2C, (void *)(VRAM + 0x7800));
+ LoadPalette(gPokedexMenuSearch_Pal + 1, 1, 0x7E);
+ if (!IsNationalPokedexEnabled())
+ {
+ for (i = 0; i < 17; i++)
+ {
+ ((u16 *)(VRAM + 0x7A80))[i] = ((u16 *)(VRAM + 0x7B00))[i];
+ ((u16 *)(VRAM + 0x7AC0))[i] = ((u16 *)(VRAM + 0x7B40))[i];
+ ((u16 *)(VRAM + 0x7B00))[i] = 1;
+ ((u16 *)(VRAM + 0x7B40))[i] = 1;
+ }
+ }
+ gMain.state = 1;
+ }
+ break;
+ case 1:
+ SetUpWindowConfig(&gWindowConfig_81E7064);
+ InitMenuWindow(&gWindowConfig_81E7064);
+ LoadCompressedObjectPic(&gUnknown_083A05CC[0]);
+ LoadSpritePalettes(gUnknown_083A05DC);
+ sub_809308C(taskId);
+ for (i = 0; i < 16; i++)
+ gTasks[taskId].data[i] = 0;
+ sub_8092EB0(taskId);
+ sub_8092AB0(0);
+ sub_8092B68(taskId);
+ gMain.state++;
+ break;
+ case 2:
+ BeginNormalPaletteFade(0xFFFFFFFF, 0, 16, 0, 0);
+ gMain.state++;
+ break;
+ case 3:
+ REG_BG3CNT = 0x0F03;
+ REG_DISPCNT = 0x1C40;
+ gMain.state++;
+ break;
+ case 4:
+ if (!gPaletteFade.active)
+ {
+ gTasks[taskId].func = sub_809204C;
+ gMain.state = 0;
+ }
+ break;
+ }
+}
+
+static void sub_809204C(u8 taskId)
+{
+ sub_8092AB0(gTasks[taskId].data[0]);
+ sub_8092B68(taskId);
+ gTasks[taskId].func = sub_809207C;
+}
+
+static void sub_809207C(u8 taskId)
+{
+ if (gMain.newKeys & B_BUTTON)
+ {
+ PlaySE(SE_PC_OFF);
+ gTasks[taskId].func = sub_80927B8;
+ return;
+ }
+ if (gMain.newKeys & A_BUTTON)
+ {
+ switch (gTasks[taskId].data[0])
+ {
+ case 0:
+ PlaySE(SE_PIN);
+ gTasks[taskId].data[1] = 0;
+ gTasks[taskId].func = sub_809217C;
+ break;
+ case 1:
+ PlaySE(SE_PIN);
+ gTasks[taskId].data[1] = 4;
+ gTasks[taskId].func = sub_809217C;
+ break;
+ case 2:
+ PlaySE(SE_PC_OFF);
+ gTasks[taskId].func = sub_80927B8;
+ break;
+ }
+ return;
+ }
+ if ((gMain.newKeys & DPAD_LEFT) && gTasks[taskId].data[0] > 0)
+ {
+ PlaySE(SE_Z_PAGE);
+ gTasks[taskId].data[0]--;
+ sub_8092AB0(gTasks[taskId].data[0]);
+ }
+ if ((gMain.newKeys & DPAD_RIGHT) && gTasks[taskId].data[0] < 2)
+ {
+ PlaySE(SE_Z_PAGE);
+ gTasks[taskId].data[0]++;
+ sub_8092AB0(gTasks[taskId].data[0]);
+ }
+}
+
+static void sub_809217C(u8 taskId)
+{
+ sub_8092AD4(gTasks[taskId].data[0], gTasks[taskId].data[1]);
+ sub_8092B68(taskId);
+ gTasks[taskId].func = sub_80921B0;
+}
+
+static void sub_80921B0(u8 taskId)
+{
+ const u8 (*r6)[4];
+
+ if (gTasks[taskId].data[0] != 0)
+ {
+ if (!IsNationalPokedexEnabled())
+ r6 = gUnknown_083B58A4;
+ else
+ r6 = gUnknown_083B586C;
+ }
+ else
+ {
+ if (!IsNationalPokedexEnabled())
+ r6 = gUnknown_083B5888;
+ else
+ r6 = gUnknown_083B5850;
+ }
+
+ if (gMain.newKeys & B_BUTTON)
+ {
+ PlaySE(SE_BOWA);
+ sub_8092EB0(taskId);
+ gTasks[taskId].func = sub_809204C;
+ return;
+ }
+ if (gMain.newKeys & A_BUTTON)
+ {
+ if (gTasks[taskId].data[1] == 6)
+ {
+ if (gTasks[taskId].data[0] != 0)
+ {
+ gUnknown_0202FFBA = 0x40;
+ gPokedexView->unk62A = 0x40;
+ gUnknown_0202FFB8 = 0;
+ gPokedexView->unk610 = 0;
+ gSaveBlock2.pokedex.unknown1 = sub_8092E10(taskId, 5);
+ if (!IsNationalPokedexEnabled())
+ gSaveBlock2.pokedex.unknown1 = 0;
+ gPokedexView->unk614 = gSaveBlock2.pokedex.unknown1;
+ gSaveBlock2.pokedex.order = sub_8092E10(taskId, 4);
+ gPokedexView->unk618 = gSaveBlock2.pokedex.order;
+ PlaySE(SE_PC_OFF);
+ gTasks[taskId].func = sub_80927B8;
+ }
+ else
+ {
+ sub_8091E20(gDexText_Searching);
+ gTasks[taskId].func = sub_80923FC;
+ PlaySE(SE_Z_SEARCH);
+ }
+ }
+ else
+ {
+ PlaySE(SE_PIN);
+ gTasks[taskId].func = sub_80925CC;
+ }
+ return;
+ }
+
+ if ((gMain.newKeys & DPAD_LEFT) && r6[gTasks[taskId].data[1]][0] != 0xFF)
+ {
+ PlaySE(SE_SELECT);
+ gTasks[taskId].data[1] = r6[gTasks[taskId].data[1]][0];
+ sub_8092AD4(gTasks[taskId].data[0], gTasks[taskId].data[1]);
+ }
+ if ((gMain.newKeys & DPAD_RIGHT) && r6[gTasks[taskId].data[1]][1] != 0xFF)
+ {
+ PlaySE(SE_SELECT);
+ gTasks[taskId].data[1] = r6[gTasks[taskId].data[1]][1];
+ sub_8092AD4(gTasks[taskId].data[0], gTasks[taskId].data[1]);
+ }
+ if ((gMain.newKeys & DPAD_UP) && r6[gTasks[taskId].data[1]][2] != 0xFF)
+ {
+ PlaySE(SE_SELECT);
+ gTasks[taskId].data[1] = r6[gTasks[taskId].data[1]][2];
+ sub_8092AD4(gTasks[taskId].data[0], gTasks[taskId].data[1]);
+ }
+ if ((gMain.newKeys & DPAD_DOWN) && r6[gTasks[taskId].data[1]][3] != 0xFF)
+ {
+ PlaySE(SE_SELECT);
+ gTasks[taskId].data[1] = r6[gTasks[taskId].data[1]][3];
+ sub_8092AD4(gTasks[taskId].data[0], gTasks[taskId].data[1]);
+ }
+}
+
+static void sub_80923FC(u8 taskId)
+{
+ u8 r10 = sub_8092E10(taskId, 5);
+ u8 r9 = sub_8092E10(taskId, 4);
+ u8 r8 = sub_8092E10(taskId, 0);
+ u8 r6 = sub_8092E10(taskId, 1);
+ u8 r4 = sub_8092E10(taskId, 2);
+ u8 r0 = sub_8092E10(taskId, 3);
+
+ sub_8091AF8(r10, r9, r8, r6, r4, r0);
+ gTasks[taskId].func = sub_80924A4;
+}
+
+static void sub_80924A4(u8 taskId)
+{
+ if (!IsSEPlaying())
+ {
+ if (gPokedexView->pokemonListCount != 0)
+ {
+ PlaySE(SE_SEIKAI);
+ sub_8091E20(gDexText_SearchComplete);
+ }
+ else
+ {
+ PlaySE(SE_HAZURE);
+ sub_8091E20(gDexText_NoMatching);
+ }
+ gTasks[taskId].func = sub_8092508;
+ }
+}
+
+static void sub_8092508(u8 taskId)
+{
+ if (gMain.newKeys & A_BUTTON)
+ {
+ if (gPokedexView->pokemonListCount != 0)
+ {
+ gPokedexView->unk64F = 1;
+ gPokedexView->dexMode = sub_8092E10(taskId, 5);
+ gPokedexView->dexOrder = sub_8092E10(taskId, 4);
+ gTasks[taskId].func = sub_80927B8;
+ PlaySE(SE_PC_OFF);
+ }
+ else
+ {
+ gTasks[taskId].func = sub_809217C;
+ PlaySE(SE_BOWA);
+ }
+ }
+}
+
+static void sub_80925B4(u16 a, int unused)
+{
+ sub_814AD7C(0x90, (a * 2 + 1) * 8);
+}
+
+static void sub_80925CC(u8 taskId)
+{
+ u8 r0;
+ u16 *p1;
+ u16 *p2;
+
+ sub_8092C8C(0);
+ r0 = gTasks[taskId].data[1];
+ p1 = &gTasks[taskId].data[gUnknown_083B5A7C[r0].unk4];
+ p2 = &gTasks[taskId].data[gUnknown_083B5A7C[r0].unk5];
+ gTasks[taskId].data[14] = *p1;
+ gTasks[taskId].data[15] = *p2;
+ sub_8092D78(taskId);
+ CreateBlendedOutlineCursor(16, 0xFFFF, 12, 0x2D9F, 11);
+ sub_80925B4(*p1, 1);
+ gTasks[taskId].func = sub_8092644;
+}
+
+static void sub_8092644(u8 taskId)
+{
+ u8 r1;
+ const struct UnknownStruct2 *r8;
+ u16 *p1;
+ u16 *p2;
+ u16 r2;
+ bool8 r3;
+
+ r1 = gTasks[taskId].data[1];
+ r8 = gUnknown_083B5A7C[r1].unk0;
+ p1 = &gTasks[taskId].data[gUnknown_083B5A7C[r1].unk4];
+ p2 = &gTasks[taskId].data[gUnknown_083B5A7C[r1].unk5];
+ r2 = gUnknown_083B5A7C[r1].unk6 - 1;
+ if (gMain.newKeys & A_BUTTON)
+ {
+ sub_814ADC8();
+ PlaySE(SE_PIN);
+ MenuZeroFillWindowRect(18, 1, 28, 12);
+ sub_8092C8C(1);
+ gTasks[taskId].func = sub_809217C;
+ return;
+ }
+ if (gMain.newKeys & B_BUTTON)
+ {
+ sub_814ADC8();
+ PlaySE(SE_BOWA);
+ MenuZeroFillWindowRect(18, 1, 28, 12);
+ sub_8092C8C(1);
+ *p1 = gTasks[taskId].data[14];
+ *p2 = gTasks[taskId].data[15];
+ gTasks[taskId].func = sub_809217C;
+ return;
+ }
+ r3 = FALSE;
+ if (gMain.newAndRepeatedKeys & DPAD_UP)
+ {
+ if (*p1 != 0)
+ {
+ sub_80925B4(*p1, 0);
+ (*p1)--;
+ sub_80925B4(*p1, 1);
+ r3 = TRUE;
+ }
+ else if (*p2 != 0)
+ {
+ (*p2)--;
+ sub_8092D78(taskId);
+ sub_80925B4(*p1, 1);
+ r3 = TRUE;
+ }
+ if (r3)
+ {
+ PlaySE(SE_SELECT);
+ sub_8091E20(r8[*p1 + *p2].text1);
+ }
+ return;
+ }
+ if (gMain.newAndRepeatedKeys & DPAD_DOWN)
+ {
+ if (*p1 < 5 && *p1 < r2)
+ {
+ sub_80925B4(*p1, 0);
+ (*p1)++;
+ sub_80925B4(*p1, 1);
+ r3 = TRUE;
+ }
+ else if (r2 > 5 && *p2 < r2 - 5)
+ {
+ (*p2)++;
+ sub_8092D78(taskId);
+ sub_80925B4(5, 1);
+ r3 = TRUE;
+ }
+ if (r3)
+ {
+ PlaySE(SE_SELECT);
+ sub_8091E20(r8[*p1 + *p2].text1);
+ }
+ return;
+ }
+}
+
+static void sub_80927B8(u8 taskId)
+{
+ BeginNormalPaletteFade(0xFFFFFFFF, 0, 0, 16, 0);
+ gTasks[taskId].func = sub_80927F0;
+}
+
+static void sub_80927F0(u8 taskId)
+{
+ if (!gPaletteFade.active)
+ DestroyTask(taskId);
+}
+
+#ifdef NONMATCHING
+void sub_8092810(u8 a, u8 b, u8 c, u8 d)
+{
+ u16 i;
+
+ for (i = 0; i < d; i++)
+ {
+ ((u16 *)VRAM)[15 * 0x400 + c * 32 + i + b] &= 0xFFF;
+ ((u16 *)VRAM)[15 * 0x400 + c * 32 + i + b] |= a << 12;
+
+ ((u16 *)VRAM)[15 * 0x400 + (c + 1) * 32 + i + b] &= 0xFFF;
+ ((u16 *)VRAM)[15 * 0x400 + (c + 1) * 32 + i + b] |= a << 12;
+ }
+}
+#else
+__attribute__((naked))
+void sub_8092810(u8 a, u8 b, u8 c, u8 d)
+{
+ asm(".syntax unified\n\
+ push {r4-r7,lr}\n\
+ lsls r0, 24\n\
+ lsrs r0, 24\n\
+ lsls r1, 24\n\
+ lsrs r1, 24\n\
+ mov r12, r1\n\
+ lsls r2, 24\n\
+ lsrs r1, r2, 24\n\
+ lsls r3, 24\n\
+ lsrs r5, r3, 8\n\
+ movs r3, 0\n\
+ cmp r5, 0\n\
+ beq _0809285A\n\
+ lsls r7, r1, 6\n\
+ ldr r6, _08092860 @ =0x00000fff\n\
+ lsls r4, r0, 12\n\
+_08092830:\n\
+ mov r0, r12\n\
+ adds r1, r0, r3\n\
+ lsls r1, 1\n\
+ adds r1, r7, r1\n\
+ ldr r0, _08092864 @ =0x06007800\n\
+ adds r2, r1, r0\n\
+ ldrh r0, [r2]\n\
+ ands r0, r6\n\
+ orrs r0, r4\n\
+ strh r0, [r2]\n\
+ ldr r0, _08092868 @ =0x06007840\n\
+ adds r1, r0\n\
+ ldrh r0, [r1]\n\
+ ands r0, r6\n\
+ orrs r0, r4\n\
+ strh r0, [r1]\n\
+ adds r0, r3, 0x1\n\
+ lsls r0, 16\n\
+ lsrs r3, r0, 16\n\
+ cmp r0, r5\n\
+ bcc _08092830\n\
+_0809285A:\n\
+ pop {r4-r7}\n\
+ pop {r0}\n\
+ bx r0\n\
+ .align 2, 0\n\
+_08092860: .4byte 0x00000fff\n\
+_08092864: .4byte 0x06007800\n\
+_08092868: .4byte 0x06007840\n\
+ .syntax divided\n");
+}
+#endif
+
+static void sub_809286C(u8 a, u8 b, u8 c)
+{
+ u8 r5 = (b & 1) | ((c & 1) << 1);
+
+ switch (a)
+ {
+ case 0:
+ case 1:
+ case 2:
+ sub_8092810(r5, gUnknown_083B57E4[a].unk4, gUnknown_083B57E4[a].unk5, gUnknown_083B57E4[a].unk6);
+ break;
+ case 3:
+ case 4:
+ case 7:
+ case 8:
+ sub_8092810(r5, gUnknown_083B57FC[a - 3].unk4, gUnknown_083B57FC[a - 3].unk5, gUnknown_083B57FC[a - 3].unk6);
+ // fall through
+ case 5:
+ case 6:
+ sub_8092810(r5, gUnknown_083B57FC[a - 3].unk7, gUnknown_083B57FC[a - 3].unk8, gUnknown_083B57FC[a - 3].unk9);
+ break;
+ case 10:
+ sub_8092810(r5, gUnknown_083B57FC[2].unk4, gUnknown_083B57FC[2].unk5, gUnknown_083B57FC[2].unk6);
+ break;
+ case 9:
+ if (!IsNationalPokedexEnabled())
+ sub_8092810(r5, gUnknown_083B57FC[a - 3].unk4, gUnknown_083B57FC[a - 3].unk5 - 2, gUnknown_083B57FC[a - 3].unk6);
+ else
+ sub_8092810(r5, gUnknown_083B57FC[a - 3].unk4, gUnknown_083B57FC[a - 3].unk5, gUnknown_083B57FC[a - 3].unk6);
+ break;
+ }
+}
+
+static void sub_8092964(u8 a)
+{
+ switch (a)
+ {
+ case 0:
+ sub_809286C(0, 0, 0);
+ sub_809286C(1, 1, 0);
+ sub_809286C(2, 1, 0);
+ sub_809286C(3, 1, 0);
+ sub_809286C(4, 1, 0);
+ sub_809286C(10, 1, 0);
+ sub_809286C(5, 1, 0);
+ sub_809286C(6, 1, 0);
+ sub_809286C(7, 1, 0);
+ sub_809286C(8, 1, 0);
+ sub_809286C(9, 1, 0);
+ break;
+ case 1:
+ sub_809286C(0, 1, 0);
+ sub_809286C(1, 0, 0);
+ sub_809286C(2, 1, 0);
+ sub_809286C(3, 1, 1);
+ sub_809286C(4, 1, 1);
+ sub_809286C(10, 1, 1);
+ sub_809286C(5, 1, 1);
+ sub_809286C(6, 1, 1);
+ sub_809286C(7, 1, 0);
+ sub_809286C(8, 1, 0);
+ sub_809286C(9, 1, 0);
+ break;
+ case 2:
+ sub_809286C(0, 1, 0);
+ sub_809286C(1, 1, 0);
+ sub_809286C(2, 0, 0);
+ sub_809286C(3, 1, 1);
+ sub_809286C(4, 1, 1);
+ sub_809286C(10, 1, 1);
+ sub_809286C(5, 1, 1);
+ sub_809286C(6, 1, 1);
+ sub_809286C(7, 1, 1);
+ sub_809286C(8, 1, 1);
+ sub_809286C(9, 1, 1);
+ break;
+ }
+}
+
+static void sub_8092AB0(u8 a)
+{
+ sub_8092964(a);
+ sub_8091E20(gUnknown_083B57E4[a].text);
+}
+
+static void sub_8092AD4(u8 a, u8 b)
+{
+ sub_8092964(a);
+ switch (b)
+ {
+ case 0:
+ sub_809286C(3, 0, 0);
+ break;
+ case 1:
+ sub_809286C(4, 0, 0);
+ break;
+ case 2:
+ sub_809286C(10, 0, 0);
+ sub_809286C(5, 0, 0);
+ break;
+ case 3:
+ sub_809286C(10, 0, 0);
+ sub_809286C(6, 0, 0);
+ break;
+ case 4:
+ sub_809286C(7, 0, 0);
+ break;
+ case 5:
+ sub_809286C(8, 0, 0);
+ break;
+ case 6:
+ sub_809286C(9, 0, 0);
+ break;
+ }
+ sub_8091E20(gUnknown_083B57FC[b].text);
+}
+
+static void sub_8092B68(u8 taskId)
+{
+ u16 var;
+
+ var = gTasks[taskId].data[6] + gTasks[taskId].data[7];
+ StringCopy(gStringVar1, gUnknown_083B5910[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AB2, 45, 16, 1);
+
+ var = gTasks[taskId].data[8] + gTasks[taskId].data[9];
+ StringCopy(gStringVar1, gUnknown_083B5968[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AB2, 45, 32, 1);
+
+ var = gTasks[taskId].data[10] + gTasks[taskId].data[11];
+ StringCopy(gStringVar1, gUnknown_083B59C8[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AAC, 45, 48, 1);
+
+ var = gTasks[taskId].data[12] + gTasks[taskId].data[13];
+ StringCopy(gStringVar1, gUnknown_083B59C8[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AAC, 93, 48, 1);
+
+ var = gTasks[taskId].data[4] + gTasks[taskId].data[5];
+ StringCopy(gStringVar1, gUnknown_083B58D8[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AB2, 45, 64, 1);
+
+ if (IsNationalPokedexEnabled())
+ {
+ var = gTasks[taskId].data[2] + gTasks[taskId].data[3];
+ StringCopy(gStringVar1, gUnknown_083B58C0[var].text2);
+ MenuPrint_PixelCoords(gUnknown_083B5AB2, 45, 80, 1);
+ }
+}
+
+static void sub_8092C8C(u8 a)
+{
+ u16 i;
+ u16 j;
+
+ if (a == 0)
+ {
+ *((u16 *)(VRAM + 0x7800 + 0x22)) = 0xC0B;
+ for (i = 0x12; i < 0x1D; i++)
+ *((u16 *)(VRAM + 0x7800 + i * 2)) = 0x80D;
+ *((u16 *)(VRAM + 0x7800 + 0x3A)) = 0x80B;
+ for (j = 1; j < 13; j++)
+ {
+ *((u16 *)(VRAM + 0x7800 + 0x22 + j * 64)) = 0x40A;
+ for (i = 0x12; i < 0x1D; i++)
+ *((u16 *)(VRAM + 0x7800 + j * 64 + i * 2)) = 2;
+ *((u16 *)(VRAM + 0x7800 + 0x3A + j * 64)) = 0xA;
+ }
+ *((u16 *)(VRAM + 0x7800 + 0x362)) = 0x40B;
+ for (i = 0x12; i < 0x1D; i++)
+ *((u16 *)(VRAM + 0x7800 + 0x340 + i * 2)) = 0xD;
+ *((u16 *)(VRAM + 0x7800 + 0x37A)) = 0xB;
+ }
+ else
+ {
+ for (j = 0; j < 14; j++)
+ {
+ for (i = 0x11; i < 0x1E; i++)
+ {
+ *((u16 *)(VRAM + 0x7800 + j * 64 + i * 2)) = 0x4F;
+ }
+ }
+ }
+}
+
+static void sub_8092D78(u8 taskId)
+{
+ const struct UnknownStruct2 *r6 = gUnknown_083B5A7C[gTasks[taskId].data[1]].unk0;
+ const u16 *r8 = &gTasks[taskId].data[gUnknown_083B5A7C[gTasks[taskId].data[1]].unk4];
+ const u16 *r7 = &gTasks[taskId].data[gUnknown_083B5A7C[gTasks[taskId].data[1]].unk5];
+ u16 i;
+ u16 j;
+
+ MenuZeroFillWindowRect(18, 1, 28, 12);
+ for (i = 0, j = *r7; i < 6 && r6[j].text2 != NULL; i++, j++)
+ {
+#ifndef NONMATCHING
+ j += 0; // Useless statement needed to match
+#endif
+ MenuPrint(r6[j].text2, 18, i * 2 + 1);
+ }
+ sub_8091E20(r6[*r8 + *r7].text1);
+}
+
+static u8 sub_8092E10(u8 taskId, u8 b)
+{
+ const u16 *ptr1 = &gTasks[taskId].data[gUnknown_083B5A7C[b].unk4];
+ const u16 *ptr2 = &gTasks[taskId].data[gUnknown_083B5A7C[b].unk5];
+ u16 r2 = *ptr1 + *ptr2;
+
+ switch (b)
+ {
+ default:
+ return 0;
+ case 5:
+ return gUnknown_083B5A60[r2];
+ case 4:
+ return gUnknown_083B5A62[r2];
+ case 0:
+ if (r2 == 0)
+ return 0xFF;
+ else
+ return r2;
+ case 1:
+ if (r2 == 0)
+ return 0xFF;
+ else
+ return r2 - 1;
+ case 2:
+ case 3:
+ return gUnknown_083B5A68[r2];
+ }
+}
+
+static void sub_8092EB0(u8 taskId)
+{
+ u16 r3;
+
+ switch (gPokedexView->unk614)
+ {
+ default:
+ case 0:
+ r3 = 0;
+ break;
+ case 1:
+ r3 = 1;
+ break;
+ }
+ gTasks[taskId].data[2] = r3;
+
+ switch (gPokedexView->unk618)
+ {
+ default:
+ case 0:
+ r3 = 0;
+ break;
+ case 1:
+ r3 = 1;
+ break;
+ case 2:
+ r3 = 2;
+ break;
+ case 3:
+ r3 = 3;
+ break;
+ case 4:
+ r3 = 4;
+ break;
+ case 5:
+ r3 = 5;
+ break;
+ }
+ gTasks[taskId].data[4] = r3;
+}
+
+static bool8 sub_8092F44(u8 taskId)
+{
+ u8 val1 = gTasks[taskId].data[1];
+ const u16 *ptr = &gTasks[taskId].data[gUnknown_083B5A7C[val1].unk5];
+ u16 val2 = gUnknown_083B5A7C[val1].unk6 - 1;
+
+ if (val2 > 5 && *ptr != 0)
+ return FALSE;
+ else
+ return TRUE;
+}
+
+static bool8 sub_8092F8C(u8 taskId)
+{
+ u8 val1 = gTasks[taskId].data[1];
+ const u16 *ptr = &gTasks[taskId].data[gUnknown_083B5A7C[val1].unk5];
+ u16 val2 = gUnknown_083B5A7C[val1].unk6 - 1;
+
+ if (val2 > 5 && *ptr < val2 - 5)
+ return FALSE;
+ else
+ return TRUE;
+}
+
+static void sub_8092FD8(struct Sprite *sprite)
+{
+ if (gTasks[sprite->data0].func == sub_8092644)
+ {
+ u8 val;
+
+ if (sprite->data1 != 0)
+ {
+ if (sub_8092F8C(sprite->data0))
+ sprite->invisible = TRUE;
+ else
+ sprite->invisible = FALSE;
+ }
+ else
+ {
+ if (sub_8092F44(sprite->data0))
+ sprite->invisible = TRUE;
+ else
+ sprite->invisible = FALSE;
+ }
+ val = sprite->data2 + sprite->data1 * 128;
+ sprite->pos2.y = gSineTable[val] / 128;
+ sprite->data2 += 8;
+ }
+ else
+ {
+ sprite->invisible = TRUE;
+ }
+}
+
+static void sub_809308C(u8 taskId)
+{
+ u8 spriteId;
+
+ spriteId = CreateSprite(&gSpriteTemplate_83A053C, 184, 4, 0);
+ gSprites[spriteId].data0 = taskId;
+ gSprites[spriteId].data1 = 0;
+ gSprites[spriteId].callback = sub_8092FD8;
+
+ spriteId = CreateSprite(&gSpriteTemplate_83A053C, 184, 108, 0);
+ gSprites[spriteId].data0 = taskId;
+ gSprites[spriteId].data1 = 1;
+ gSprites[spriteId].vFlip = TRUE;
+ gSprites[spriteId].callback = sub_8092FD8;
+}
diff --git a/src/pokedex_cry_screen.c b/src/pokedex_cry_screen.c
index 53807befc..92fd832fc 100644
--- a/src/pokedex_cry_screen.c
+++ b/src/pokedex_cry_screen.c
@@ -1,5 +1,5 @@
#include "global.h"
-#include "asm.h"
+#include "pokedex_cry_screen.h"
#include "palette.h"
#include "sprite.h"
diff --git a/src/pokemon_1.c b/src/pokemon_1.c
index dacbb81c3..c55105ef3 100644
--- a/src/pokemon_1.c
+++ b/src/pokemon_1.c
@@ -1,5 +1,4 @@
#include "global.h"
-#include "asm.h"
#include "data2.h"
#include "items.h"
#include "main.h"
@@ -17,17 +16,10 @@
//Extracts the lower 16 bits of a 32-bit number
#define LOHALF(n) ((n) & 0xFFFF)
-extern struct Pokemon gPlayerParty[6]; // 0x3004360
-extern struct Pokemon gEnemyParty[6]; // 0x30045C0
-
extern u8 unk_2000000[];
extern u16 word_2024E82;
extern u8 byte_2024E88;
-extern u32 gExperienceTables[8][101];
-extern struct BaseStats gBaseStats[];
-extern const u16 *gLevelUpLearnsets[];
-
void ZeroBoxMonData(struct BoxPokemon *boxMon)
{
u8 *raw = (u8 *)boxMon;
diff --git a/src/pokemon_2.c b/src/pokemon_2.c
index 7fbfc1271..91cd77f86 100644
--- a/src/pokemon_2.c
+++ b/src/pokemon_2.c
@@ -1,20 +1,20 @@
#include "global.h"
-#include "asm.h"
+#include "battle.h"
#include "data2.h"
#include "event_data.h"
#include "main.h"
#include "pokemon.h"
#include "rng.h"
+#include "rom_8077ABC.h"
#include "species.h"
#include "sprite.h"
#include "string_util.h"
-#include "text.h"
#include "strings2.h"
+#include "text.h"
+#include "util.h"
extern u8 gPlayerPartyCount;
-extern struct Pokemon gPlayerParty[6];
extern u8 gEnemyPartyCount;
-extern struct Pokemon gEnemyParty[6];
extern u16 unk_20160BC[];
extern struct SecretBaseRecord gSecretBaseRecord;
@@ -36,16 +36,9 @@ extern u16 gTrainerBattleOpponent;
extern struct PokemonStorage gPokemonStorage;
extern u8 gBadEggNickname[];
-extern u32 gBitTable[];
-extern struct BaseStats gBaseStats[];
extern const struct SpriteTemplate gSpriteTemplate_8208288[];
//array of pointers to arrays of pointers to union AnimCmd (We probably need to typedef this.)
-extern u8 gTrainerClassToPicIndex[];
-extern u8 gTrainerClassToNameIndex[];
extern u8 gSecretBaseTrainerClasses[];
-extern u8 gUnknown_08208238[];
-extern u8 gUnknown_0820823C[];
-extern u8 gStatStageRatios[][2];
extern u8 gHoldEffectToType[][2];
u8 sub_803C348(u8 a1)
diff --git a/src/pokemon_3.c b/src/pokemon_3.c
index f9eb3a7e9..9e69a3850 100644
--- a/src/pokemon_3.c
+++ b/src/pokemon_3.c
@@ -1,17 +1,19 @@
#include "global.h"
-#include "asm.h"
#include "battle.h"
+#include "battle_message.h"
#include "data2.h"
#include "event_data.h"
#include "hold_effects.h"
#include "item.h"
#include "items.h"
#include "link.h"
-#include "main.h"
#include "m4a.h"
+#include "main.h"
#include "pokemon.h"
#include "rng.h"
#include "rom4.h"
+#include "rom_8077ABC.h"
+#include "rom_8094928.h"
#include "rtc.h"
#include "songs.h"
#include "sound.h"
@@ -19,6 +21,7 @@
#include "sprite.h"
#include "string_util.h"
#include "text.h"
+#include "util.h"
#define EVO_FRIENDSHIP 0x0001 // Pokémon levels up with friendship ≥ 220
#define EVO_FRIENDSHIP_DAY 0x0002 // Pokémon levels up during the day with friendship ≥ 220
@@ -36,18 +39,6 @@
#define EVO_LEVEL_SHEDINJA 0x000e // Pokémon reaches the specified level (special value for Shedinja)
#define EVO_BEAUTY 0x000f // Pokémon levels up with beauty ≥ specified value
-struct Evolution
-{
- u16 method;
- u16 param;
- u16 targetSpecies;
-};
-
-struct EvolutionData
-{
- struct Evolution evolutions[5];
-};
-
struct SpindaSpot
{
u8 x, y;
@@ -55,14 +46,10 @@ struct SpindaSpot
};
extern u8 gPlayerPartyCount;
-extern struct Pokemon gPlayerParty[6];
extern u8 gEnemyPartyCount;
-extern struct Pokemon gEnemyParty[6];
extern struct BattlePokemon gBattleMons[4];
-extern u8 * const gItemEffectTable[];
extern u8 gUnknown_02024A60;
extern struct BattleEnigmaBerry gEnigmaBerries[];
-extern struct EvolutionData gEvolutionTable[];
extern u16 gSpeciesToHoennPokedexNum[];
extern u16 gSpeciesToNationalPokedexNum[];
extern u16 gHoennToNationalOrder[];
@@ -79,11 +66,7 @@ extern s8 gNatureStatTable[][5];
extern s8 gUnknown_082082FE[][3];
extern u16 gTrainerBattleOpponent;
extern u16 gBattleTypeFlags;
-extern struct BaseStats gBaseStats[];
-extern u32 gBitTable[];
-extern u32 gExperienceTables[8][101];
extern u32 gTMHMLearnsets[][2];
-extern const u16 *gLevelUpLearnsets[];
extern u8 gBattleMonForms[];
extern const u8 BattleText_Wally[];
extern const u16 gHMMoves[];
@@ -100,8 +83,6 @@ extern u8 gUnknown_083FEE5D[];
extern u8 gUnknown_083FEE92[];
extern u8 *gUnknown_08400F58[];
-u8 CheckPartyHasHadPokerus(struct Pokemon *, u8);
-
bool8 HealStatusConditions(struct Pokemon *mon, u32 unused, u32 healMask, u8 battleId)
{
u32 status = GetMonData(mon, MON_DATA_STATUS, 0);
@@ -131,7 +112,7 @@ u8 GetItemEffectParamOffset(u16 itemId, u8 effectByte, u8 effectBit)
offset = 6;
- temp = gItemEffectTable[itemId - 13];
+ temp = (u8 *) gItemEffectTable[itemId - 13];
if (!temp && itemId != ITEM_ENIGMA_BERRY)
return 0;
@@ -259,7 +240,7 @@ u8 *sub_803F378(u16 itemId)
}
else
{
- itemEffect = gItemEffectTable[itemId - 13];
+ itemEffect = (u8 *) gItemEffectTable[itemId - 13];
}
gUnknown_02024C0B = gUnknown_02024E6C;
@@ -1191,8 +1172,6 @@ void current_map_music_set__default_for_battle(u16 song)
PlayNewMapMusic(sub_8040728());
}
-const u16 *species_and_otid_get_pal(u16, u32, u32);
-
const u16 *pokemon_get_pal(struct Pokemon *mon)
{
u16 species = GetMonData(mon, MON_DATA_SPECIES2, 0);
@@ -1207,7 +1186,7 @@ const u16 *pokemon_get_pal(struct Pokemon *mon)
//Extracts the lower 16 bits of a 32-bit number
#define LOHALF(n) ((n) & 0xFFFF)
-const u16 *species_and_otid_get_pal(u16 species, u32 otId , u32 personality)
+const u16 *species_and_otid_get_pal(u16 species, u32 otId, u32 personality)
{
u32 shinyValue;
@@ -1221,8 +1200,6 @@ const u16 *species_and_otid_get_pal(u16 species, u32 otId , u32 personality)
return gMonPaletteTable[species].data;
}
-const struct SpritePalette *sub_80409C8(u16, u32, u32);
-
const struct SpritePalette *sub_8040990(struct Pokemon *mon)
{
u16 species = GetMonData(mon, MON_DATA_SPECIES2, 0);
@@ -1255,7 +1232,7 @@ bool8 IsHMMove2(u16 move)
bool8 sub_8040A3C(u16 species)
{
- return gBaseStats[species].bodyColor >> 7; // XXX: should this be a bitfield instead?
+ return gBaseStats[species].unk19_7;
}
s8 sub_8040A54(struct Pokemon *mon, u8 a2)
@@ -1270,8 +1247,6 @@ s8 sub_8040A7C(u32 personality, u8 a2)
return gUnknown_083F7E28[nature * 5 + a2];
}
-bool8 IsOtherTrainer(u32, u8 *);
-
bool8 IsTradedMon(struct Pokemon *mon)
{
u8 otName[8];
diff --git a/src/pokemon_size_record.c b/src/pokemon_size_record.c
index b2f8a1569..f293190e8 100644
--- a/src/pokemon_size_record.c
+++ b/src/pokemon_size_record.c
@@ -2,14 +2,12 @@
#include "pokemon_size_record.h"
#include "data2.h"
#include "event_data.h"
+#include "pokedex.h"
#include "species.h"
#include "string_util.h"
#include "strings2.h"
#include "text.h"
-extern u16 SpeciesToNationalPokedexNum(u16);
-extern u16 GetPokedexHeightWeight(u16, u8);
-
struct UnknownStruct
{
u16 unk0;
diff --git a/src/pokemon_storage_system.c b/src/pokemon_storage_system.c
index 679ec0bc4..fb837f1f6 100644
--- a/src/pokemon_storage_system.c
+++ b/src/pokemon_storage_system.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "pokemon_storage_system.h"
#include "menu.h"
#include "string_util.h"
diff --git a/src/pokemon_summary_screen.c b/src/pokemon_summary_screen.c
index 56a56e455..61ae11438 100644
--- a/src/pokemon_summary_screen.c
+++ b/src/pokemon_summary_screen.c
@@ -1,20 +1,15 @@
#include "global.h"
-#include "asm.h"
+#include "pokemon_summary_screen.h"
#include "link.h"
#include "menu.h"
#include "pokemon.h"
+#include "region_map.h"
#include "string_util.h"
#include "strings2.h"
+#include "tv.h"
extern struct Pokemon *unk_2018000;
-extern u8 *(gNatureNames[]);
-
-u8 *sub_80A1E9C(u8 *dest, u8 *src, u8);
-u8 PokemonSummaryScreen_CheckOT(struct Pokemon *pokemon);
-u8 *PokemonSummaryScreen_CopyPokemonLevel(u8 *dest, u8 level);
-u32 GetPlayerTrainerId(void);
-
bool8 PokemonSummaryScreen_CheckOT(struct Pokemon *mon)
{
u32 trainerId;
diff --git a/src/pokenav.c b/src/pokenav.c
index f50f039f8..24253e878 100644
--- a/src/pokenav.c
+++ b/src/pokenav.c
@@ -1,24 +1,9 @@
#include "global.h"
+#include "pokenav.h"
#include "battle.h"
#include "data2.h"
#include "string_util.h"
-struct UnkPokenavStruct_Sub {
- /*0x0*/ u16 unk0;
- /*0x2*/ u8 filler2[6];
-};
-
-
-struct UnkPokenavStruct {
- /*0x0000*/ u8 filler0000[0xCEE8];
- /*0xCEE8*/ struct UnkPokenavStruct_Sub unkCEE8[78];
- /*0xD158*/ u16 unkD158;
-
-};
-
-extern struct UnkPokenavStruct *gUnknown_083DFEC4;
-
-
void sub_80F700C(u8 *arg0, u16 arg1) {
struct Trainer *trainer;
u8 *ptr;
diff --git a/src/post_battle_event_funcs.c b/src/post_battle_event_funcs.c
index f0b88025c..8d85705c8 100644
--- a/src/post_battle_event_funcs.c
+++ b/src/post_battle_event_funcs.c
@@ -1,13 +1,12 @@
#include "global.h"
#include "event_data.h"
+#include "hall_of_fame.h"
#include "load_save.h"
#include "main.h"
#include "pokemon.h"
#include "rom4.h"
#include "script_pokemon_80C4.h"
-extern void sub_8141F90(void);
-
extern u8 gUnknown_02039324;
int GameClear(void)
diff --git a/src/record_mixing.c b/src/record_mixing.c
index c84cfd2ae..e1a72cf2e 100644
--- a/src/record_mixing.c
+++ b/src/record_mixing.c
@@ -1,30 +1,38 @@
#include "global.h"
#include "record_mixing.h"
-#include "asm.h"
+#include "battle_tower.h"
+#include "cable_club.h"
+#include "daycare.h"
#include "dewford_trend.h"
#include "event_data.h"
+#include "fldeff_80C5CD4.h"
#include "link.h"
+#include "mauville_old_man.h"
#include "menu.h"
+#include "mystery_event_script.h"
#include "rom4.h"
#include "script.h"
+#include "secret_base.h"
#include "songs.h"
#include "sound.h"
#include "string_util.h"
#include "strings2.h"
#include "task.h"
+#include "tv.h"
+
extern void *recordMixingSecretBases;
extern void *recordMixingTvShows;
extern void *gUnknown_083D0274;
extern void *gUnknown_083D0278;
extern void *recordMixingEasyChatPairs;
-extern void *gUnknown_083D0280;
extern void *gUnknown_083D0284;
extern u8 gUnknown_083D0288[2];
extern u8 gUnknown_083D028A[2][3];
extern u8 gUnknown_083D0290[9][4];
-extern struct RecordMixing_UnknownStruct gUnknown_02038738[2]; //Don't know what type this points to
+extern struct RecordMixing_UnknownStruct gUnknown_02038738; //Don't know what type this points to
+extern struct RecordMixing_UnknownStruct *gUnknown_083D0280;
extern u16 gSpecialVar_0x8005;
extern u32 gUnknown_03005D2C;
extern u8 gUnknown_03000718;
@@ -40,11 +48,11 @@ void sub_80B929C(void)
struct PlayerRecords {
struct SecretBaseRecord secretBases[20];
- u8 tvShows[25][36];
+ TVShow tvShows[25];
u8 filler1004[0x40];
u8 filler1044[0x40];
struct EasyChatPair easyChatPairs[5];
- u8 filler10AC[0x78];
+ struct RecordMixing_UnknownStruct filler10AC;
u8 filler1124[0xA4];
u16 filler11C8[0x34];
};
@@ -52,9 +60,6 @@ struct PlayerRecords {
extern struct PlayerRecords unk_2008000;
extern struct PlayerRecords unk_2018000;
-void sub_80BC300();
-void sub_80C045C();
-
void RecordMixing_PrepareExchangePacket(void)
{
sub_80BC300();
@@ -65,10 +70,10 @@ void RecordMixing_PrepareExchangePacket(void)
memcpy(unk_2018000.filler1004, gUnknown_083D0274, 0x40);
memcpy(unk_2018000.filler1044, gUnknown_083D0278, 0x40);
memcpy(unk_2018000.easyChatPairs, recordMixingEasyChatPairs, 0x28);
- gUnknown_02038738[0] = gSaveBlock1.filler_303C[0];
- gUnknown_02038738[1] = gSaveBlock1.filler_303C[1];
- sub_8041324(gSaveBlock1.daycareData, gUnknown_02038738);
- memcpy(unk_2018000.filler10AC, gUnknown_083D0280, 0x78);
+ gUnknown_02038738.data[0] = gSaveBlock1.filler_303C.data[0];
+ gUnknown_02038738.data[1] = gSaveBlock1.filler_303C.data[1];
+ sub_8041324(gSaveBlock1.daycareData, &gUnknown_02038738);
+ memcpy(&unk_2018000.filler10AC, gUnknown_083D0280, sizeof(struct RecordMixing_UnknownStruct));
memcpy(unk_2018000.filler1124, gUnknown_083D0284, 0xA4);
if (GetMultiplayerId() == 0)
@@ -83,7 +88,7 @@ void RecordMixing_ReceiveExchangePacket(u32 a)
sub_80B9B1C(unk_2008000.filler1044, sizeof(struct PlayerRecords), a);
//UB: Too many arguments for function "sub_80FA4E4"
sub_80FA4E4(unk_2008000.easyChatPairs, sizeof(struct PlayerRecords), a);
- sub_80B9C6C(unk_2008000.filler10AC, sizeof(struct PlayerRecords), a, unk_2008000.tvShows);
+ sub_80B9C6C(&unk_2008000.filler10AC, sizeof(struct PlayerRecords), a, unk_2008000.tvShows);
sub_80B9B70(unk_2008000.filler1124, sizeof(struct PlayerRecords), a);
sub_80B9F3C(unk_2008000.filler11C8, a);
}
@@ -428,14 +433,20 @@ u8 sub_80B9BBC(u16 *a)
#undef NONMATCHING
#ifdef NONMATCHING
-void sub_80B9BC4(u32 a, u32 b, u32 c, u32 d)
+void sub_80B9BC4(struct RecordMixing_UnknownStruct *a, size_t b, u8 c[][2], u8 d, u8 e)
{
+ struct RecordMixing_UnknownStructSub *offA;
+ struct RecordMixing_UnknownStructSub *offB;
+ struct RecordMixing_UnknownStructSub v0;
+ v0 = (offA = ((struct RecordMixing_UnknownStruct *)(b * c[d][0] + (u32)&a))->data)[c[d][1]];
+ offA[c[d][1]] = (offB = ((struct RecordMixing_UnknownStruct *)(b * c[e][0] + (u32)&a))->data)[c[e][1]];
+ offB[c[e][1]] = v0;
//ToDo: Figure out what this strange stack usage is
}
#else
__attribute__((naked))
-void sub_80B9BC4(u32 a, u32 b, u32 c, u32 d)
+void sub_80B9BC4(struct RecordMixing_UnknownStruct *a, size_t b, u8 c[][2], u8 d, u8 e)
{
asm(".syntax unified\n\
push {r4-r6,lr}\n\
@@ -517,75 +528,3 @@ u8 sub_80B9C4C(u8 *a)
return r2;
}
-struct UnkStruct1
-{
- u8 unk0[4];
- u8 unk4[4];
- u8 unk8[4];
- u8 fillerC[0x10];
- u8 unk1C[4][2];
- u8 filler24[8];
- void *unk2C;
- u32 unk30;
- u32 unk34;
- void *unk38;
- u32 unk3C;
- u32 unk40;
- u8 filler44[4];
- u32 unk48;
- u32 unk4C;
- u32 unk50;
-
-};
-
-/*
-//Not finished
-extern void sub_80B9C6C(void *a, u32 b, u8 c, void *d)
-{
- struct UnkStruct1 s;
- u16 r8;
- u16 r3;
-
- s.unk2C = a;
- s.unk30 = b;
- s.unk38 = d;
- s.unk34 = c;
- s.unk40 = Random();
- SeedRng(gLinkPlayers[0].trainerId);
- r8 = GetLinkPlayerCount();
- r3 = 0;
-
- s.unk4C = 12;
-
- while (r3 < 4)
- {
-
- s.unk4[r3] |= 0xFF;
- s.unk8[r3] = 0;
-
- s.unk1C[r3][0] = 0;
- s.unk1C[r3][1] = 0;
- r3++;
- }
- s.unk3C = 0;
- r3 = 0;
- s.unk50 = r8 << 16;
- s.unk48 = s.unk30 * s.unk34;
-
- if (s.unk3C < r8)
- {
- do //_080B9D00
- {
- u32 *r6 = (u32 *)(s.unk2C + s.unk30 * r3);
- if (r6[0x1C] != 0 && r6[0x1C] > 0)
- {
-
- }
- //_080B9D3C
- }
- while (r3 < r8);
- }
- //_080B9D46
-}
-*/
-
diff --git a/src/roamer.c b/src/roamer.c
index 394f81c75..948828d5e 100644
--- a/src/roamer.c
+++ b/src/roamer.c
@@ -1,7 +1,7 @@
#include "global.h"
+#include "roamer.h"
#include "pokemon.h"
#include "rng.h"
-#include "roamer.h"
#include "species.h"
#ifdef SAPPHIRE
diff --git a/src/rom3.c b/src/rom3.c
index be6ae0b27..93f0f0356 100644
--- a/src/rom3.c
+++ b/src/rom3.c
@@ -1,11 +1,19 @@
#include "global.h"
-#include "asm.h"
+#include "rom3.h"
#include "battle.h"
+#include "battle_811DA74.h"
+#include "battle_ai.h"
+#include "battle_anim.h"
+#include "battle_anim_81258BC.h"
+#include "battle_anim_8137220.h"
+#include "cable_club.h"
#include "items.h"
#include "link.h"
#include "pokemon.h"
+#include "rom_8094928.h"
#include "species.h"
#include "task.h"
+#include "util.h"
extern u8 unk_2000000[];
@@ -13,7 +21,6 @@ extern u8 unk_2000000[];
#define EWRAM_15000 ((u8 *)(unk_2000000 + 0x15000))
extern u16 gBattleTypeFlags;
-extern const u32 gBitTable[];
extern u16 gBattleWeather;
extern struct BattlePokemon gBattleMons[];
@@ -49,32 +56,6 @@ extern u8 gUnknown_030042B0[];
extern void (*gUnknown_030042D4)(void);
extern void (*gUnknown_03004330[])(void);
-extern void sub_800BF28(void);
-extern void sub_8083C50(u8);
-extern void nullsub_41(void);
-extern void nullsub_91(void);
-extern void battle_anim_clear_some_data(void);
-extern void ClearBattleMonForms(void);
-extern void BattleAI_HandleItemUseBeforeAISetup(void);
-extern void sub_8094978(u8, int);
-extern void sub_800BA78(void);
-extern void sub_800B9A8(void);
-extern void sub_800BD54(void);
-extern void sub_8010800(void);
-extern void sub_812B468(void);
-extern void sub_8137224(void);
-extern void sub_802BF74(void);
-extern void sub_8032AE0(void);
-extern void sub_8037510(void);
-extern void sub_811DA78(void);
-extern void dp01_prepare_buffer_wireless_probably(u8 a, u16, u8 *c);
-extern void sub_800C1A8(u8);
-extern void sub_800C47C(u8);
-extern void sub_8007F4C(void);
-extern u8 sub_8007ECC(void);
-extern void sub_80155A4();
-extern u8 sub_8018324();
-
void sub_800B858(void)
{
if (gBattleTypeFlags & BATTLE_TYPE_LINK)
diff --git a/src/rom4.c b/src/rom4.c
index 79ac6d769..2ddd5ed9f 100644
--- a/src/rom4.c
+++ b/src/rom4.c
@@ -1,24 +1,31 @@
#include "global.h"
#include "rom4.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
#include "battle_setup.h"
#include "berry.h"
+#include "cable_club.h"
#include "clock.h"
#include "event_data.h"
#include "field_camera.h"
#include "field_control_avatar.h"
#include "field_effect.h"
+#include "field_fadetransition.h"
+#include "field_ground_effect.h"
#include "field_map_obj.h"
#include "field_map_obj_helpers.h"
#include "field_message_box.h"
#include "field_player_avatar.h"
-#include "field_weather.h"
+#include "field_screen_effect.h"
#include "field_special_scene.h"
+#include "field_specials.h"
+#include "field_tasks.h"
+#include "field_weather.h"
+#include "fieldmap.h"
+#include "fldeff_flash.h"
#include "heal_location.h"
#include "link.h"
#include "load_save.h"
#include "main.h"
+#include "map_name_popup.h"
#include "menu.h"
#include "metatile_behavior.h"
#include "new_game.h"
@@ -26,14 +33,19 @@
#include "play_time.h"
#include "rng.h"
#include "roamer.h"
+#include "rotating_gate.h"
#include "safari_zone.h"
#include "script.h"
#include "script_pokemon_80C4.h"
+#include "secret_base.h"
#include "songs.h"
#include "sound.h"
#include "start_menu.h"
#include "task.h"
#include "tileset_anim.h"
+#include "time_events.h"
+#include "tv.h"
+#include "unknown_task.h"
#include "wild_encounter.h"
#ifdef SAPPHIRE
@@ -48,11 +60,6 @@ struct UnkTVStruct
u32 tv_field_4;
};
-struct UCoords32
-{
- u32 x, y;
-};
-
extern struct WarpData gUnknown_020297F0;
extern struct WarpData gUnknown_020297F8;
extern struct WarpData gUnknown_02029800;
@@ -67,12 +74,10 @@ extern u16 (*gUnknown_03000584)(u32);
extern u8 gUnknown_03000588;
extern u16 word_3004858;
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern u8 gUnknown_03004860;
extern u8 gFieldLinkPlayerCount;
-extern struct UnkTVStruct gUnknown_03004870;
-
extern u16 gUnknown_03004898;
extern u16 gUnknown_0300489C;
@@ -97,8 +102,6 @@ extern u8 TradeRoom_PromptToCancelLink[];
extern u8 TradeRoom_TerminateLink[];
extern u8 gUnknown_081A4508[];
-extern struct UCoords32 gUnknown_0821664C[];
-
extern u8 (*gUnknown_082166A0[])(struct LinkPlayerMapObject *, struct MapObject *, u8);
extern u8 (*gUnknown_082166AC[])(struct LinkPlayerMapObject *, struct MapObject *, u8);
extern void (*gUnknown_082166D8[])(struct LinkPlayerMapObject *, struct MapObject *);
@@ -567,7 +570,7 @@ void sub_8053994(u32 a1)
not_trainer_hill_battle_pyramid();
if (a1 != 1 && v3)
{
- UpdateTVScreensOnMap(gUnknown_03004870.tv_field_0, gUnknown_03004870.tv_field_4);
+ UpdateTVScreensOnMap(gUnknown_03004870.width, gUnknown_03004870.height);
sub_80BBCCC(1);
}
}
@@ -1082,11 +1085,11 @@ void sub_80543DC(u16 (*a1)(u32))
void sub_80543E8(void)
{
- if (gUnknown_0300485C)
- gUnknown_0300485C();
+ if (gFieldCallback)
+ gFieldCallback();
else
mapldr_default();
- gUnknown_0300485C = NULL;
+ gFieldCallback = NULL;
}
void CB2_NewGame(void)
@@ -1099,7 +1102,7 @@ void CB2_NewGame(void)
PlayTimeCounter_Start();
ScriptContext1_Init();
ScriptContext2_Disable();
- gUnknown_0300485C = ExecuteTruckSequence;
+ gFieldCallback = ExecuteTruckSequence;
do_load_map_stuff_loop(&gMain.state);
SetFieldVBlankCallback();
set_callback1(c1_overworld);
@@ -1119,7 +1122,7 @@ void CB2_WhiteOut(void)
player_avatar_init_params_reset();
ScriptContext1_Init();
ScriptContext2_Disable();
- gUnknown_0300485C = sub_8080B60;
+ gFieldCallback = sub_8080B60;
val = 0;
do_load_map_stuff_loop(&val);
SetFieldVBlankCallback();
@@ -1166,7 +1169,7 @@ void sub_8054534(void)
void sub_8054588(void)
{
FieldClearVBlankHBlankCallbacks();
- gUnknown_0300485C = sub_8080AC4;
+ gFieldCallback = sub_8080AC4;
SetMainCallback2(c2_80567AC);
}
@@ -1216,7 +1219,7 @@ void sub_805465C(void)
sub_8054F70();
set_callback1(sub_8055354);
sub_80543DC(sub_8055390);
- gUnknown_0300485C = sub_8080A3C;
+ gFieldCallback = sub_8080A3C;
ScriptContext1_Init();
ScriptContext2_Disable();
c2_exit_to_overworld_2_switch();
@@ -1225,28 +1228,28 @@ void sub_805465C(void)
void sub_805469C(void)
{
FieldClearVBlankHBlankCallbacks();
- gUnknown_0300485C = atk17_seteffectuser;
+ gFieldCallback = atk17_seteffectuser;
c2_exit_to_overworld_2_switch();
}
void sub_80546B8(void)
{
FieldClearVBlankHBlankCallbacks();
- gUnknown_0300485C = sub_80809B0;
+ gFieldCallback = sub_80809B0;
c2_exit_to_overworld_2_switch();
}
void c2_exit_to_overworld_1_continue_scripts_restart_music(void)
{
FieldClearVBlankHBlankCallbacks();
- gUnknown_0300485C = sub_8080990;
+ gFieldCallback = sub_8080990;
c2_exit_to_overworld_2_switch();
}
void sub_80546F0(void)
{
FieldClearVBlankHBlankCallbacks();
- gUnknown_0300485C = sub_8080B60;
+ gFieldCallback = sub_8080B60;
c2_exit_to_overworld_2_switch();
}
@@ -1280,7 +1283,7 @@ void CB2_ContinueSavedGame(void)
}
else
{
- gUnknown_0300485C = sub_805470C;
+ gFieldCallback = sub_805470C;
set_callback1(c1_overworld);
c2_exit_to_overworld_2_switch();
}
diff --git a/src/rom6.c b/src/rom6.c
index a2b52c9aa..759aed93f 100644
--- a/src/rom6.c
+++ b/src/rom6.c
@@ -1,9 +1,11 @@
#include "global.h"
#include "rom6.h"
-#include "asm.h"
#include "braille_puzzles.h"
#include "field_effect.h"
+#include "field_map_obj.h"
#include "field_player_avatar.h"
+#include "item_use.h"
+#include "pokemon_menu.h"
#include "rom4.h"
#include "script.h"
#include "songs.h"
@@ -14,15 +16,11 @@
extern u16 gScriptLastTalked;
extern u32 gUnknown_0202FF84[];
extern struct MapPosition gUnknown_0203923C;
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern u8 gLastFieldPokeMenuOpened;
extern void (*gUnknown_03005CE4)(void);
extern u8 UseRockSmashScript[];
-extern void sub_808AB90(void);
-extern void task08_080A1C44(u8);
-extern u8 sub_80CA1C8(void);
-
static void task08_080C9820(u8);
static void sub_810B3DC(u8);
static void sub_810B428(u8);
@@ -122,7 +120,7 @@ bool8 SetUpFieldMove_RockSmash(void)
{
if (npc_before_player_of_type(0x56) == TRUE)
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_810B53C;
return TRUE;
}
@@ -159,7 +157,7 @@ int SetUpFieldMove_Dig(void)
{
if (sub_80CA1C8() == TRUE)
{
- gUnknown_0300485C = sub_808AB90;
+ gFieldCallback = sub_808AB90;
gUnknown_03005CE4 = sub_810B5D8;
return TRUE;
}
diff --git a/src/rom_8077ABC.c b/src/rom_8077ABC.c
index 9561db690..a31a764fb 100644
--- a/src/rom_8077ABC.c
+++ b/src/rom_8077ABC.c
@@ -1,13 +1,17 @@
#include "global.h"
+#include "rom_8077ABC.h"
#include "battle.h"
+#include "battle_anim.h"
#include "blend_palette.h"
#include "data2.h"
#include "decompress.h"
#include "palette.h"
+#include "pokemon_icon.h"
#include "species.h"
#include "sprite.h"
#include "task.h"
#include "trig.h"
+#include "util.h"
#define GET_UNOWN_LETTER(personality) ((\
(((personality & 0x03000000) >> 24) << 6) \
@@ -89,7 +93,6 @@ struct BGCnt {
extern struct OamData gOamData_837DF9C[];
extern const union AnimCmd *const gDummySpriteAnimTable[];
extern const union AffineAnimCmd *const gDummySpriteAffineAnimTable[];
-extern u8 gMiscBlank_Gfx[];
extern struct Struct_unk_2019348 unk_2019348;
extern struct TransformStatus gTransformStatuses[];
@@ -108,45 +111,6 @@ extern struct OamMatrix gOamMatrices[];
extern struct Struct_2017810 unk_2017810[];
extern u8 gUnknown_0202F7BE;
-extern u8 IsContest();
-extern bool8 sub_8078874(u8);
-extern bool8 b_side_obj__get_some_boolean(u8);
-extern void UpdateMonIconFrame(struct Sprite *sprite);
-extern void CalcCenterToCornerVec(struct Sprite *sprite, u8 shape, u8 size, u8 affineMode);
-extern void *species_and_otid_get_pal(u32, u32, u32);
-extern void FreeSpriteOamMatrix(struct Sprite *sprite);
-extern void ResetPaletteStructByUid(u16);
-extern void DestroyAnimVisualTask(u8 task);
-extern u8 CreateInvisibleSpriteWithCallback(void (*callback)(struct Sprite *));
-
-u8 sub_8077E44(u8 slot, u16 species, u8 a3);
-u8 battle_get_per_side_status(u8 slot);
-u8 battle_side_get_owner(u8 slot);
-void sub_8078314(struct Sprite *sprite);
-void sub_8078364(struct Sprite *sprite);
-void move_anim_8072740(struct Sprite *sprite);
-void obj_translate_based_on_private_1_2_3_4(struct Sprite *sprite);
-bool8 sub_8078B5C(struct Sprite *sprite);
-u8 battle_get_per_side_status_permutated(u8 slot);
-void sub_8078A5C(struct Sprite *sprite);
-void sub_8078BB8(struct Sprite *sprite);
-void sub_8078D44(struct Sprite *sprite);
-bool8 sub_8078E38();
-void sub_8079518(struct Sprite *sprite);
-void sub_80796F8(u8 task);
-void sub_80797EC(struct Task *task);
-void sub_8079814(u8 taskId);
-void sub_8079BF4(s16 *bottom, s16 *top, void *ptr);
-void *sub_8079BFC(s16 bottom, s16 top);
-void sub_8079A64(u8 sprite);
-u16 sub_8079B10(u8 sprite);
-u8 sub_8079E90(u8 slot);
-void sub_807A784(u8 taskId);
-void sub_807A850(struct Task *task, u8 taskId);
-void sub_807A8D4(struct Sprite *sprite);
-void sub_807A960(struct Sprite *sprite);
-
-
EWRAM_DATA union AffineAnimCmd *gUnknown_0202F7D4 = NULL;
EWRAM_DATA u32 filler_0202F7D8[3] = {0};
diff --git a/src/rom_8094928.c b/src/rom_8094928.c
deleted file mode 100644
index 794fc78f6..000000000
--- a/src/rom_8094928.c
+++ /dev/null
@@ -1,135 +0,0 @@
-#include "global.h"
-#include "pokemon.h"
-
-#define UNK_201606C_ARRAY (unk_2000000 + 0x1606C) // lazy define but whatever.
-
-extern u8 unk_2000000[];
-
-extern struct PokemonStorage gPokemonStorage;
-extern u8 IsLinkDoubleBattle(void);
-extern u8 IsDoubleBattle(void);
-extern u8 battle_get_side_with_given_state(u8);
-extern u8 battle_side_get_owner(u8);
-void sub_8094998(u8[3], u8);
-void sub_8094A74(u8[3], u8, u32);
-
-extern u8 gUnknown_02038470[3];
-extern u8 sub_803FBBC(void);
-extern u16 gUnknown_02024A6A[];
-
-void unref_sub_8094928(struct PokemonStorage *ptr)
-{
- *ptr = gPokemonStorage;
-}
-
-void unref_sub_8094940(struct PokemonStorage *ptr)
-{
- gPokemonStorage = *ptr;
-}
-
-void sub_8094958(void)
-{
- sub_8094998(gUnknown_02038470, sub_803FBBC());
-}
-
-void sub_8094978(u8 arg1, u8 arg2)
-{
- sub_8094A74((UNK_201606C_ARRAY) + arg1 * 3, arg2, arg1);
-}
-
-void sub_8094998(u8 arg[3], u8 player_number)
-{
- int i;
- u32 pos;
- u8 temp[6];
- if (IsLinkDoubleBattle() == TRUE)
- {
- if (player_number)
- {
- *arg = 0x30;
- arg[1] = 0x45;
- arg[2] = 0x12;
- }
- else
- {
- *arg = 0x03;
- arg[1] = 0x12;
- arg[2] = 0x45;
- }
- }
- else
- {
- if (!IsDoubleBattle())
- {
- pos = 1;
- *temp = gUnknown_02024A6A[battle_get_side_with_given_state(0)];
- for (i = 0; i <= 5; i++)
- if (i != *temp)
- temp[pos++] = i;
- }
- else
- {
- pos = 2;
- *temp = gUnknown_02024A6A[battle_get_side_with_given_state(0)];
- temp[1] = gUnknown_02024A6A[battle_get_side_with_given_state(2)];
- for (i = 0; i <= 5; i++)
- if ((i != *temp) && (i != temp[1]))
- temp[pos++] = i;
- }
- for (i = 0; i <= 2; i++)
- arg[i] = (temp[i << 1] << 4) | temp[(i << 1) + 1];
- }
-}
-
-void sub_8094A74(u8 arg[3], u8 player_number, u32 arg3)
-{
- int i, j;
- u8 temp[6];
- if (!battle_side_get_owner(arg3))
- {
- i = battle_get_side_with_given_state(0);
- j = battle_get_side_with_given_state(2);
- }
- else
- {
- i = battle_get_side_with_given_state(1);
- j = battle_get_side_with_given_state(3);
- }
- if (IsLinkDoubleBattle() == TRUE)
- {
- if (player_number)
- {
- *arg = 0x30;
- arg[1] = 0x45;
- arg[2] = 0x12;
- }
- else
- {
- *arg = 0x03;
- arg[1] = 0x12;
- arg[2] = 0x45;
- }
- }
- else
- {
- if (!IsDoubleBattle())
- {
- int pos = 1;
- *temp = gUnknown_02024A6A[i];
- for (i = 0; i <= 5; i++)
- if (i != *temp)
- temp[pos++] = i;
- }
- else
- {
- int pos = 2;
- *temp = gUnknown_02024A6A[i];
- temp[1] = gUnknown_02024A6A[j];
- for (i = 0; i <= 5; i++)
- if ((i != *temp) && (i != temp[1]))
- temp[pos++] = i;
- }
- for (i = 0; i <= 2; i++)
- arg[i] = (temp[i << 1] << 4) | temp[(i << 1) + 1];
- }
-}
diff --git a/src/safari_zone.c b/src/safari_zone.c
index 8c2b63469..fa6c11f52 100644
--- a/src/safari_zone.c
+++ b/src/safari_zone.c
@@ -1,7 +1,7 @@
#include "global.h"
#include "safari_zone.h"
-#include "asm.h"
#include "event_data.h"
+#include "field_fadetransition.h"
#include "field_player_avatar.h"
#include "main.h"
#include "rom4.h"
@@ -29,7 +29,7 @@ EWRAM_DATA u8 gNumSafariBalls = 0;
EWRAM_DATA static u16 gSafariZoneStepCounter = 0;
EWRAM_DATA static struct PokeblockFeeder gPokeblockFeeders[NUM_POKEBLOCK_FEEDERS] = {0};
-extern void (*gUnknown_0300485C)(void);
+extern void (*gFieldCallback)(void);
extern u8 gUnknown_081C340A;
extern u8 gUnknown_081C342D;
@@ -103,7 +103,7 @@ void sub_80C824C(void)
{
ScriptContext2_RunNewScript(&gUnknown_081C340A);
warp_in();
- gUnknown_0300485C = sub_8080E44;
+ gFieldCallback = sub_8080E44;
SetMainCallback2(CB2_LoadMap);
}
else if (gUnknown_02024D26 == 7)
diff --git a/src/save.c b/src/save.c
index 9ab6e83f6..570210fb0 100644
--- a/src/save.c
+++ b/src/save.c
@@ -2,7 +2,6 @@
#include "gba/gba.h"
#include "gba/flash_internal.h"
#include "save.h"
-#include "asm.h"
#include "load_save.h"
#include "rom4.h"
#include "save_failed_screen.h"
diff --git a/src/save_failed_screen.c b/src/save_failed_screen.c
index a3de0bd00..a64b3eb5f 100644
--- a/src/save_failed_screen.c
+++ b/src/save_failed_screen.c
@@ -1,12 +1,13 @@
#include "global.h"
#include "gba/flash_internal.h"
-#include "asm.h"
+#include "save_failed_screen.h"
#include "m4a.h"
#include "main.h"
#include "menu.h"
#include "palette.h"
#include "save.h"
#include "sprite.h"
+#include "starter_choose.h"
#include "strings.h"
#include "task.h"
#include "text.h"
@@ -35,12 +36,6 @@ extern struct SaveFailedClockStruct gSaveFailedClockInfo;
extern u32 gDamagedSaveSectors;
extern u32 gGameContinueCallback;
-extern u8 gBirchHelpGfx[];
-
-extern u8 gBirchGrassTilemap[];
-extern u8 gBirchBagTilemap[];
-extern u8 gBirchBagGrassPal[0x40];
-
static const struct OamData sClockOamData =
{
160, // Y
diff --git a/src/save_menu_util.c b/src/save_menu_util.c
index 8910bb300..b2dd662d6 100644
--- a/src/save_menu_util.c
+++ b/src/save_menu_util.c
@@ -1,9 +1,9 @@
#include "global.h"
#include "save_menu_util.h"
-#include "asm.h"
#include "event_data.h"
#include "menu.h"
#include "pokedex.h"
+#include "region_map.h"
#include "string_util.h"
#include "strings2.h"
diff --git a/src/scrcmd.c b/src/scrcmd.c
index f2b5090af..a394f2a55 100644
--- a/src/scrcmd.c
+++ b/src/scrcmd.c
@@ -1,43 +1,52 @@
#include "global.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
#include "battle_setup.h"
#include "berry.h"
#include "clock.h"
#include "coins.h"
+#include "contest_link_80C2020.h"
#include "contest_painting.h"
#include "data2.h"
#include "decoration.h"
+#include "decoration_inventory.h"
#include "event_data.h"
#include "field_door.h"
#include "field_effect.h"
+#include "field_fadetransition.h"
+#include "field_map_obj.h"
#include "field_map_obj_helpers.h"
#include "field_message_box.h"
#include "field_player_avatar.h"
+#include "field_screen_effect.h"
+#include "field_specials.h"
+#include "field_tasks.h"
#include "field_weather.h"
+#include "fieldmap.h"
#include "item.h"
#include "main.h"
#include "map_obj_lock.h"
#include "menu.h"
#include "money.h"
+#include "mystery_event_script.h"
#include "palette.h"
+#include "party_menu.h"
#include "pokemon.h"
#include "rng.h"
#include "rom4.h"
#include "rtc.h"
#include "script.h"
#include "script_menu.h"
+#include "script_movement.h"
#include "script_pokemon_80C4.h"
#include "script_pokemon_80F9.h"
+#include "shop.h"
+#include "slot_machine.h"
#include "sound.h"
#include "string_util.h"
+#include "tv.h"
typedef u16 (*SpecialFunc)(void);
typedef void (*NativeFunc)(void);
-extern struct Pokemon gPlayerParty[6]; // 0x3004360
-extern struct Pokemon gEnemyParty[6]; // 0x30045C0
-
extern u32 gUnknown_0202E8AC;
extern u32 gUnknown_0202E8B0;
extern u16 gUnknown_0202E8B4;
@@ -60,8 +69,6 @@ extern SpecialFunc gSpecials[];
extern u8 *gStdScripts[];
extern u8 *gStdScripts_End[];
-extern u8 * const gUnknown_083CE048[];
-
// This is defined in here so the optimizer can't see its value when compiling
// script.c.
void * const gNullScriptPtr = NULL;
@@ -1409,7 +1416,7 @@ bool8 ScrCmd_bufferstd(struct ScriptContext *ctx)
{
u8 stringVarIndex = ScriptReadByte(ctx);
u16 index = VarGet(ScriptReadHalfword(ctx));
- StringCopy(sScriptStringVars[stringVarIndex], gUnknown_083CE048[index]);
+ StringCopy(sScriptStringVars[stringVarIndex], gUnknown_083CE048[index].text);
return FALSE;
}
diff --git a/src/script.c b/src/script.c
index 7a9c8e102..488a67de1 100644
--- a/src/script.c
+++ b/src/script.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "script.h"
-#include "asm_fieldmap.h"
#include "event_data.h"
#define RAM_SCRIPT_MAGIC 51
diff --git a/src/script_menu.c b/src/script_menu.c
index 50941f9ac..23e8bf2d9 100644
--- a/src/script_menu.c
+++ b/src/script_menu.c
@@ -1,6 +1,7 @@
#include "global.h"
#include "script_menu.h"
#include "event_data.h"
+#include "field_effect.h"
#include "menu.h"
#include "palette.h"
#include "script.h"
@@ -573,10 +574,6 @@ extern u8 gPCText_WhichPCShouldBeAccessed[];
extern u16 gScriptResult;
-// field_effect
-extern void FreeResourcesAndDestroySprite(struct Sprite *sprite);
-extern u8 CreateMonSprite_PicBox(u16, s16, s16, u8);
-
bool8 sub_80B5054(u8 left, u8 top, u8 var3, u8 var4)
{
if (FuncIsActiveTask(sub_80B52B4) == 1)
@@ -684,7 +681,7 @@ void sub_80B52B4(u8 taskId)
{
gScriptResult = var;
}
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(gTasks[taskId].data[0], gTasks[taskId].data[1], gTasks[taskId].data[2], gTasks[taskId].data[3]);
DestroyTask(taskId);
EnableBothScriptContexts();
@@ -847,7 +844,7 @@ void sub_80B5684(u8 taskId)
{
gScriptResult = var;
}
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(gTasks[taskId].data[0], gTasks[taskId].data[1], gTasks[taskId].data[2], gTasks[taskId].data[3]);
DestroyTask(taskId);
EnableBothScriptContexts();
diff --git a/src/script_movement.c b/src/script_movement.c
index 2dc816532..31143ed6f 100644
--- a/src/script_movement.c
+++ b/src/script_movement.c
@@ -1,14 +1,12 @@
#include "global.h"
-#include "asm.h"
+#include "script_movement.h"
+#include "field_map_obj.h"
#include "field_map_obj_helpers.h"
#include "task.h"
+#include "util.h"
-extern const u32 gBitTable[];
extern u8 *gUnknown_020384F8[];
-extern void UnfreezeMapObject(struct MapObject *);
-extern bool8 FieldObjectIsSpecialAnimActive(struct MapObject *);
-
static void sub_80A2198(u8);
static u8 sub_80A21E0(void);
static bool8 sub_80A21F4(u8, u8, u8 *);
diff --git a/src/script_pokemon_util_80C4BF0.c b/src/script_pokemon_util_80C4BF0.c
index d111cf8f6..c8171db52 100644
--- a/src/script_pokemon_util_80C4BF0.c
+++ b/src/script_pokemon_util_80C4BF0.c
@@ -1,9 +1,13 @@
#include "global.h"
-#include "asm.h"
#include "battle.h"
#include "berry.h"
+#include "choose_party.h"
#include "contest.h"
+#include "contest_link_80C2020.h"
+#include "contest_painting.h"
#include "data2.h"
+#include "daycare.h"
+#include "debug.h"
#include "decompress.h"
#include "event_data.h"
#include "items.h"
@@ -22,19 +26,7 @@
#define CONTEST_ENTRY_PIC_LEFT 10
#define CONTEST_ENTRY_PIC_TOP 3
-extern void sub_80C46EC(void);
-extern void sub_80C4740(void);
-extern void sub_80C48F4(void);
-extern void sub_80B2A7C(u8);
-extern void sub_80AAF30(void); // matsuda debug?
-extern u8 sub_80B2C4C(u8, u8);
-extern void CB2_ContestPainting(void);
-extern void sub_8042044(struct Pokemon *mon, u16, u8);
-extern void sub_8121E10(void);
-extern void sub_8121E34(void);
-
extern struct SpriteTemplate gUnknown_02024E8C;
-extern struct SpritePalette *sub_80409C8(u16, u32, u32);
extern u8 gContestPlayerMonIndex;
extern u8 gIsLinkContest;
@@ -436,7 +428,7 @@ void ShowContestEntryMonPic(void)
HandleLoadSpecialPokePic((struct SpriteSheet *)&gMonFrontPicTable[species].data,
gMonFrontPicCoords[species].coords, gMonFrontPicCoords[species].y_offset,
(u32)gUnknown_081FAF4C[0], gUnknown_081FAF4C[1], species, var1);
- paletteData = sub_80409C8(species, var2, var1);
+ paletteData = (struct SpritePalette *) sub_80409C8(species, var2, var1);
LoadCompressedObjectPalette(paletteData);
GetMonSpriteTemplate_803C56C(species, 1);
gUnknown_02024E8C.paletteTag = paletteData->tag;
@@ -560,16 +552,16 @@ u8 ScriptGiveMon(u16 species, u8 var, u16 item, u32 var3, u32 var4, u8 var5)
nationalSpecies = SpeciesToNationalPokedexNum(species);
// nested if check to fool compiler
- if(sentToPc < 2)
+ switch(sentToPc)
{
- if(sentToPc >= 0)
- {
- // set both the seen and caught flags
- sub_8090D90(nationalSpecies, 2);
- sub_8090D90(nationalSpecies, 3);
- }
+ case 0:
+ case 1:
+ GetNationalPokedexFlag(nationalSpecies, 2);
+ GetNationalPokedexFlag(nationalSpecies, 3);
+ return sentToPc;
+ default:
+ return sentToPc;
}
- return sentToPc;
}
u8 ScriptGiveEgg(u16 value)
diff --git a/src/script_pokemon_util_80F99CC.c b/src/script_pokemon_util_80F99CC.c
index 9e833ec34..606cd9dd4 100644
--- a/src/script_pokemon_util_80F99CC.c
+++ b/src/script_pokemon_util_80F99CC.c
@@ -1,9 +1,13 @@
#include "global.h"
-#include "asm.h"
#include "battle_party_menu.h"
+#include "choose_party.h"
+#include "contest.h"
#include "data2.h"
+#include "field_fadetransition.h"
#include "palette.h"
+#include "party_menu.h"
#include "pokemon.h"
+#include "pokemon_summary_screen.h"
#include "rom4.h"
#include "script.h"
#include "script_pokemon_80F9.h"
@@ -18,23 +22,7 @@ extern u16 gSpecialVar_0x8005;
extern u8 gUnknown_02038694;
extern u16 gScriptResult;
-extern void (*gUnknown_0300485C)(void);
-
-extern void OpenPartyMenu(u8, u8);
-extern void TryCreatePartyMenuMonIcon(u8, u8, struct Pokemon *);
-extern void LoadHeldItemIconGraphics(void);
-extern void CreateHeldItemIcons_806DC34(); // undefined args
-extern u8 sub_806BD58(u8, u8);
-extern void PartyMenuPrintMonsLevelOrStatus(void);
-extern void PrintPartyMenuMonNicknames(void);
-extern u8 sub_806B58C(u8);
-extern u8 sub_80AE47C(struct Pokemon *party);
-extern void sub_806BC3C(u8, u8);
-extern u16 sub_806BD80(); // undefined args in battle_party_menu.c
-extern u8 sub_806CA38();
-extern void sub_8123138(u8);
-extern u8 sub_8040574(struct Pokemon *party);
-extern void sub_809D9F0(struct Pokemon *party, u8, u8, void *, u32);
+extern void (*gFieldCallback)(void);
void sub_80F99CC(void)
{
@@ -71,7 +59,7 @@ void sub_80F9A8C(u8 taskId)
if(!gPaletteFade.active)
{
gPaletteFade.bufferTransferDisabled = 1;
- OpenPartyMenu(gTasks[taskId].data[0], 0);
+ OpenPartyMenu((u8) gTasks[taskId].data[0], 0);
DestroyTask(taskId);
}
}
@@ -284,7 +272,7 @@ void sub_80F9EEC(void)
{
sub_809D9F0(&gPlayerParty[0], gSpecialVar_0x8004, gPlayerPartyCount - 1, c2_exit_to_overworld_2_switch, 0);
unk_2018000.unk8 = 3;
- gUnknown_0300485C = sub_8080990;
+ gFieldCallback = sub_8080990;
}
void sub_80F9F3C(void) // count pokemon moves
diff --git a/src/secret_base.c b/src/secret_base.c
index aae3853f9..6291051a6 100644
--- a/src/secret_base.c
+++ b/src/secret_base.c
@@ -1,22 +1,25 @@
#include "global.h"
-#include "string_util.h"
-#include "strings.h"
-#include "text.h"
+#include "secret_base.h"
+#include "decoration.h"
#include "event_data.h"
-#include "vars.h"
-#include "rom4.h"
-#include "asm.h"
-#include "script.h"
-#include "field_player_avatar.h"
#include "field_camera.h"
-#include "map_constants.h"
-#include "task.h"
-#include "palette.h"
+#include "field_fadetransition.h"
+#include "field_player_avatar.h"
#include "field_weather.h"
+#include "fieldmap.h"
+#include "main.h"
+#include "map_constants.h"
+#include "map_name_popup.h"
#include "metatile_behavior.h"
+#include "palette.h"
#include "pokemon.h"
+#include "rom4.h"
#include "script.h"
-#include "decoration.h"
+#include "string_util.h"
+#include "strings.h"
+#include "task.h"
+#include "text.h"
+#include "vars.h"
extern u8 gUnknown_020387DC;
extern u16 gSpecialVar_0x8004;
@@ -30,8 +33,8 @@ extern const struct
u16 unk_083D1358_1;
} gUnknown_083D1358[7];
extern const u8 gUnknown_083D1374[4 * 16];
+extern void *gUnknown_0300485C;
extern const u8 gUnknown_083D13EC[12];
-extern const u8 sub_80BCCA4(u8);
extern u8 gUnknown_081A2E14[];
@@ -250,7 +253,7 @@ void sub_80BBA48(u8 taskid)
gSaveBlock1.secretBases[curbaseid].sbr_field_10 ++;
sub_80BBA14();
warp_in();
- gUnknown_0300485C = sub_8080990;
+ gFieldCallback = sub_8080990;
SetMainCallback2(CB2_LoadMap);
DestroyTask(taskid);
break;
@@ -299,7 +302,7 @@ void sub_80BBBEC(u8 taskid)
idx = 4 * (gUnknown_020387DC / 10);
warp1_set(gSaveBlock1.location.mapGroup, gSaveBlock1.location.mapNum, -1, gUnknown_083D1374[idx + 2], gUnknown_083D1374[idx + 3]);
warp_in();
- gUnknown_0300485C = sub_80BBB90;
+ gFieldCallback = sub_80BBB90;
SetMainCallback2(CB2_LoadMap);
DestroyTask(taskid);
}
@@ -793,7 +796,7 @@ void sub_80BC074(u8 taskid)
case 2:
copy_saved_warp2_bank_and_enter_x_to_warp1(0x7E);
warp_in();
- gUnknown_0300485C = mapldr_default;
+ gFieldCallback = mapldr_default;
SetMainCallback2(CB2_LoadMap);
ScriptContext2_Disable();
DestroyTask(taskid);
@@ -823,8 +826,6 @@ u8 sub_80BC14C(u8 sbid)
return 0;
}
-
-
u8 *sub_80BC190(u8 *dest, u8 arg1) { // 80bc190
u8 local1;
u8 *str;
diff --git a/src/shop.c b/src/shop.c
index 81c403e92..d53646a88 100644
--- a/src/shop.c
+++ b/src/shop.c
@@ -1,9 +1,12 @@
#include "global.h"
-#include "asm.h"
+#include "shop.h"
#include "decompress.h"
+#include "field_fadetransition.h"
#include "field_weather.h"
+#include "item_menu.h"
#include "main.h"
#include "menu.h"
+#include "menu_helpers.h"
#include "money.h"
#include "palette.h"
#include "script.h"
@@ -11,6 +14,8 @@
#include "sprite.h"
#include "strings.h"
#include "task.h"
+#include "tv.h"
+#include "unknown_task.h"
struct UnknownShopStruct
{
@@ -35,26 +40,6 @@ extern u16 gBuyMenuFrame_Tilemap[];
extern u16 gMenuMoneyPal[16];
extern u16 gUnknown_083CC710[2];
-extern void sub_80A6300(void);
-extern void sub_80BE3BC(void);
-extern void DisplayItemMessageOnField(u8, const u8*, TaskFunc, u16);
-extern u8 sub_807D770(void);
-extern void pal_fill_black(void);
-extern void sub_80B3764(int, int);
-extern void sub_80B37EC(void);
-extern void sub_80B40E8(u8);
-extern void BuyMenuDrawMapGraphics(void);
-extern void sub_80F944C(void);
-extern void CreateVerticalScrollIndicators(u32, u32, u32); // unknown args
-extern void sub_80F979C(u32, u32); // unknown args
-
-void sub_80B2E38(u8);
-void HandleShopMenuQuit(u8);
-void sub_80B2FA0(u8);
-void BuyMenuDrawGraphics(void);
-void sub_80B3240(void);
-void sub_80B3270(void);
-
u8 CreateShopMenu(bool8 var)
{
ScriptContext2_Enable();
@@ -154,7 +139,7 @@ void sub_80B2F30(u8 taskId)
void HandleShopMenuQuit(u8 taskId)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
MenuZeroFillWindowRect(0, 0, 11, 8);
sub_80BE3BC(); // in tv.s?
ScriptContext2_Disable();
diff --git a/src/slot_machine.c b/src/slot_machine.c
index c087bf6b4..c9a06a758 100644
--- a/src/slot_machine.c
+++ b/src/slot_machine.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "slot_machine.h"
#include "decompress.h"
#include "palette.h"
#include "task.h"
@@ -31,11 +32,6 @@ extern const u16 gUnknown_08E95A18[];
extern u16 gUnknown_08E95AB8[];
extern u16 gUnknown_08E95FB8[];
-
-void sub_8104DA4(void);
-
-u8 sub_8105BB4(u8, u8, s16);
-
static void LoadSlotMachineWheelOverlay(void);
void sub_8104CAC(u8 arg0) {
diff --git a/src/smokescreen.c b/src/smokescreen.c
index 0406c1cb3..8345cb6ad 100644
--- a/src/smokescreen.c
+++ b/src/smokescreen.c
@@ -2,8 +2,8 @@
#include "data2.h"
#include "decompress.h"
#include "sprite.h"
+#include "util.h"
-extern u8 CreateInvisibleSpriteWithCallback(void (*)(struct Sprite *));
static void sub_8046388(struct Sprite *);
diff --git a/src/sound.c b/src/sound.c
index ed69ca01d..c9c4916b0 100644
--- a/src/sound.c
+++ b/src/sound.c
@@ -1,9 +1,9 @@
#include "global.h"
#include "gba/m4a_internal.h"
#include "sound.h"
-#include "asm.h"
#include "battle.h"
#include "m4a.h"
+#include "main.h"
#include "songs.h"
#include "task.h"
@@ -13,7 +13,7 @@ struct Fanfare
u16 duration;
};
-// Hack: different prototype than definition
+// FIXME: different prototype than definition
u32 SpeciesToCryId(u32);
extern u16 gBattleTypeFlags;
diff --git a/src/sprite.c b/src/sprite.c
index 409c66cfa..fb8c2b648 100644
--- a/src/sprite.c
+++ b/src/sprite.c
@@ -57,7 +57,6 @@ static void ClearSpriteCopyRequests(void);
static void ResetOamMatrices(void);
static void ResetSprite(struct Sprite *sprite);
static s16 AllocSpriteTiles(u16 tileCount);
-u8 SpriteTileAllocBitmapOp(u16 bit, u8 op);
static void RequestSpriteFrameImageCopy(u16 index, u16 tileNum, const struct SpriteFrameImage *images);
static void ResetAllSprites(void);
static void BeginAnim(struct Sprite *sprite);
diff --git a/src/start_menu.c b/src/start_menu.c
index a3258bab1..e05f3a999 100644
--- a/src/start_menu.c
+++ b/src/start_menu.c
@@ -1,10 +1,11 @@
#include "global.h"
#include "start_menu.h"
-#include "asm.h"
#include "event_data.h"
#include "field_map_obj_helpers.h"
#include "field_player_avatar.h"
#include "field_weather.h"
+#include "fieldmap.h"
+#include "item_menu.h"
#include "load_save.h"
#include "main.h"
#include "map_obj_lock.h"
@@ -12,6 +13,8 @@
#include "option_menu.h"
#include "palette.h"
#include "pokedex.h"
+#include "pokemon_menu.h"
+#include "pokenav.h"
#include "rom4.h"
#include "safari_zone.h"
#include "save.h"
@@ -25,6 +28,7 @@
#include "strings2.h"
#include "task.h"
#include "trainer_card.h"
+#include "unknown_task.h"
//Menu actions
enum {
@@ -49,7 +53,6 @@ extern u16 gSaveFileStatus;
extern u16 gScriptResult;
extern u8 (*gCallback_03004AE8)(void);
extern u8 gUnknown_03004860;
-extern u8 gNumSafariBalls;
EWRAM_DATA static u8 sStartMenuCursorPos = 0;
EWRAM_DATA static u8 sNumStartMenuActions = 0;
@@ -399,7 +402,7 @@ static u8 StartMenu_PlayerCallback(void)
//When player selects SAVE
static u8 StartMenu_SaveCallback(void)
{
- sub_8072DEC();
+ HandleDestroyMenuCursors();
gCallback_03004AE8 = SaveCallback1;
return 0;
}
diff --git a/src/starter_choose.c b/src/starter_choose.c
index 32b6adf36..f30be8e08 100644
--- a/src/starter_choose.c
+++ b/src/starter_choose.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "starter_choose.h"
-#include "asm.h"
#include "data2.h"
#include "decompress.h"
#include "main.h"
@@ -15,6 +14,7 @@
#include "strings.h"
#include "task.h"
#include "trig.h"
+#include "unknown_task.h"
extern u16 gScriptResult;
extern struct SpriteTemplate gUnknown_02024E8C;
@@ -23,7 +23,7 @@ extern struct SpriteTemplate gUnknown_02024E8C;
// Graphics Data
//--------------------------------------------------
-const u16 gBirchBagGrassPal[][16] =
+const u16 gBirchBagGrassPal[2][16] =
{
INCBIN_U16("graphics/misc/birch_bag.gbapal"),
INCBIN_U16("graphics/misc/birch_grass.gbapal"),
@@ -483,7 +483,7 @@ static void AddTextColorCtrlCode(u8 *string, u8 bgColor, u8 textColor, u8 shadow
static void CreateStarterPokemonLabel(u8 prevSelection, u8 selection)
{
u8 labelText[72];
- u8 *category;
+ const u8 *category;
u8 srcIndex;
u8 dstIndex;
u16 species;
diff --git a/src/strings.c b/src/strings.c
index f41af082c..cc0641dce 100644
--- a/src/strings.c
+++ b/src/strings.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "strings.h"
#if ENGLISH
// placeholder strings
@@ -923,7 +924,6 @@ const u8 gSystemText_NoSaveFileNoTime[] = _("There is no save file, so the time\
const u8 gSystemText_ClockAdjustmentUsable[] = _("The in-game clock adjustment system\nis now useable.");
const u8 gSystemText_Saving[] = _("SAVING...\nDON’T TURN OFF THE POWER.");
#elif GERMAN
-#include "global.h"
// placeholder strings
const u8 gExpandedPlaceholder_Empty[] = _("");
@@ -1149,7 +1149,7 @@ const u8 gOtherText_OkayToThrowAwayPrompt[] = _("Willst du wirklich\n{STR_VAR_2}
const u8 gOtherText_DadsAdvice[] = _("VATI sagt immer...\n{PLAYER}, dies ist weder der rechte\lOrt noch der rechte Zeitpunkt dafür!{PAUSE_UNTIL_PRESS}");
const u8 gOtherText_CantGetOffBike[] = _("Du kannst hier nicht vom RAD steigen.{PAUSE_UNTIL_PRESS}");
const u8 gOtherText_ItemfinderResponding[] = _("Oh!\nDas Gerät zeigt etwas an!\pHier muss ein Item vergraben sein!{PAUSE_UNTIL_PRESS}");
-const u8 gOtherText_ItemfinderItemUnderfoot[] = _("Das Gerät macht direkt unter\ndeinen Füßen etwas aus!{PAUSE_UNTIL_PRESS}");
+const u8 gOtherText_ItemfinderItemUnderfoot[] = _("Das Gerät macht direkt unter\ndeinen Füßen etwas aus!{PAUSE_UNTIL_PRESS}");
const u8 gOtherText_NoResponse[] = _("... ... ... ... Nichts!\nKeine Anzeige.{PAUSE_UNTIL_PRESS}");
const u8 gOtherText_Coins3[] = _("Deine MÜNZEN:\n{STR_VAR_1}{PAUSE_UNTIL_PRESS}");
const u8 gOtherText_BootedTM[] = _("Eine TM wurde aktiviert.");
diff --git a/src/time_events.c b/src/time_events.c
index 8cbf52a1a..e1b9a2e9e 100644
--- a/src/time_events.c
+++ b/src/time_events.c
@@ -1,5 +1,7 @@
#include "global.h"
+#include "time_events.h"
#include "event_data.h"
+#include "field_weather.h"
#include "pokemon.h"
#include "rng.h"
#include "rom4.h"
@@ -7,16 +9,14 @@
#include "script.h"
#include "task.h"
-extern bool8 sub_807DDFC(void);
-
-u32 GetMirageRnd(void)
+static u32 GetMirageRnd(void)
{
u32 hi = VarGet(VAR_MIRAGE_RND_H);
u32 lo = VarGet(VAR_MIRAGE_RND_L);
return (hi << 16) | lo;
}
-void SetMirageRnd(u32 rnd)
+static void SetMirageRnd(u32 rnd)
{
VarSet(VAR_MIRAGE_RND_H, rnd >> 16);
VarSet(VAR_MIRAGE_RND_L, rnd);
diff --git a/src/title_screen.c b/src/title_screen.c
index 241e5489e..12c31d10a 100644
--- a/src/title_screen.c
+++ b/src/title_screen.c
@@ -1,7 +1,6 @@
#include "global.h"
#include "gba/m4a_internal.h"
#include "title_screen.h"
-#include "asm.h"
#include "clear_save_data_menu.h"
#include "decompress.h"
#include "event_data.h"
@@ -10,9 +9,11 @@
#include "main.h"
#include "main_menu.h"
#include "palette.h"
+#include "reset_rtc_screen.h"
#include "sound.h"
#include "sprite.h"
#include "task.h"
+#include "unknown_task.h"
extern u8 gReservedSpritePaletteCount;
extern struct MusicPlayerInfo gMPlay_BGM;
diff --git a/src/trainer_card.c b/src/trainer_card.c
index ef3a2d857..b2a1ad71b 100644
--- a/src/trainer_card.c
+++ b/src/trainer_card.c
@@ -1,7 +1,8 @@
#include "global.h"
#include "trainer_card.h"
-#include "asm.h"
+#include "easy_chat.h"
#include "event_data.h"
+#include "field_effect.h"
#include "link.h"
#include "main.h"
#include "menu.h"
@@ -16,6 +17,8 @@
#include "string_util.h"
#include "strings2.h"
#include "task.h"
+#include "unknown_task.h"
+#include "util.h"
typedef void (*Callback)(void);
@@ -68,9 +71,8 @@ extern u16 gUnknown_08E8D9C0[];
extern bool8 (*const gUnknown_083B5EBC[])(struct Task *);
extern bool8 (*const gUnknown_083B5ED8[])(struct Task *);
-// Other signature than on save_menu_util.h
+// FIXME: Other signature than on save_menu_util.h
void FormatPlayTime(u8 *playtime, u16 hours, u16 minutes, s16 colon);
-
u16 GetPokedexSeenCount(void);
enum
diff --git a/src/trainer_see.c b/src/trainer_see.c
index 6c2bf0ab0..9b7a47f6b 100644
--- a/src/trainer_see.c
+++ b/src/trainer_see.c
@@ -1,7 +1,5 @@
#include "global.h"
#include "trainer_see.h"
-#include "asm.h"
-#include "asm_fieldmap.h"
#include "battle_setup.h"
#include "field_effect.h"
#include "field_map_obj.h"
@@ -9,6 +7,7 @@
#include "script.h"
#include "sprite.h"
#include "task.h"
+#include "util.h"
extern bool8 (*gIsTrainerInRange[])(struct MapObject *, u16, s16, s16);
extern bool8 (*gTrainerSeeFuncList[])(u8, struct Task *, struct MapObject *);
diff --git a/src/tv.c b/src/tv.c
index e1bf7c8fe..ca9785da6 100644
--- a/src/tv.c
+++ b/src/tv.c
@@ -1,7 +1,9 @@
#include "global.h"
-#include "asm.h"
#include "tv.h"
+#include "battle_tower.h"
+#include "contest_painting.h"
#include "data2.h"
+#include "easy_chat.h"
#include "event_data.h"
#include "fieldmap.h"
#include "field_message_box.h"
@@ -19,17 +21,30 @@
#include "battle.h"
#include "link.h"
#include "easy_chat.h"
+#include "field_map_obj.h"
+#include "field_specials.h"
#include "item.h"
#include "items.h"
-#include "contest_painting.h"
+#include "link.h"
+#include "map_constants.h"
+#include "naming_screen.h"
+#include "pokedex.h"
+#include "region_map.h"
+#include "rng.h"
+#include "rom4.h"
#include "rtc.h"
+#include "script_menu.h"
+#include "species.h"
+#include "string_util.h"
+#include "strings.h"
+#include "text.h"
struct UnkTvStruct
{
s8 var0;
};
-extern struct UnknownStruct11 gUnknown_030042E0;
+extern struct Struct30042E0 gUnknown_030042E0;
extern u8 gUnknown_0300430A[11];
struct OutbreakPokemon
@@ -40,13 +55,13 @@ struct OutbreakPokemon
/*0x0B*/ u8 location;
};
-extern u8 *gUnknown_083D1464[3];
-extern u8 gUnknown_02038694;
-
struct TVSaleItem {
u16 item_id;
u16 item_amount;
};
+
+extern u8 gUnknown_02038694;
+
extern struct TVSaleItem gUnknown_02038724[3];
extern u16 gSpecialVar_0x8004;
@@ -73,11 +88,8 @@ extern u8 *gTVFishingGuruAdviceTextGroup[];
extern u8 *gTVWorldOfMastersTextGroup[];
extern struct OutbreakPokemon gPokeOutbreakSpeciesList[5];
-extern void sub_80BEBF4(void);
-
extern u16 gUnknown_020387E0;
extern u16 gUnknown_020387E2;
-extern const u8 *gUnknown_083CE048[];
extern const u8 *gTVNewsTextGroup1[];
extern const u8 *gTVNewsTextGroup2[];
@@ -85,7 +97,20 @@ extern const u8 *gTVNewsTextGroup3[];
extern u16 gScriptLastTalked;
-u32 GetPlayerTrainerId(void);
+
+extern u8 gScriptContestCategory;
+extern u8 gScriptContestRank;
+extern u8 gUnknown_03004316[11];
+extern u8 gUnknown_02024D26;
+
+extern u16 gUnknown_02024C04;
+
+extern u8 ewram[];
+#define gUnknown_02007000 (*(ewramStruct_02007000 *)(ewram + 0x7000))
+extern u8 gUnknown_020387E4;
+
+extern u8 gUnknown_03000720;
+extern s8 gUnknown_03000722;
void ClearTVShowData(void)
{
@@ -302,7 +327,7 @@ void SetTVMetatilesOnMap(int, int, u16);
bool8 sub_80BECA0(void);
bool8 IsTVShowInSearchOfTrainersAiring(void);
-void UpdateTVScreensOnMap(int a0, int a1)
+void UpdateTVScreensOnMap(int width, int height)
{
u8 bigMovieOrEmergencyNewsOnTv;
FlagSet(SYS_TV_WATCH);
@@ -310,19 +335,19 @@ void UpdateTVScreensOnMap(int a0, int a1)
switch (bigMovieOrEmergencyNewsOnTv)
{
case 1:
- SetTVMetatilesOnMap(a0, a1, 0x3);
+ SetTVMetatilesOnMap(width, height, 0x3);
break;
case 2:
break;
default:
if (gSaveBlock1.location.mapGroup == MAP_GROUP_LILYCOVE_CITY_COVE_LILY_MOTEL_1F && gSaveBlock1.location.mapNum == MAP_ID_LILYCOVE_CITY_COVE_LILY_MOTEL_1F)
{
- SetTVMetatilesOnMap(a0, a1, 0x3);
+ SetTVMetatilesOnMap(width, height, 0x3);
}
else if (FlagGet(SYS_TV_START) && (sub_80BD8B8() != 0xff || sub_80BECA0() != 0xff || IsTVShowInSearchOfTrainersAiring()))
{
FlagReset(SYS_TV_WATCH);
- SetTVMetatilesOnMap(a0, a1, 0x3);
+ SetTVMetatilesOnMap(width, height, 0x3);
}
}
}
@@ -1141,8 +1166,6 @@ void UpdateMassOutbreakTimeLeft(u16 arg0)
gSaveBlock1.outbreakUnk5 -= arg0;
}
-void sub_80BE9D4();
-
void sub_80BE97C(bool8 flag)
{
u8 var0, var1;
@@ -1241,15 +1264,6 @@ void sub_80BEA88(void)
}
}
-int sub_80BEBC8(struct UnknownSaveStruct2ABC *arg0);
-void sub_80BEC10(u8);
-void sub_80BF588(TVShow tvShows[]);
-void sub_80BF6D8(void);
-bool8 sub_80BF77C(u16);
-bool8 sub_80BEE48(u8);
-
-bool8 IsPriceDiscounted(u8);
-
void sub_80BEB20(void) {
u16 rval;
struct SaveBlock1 *save;
@@ -1453,16 +1467,16 @@ void sub_80BEF10(u8 strvaridx, u8 rank)
switch (rank)
{
case NORMAL_RANK:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[NORMAL_RANK + 5]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[NORMAL_RANK + 5].text);
break;
case SUPER_RANK:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[SUPER_RANK + 5]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[SUPER_RANK + 5].text);
break;
case HYPER_RANK:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[HYPER_RANK + 5]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[HYPER_RANK + 5].text);
break;
case MASTER_RANK:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[MASTER_RANK + 5]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[MASTER_RANK + 5].text);
break;
}
}
@@ -1472,19 +1486,19 @@ void CopyContestCategoryToStringVar(u8 strvaridx, u8 category)
switch (category)
{
case CONTEST_COOL:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_COOL]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_COOL].text);
break;
case CONTEST_BEAUTY:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_BEAUTY]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_BEAUTY].text);
break;
case CONTEST_CUTE:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_CUTE]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_CUTE].text);
break;
case CONTEST_SMART:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_SMART]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_SMART].text);
break;
case CONTEST_TOUGH:
- StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_TOUGH]);
+ StringCopy(gUnknown_083D1464[strvaridx], gUnknown_083CE048[CONTEST_TOUGH].text);
break;
}
}
@@ -1774,7 +1788,7 @@ u16 sub_80BF674(u16 species)
u16 cspecies;
rspecies = (Random() % (NUM_SPECIES - 1)) + 1;
cspecies = rspecies;
- while ((s8)sub_8090D90(SpeciesToNationalPokedexNum(cspecies), 0) != 1 || cspecies == species) {
+ while ((s8)GetNationalPokedexFlag(SpeciesToNationalPokedexNum(cspecies), 0) != 1 || cspecies == species) {
if (cspecies == SPECIES_BULBASAUR)
cspecies = NUM_SPECIES - 1;
else
@@ -2158,10 +2172,6 @@ void sub_80BFD20(void)
RemoveFieldObjectByLocalIdAndMap(5, gSaveBlock1.location.mapNum, gSaveBlock1.location.mapGroup);
}
-extern u8 ewram[];
-#define gUnknown_02007000 (*(ewramStruct_02007000 *)(ewram + 0x7000))
-extern u8 gUnknown_020387E4;
-
typedef union ewramStruct_02007000 {
TVShow tvshows[4][25];
struct UnknownSaveStruct2ABC unknown_2abc[4][16];
@@ -2450,9 +2460,6 @@ s8 sub_80C019C(TVShow tvShows[]) {
return -1;
}
-void sub_80C03A8(u8 showidx);
-void sub_80C03C8(u16 species, u8 showidx);
-
#ifdef NONMATCHING
void sub_80C01D4(void)
{
@@ -2718,7 +2725,7 @@ void sub_80C03A8(u8 showidx) {
}
void sub_80C03C8(u16 species, u8 showidx) {
- if (!sub_8090D90(SpeciesToNationalPokedexNum(species), 0)) {
+ if (GetNationalPokedexFlag(SpeciesToNationalPokedexNum(species), 0) == 0) {
gSaveBlock1.tvShows[showidx].common.var01 = 0;
}
}
@@ -2875,22 +2882,6 @@ void sub_80C05C4(struct UnknownSaveStruct2ABC a0[16], struct UnknownSaveStruct2A
}
}
-void DoTVShowPokemonFanClubLetter(void);
-void DoTVShowRecentHappenings(void);
-void DoTVShowPokemonFanClubOpinions(void);
-void nullsub_22(void);
-void DoTVShowPokemonNewsMassOutbreak(void);
-void DoTVShowBravoTrainerPokemonProfile(void);
-void DoTVShowBravoTrainerBattleTowerProfile(void);
-void DoTVShowPokemonTodaySuccessfulCapture(void);
-void DoTVShowTodaysSmartShopper(void);
-void DoTVShowTheNameRaterShow(void);
-void DoTVShowPokemonTodayFailedCapture(void);
-void DoTVShowPokemonAngler(void);
-void DoTVShowTheWorldOfMasters(void);
-
-bool8 sub_80C06E8(struct UnknownSaveStruct2ABC *arg0, struct UnknownSaveStruct2ABC *arg1, s8 arg2);
-
void sub_80C06BC(struct UnknownSaveStruct2ABC *arg0[16], struct UnknownSaveStruct2ABC *arg1[16]) {
struct UnknownSaveStruct2ABC *str0;
struct UnknownSaveStruct2ABC *str1;
@@ -3298,10 +3289,6 @@ void DoTVShowTodaysSmartShopper(void)
ShowFieldMessage(gTVSmartShopperTextGroup[switchval]);
}
-void TVShowConvertInternationalString(u8 *, u8 *, u8);
-
-void TakeTVShowInSearchOfTrainersOffTheAir(void);
-
void DoTVShowTheNameRaterShow(void) {
TVShow *tvShow;
u8 switchval;
diff --git a/src/unknown_debug_menu.c b/src/unknown_debug_menu.c
index bbaeef63a..2cdcbaabd 100644
--- a/src/unknown_debug_menu.c
+++ b/src/unknown_debug_menu.c
@@ -7,7 +7,7 @@ extern u8 (*gCallback_03004AE8)(void);
extern const struct MenuAction gUnknown_0842C29C[];
-u8 sub_814A464(void);
+static u8 sub_814A464(void);
int unref_sub_814A414(void)
{
@@ -19,7 +19,7 @@ int unref_sub_814A414(void)
return 0;
}
-u8 sub_814A464(void)
+static u8 sub_814A464(void)
{
s8 result = ProcessMenuInput();
if (result == -2)
diff --git a/src/util.c b/src/util.c
index 55608854c..c83fe8c8a 100644
--- a/src/util.c
+++ b/src/util.c
@@ -1,5 +1,5 @@
#include "global.h"
-#include "sprite.h"
+#include "util.h"
extern const struct SpriteTemplate gInvisibleSpriteTemplate;
extern const u8 gSpriteDimensions[3][4][2];
diff --git a/src/wallclock.c b/src/wallclock.c
index 0b9948adc..efc7dd42a 100644
--- a/src/wallclock.c
+++ b/src/wallclock.c
@@ -1,6 +1,5 @@
#include "global.h"
#include "wallclock.h"
-#include "asm.h"
#include "decompress.h"
#include "main.h"
#include "menu.h"
@@ -11,12 +10,12 @@
#include "strings2.h"
#include "task.h"
#include "trig.h"
+#include "unknown_task.h"
extern u16 gSpecialVar_0x8004;
extern u8 gMiscClock_Gfx[];
extern u8 gUnknown_08E95774[];
extern u8 gUnknown_08E954B0[];
-extern const struct MenuAction gMenuYesNoItems[];
extern u16 gMiscClockMale_Pal[];
extern u16 gMiscClockFemale_Pal[];
@@ -434,7 +433,7 @@ static void Task_SetClock4(u8 taskId)
return;
case -1: //B button
case 1: //NO
- sub_8072DEC();
+ HandleDestroyMenuCursors();
PlaySE(SE_SELECT);
MenuZeroFillWindowRect(23, 8, 29, 13);
MenuZeroFillWindowRect(2, 16, 27, 19);
diff --git a/src/wild_encounter.c b/src/wild_encounter.c
index 9dfcf0e5c..96f47c067 100644
--- a/src/wild_encounter.c
+++ b/src/wild_encounter.c
@@ -1,41 +1,19 @@
#include "global.h"
#include "wild_encounter.h"
#include "abilities.h"
-#include "asm.h"
#include "battle_setup.h"
#include "event_data.h"
#include "field_player_avatar.h"
+#include "fieldmap.h"
#include "metatile_behavior.h"
+#include "pokeblock.h"
#include "rng.h"
#include "roamer.h"
#include "rom4.h"
#include "safari_zone.h"
#include "script.h"
#include "species.h"
-
-struct WildPokemon
-{
- u8 minLevel;
- u8 maxLevel;
- u16 species;
-};
-
-struct WildPokemonInfo
-{
- u8 encounterRate;
- const struct WildPokemon *wildPokemon;
-};
-
-struct WildPokemonHeader
-{
- u8 mapGroup;
- u8 mapNum;
- struct WildPokemonInfo *landMonsInfo;
- struct WildPokemonInfo *waterMonsInfo;
- struct WildPokemonInfo *rockSmashMonsInfo;
- struct WildPokemonInfo *fishingMonsInfo;
-};
-
+#include "tv.h"
const struct WildPokemon PetalburgCity_WaterMons [] =
{
@@ -2921,9 +2899,6 @@ const struct WildPokemonInfo Underwater2_WaterMonsInfo = {4, Underwater2_WaterMo
extern u16 gRoute119WaterTileData[];
-extern struct WildPokemonHeader gWildMonHeaders[];
-extern struct Pokemon gEnemyParty[6];
-extern struct Pokemon gPlayerParty[6];
extern u16 gScriptResult;
extern struct WildPokemon gWildFeebasRoute119Data;
extern u8 Event_RepelWoreOff[];
diff --git a/sym_bss.txt b/sym_bss.txt
index c7e0b5d6e..315bad6bb 100644
--- a/sym_bss.txt
+++ b/sym_bss.txt
@@ -160,7 +160,7 @@ gUnknown_03000760: @ 3000760
gUnknown_030007B0: @ 30007B0
.space 0x4
-gUnknown_030007B4: @ 30007B4
+gPcItemMenuOptionsNum: @ 30007B4
.space 0x4
gUnknown_030007B8: @ 30007B8
diff --git a/sym_common.txt b/sym_common.txt
index f8645c427..407dca9d1 100644
--- a/sym_common.txt
+++ b/sym_common.txt
@@ -145,7 +145,7 @@ gUnknown_03004854: @ 3004854
word_3004858: @ 3004858
.space 0x4
-gUnknown_0300485C: @ 300485C
+gFieldCallback: @ 300485C
.space 0x4
gUnknown_03004860: @ 3004860
diff --git a/sym_ewram.txt b/sym_ewram.txt
index bf976e5dd..dadf5e615 100644
--- a/sym_ewram.txt
+++ b/sym_ewram.txt
@@ -976,7 +976,7 @@ gUnknown_02039310: @ 2039310
gUnknown_02039312: @ 2039312
.space 0x2
-gUnknown_02039314: @ 2039314
+gPcItemMenuOptionOrder: @ 2039314
.space 0x4
gUnknown_02039318: @ 2039318