From 88c019eb912322c00bba17e30aa23f77b0395328 Mon Sep 17 00:00:00 2001 From: nmlgc Date: Thu, 25 Feb 2021 17:34:41 +0100 Subject: [PATCH] [Maintenance] Move the bgimage_*() functions to the hardware/ directory Not that it really fits there either, but I've been trying to keep the th0?/ directories free from any actual code. They should only contain the distinct translation units within the original three .EXE binaries, `#include`ing files from subdirectories, along with maybe game-specific `#pragma`s, but contain no code on their own. Port authors would simply ignore those, and link everything from the subdirectories into one binary. That approach has seemed to make the most sense for all of this so far. Part of P0135, funded by [Anonymous]. --- th04/{ => hardware}/bgimage.asm | 0 th04/{ => hardware}/bgimage.h | 0 th04/{ => hardware}/bgimage[data].asm | 0 th04/{ => hardware}/bgimage_put_rect.asm | 0 th04_maine.asm | 6 +++--- th04_op.asm | 6 +++--- th05/m_char.cpp | 2 +- th05_maine.asm | 6 +++--- th05_op.asm | 6 +++--- 9 files changed, 13 insertions(+), 13 deletions(-) rename th04/{ => hardware}/bgimage.asm (100%) rename th04/{ => hardware}/bgimage.h (100%) rename th04/{ => hardware}/bgimage[data].asm (100%) rename th04/{ => hardware}/bgimage_put_rect.asm (100%) diff --git a/th04/bgimage.asm b/th04/hardware/bgimage.asm similarity index 100% rename from th04/bgimage.asm rename to th04/hardware/bgimage.asm diff --git a/th04/bgimage.h b/th04/hardware/bgimage.h similarity index 100% rename from th04/bgimage.h rename to th04/hardware/bgimage.h diff --git a/th04/bgimage[data].asm b/th04/hardware/bgimage[data].asm similarity index 100% rename from th04/bgimage[data].asm rename to th04/hardware/bgimage[data].asm diff --git a/th04/bgimage_put_rect.asm b/th04/hardware/bgimage_put_rect.asm similarity index 100% rename from th04/bgimage_put_rect.asm rename to th04/hardware/bgimage_put_rect.asm diff --git a/th04_maine.asm b/th04_maine.asm index 42a50829..793b1f2c 100644 --- a/th04_maine.asm +++ b/th04_maine.asm @@ -4615,8 +4615,8 @@ include th02/initmain.asm db 0 include th04/hardware/input_s.asm include th04/snd/se.asm -include th04/bgimage.asm -include th04/bgimage_put_rect.asm +include th04/hardware/bgimage.asm +include th04/hardware/bgimage_put_rect.asm extern CDG_LOAD_SINGLE_NOALPHA:proc extern CDG_LOAD_SINGLE:proc extern CDG_FREE:proc @@ -4667,7 +4667,7 @@ include th04/snd/snd[data].asm include th04/snd/load[data].asm include th04/hardware/grppsafx[data].asm include th03/snd/se_state[data].asm -include th04/bgimage[data].asm +include th04/hardware/bgimage[data].asm include th03/formats/cdg[data].asm include th03/formats/pi_put_masked[data].asm include th04/end/box[data].asm diff --git a/th04_op.asm b/th04_op.asm index 7c4a1449..7596c613 100644 --- a/th04_op.asm +++ b/th04_op.asm @@ -2667,8 +2667,8 @@ include th04/formats/cdg_put_noalpha.asm include th04/hardware/input_s.asm include th04/snd/se.asm include th04/hardware/egcrect.asm -include th04/bgimage.asm -include th04/bgimage_put_rect.asm +include th04/hardware/bgimage.asm +include th04/hardware/bgimage_put_rect.asm SHARED ends SHARED_ segment word public 'CODE' use16 @@ -2787,7 +2787,7 @@ include th04/snd/snd[data].asm include th04/snd/load[data].asm include th04/hardware/grppsafx[data].asm include th03/snd/se_state[data].asm -include th04/bgimage[data].asm +include th04/hardware/bgimage[data].asm include th03/formats/cdg[data].asm include th04/setup[data].asm include th04/zunsoft[data].asm diff --git a/th05/m_char.cpp b/th05/m_char.cpp index 6c4a7b17..46915397 100644 --- a/th05/m_char.cpp +++ b/th05/m_char.cpp @@ -14,7 +14,7 @@ extern "C" { #include "th01/ranks.h" #include "th02/hardware/frmdelay.h" #include "th04/formats/cdg.h" -#include "th04/bgimage.h" +#include "th04/hardware/bgimage.h" #include "th04/score.h" #include "th04/common.h" #include "th05/chars.h" diff --git a/th05_maine.asm b/th05_maine.asm index 45bfa98c..4cd56836 100644 --- a/th05_maine.asm +++ b/th05_maine.asm @@ -7531,11 +7531,11 @@ include th04/snd/detmodes.asm include th04/hardware/grppsafx.asm include th04/formats/cdg_put_noalpha.asm include th04/snd/se.asm -include th04/bgimage.asm +include th04/hardware/bgimage.asm include th02/exit.asm include th04/math/vector1_at.asm include th04/math/vector2_at.asm -include th04/bgimage_put_rect.asm +include th04/hardware/bgimage_put_rect.asm extern SND_LOAD:proc extern SND_KAJA_INTERRUPT:proc extern PI_PUT_QUARTER_MASKED_8:proc @@ -7593,7 +7593,7 @@ include libs/master.lib/bgm[data].asm include th04/snd/se_priority[data].asm include th04/hardware/grppsafx[data].asm include th03/snd/se_state[data].asm -include th04/bgimage[data].asm +include th04/hardware/bgimage[data].asm include th05/mem[data].asm include th05/snd/load[data].asm include th04/snd/snd[data].asm diff --git a/th05_op.asm b/th05_op.asm index 338b4659..519ed2a9 100644 --- a/th05_op.asm +++ b/th05_op.asm @@ -2532,7 +2532,7 @@ include th02/exit_dos.asm include th04/hardware/grppsafx.asm include th04/formats/cdg_put_noalpha.asm include th04/snd/se.asm -include th04/bgimage.asm +include th04/hardware/bgimage.asm include th04/formats/cdg_put.asm include th02/exit.asm include th04/math/vector1_at.asm @@ -2540,7 +2540,7 @@ include th04/math/vector2_at.asm include th05/music/piano.asm GRCG_SETCOLOR_DIRECT_DEF 1 db 0 -include th04/bgimage_put_rect.asm +include th04/hardware/bgimage_put_rect.asm extern SND_LOAD:proc extern SND_KAJA_INTERRUPT:proc extern PI_PUT_MASKED_8:proc @@ -2660,7 +2660,7 @@ include libs/master.lib/bgm[data].asm include th04/snd/se_priority[data].asm include th04/hardware/grppsafx[data].asm include th03/snd/se_state[data].asm -include th04/bgimage[data].asm +include th04/hardware/bgimage[data].asm include th05/mem[data].asm include th05/music/piano[data].asm include th05/sprites/piano_l.asp