ref: a90d7bed73bb7b9effbfce8d94b8a901323aaf8e
parent: af4558f0df58f3f2b18cfb31c276696d6f3f1432
author: Rangi <remy.oukaour+rangi42@gmail.com>
date: Tue Apr 13 08:51:27 EDT 2021
Group miscellaneous graphics from main.asm into their own object file Fixes #824
--- a/Makefile
+++ b/Makefile
@@ -12,6 +12,7 @@
data/pokemon/evos_attacks.o \
engine/movie/credits.o \
engine/overworld/events.o \
+gfx/misc.o \
gfx/pics.o \
gfx/sprites.o \
gfx/tilesets.o \
--- /dev/null
+++ b/gfx/misc.asm
@@ -1,0 +1,58 @@
+SECTION "Trainer Backpics", ROMX
+
+ChrisBackpic::
+INCBIN "gfx/player/chris_back.2bpp.lz"
+DudeBackpic::
+INCBIN "gfx/battle/dude.2bpp.lz"
+
+
+SECTION "Shrink Pics", ROMX
+
+Shrink1Pic::
+INCBIN "gfx/new_game/shrink1.2bpp.lz"
+Shrink2Pic::
+INCBIN "gfx/new_game/shrink2.2bpp.lz"
+
+
+SECTION "Unused Egg Pic", ROMX
+
+UnusedEggPic::
+; The G/S Egg pic. This is shifted up a few pixels.
+INCBIN "gfx/pokemon/egg/unused_front.2bpp.lz"
+
+
+SECTION "The End", ROMX
+
+TheEndGFX::
+INCBIN "gfx/credits/theend.2bpp"
+
+
+SECTION "Font Inversed", ROMX
+
+FontInversed::
+INCBIN "gfx/font/font_inversed.1bpp"
+
+
+SECTION "Copyright", ROMX
+
+CopyrightGFX::
+INCBIN "gfx/splash/copyright.2bpp"
+
+
+SECTION "Intro Logo", ROMX
+
+GameFreakDittoGFX::
+INCBIN "gfx/splash/ditto.2bpp.lz"
+
+
+SECTION "Unown Font", ROMX
+
+UnownFont::
+INCBIN "gfx/font/unown_font.2bpp"
+
+
+SECTION "Pokégear GFX", ROMX
+
+PokegearGFX::
+INCBIN "gfx/pokegear/pokegear.2bpp.lz"
+
--- a/layout.link
+++ b/layout.link
@@ -53,6 +53,7 @@
"bank9"
ROMX $0a
"bankA"
+ "Trainer Backpics"
ROMX $0b
"bankB"
ROMX $0c
@@ -72,8 +73,11 @@
"Crystal Features 1"
ROMX $13
"bank13"
+ "Shrink Pics"
+ "bank13_2"
ROMX $14
"bank14"
+ "Unused Egg Pic"
ROMX $15
"Map Scripts 1"
ROMX $16
@@ -135,6 +139,7 @@
"Sprites 2"
ROMX $32
"bank32"
+ "The End"
ROMX $33
"Move Animations"
"Extra Songs 2"
@@ -150,6 +155,7 @@
ROMX $38
"bank38"
ROMX $39
+ "Copyright"
"bank39"
ROMX $3a
"Audio"
@@ -290,9 +296,12 @@
ROMX $74
"Pokedex Entries 193-251"
ROMX $77
- "bank77"
+ "Unown Font"
+ "Print Party"
"Tileset Data 7"
- "bank77_2"
+ "bank77"
+ "Pokégear GFX"
+ "European Mail"
ROMX $78
"Debug Room"
"Tileset Data 8"
--- a/main.asm
+++ b/main.asm
@@ -130,13 +130,7 @@
INCLUDE "engine/overworld/wildmons.asm"
INCLUDE "engine/battle/link_result.asm"
-ChrisBackpic:
-INCBIN "gfx/player/chris_back.2bpp.lz"
-DudeBackpic:
-INCBIN "gfx/battle/dude.2bpp.lz"
-
-
SECTION "bankB", ROMX
INCLUDE "engine/battle/trainer_huds.asm"
@@ -211,11 +205,8 @@
INCLUDE "engine/overworld/load_map_part.asm"
INCLUDE "engine/phone/phonering_copytilemapatonce.asm"
-Shrink1Pic:
-INCBIN "gfx/new_game/shrink1.2bpp.lz"
-Shrink2Pic:
-INCBIN "gfx/new_game/shrink2.2bpp.lz"
+SECTION "bank13_2", ROMX
INCLUDE "engine/link/link_2.asm"
INCLUDE "engine/rtc/reset_password.asm"
@@ -261,11 +252,7 @@
INCLUDE "data/pokemon/names.asm"
INCLUDE "data/pokemon/unused_pic_banks.asm"
-UnusedEggPic::
-; The G/S Egg pic. This is shifted up a few pixels.
-INCBIN "gfx/pokemon/egg/unused_front.2bpp.lz"
-
SECTION "Crystal Phone Text", ROMX
INCLUDE "data/phone/text/irwin_caller.asm"
@@ -425,10 +412,7 @@
INCLUDE "data/moves/animations.asm"
INCLUDE "engine/events/poisonstep_pals.asm"
-TheEndGFX::
-INCBIN "gfx/credits/theend.2bpp"
-
SECTION "Move Animations", ROMX
INCLUDE "engine/events/bug_contest/display_stats.asm"
@@ -461,12 +445,6 @@
INCLUDE "gfx/pokemon/kanto_frames.asm"
-SECTION "Font Inversed", ROMX
-
-FontInversed:
-INCBIN "gfx/font/font_inversed.1bpp"
-
-
SECTION "Pic Animations 3", ROMX
INCLUDE "gfx/pokemon/johto_frames.asm"
@@ -485,9 +463,6 @@
SECTION "bank39", ROMX
-CopyrightGFX::
-INCBIN "gfx/splash/copyright.2bpp"
-
INCLUDE "engine/menus/options_menu.asm"
INCLUDE "engine/movie/splash.asm"
INCLUDE "engine/movie/intro.asm"
@@ -535,12 +510,6 @@
INCLUDE "mobile/mobile_42.asm"
-SECTION "Intro Logo", ROMX
-
-GameFreakDittoGFX:
-INCBIN "gfx/splash/ditto.2bpp.lz"
-
-
SECTION "Title", ROMX
INCLUDE "engine/movie/unused_title.asm"
@@ -671,15 +640,12 @@
INCLUDE "engine/overworld/landmarks.asm"
-SECTION "bank77", ROMX
+SECTION "Print Party", ROMX
-UnownFont:
-INCBIN "gfx/font/unown_font.2bpp"
-
INCLUDE "engine/printer/print_party.asm"
-SECTION "bank77_2", ROMX
+SECTION "bank77", ROMX
INCLUDE "engine/rtc/print_hours_mins.asm"
INCLUDE "engine/events/diploma.asm"
@@ -687,8 +653,8 @@
INCLUDE "engine/events/catch_tutorial_input.asm"
INCLUDE "engine/pokegear/townmap_convertlinebreakcharacters.asm"
-PokegearGFX:
-INCBIN "gfx/pokegear/pokegear.2bpp.lz"
+
+SECTION "European Mail", ROMX
INCLUDE "engine/pokemon/european_mail.asm"