Commit Graph

5 Commits

Author SHA1 Message Date
nmlgc b61e612fdf [Maintenance] #include each header's dependencies within the header itself
OK, this is the big one. We still keep using `#include` guards only
where we absolutely need to, but with each header now being valid in
isolation, this can now actually help *minimize* the length of each
translation unit's `#include` list. Turns out that after removing all
the duplicates, we only *actually* need to guard 29 headers across all
5 games.

Part of P0285, funded by [Anonymous] and iruleatgames.
2024-07-09 08:46:42 +02:00
nmlgc 1f2ea181f6 [Decompilation] [th04/th05] Dialog: Script opcode interpreter
Part of P0259, funded by Splashman and Yanga.
2023-11-01 23:17:50 +01:00
nmlgc bab5634ff1 [Decompilation] [th04/th05] Dialog: Script freeing function
One of the rare cases where explicitly spelling out the FP_SEG() cast
is better than just calling the C++ wrapper: To drive home the point
that this code relies on `far` pointer semantics. Running the dialog
script performs arithmetic on only the offset part of this pointer, and
the segment part must remain unchanged for this hmem_free() call to
work as intended.

Completes P0186, funded by [Anonymous] and Blue Bolt.
2022-03-27 00:39:04 +01:00
nmlgc 903d824c48 [Decompilation] [th04/th05] Dialog: Script loading functions
Part of P0186, funded by [Anonymous] and Blue Bolt.
2022-03-27 00:39:04 +01:00
nmlgc b33631daf4 [Reverse-engineering] [th04/th05] Dialog: Buffer pointer
Part of P0186, funded by [Anonymous] and Blue Bolt.
2022-03-27 00:39:04 +01:00