From 83e058a8a11e9764d5674100a77310b5f10fee7c Mon Sep 17 00:00:00 2001 From: mike8699 Date: Wed, 1 Jan 2025 21:19:30 -0500 Subject: [PATCH] Run `pre-commit` formatting --- INSTALL.md | 2 +- docs/actors.md | 4 ++-- docs/build_system.md | 2 +- docs/decompiling.md | 4 ++-- extract/README.md | 2 +- include/System/SysNew.hpp | 2 +- tools/configure.py | 4 ++-- tools/mangle.py | 2 +- tools/requirements.txt | 2 +- 9 files changed, 12 insertions(+), 12 deletions(-) diff --git a/INSTALL.md b/INSTALL.md index 22a4f1fb..e6df2e4b 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -46,7 +46,7 @@ Now you can run `ninja` to build a ROM for the chosen version. First, [extract the ARM7 BIOS from your DS device](https://wiki.ds-homebrew.com/ds-index/ds-bios-firmware-dump). Put the ARM7 BIOS in the root directory of this repository, and verify that your dumped BIOS matches the one below: -| File name | SHA1 | +| File name | SHA1 | | --------------- | ------------------------------------------ | | `arm7_bios.bin` | `6ee830c7f552c5bf194c20a2c13d5bb44bdb5c03` | diff --git a/docs/actors.md b/docs/actors.md index d0efbc13..49300936 100644 --- a/docs/actors.md +++ b/docs/actors.md @@ -253,12 +253,12 @@ translations. Feel free to contribute to this list! `EVIC` | Event Icon | Exclamation point icon on the map screen `EQAR` | Earthquake Area `FMSG` | Freestanding? Message | Freestanding textbox -`ITGE` | Item Generator | Spawns an item, such as a small key +`ITGE` | Item Generator | Spawns an item, such as a small key `NCMA` | NPC Conversation Message? `NCM2` | NPC Conversation Message 2? `NMSG` | Navi Message | Starts dialogue with the fairy `RMTG` | Room Tag | Midpoint of small rooms, such as houses -`SWDS` | +`SWDS` | `SWOB` | Switch Object | Causes an event when one or more switches are active `VOCA` | Voice Area | Listens for microphone volume while Link is in the area `WNAR` | Wind Area | Creates gusts of wind that push Link diff --git a/docs/build_system.md b/docs/build_system.md index 8b40d3ab..82d32c6b 100644 --- a/docs/build_system.md +++ b/docs/build_system.md @@ -32,7 +32,7 @@ files to the project. Each `delinks.txt` file belongs to one module, such as the ARM9 program, the ITCM, the DTCM or an overlay. > [!NOTE] -> For interested readers: +> For interested readers: > All modules are loaded into RAM. This is different from the DS predecessor, the Game Boy Advance (GBA), in which all code was > simply on the ROM at all times. As a result, the GBA's RAM only consisted of variable data. > diff --git a/docs/decompiling.md b/docs/decompiling.md index c572e6f2..6eb32c39 100644 --- a/docs/decompiling.md +++ b/docs/decompiling.md @@ -24,9 +24,9 @@ We use the object diffing tool [`objdiff`](https://github.com/encounter/objdiff) 1. [Download the latest release.](https://github.com/encounter/objdiff/releases/latest) 1. Run `configure.py ` and `ninja` to generate `objdiff.json` in the repository root. 1. In `objdiff`, set the project directory to the repository root. -1. Select your source file in the left sidebar: +1. Select your source file in the left sidebar: ![List of objects in objdiff](images/objdiff_objects.png) -5. See the list of functions and data to decompile: +5. See the list of functions and data to decompile: ![List of symbols in objdiff](images/objdiff_symbols.png) > [!NOTE] diff --git a/extract/README.md b/extract/README.md index cb6f93a5..1aa8c5c2 100644 --- a/extract/README.md +++ b/extract/README.md @@ -2,7 +2,7 @@ This repository does not include any of the game's assets, and you will need an Put the base ROM(s) in this directory. Please verify that your dumped ROM matches one of the versions below: -| Version | File name | SHA1 | +| Version | File name | SHA1 | | ------- | -------------------- | ------------------------------------------ | | EUR | `baserom_ph_eur.nds` | `02be55db55cf254bd064d2b3eb368b92a5b4156d` | | USA | `baserom_ph_usa.nds` | `4c8f52dd719918bbcd46e73a8bae8628139c1b85` | diff --git a/include/System/SysNew.hpp b/include/System/SysNew.hpp index 20d4a46f..78f3b290 100644 --- a/include/System/SysNew.hpp +++ b/include/System/SysNew.hpp @@ -4,6 +4,6 @@ class SysObject { public: - static void* operator new(unsigned long length, u32 *id, u32 idLength); + static void *operator new(unsigned long length, u32 *id, u32 idLength); static void operator delete(void *ptr); }; diff --git a/tools/configure.py b/tools/configure.py index dbfb4f16..b1416e0f 100644 --- a/tools/configure.py +++ b/tools/configure.py @@ -158,7 +158,7 @@ def main(): command="./dsd rom build --config $in --rom $out $arm7_bios_flag" ) n.newline() - + n.rule( name="objdiff", command=f"./dsd objdiff --config-path $config_path {DSD_OBJDIFF_ARGS}" @@ -258,7 +258,7 @@ def add_mwcc_builds(n: ninja_syntax.Writer, game_version: str, game_build: Path) } ) n.newline() - + extension = source_file.suffix ctx_file = str(game_build / source_file.with_suffix(f".ctx{extension}")) n.build( diff --git a/tools/mangle.py b/tools/mangle.py index d14bec54..68d2aeb3 100644 --- a/tools/mangle.py +++ b/tools/mangle.py @@ -46,7 +46,7 @@ try: except subprocess.CalledProcessError as e: print(e.stdout.decode()) exit(1) - + output = output.decode() # print(output) diff --git a/tools/requirements.txt b/tools/requirements.txt index c0988481..7edbb58e 100644 --- a/tools/requirements.txt +++ b/tools/requirements.txt @@ -1,2 +1,2 @@ -requests pyperclip +requests