summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSlawter666 <38655737+Slawter666@users.noreply.github.com>2018-11-14 00:01:50 +0000
committerSlawter666 <38655737+Slawter666@users.noreply.github.com>2018-11-14 00:01:50 +0000
commit4311fd8b89903a35a4485ff7db8a44036bfd1bdc (patch)
treec9851d26cc3c1657fd6b84b5eaaeb7e7074ccd1c /src
parent6fcf878e2f8b4836a2652cd2c90ef5cf67c4b976 (diff)
Sort includes into alphabetical order
Diffstat (limited to 'src')
-rw-r--r--src/battle_ai_script_commands.c14
-rw-r--r--src/battle_ai_switch_items.c6
-rw-r--r--src/battle_anim_80A5C6C.c12
-rw-r--r--src/battle_anim_80A9C70.c8
-rw-r--r--src/battle_anim_sound_tasks.c8
-rw-r--r--src/battle_arena.c24
-rw-r--r--src/battle_controller_link_opponent.c32
-rw-r--r--src/battle_controller_link_partner.c32
-rw-r--r--src/battle_controller_opponent.c44
-rw-r--r--src/battle_controller_player.c48
-rw-r--r--src/battle_controller_player_partner.c32
-rw-r--r--src/battle_controller_recorded_opponent.c36
-rw-r--r--src/battle_controller_recorded_player.c30
-rw-r--r--src/battle_controller_safari.c28
-rw-r--r--src/battle_controller_wally.c42
-rw-r--r--src/battle_controllers.c10
-rw-r--r--src/battle_main.c4
-rw-r--r--src/field_door.c6
-rw-r--r--src/field_poison.c2
-rw-r--r--src/field_region_map.c18
-rw-r--r--src/field_tasks.c28
-rw-r--r--src/fieldmap.c6
-rw-r--r--src/fldeff_escalator.c4
-rw-r--r--src/fldeff_flash.c5
-rw-r--r--src/fldeff_groundshake.c7
-rw-r--r--src/fldeff_softboiled.c2
-rw-r--r--src/pokeball.c20
-rw-r--r--src/pokeblock.c48
-rw-r--r--src/pokeblock_feed.c34
-rw-r--r--src/pokedex.c43
-rw-r--r--src/pokemon.c59
-rw-r--r--src/pokemon_animation.c6
-rw-r--r--src/pokemon_icon.c6
-rw-r--r--src/pokemon_size_record.c6
-rw-r--r--src/pokemon_storage_system.c30
35 files changed, 367 insertions, 373 deletions
diff --git a/src/battle_ai_script_commands.c b/src/battle_ai_script_commands.c
index ab850f4fb..3e7064eb5 100644
--- a/src/battle_ai_script_commands.c
+++ b/src/battle_ai_script_commands.c
@@ -1,18 +1,18 @@
#include "global.h"
-#include "battle_ai_script_commands.h"
-#include "pokemon.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_factory.h"
#include "battle_setup.h"
-#include "recorded_battle.h"
-#include "random.h"
#include "item.h"
+#include "pokemon.h"
+#include "random.h"
+#include "recorded_battle.h"
#include "util.h"
-#include "battle_factory.h"
-#include "constants/species.h"
#include "constants/abilities.h"
+#include "constants/battle_ai.h"
#include "constants/battle_move_effects.h"
#include "constants/moves.h"
-#include "constants/battle_ai.h"
+#include "constants/species.h"
#define AI_ACTION_DONE 0x0001
#define AI_ACTION_FLEE 0x0002
diff --git a/src/battle_ai_switch_items.c b/src/battle_ai_switch_items.c
index 40fffd6e5..71d0e8381 100644
--- a/src/battle_ai_switch_items.c
+++ b/src/battle_ai_switch_items.c
@@ -1,13 +1,13 @@
#include "global.h"
#include "battle.h"
#include "battle_controllers.h"
-#include "constants/abilities.h"
-#include "constants/moves.h"
#include "pokemon.h"
-#include "constants/species.h"
#include "random.h"
#include "util.h"
+#include "constants/abilities.h"
#include "constants/items.h"
+#include "constants/moves.h"
+#include "constants/species.h"
// this file's functions
static bool8 HasSuperEffectiveMoveAgainstOpponents(bool8 noRng);
diff --git a/src/battle_anim_80A5C6C.c b/src/battle_anim_80A5C6C.c
index ebe1718b7..d213e4831 100644
--- a/src/battle_anim_80A5C6C.c
+++ b/src/battle_anim_80A5C6C.c
@@ -1,21 +1,21 @@
#include "global.h"
-#include "constants/battle_anim.h"
-#include "constants/species.h"
#include "battle.h"
#include "battle_anim.h"
+#include "bg.h"
#include "contest.h"
#include "data2.h"
#include "decompress.h"
+#include "dma3.h"
+#include "gpu_regs.h"
+#include "malloc.h"
#include "palette.h"
#include "pokemon_icon.h"
#include "sprite.h"
#include "task.h"
#include "trig.h"
#include "util.h"
-#include "gpu_regs.h"
-#include "bg.h"
-#include "malloc.h"
-#include "dma3.h"
+#include "constants/battle_anim.h"
+#include "constants/species.h"
#define GET_UNOWN_LETTER(personality) (( \
(((personality & 0x03000000) >> 24) << 6) \
diff --git a/src/battle_anim_80A9C70.c b/src/battle_anim_80A9C70.c
index 89c945ca4..5401247b8 100644
--- a/src/battle_anim_80A9C70.c
+++ b/src/battle_anim_80A9C70.c
@@ -1,15 +1,15 @@
#include "global.h"
#include "battle.h"
#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "constants/rgb.h"
-#include "util.h"
#include "decompress.h"
+#include "gpu_regs.h"
#include "palette.h"
#include "sprite.h"
#include "task.h"
#include "trig.h"
-#include "gpu_regs.h"
+#include "util.h"
+#include "constants/battle_anim.h"
+#include "constants/rgb.h"
extern const struct CompressedSpriteSheet gBattleAnimPicTable[];
extern const struct CompressedSpritePalette gBattleAnimPaletteTable[];
diff --git a/src/battle_anim_sound_tasks.c b/src/battle_anim_sound_tasks.c
index 7b8eb4ed7..b49a6d03f 100644
--- a/src/battle_anim_sound_tasks.c
+++ b/src/battle_anim_sound_tasks.c
@@ -1,11 +1,11 @@
#include "global.h"
#include "battle.h"
-#include "constants/battle_anim.h"
-#include "constants/species.h"
#include "battle_anim.h"
-#include "task.h"
-#include "sound.h"
#include "contest.h"
+#include "sound.h"
+#include "task.h"
+#include "constants/battle_anim.h"
+#include "constants/species.h"
// this file's functions
static void sub_8158B98(u8 taskId);
diff --git a/src/battle_arena.c b/src/battle_arena.c
index 2d9f82ab6..4b47dcaf1 100644
--- a/src/battle_arena.c
+++ b/src/battle_arena.c
@@ -1,22 +1,22 @@
#include "global.h"
-#include "battle_arena.h"
-#include "event_data.h"
-#include "palette.h"
-#include "gpu_regs.h"
-#include "decompress.h"
#include "battle.h"
+#include "battle_arena.h"
#include "battle_message.h"
-#include "text.h"
+#include "battle_setup.h"
+#include "battle_tower.h"
#include "bg.h"
-#include "sound.h"
+#include "decompress.h"
+#include "event_data.h"
+#include "frontier_util.h"
+#include "gpu_regs.h"
+#include "item.h"
#include "m4a.h"
-#include "util.h"
-#include "battle_setup.h"
#include "overworld.h"
-#include "frontier_util.h"
+#include "palette.h"
#include "random.h"
-#include "item.h"
-#include "battle_tower.h"
+#include "sound.h"
+#include "text.h"
+#include "util.h"
#include "constants/songs.h"
#include "constants/battle_string_ids.h"
#include "constants/battle_frontier.h"
diff --git a/src/battle_controller_link_opponent.c b/src/battle_controller_link_opponent.c
index 4fea3aca8..2b6a356dd 100644
--- a/src/battle_controller_link_opponent.c
+++ b/src/battle_controller_link_opponent.c
@@ -1,30 +1,30 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
-#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "battle_ai_script_commands.h"
+#include "battle_message.h"
+#include "battle_setup.h"
#include "battle_tv.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "constants/trainers.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "battle_setup.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_link_partner.c b/src/battle_controller_link_partner.c
index 51e26b620..203883c27 100644
--- a/src/battle_controller_link_partner.c
+++ b/src/battle_controller_link_partner.c
@@ -1,30 +1,30 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
-#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "battle_ai_script_commands.h"
+#include "battle_message.h"
+#include "battle_setup.h"
#include "battle_tv.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "constants/trainers.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "battle_setup.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_opponent.c b/src/battle_controller_opponent.c
index 2629a56c0..54726229d 100644
--- a/src/battle_controller_opponent.c
+++ b/src/battle_controller_opponent.c
@@ -1,37 +1,37 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
+#include "battle_arena.h"
#include "battle_controllers.h"
#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
+#include "battle_setup.h"
+#include "battle_tower.h"
#include "battle_tv.h"
-#include "battle_ai_script_commands.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
+#include "frontier_util.h"
+#include "item.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "item.h"
-#include "constants/items.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "constants/moves.h"
-#include "constants/trainers.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "random.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "random.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "battle_setup.h"
-#include "battle_arena.h"
-#include "battle_tower.h"
-#include "frontier_util.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/items.h"
+#include "constants/moves.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_player.c b/src/battle_controller_player.c
index 20781ca44..ad5ae2059 100644
--- a/src/battle_controller_player.c
+++ b/src/battle_controller_player.c
@@ -1,38 +1,38 @@
#include "global.h"
#include "battle.h"
+#include "battle_anim.h"
+#include "battle_arena.h"
#include "battle_controllers.h"
-#include "battle_message.h"
+#include "battle_dome.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
+#include "battle_message.h"
+#include "battle_setup.h"
#include "battle_tv.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
+#include "item.h"
+#include "item_menu.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "item.h"
-#include "constants/items.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "constants/moves.h"
-#include "constants/trainers.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
-#include "task.h"
-#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "random.h"
+#include "party_menu.h"
#include "pokeball.h"
-#include "data2.h"
-#include "battle_setup.h"
-#include "item_menu.h"
+#include "pokemon.h"
+#include "random.h"
#include "recorded_battle.h"
-#include "party_menu.h"
-#include "battle_dome.h"
-#include "battle_arena.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
+#include "task.h"
+#include "text.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/items.h"
+#include "constants/moves.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u8 gUnknown_0203CEE8;
extern u8 gUnknown_0203CEE9;
diff --git a/src/battle_controller_player_partner.c b/src/battle_controller_player_partner.c
index e893d2f3d..3572c1c69 100644
--- a/src/battle_controller_player_partner.c
+++ b/src/battle_controller_player_partner.c
@@ -1,30 +1,30 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "battle_ai_script_commands.h"
-#include "pokemon.h"
+#include "battle_setup.h"
+#include "bg.h"
+#include "data2.h"
+#include "item_use.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "constants/trainers.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "battle_setup.h"
-#include "item_use.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_recorded_opponent.c b/src/battle_controller_recorded_opponent.c
index 57eb6842e..72667649f 100644
--- a/src/battle_controller_recorded_opponent.c
+++ b/src/battle_controller_recorded_opponent.c
@@ -1,32 +1,32 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
-#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "battle_ai_script_commands.h"
+#include "battle_message.h"
+#include "battle_setup.h"
#include "battle_tv.h"
-#include "recorded_battle.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
+#include "item_use.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "constants/trainers.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "recorded_battle.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "item_use.h"
-#include "battle_setup.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_recorded_player.c b/src/battle_controller_recorded_player.c
index f6c19121d..b74d55cc8 100644
--- a/src/battle_controller_recorded_player.c
+++ b/src/battle_controller_recorded_player.c
@@ -1,29 +1,29 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "battle_ai_script_commands.h"
-#include "recorded_battle.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
+#include "item_use.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "recorded_battle.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "item_use.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_safari.c b/src/battle_controller_safari.c
index 148f13865..a7ea04515 100644
--- a/src/battle_controller_safari.c
+++ b/src/battle_controller_safari.c
@@ -1,27 +1,27 @@
#include "global.h"
#include "battle.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
-#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
-#include "pokemon.h"
+#include "battle_message.h"
+#include "bg.h"
+#include "data2.h"
+#include "item_menu.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
-#include "task.h"
-#include "text.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
#include "pokeball.h"
-#include "data2.h"
#include "pokeblock.h"
-#include "item_menu.h"
+#include "pokemon.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "task.h"
+#include "text.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/songs.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controller_wally.c b/src/battle_controller_wally.c
index 80dd6d3bb..f7e9831a7 100644
--- a/src/battle_controller_wally.c
+++ b/src/battle_controller_wally.c
@@ -1,35 +1,35 @@
#include "global.h"
#include "battle.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
-#include "battle_message.h"
#include "battle_interface.h"
-#include "battle_anim.h"
-#include "constants/battle_anim.h"
+#include "battle_message.h"
+#include "battle_setup.h"
#include "battle_tv.h"
-#include "pokemon.h"
+#include "bg.h"
+#include "data2.h"
+#include "item.h"
+#include "item_menu.h"
#include "link.h"
-#include "util.h"
#include "main.h"
-#include "item.h"
-#include "constants/items.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "constants/moves.h"
-#include "constants/trainers.h"
-#include "window.h"
#include "m4a.h"
#include "palette.h"
+#include "party_menu.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "random.h"
+#include "reshow_battle_screen.h"
+#include "sound.h"
+#include "string_util.h"
#include "task.h"
#include "text.h"
-#include "string_util.h"
-#include "bg.h"
-#include "reshow_battle_screen.h"
-#include "random.h"
-#include "pokeball.h"
-#include "data2.h"
-#include "party_menu.h"
-#include "battle_setup.h"
-#include "item_menu.h"
+#include "util.h"
+#include "window.h"
+#include "constants/battle_anim.h"
+#include "constants/items.h"
+#include "constants/moves.h"
+#include "constants/songs.h"
+#include "constants/trainers.h"
extern u16 gBattle_BG0_X;
extern u16 gBattle_BG0_Y;
diff --git a/src/battle_controllers.c b/src/battle_controllers.c
index 56ff34528..1c6942ead 100644
--- a/src/battle_controllers.c
+++ b/src/battle_controllers.c
@@ -1,17 +1,17 @@
#include "global.h"
#include "battle.h"
+#include "battle_ai_script_commands.h"
+#include "battle_anim.h"
#include "battle_controllers.h"
+#include "battle_message.h"
#include "cable_club.h"
#include "link.h"
-#include "task.h"
-#include "battle_ai_script_commands.h"
-#include "battle_anim.h"
#include "pokemon.h"
-#include "constants/species.h"
#include "recorded_battle.h"
+#include "task.h"
#include "util.h"
#include "constants/abilities.h"
-#include "battle_message.h"
+#include "constants/species.h"
extern u8 gUnknown_02022D08;
extern u8 gUnknown_02022D09;
diff --git a/src/battle_main.c b/src/battle_main.c
index 2546a4eb2..f6c01aee2 100644
--- a/src/battle_main.c
+++ b/src/battle_main.c
@@ -10,9 +10,9 @@
#include "battle_tower.h"
#include "berry.h"
#include "bg.h"
-#include "dma3.h"
#include "data2.h"
#include "decompress.h"
+#include "dma3.h"
#include "event_data.h"
#include "evolution_scene.h"
#include "gpu_regs.h"
@@ -50,9 +50,9 @@
#include "constants/items.h"
#include "constants/moves.h"
#include "constants/rgb.h"
-#include "constants/trainers.h"
#include "constants/songs.h"
#include "constants/species.h"
+#include "constants/trainers.h"
struct UnknownPokemonStruct4
{
diff --git a/src/field_door.c b/src/field_door.c
index fe9de01fd..c197aca14 100644
--- a/src/field_door.c
+++ b/src/field_door.c
@@ -1,13 +1,13 @@
#include "global.h"
+#include "event_data.h"
#include "field_door.h"
#include "field_camera.h"
#include "fieldmap.h"
#include "metatile_behavior.h"
-#include "event_data.h"
-#include "constants/songs.h"
+#include "task.h"
#include "constants/flags.h"
#include "constants/maps.h"
-#include "task.h"
+#include "constants/songs.h"
bool8 sub_808A964(void);
diff --git a/src/field_poison.c b/src/field_poison.c
index e7d2a7e8a..02f37f69f 100644
--- a/src/field_poison.c
+++ b/src/field_poison.c
@@ -1,5 +1,6 @@
#include "global.h"
#include "battle.h"
+#include "battle_pike.h"
#include "event_data.h"
#include "field_message_box.h"
#include "field_poison.h"
@@ -12,7 +13,6 @@
#include "string_util.h"
#include "strings.h"
#include "task.h"
-#include "battle_pike.h"
#include "constants/species.h"
static bool32 IsMonValidSpecies(struct Pokemon *pokemon)
diff --git a/src/field_region_map.c b/src/field_region_map.c
index c15959afc..40f48e668 100644
--- a/src/field_region_map.c
+++ b/src/field_region_map.c
@@ -1,18 +1,16 @@
-
-// Includes
#include "global.h"
+#include "bg.h"
+#include "gpu_regs.h"
+#include "international_string_util.h"
#include "main.h"
#include "malloc.h"
-#include "gpu_regs.h"
-#include "bg.h"
-#include "text.h"
-#include "window.h"
-#include "text_window.h"
-#include "palette.h"
#include "menu.h"
-#include "strings.h"
-#include "international_string_util.h"
+#include "palette.h"
#include "region_map.h"
+#include "strings.h"
+#include "text.h"
+#include "text_window.h"
+#include "window.h"
// Static type declarations
diff --git a/src/field_tasks.c b/src/field_tasks.c
index 5fb23f536..7a7f49120 100644
--- a/src/field_tasks.c
+++ b/src/field_tasks.c
@@ -1,24 +1,24 @@
#include "global.h"
-#include "task.h"
-#include "main.h"
-#include "constants/vars.h"
#include "bike.h"
-#include "item.h"
-#include "constants/items.h"
+#include "clock.h"
#include "event_data.h"
+#include "field_camera.h"
+#include "field_effect_helpers.h"
+#include "field_player_avatar.h"
+#include "field_special_scene.h"
+#include "field_tasks.h"
+#include "fieldmap.h"
+#include "item.h"
+#include "main.h"
+#include "metatile_behavior.h"
#include "overworld.h"
-#include "clock.h"
#include "script.h"
-#include "field_special_scene.h"
-#include "field_effect_helpers.h"
#include "secret_base.h"
-#include "metatile_behavior.h"
-#include "fieldmap.h"
-#include "field_player_avatar.h"
-#include "field_camera.h"
-#include "constants/songs.h"
#include "sound.h"
-#include "field_tasks.h"
+#include "task.h"
+#include "constants/items.h"
+#include "constants/songs.h"
+#include "constants/vars.h"
struct MetatileOffset
{
diff --git a/src/fieldmap.c b/src/fieldmap.c
index 5019b5dc7..0d8a706b1 100644
--- a/src/fieldmap.c
+++ b/src/fieldmap.c
@@ -1,18 +1,18 @@
#include "global.h"
-#include "overworld.h"
#include "bg.h"
-#include "frontier_util.h"
-#include "constants/rgb.h"
#include "fieldmap.h"
#include "fldeff_80F9BCC.h"
#include "fldeff_cut.h"
#include "fldeff_groundshake.h"
+#include "frontier_util.h"
#include "menu.h"
+#include "overworld.h"
#include "palette.h"
#include "pokenav.h"
#include "script.h"
#include "secret_base.h"
#include "tv.h"
+#include "constants/rgb.h"
extern void sub_81AA078(u16*, u8);
diff --git a/src/fldeff_escalator.c b/src/fldeff_escalator.c
index b906225da..7d3e07123 100644
--- a/src/fldeff_escalator.c
+++ b/src/fldeff_escalator.c
@@ -1,8 +1,8 @@
#include "global.h"
-#include "task.h"
-#include "fieldmap.h"
#include "field_camera.h"
#include "field_player_avatar.h"
+#include "fieldmap.h"
+#include "task.h"
static EWRAM_DATA u8 sEscalatorAnim_TaskId = 0;
diff --git a/src/fldeff_flash.c b/src/fldeff_flash.c
index fe219422d..9771232f2 100644
--- a/src/fldeff_flash.c
+++ b/src/fldeff_flash.c
@@ -1,20 +1,19 @@
#include "global.h"
-#include "constants/songs.h"
#include "braille_puzzles.h"
#include "event_data.h"
#include "event_scripts.h"
#include "field_effect.h"
#include "gpu_regs.h"
-#include "gba/io_reg.h"
#include "main.h"
+#include "overworld.h"
#include "palette.h"
#include "party_menu.h"
-#include "overworld.h"
#include "rom6.h"
#include "script.h"
#include "sound.h"
#include "sprite.h"
#include "task.h"
+#include "constants/songs.h"
// structures
struct FlashStruct
diff --git a/src/fldeff_groundshake.c b/src/fldeff_groundshake.c
index 60b078982..e9a46bb86 100644
--- a/src/fldeff_groundshake.c
+++ b/src/fldeff_groundshake.c
@@ -1,10 +1,7 @@
#include "global.h"
-#include "global.fieldmap.h"
-#include "constants/flags.h"
-#include "constants/songs.h"
#include "event_data.h"
-#include "field_camera.h"
#include "event_object_movement.h"
+#include "field_camera.h"
#include "malloc.h"
#include "random.h"
#include "roulette_util.h"
@@ -12,6 +9,8 @@
#include "sound.h"
#include "sprite.h"
#include "task.h"
+#include "constants/flags.h"
+#include "constants/songs.h"
// structures
struct Struct203CF18 {
diff --git a/src/fldeff_softboiled.c b/src/fldeff_softboiled.c
index d0a40a9a9..471a83c61 100644
--- a/src/fldeff_softboiled.c
+++ b/src/fldeff_softboiled.c
@@ -2,12 +2,12 @@
#include "menu.h"
#include "party_menu.h"
#include "pokemon.h"
-#include "constants/songs.h"
#include "sound.h"
#include "sprite.h"
#include "string_util.h"
#include "strings.h"
#include "task.h"
+#include "constants/songs.h"
static void sub_816166C(u8 taskId);
static void sub_81616C0(u8 taskId);
diff --git a/src/pokeball.c b/src/pokeball.c
index bb02a02ba..09e7ac639 100644
--- a/src/pokeball.c
+++ b/src/pokeball.c
@@ -1,19 +1,19 @@
#include "global.h"
-#include "pokemon.h"
-#include "sprite.h"
-#include "pokeball.h"
#include "battle.h"
#include "battle_anim.h"
-#include "task.h"
-#include "sound.h"
-#include "constants/songs.h"
-#include "trig.h"
+#include "decompress.h"
+#include "graphics.h"
#include "main.h"
#include "m4a.h"
-#include "decompress.h"
-#include "constants/species.h"
+#include "pokeball.h"
+#include "pokemon.h"
+#include "sound.h"
+#include "sprite.h"
+#include "task.h"
+#include "trig.h"
#include "util.h"
-#include "graphics.h"
+#include "constants/songs.h"
+#include "constants/species.h"
extern struct MusicPlayerInfo gMPlayInfo_BGM;
diff --git a/src/pokeblock.c b/src/pokeblock.c
index c8f2c67ed..01343c6eb 100644
--- a/src/pokeblock.c
+++ b/src/pokeblock.c
@@ -1,35 +1,35 @@
#include "global.h"
-#include "pokeblock.h"
-#include "bg.h"
-#include "strings.h"
-#include "text.h"
-#include "text_window.h"
-#include "menu.h"
-#include "task.h"
-#include "menu_helpers.h"
-#include "pokemon.h"
-#include "graphics.h"
-#include "malloc.h"
-#include "main.h"
#include "battle.h"
#include "battle_controllers.h"
-#include "palette.h"
-#include "scanline_effect.h"
-#include "list_menu.h"
-#include "gpu_regs.h"
+#include "battle_message.h"
+#include "berry.h"
+#include "bg.h"
#include "decompress.h"
+#include "event_data.h"
+#include "gpu_regs.h"
+#include "graphics.h"
#include "international_string_util.h"
#include "item.h"
-#include "constants/items.h"
-#include "string_util.h"
-#include "constants/songs.h"
-#include "sound.h"
-#include "berry.h"
-#include "event_data.h"
-#include "battle_message.h"
-#include "safari_zone.h"
#include "lilycove_lady.h"
+#include "list_menu.h"
+#include "main.h"
+#include "malloc.h"
+#include "menu.h"
+#include "menu_helpers.h"
#include "overworld.h"
+#include "palette.h"
+#include "pokeblock.h"
+#include "pokemon.h"
+#include "safari_zone.h"
+#include "scanline_effect.h"
+#include "sound.h"
+#include "string_util.h"
+#include "strings.h"
+#include "task.h"
+#include "text.h"
+#include "text_window.h"
+#include "constants/items.h"
+#include "constants/songs.h"
#define POKEBLOCK_MAX_FEEL 99
#define FIELD_E75_COUNT 7
diff --git a/src/pokeblock_feed.c b/src/pokeblock_feed.c
index 6978f0715..0a8f1b8c2 100644
--- a/src/pokeblock_feed.c
+++ b/src/pokeblock_feed.c
@@ -1,28 +1,28 @@
#include "global.h"
-#include "pokeblock.h"
-#include "sprite.h"
-#include "task.h"
-#include "palette.h"
-#include "menu.h"
-#include "malloc.h"
-#include "pokemon.h"
-#include "util.h"
-#include "main.h"
-#include "menu_helpers.h"
+#include "battle.h" // to get rid of once gMonSpritesGfxPtr is put elsewhere
#include "bg.h"
-#include "gpu_regs.h"
#include "data2.h"
#include "decompress.h"
#include "event_data.h"
-#include "strings.h"
-#include "string_util.h"
-#include "party_menu.h"
+#include "gpu_regs.h"
+#include "graphics.h"
+#include "main.h"
+#include "malloc.h"
+#include "menu.h"
+#include "menu_helpers.h"
#include "m4a.h"
+#include "palette.h"
+#include "party_menu.h"
+#include "pokeblock.h"
+#include "pokemon.h"
+#include "sprite.h"
+#include "string_util.h"
+#include "strings.h"
#include "sound.h"
-#include "trig.h"
-#include "graphics.h"
+#include "task.h"
#include "text_window.h"
-#include "battle.h" // to get rid of once gMonSpritesGfxPtr is put elsewhere
+#include "trig.h"
+#include "util.h"
struct PokeblockFeedStruct
{
diff --git a/src/pokedex.c b/src/pokedex.c
index 48bf64338..93ff06876 100644
--- a/src/pokedex.c
+++ b/src/pokedex.c
@@ -1,34 +1,33 @@
#include "global.h"
-#include "gba/m4a_internal.h"
-#include "pokedex.h"
-#include "sprite.h"
-#include "graphics.h"
-#include "decompress.h"
#include "bg.h"
-#include "window.h"
+#include "data2.h"
+#include "decompress.h"
#include "event_data.h"
-#include "palette.h"
+#include "gpu_regs.h"
+#include "graphics.h"
+#include "international_string_util.h"
#include "main.h"
-#include "sound.h"
-#include "task.h"
-#include "trainer_pokemon_sprites.h"
-#include "scanline_effect.h"
#include "malloc.h"
-#include "gpu_regs.h"
-#include "constants/songs.h"
-#include "constants/species.h"
-#include "constants/rgb.h"
-#include "overworld.h"
#include "menu.h"
-#include "text_window.h"
-#include "data2.h"
-#include "string_util.h"
-#include "trig.h"
+#include "m4a.h"
+#include "overworld.h"
+#include "palette.h"
+#include "pokedex.h"
#include "pokedex_area_screen.h"
#include "pokedex_cry_screen.h"
+#include "scanline_effect.h"
+#include "sound.h"
+#include "sprite.h"
+#include "string_util.h"
#include "strings.h"
-#include "m4a.h"
-#include "international_string_util.h"
+#include "task.h"
+#include "text_window.h"
+#include "trainer_pokemon_sprites.h"
+#include "trig.h"
+#include "window.h"
+#include "constants/rgb.h"
+#include "constants/songs.h"
+#include "constants/species.h"
static EWRAM_DATA struct PokedexView *gUnknown_02039B4C = NULL;
static EWRAM_DATA u16 gUnknown_02039B50 = 0;
diff --git a/src/pokemon.c b/src/pokemon.c
index 02541aa2c..47c4f9217 100644
--- a/src/pokemon.c
+++ b/src/pokemon.c
@@ -1,43 +1,42 @@
#include "global.h"
-#include "pokemon.h"
+#include "apprentice.h"
#include "battle.h"
-#include "battle_setup.h"
-#include "battle_message.h"
-#include "random.h"
-#include "main.h"
-#include "constants/species.h"
-#include "constants/abilities.h"
-#include "constants/items.h"
-#include "constants/trainers.h"
-#include "constants/moves.h"
-#include "constants/hold_effects.h"
-#include "constants/battle_move_effects.h"
-#include "constants/songs.h"
-#include "constants/battle_frontier.h"
-#include "string_util.h"
-#include "text.h"
-#include "link.h"
-#include "event_data.h"
-#include "item.h"
#include "battle_controllers.h"
#include "battle_message.h"
+#include "battle_pike.h"
+#include "battle_setup.h"
+#include "battle_tower.h"
+#include "event_data.h"
#include "evolution_scene.h"
-#include "pokemon_animation.h"
+#include "item.h"
+#include "link.h"
+#include "main.h"
+#include "malloc.h"
+#include "m4a.h"
#include "pokedex.h"
#include "pokeblock.h"
+#include "pokemon.h"
+#include "pokemon_animation.h"
+#include "pokemon_storage_system.h"
+#include "pokenav.h"
+#include "random.h"
+#include "recorded_battle.h"
+#include "rtc.h"
#include "sound.h"
+#include "string_util.h"
+#include "strings.h"
#include "task.h"
-#include "rtc.h"
-#include "m4a.h"
-#include "malloc.h"
+#include "text.h"
#include "util.h"
-#include "strings.h"
-#include "pokenav.h"
-#include "pokemon_storage_system.h"
-#include "recorded_battle.h"
-#include "apprentice.h"
-#include "battle_pike.h"
-#include "battle_tower.h"
+#include "constants/abilities.h"
+#include "constants/battle_frontier.h"
+#include "constants/battle_move_effects.h"
+#include "constants/hold_effects.h"
+#include "constants/items.h"
+#include "constants/moves.h"
+#include "constants/songs.h"
+#include "constants/species.h"
+#include "constants/trainers.h"
struct SpeciesItem
{
diff --git a/src/pokemon_animation.c b/src/pokemon_animation.c
index 90bba702e..989bce37d 100644
--- a/src/pokemon_animation.c
+++ b/src/pokemon_animation.c
@@ -1,12 +1,12 @@
#include "global.h"
#include "pokemon.h"
-#include "sprite.h"
#include "pokemon_animation.h"
-#include "trig.h"
+#include "sprite.h"
#include "task.h"
+#include "trig.h"
#include "util.h"
-#include "constants/rgb.h"
#include "constants/battle_anim.h"
+#include "constants/rgb.h"
#include "constants/species.h"
struct UnkAnimStruct
diff --git a/src/pokemon_icon.c b/src/pokemon_icon.c
index e3b54058d..994cc520e 100644
--- a/src/pokemon_icon.c
+++ b/src/pokemon_icon.c
@@ -1,10 +1,10 @@
#include "global.h"
-#include "sprite.h"
-#include "mail.h"
#include "graphics.h"
-#include "constants/species.h"
+#include "mail.h"
#include "palette.h"
#include "pokemon_icon.h"
+#include "sprite.h"
+#include "constants/species.h"
#define POKE_ICON_BASE_PAL_TAG 56000
diff --git a/src/pokemon_size_record.c b/src/pokemon_size_record.c
index fe3b3e8dd..473bbee03 100644
--- a/src/pokemon_size_record.c
+++ b/src/pokemon_size_record.c
@@ -1,10 +1,10 @@
#include "global.h"
-#include "pokemon_size_record.h"
#include "event_data.h"
-#include "constants/species.h"
+#include "pokemon.h"
+#include "pokemon_size_record.h"
#include "string_util.h"
#include "text.h"
-#include "pokemon.h"
+#include "constants/species.h"
#define DEFAULT_MAX_SIZE 0x8000 // was 0x8100 in Ruby/Sapphire
diff --git a/src/pokemon_storage_system.c b/src/pokemon_storage_system.c
index c102b570a..465b97da2 100644
--- a/src/pokemon_storage_system.c
+++ b/src/pokemon_storage_system.c
@@ -1,25 +1,25 @@
#include "global.h"
-#include "pokemon_storage_system.h"
-#include "pokemon.h"
-#include "constants/species.h"
-#include "event_data.h"
-#include "string_util.h"
-#include "text.h"
-#include "strings.h"
-#include "window.h"
-#include "menu.h"
#include "bg.h"
-#include "main.h"
-#include "palette.h"
-#include "overworld.h"
+#include "event_data.h"
#include "field_screen.h"
#include "field_weather.h"
-#include "script.h"
+#include "gpu_regs.h"
#include "international_string_util.h"
-#include "walda_phrase.h"
+#include "main.h"
+#include "menu.h"
+#include "overworld.h"
+#include "palette.h"
+#include "pokemon.h"
+#include "pokemon_storage_system.h"
+#include "script.h"
#include "sound.h"
-#include "gpu_regs.h"
+#include "string_util.h"
+#include "strings.h"
+#include "text.h"
+#include "walda_phrase.h"
+#include "window.h"
#include "constants/songs.h"
+#include "constants/species.h"
IWRAM_DATA u8 gUnknown_03000F78[0x188];