From 9f0b7bb8a3e84cedbe2eca82450113fe3b5b9b98 Mon Sep 17 00:00:00 2001 From: playerskel <97991990+playerskel@users.noreply.github.com> Date: Sun, 26 Feb 2023 17:26:07 +0100 Subject: [PATCH] another round of trailing whitespaces (#1495) --- Makefile | 6 +++--- assets/xml/objects/object_mori_tex.xml | 2 +- assets/xml/objects/object_rs.xml | 2 +- docs/vscode.md | 4 ++-- include/z64camera.h | 4 ++-- include/z64cutscene.h | 2 +- include/z64cutscene_commands.h | 10 +++++----- include/z64environment.h | 6 +++--- include/z64item.h | 2 +- include/z64scene.h | 2 +- src/overlays/actors/ovl_En_Bird/z_en_bird.h | 4 ++-- src/overlays/actors/ovl_En_Ta/z_en_ta.h | 2 +- tools/asmsplitter/asmsplitter.py | 4 ++-- tools/mkldscript.c | 10 +++++----- tools/msgdis.py | 2 +- tools/spec.c | 8 ++++---- 16 files changed, 35 insertions(+), 35 deletions(-) diff --git a/Makefile b/Makefile index 7cdb1e35ec..c5723d90eb 100644 --- a/Makefile +++ b/Makefile @@ -70,7 +70,7 @@ endif # Detect compiler and set variables appropriately. ifeq ($(COMPILER),gcc) CC := $(MIPS_BINUTILS_PREFIX)gcc -else +else ifeq ($(COMPILER),ido) CC := tools/ido_recomp/$(DETECTED_OS)/7.1/cc CC_OLD := tools/ido_recomp/$(DETECTED_OS)/5.3/cc @@ -121,7 +121,7 @@ ASFLAGS := -march=vr4300 -32 -no-pad-sections -Iinclude ifeq ($(COMPILER),gcc) CFLAGS += -G 0 -nostdinc $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -mdivide-breaks -fno-zero-initialized-in-bss -fno-toplevel-reorder -ffreestanding -fno-common -fno-merge-constants -mno-explicit-relocs -mno-split-addresses $(CHECK_WARNINGS) -funsigned-char MIPS_VERSION := -mips3 -else +else # we support Microsoft extensions such as anonymous structs, which the compiler does support but warns for their usage. Surpress the warnings with -woff. CFLAGS += -G 0 -non_shared -fullwarn -verbose -Xcpluscomm $(INC) -Wab,-r4300_mul -woff 516,649,838,712 MIPS_VERSION := -mips2 @@ -281,7 +281,7 @@ $(ROM): $(ELF) $(ELF): $(TEXTURE_FILES_OUT) $(ASSET_FILES_OUT) $(O_FILES) $(OVL_RELOC_FILES) build/ldscript.txt build/undefined_syms.txt $(LD) -T build/undefined_syms.txt -T build/ldscript.txt --no-check-sections --accept-unknown-input-arch --emit-relocs -Map build/z64.map -o $@ -## Order-only prerequisites +## Order-only prerequisites # These ensure e.g. the O_FILES are built before the OVL_RELOC_FILES. # The intermediate phony targets avoid quadratically-many dependencies between the targets and prerequisites. diff --git a/assets/xml/objects/object_mori_tex.xml b/assets/xml/objects/object_mori_tex.xml index 89fb06d354..c58078e0fd 100644 --- a/assets/xml/objects/object_mori_tex.xml +++ b/assets/xml/objects/object_mori_tex.xml @@ -14,7 +14,7 @@ - + diff --git a/assets/xml/objects/object_rs.xml b/assets/xml/objects/object_rs.xml index 6081d6f371..a5f7536590 100644 --- a/assets/xml/objects/object_rs.xml +++ b/assets/xml/objects/object_rs.xml @@ -21,7 +21,7 @@ - + diff --git a/docs/vscode.md b/docs/vscode.md index 45ad9097d0..efd8e8b605 100644 --- a/docs/vscode.md +++ b/docs/vscode.md @@ -1,6 +1,6 @@ # VSCode -A lot of people on this project use VSCode as their coding environment. +A lot of people on this project use VSCode as their coding environment. ## Extensions @@ -23,7 +23,7 @@ There are a number of useful extensions available to make work more efficient: - Ctrl + P offers a box to use to search for and open files. - Ctrl + Shift + P offers a box for commands like editing settings or reloading the window. -- Make use of VSCode's search/search-and-replace features. +- Make use of VSCode's search/search-and-replace features. - Ctrl + Click goes to a definition. - Ctrl + F for search in current file - Ctrl + H for replace in current file diff --git a/include/z64camera.h b/include/z64camera.h index c85500cf49..c7ff017e32 100644 --- a/include/z64camera.h +++ b/include/z64camera.h @@ -42,7 +42,7 @@ #define CAM_LETTERBOX_MEDIUM CAM_LETTERBOX(2) #define CAM_LETTERBOX_LARGE CAM_LETTERBOX(3) -#define CAM_LETTERBOX_INSTANT CAM_LETTERBOX(8) // Bit to determine whether to set the current value directly (on), or to set the size target (off) +#define CAM_LETTERBOX_INSTANT CAM_LETTERBOX(8) // Bit to determine whether to set the current value directly (on), or to set the size target (off) #define CAM_LETTERBOX_IGNORE CAM_LETTERBOX(0xF) // No change in letterbox size, keep the previous size // Camera-unique hud visibility mode macros @@ -121,7 +121,7 @@ #define CAM_VIEW_FOV (1 << 5) // camera->fov #define CAM_VIEW_ROLL (1 << 6) // camera->roll -// All scenes using `SCENE_CAM_TYPE_FIXED_SHOP_VIEWPOINT` or `SCENE_CAM_TYPE_FIXED_TOGGLE_VIEWPOINT` are expected +// All scenes using `SCENE_CAM_TYPE_FIXED_SHOP_VIEWPOINT` or `SCENE_CAM_TYPE_FIXED_TOGGLE_VIEWPOINT` are expected // to have their first two bgCamInfo entries be the following: #define BGCAM_INDEX_TOGGLE_LOCKED 0 #define BGCAM_INDEX_TOGGLE_PIVOT 1 diff --git a/include/z64cutscene.h b/include/z64cutscene.h index e509138d22..24ca4ffc9a 100644 --- a/include/z64cutscene.h +++ b/include/z64cutscene.h @@ -212,7 +212,7 @@ typedef enum { } CutsceneTextType; typedef enum { - /* 0x03 */ CS_FADE_OUT_FANFARE = 3, + /* 0x03 */ CS_FADE_OUT_FANFARE = 3, /* 0x04 */ CS_FADE_OUT_BGM_MAIN } CutsceneFadeOutSeqPlayer; diff --git a/include/z64cutscene_commands.h b/include/z64cutscene_commands.h index 89ef7ef2df..f467fc32c4 100644 --- a/include/z64cutscene_commands.h +++ b/include/z64cutscene_commands.h @@ -137,7 +137,7 @@ CMD_W(cmdType), CMD_W(entries) /** - * Defines a cue that an actor can listen for. + * Defines a cue that an actor can listen for. * The actor can choose whether or not to use the position and rotation data supplied to it. * The cue `id` is a number that has an actor-specific meaning. */ @@ -154,7 +154,7 @@ CS_CMD_PLAYER_CUE, CMD_W(entries) /** - * A player cue is the same as `CS_ACTOR_CUE` but is specifically for player. + * A player cue is the same as `CS_ACTOR_CUE` but is specifically for player. */ #define CS_PLAYER_CUE(id, startFrame, endFrame, rotX, rotY, rotZ, startX, startY, startZ, endX, endY, endZ, unused0, unused1, unused2) \ CS_ACTOR_CUE(id, startFrame, endFrame, rotX, rotY, rotZ, startX, startY, startZ, endX, endY, endZ, unused0, unused1, unused2) @@ -166,7 +166,7 @@ CS_CMD_TEXT, CMD_W(entries) /** - * Starts a textbox at the specified time. + * Starts a textbox at the specified time. * For `CS_TEXT_OCARINA_ACTION`, `textId` is used as an ocarina action. * For a choice textbox, `altTextId1` is the top text id to branch to and `altTextId2` is the bottom. */ @@ -246,11 +246,11 @@ CMD_HH(unused0, startFrame), CMD_HBB(endFrame, hour, min), CMD_W(0) /** - * Sends the player to a new destination. + * Sends the player to a new destination. * `destination` maps to a custom block of code that must implement the scene transition on its own. * This custom code can also do other tasks like changing age, setting flags, or any other setup that is needed * before going to the next destination. - * + * * @see `CutsceneDestination` * @note `endFrame` is not used in the implementation of the command, so its value does not matter */ diff --git a/include/z64environment.h b/include/z64environment.h index e15641517e..ca76e3d9bf 100644 --- a/include/z64environment.h +++ b/include/z64environment.h @@ -148,8 +148,8 @@ typedef struct { // `EnvLightSettings` is very similar to `CurrentEnvLightSettings` with one key difference. // The light settings data in the scene packs blend rate information with the fog near value. -// The blendRate determines how fast the current light settings fade to the next one -// (under LIGHT_MODE_SETTINGS, otherwise unused). +// The blendRate determines how fast the current light settings fade to the next one +// (under LIGHT_MODE_SETTINGS, otherwise unused). // Get blend rate from `EnvLightSettings.blendRateAndFogNear` in 0-255 range #define ENV_LIGHT_SETTINGS_BLEND_RATE_U8(blendRateAndFogNear) (((blendRateAndFogNear) >> 10) * 4) @@ -162,7 +162,7 @@ typedef struct { /* 0x09 */ s8 light2Dir[3]; /* 0x0C */ u8 light2Color[3]; /* 0x0F */ u8 fogColor[3]; - /* 0x12 */ s16 blendRateAndFogNear; + /* 0x12 */ s16 blendRateAndFogNear; /* 0x14 */ s16 zFar; } EnvLightSettings; // size = 0x16 diff --git a/include/z64item.h b/include/z64item.h index 64deccd097..cc083f1cb0 100644 --- a/include/z64item.h +++ b/include/z64item.h @@ -2,7 +2,7 @@ #define Z64ITEM_H // Note that z_kaleido_scope_PAL.c assumes that the dimensions and texture format here also matches the dimensions and -// texture format for MAP_NAME_TEX1_* +// texture format for MAP_NAME_TEX1_* #define ITEM_NAME_TEX_WIDTH 128 #define ITEM_NAME_TEX_HEIGHT 16 #define ITEM_NAME_TEX_SIZE ((ITEM_NAME_TEX_WIDTH * ITEM_NAME_TEX_HEIGHT) / 2) // 128x16 IA4 texture diff --git a/include/z64scene.h b/include/z64scene.h index d29be7bbec..4efc1a567d 100644 --- a/include/z64scene.h +++ b/include/z64scene.h @@ -43,7 +43,7 @@ typedef struct { } Spawn; // TODO: ZAPD Compatibility -typedef Spawn EntranceEntry; +typedef Spawn EntranceEntry; typedef struct { /* 0x00 */ u8 count; // number of points in the path diff --git a/src/overlays/actors/ovl_En_Bird/z_en_bird.h b/src/overlays/actors/ovl_En_Bird/z_en_bird.h index b255ee39b7..1cc9858b13 100644 --- a/src/overlays/actors/ovl_En_Bird/z_en_bird.h +++ b/src/overlays/actors/ovl_En_Bird/z_en_bird.h @@ -15,8 +15,8 @@ typedef struct EnBird { /* 0x0194 */ u32 unk_194; // set to 0 but otherwise unused /* 0x0198 */ s32 timer; /* 0x019C */ s16 scaleAnimSpeed; // when true, anim speed scales with XZ speed while slowing down. otherwise anim plays full speed - /* 0x01A0 */ f32 posYMag; - /* 0x01A4 */ f32 rotYMag; + /* 0x01A0 */ f32 posYMag; + /* 0x01A4 */ f32 rotYMag; /* 0x01A8 */ f32 speedTarget; /* 0x01AC */ f32 speedStep; /* 0x01B0 */ f32 flightDistance; // radius of "home" area diff --git a/src/overlays/actors/ovl_En_Ta/z_en_ta.h b/src/overlays/actors/ovl_En_Ta/z_en_ta.h index d5bd5c49a3..8f7e1f8b5c 100644 --- a/src/overlays/actors/ovl_En_Ta/z_en_ta.h +++ b/src/overlays/actors/ovl_En_Ta/z_en_ta.h @@ -43,7 +43,7 @@ typedef struct EnTa { /* 0x0000 */ Actor actor; /* 0x014C */ SkelAnime skelAnime; /* 0x0190 */ Vec3s jointTable[ENTA_LIMB_MAX]; - /* 0x01F6 */ Vec3s morphTable[ENTA_LIMB_MAX]; + /* 0x01F6 */ Vec3s morphTable[ENTA_LIMB_MAX]; /* 0x025C */ EnTaActionFunc actionFunc; /* 0x0260 */ EnTaAnimFunc animFunc; /* 0x0264 */ ColliderCylinder collider; diff --git a/tools/asmsplitter/asmsplitter.py b/tools/asmsplitter/asmsplitter.py index c3cfe3a7a3..39a88225f9 100644 --- a/tools/asmsplitter/asmsplitter.py +++ b/tools/asmsplitter/asmsplitter.py @@ -31,7 +31,7 @@ for directory in dirs: continue print("Processing asm//" + directory) - + folderName = os.path.splitext(directory)[0] lines = ReadAllLines("asm//" + directory) functions = list() @@ -65,5 +65,5 @@ for directory in dirs: cLines.insert(len(cLines), "#pragma GLOBAL_ASM(\"asm/non_matchings/code/" + folderName + "/" + func.funcName + ".s\")\n") WriteAllLines("c//" + folderName + ".c", cLines) - + print("Done!") diff --git a/tools/mkldscript.c b/tools/mkldscript.c index a2c992e3ae..c29f61f819 100644 --- a/tools/mkldscript.c +++ b/tools/mkldscript.c @@ -9,13 +9,13 @@ #include "spec.h" #include "util.h" -// Note: *SECTION ALIGNMENT* Object files built with a compiler such as GCC can, by default, use narrower +// Note: *SECTION ALIGNMENT* Object files built with a compiler such as GCC can, by default, use narrower // alignment for sections size, compared to IDO padding sections to a 0x10-aligned size. -// To properly generate relocations relative to section starts, sections currently need to be aligned -// explicitly (to 0x10 currently, a narrower alignment might work), otherwise the linker does implicit alignment -// and inserts padding between the address indicated by section start symbols (such as *SegmentRoDataStart) and +// To properly generate relocations relative to section starts, sections currently need to be aligned +// explicitly (to 0x10 currently, a narrower alignment might work), otherwise the linker does implicit alignment +// and inserts padding between the address indicated by section start symbols (such as *SegmentRoDataStart) and // the actual aligned start of the section. -// With IDO, the padding of sections to an aligned size makes the section start at aligned addresses out of the box, +// With IDO, the padding of sections to an aligned size makes the section start at aligned addresses out of the box, // so the explicit alignment has no further effect. struct Segment *g_segments; diff --git a/tools/msgdis.py b/tools/msgdis.py index 95b1a34706..3d569802b3 100644 --- a/tools/msgdis.py +++ b/tools/msgdis.py @@ -309,7 +309,7 @@ def cvt(m): doubles = re.compile(r"(?fields & (1 << stmt))) util_fatal_error("line %i: duplicate '%s' statement", lineNum, stmtNames[stmt]); @@ -292,7 +292,7 @@ void parse_rom_spec(char *spec, struct Segment **segments, int *segment_count) /** * @brief Parses the spec, looking only for the segment with the name `segmentName`. * Returns true if the segment was found, false otherwise - * + * * @param[out] dstSegment The Segment to be filled. Will only contain the data of the searched segment, or garbage if the segment was not found. dstSegment must be previously allocated, a stack variable is recommended * @param[in,out] spec A null-terminated string containing the whole spec file. This string will be modified by this function * @param[in] segmentName The name of the segment being searched @@ -344,8 +344,8 @@ bool get_single_segment_by_name(struct Segment* dstSegment, char *spec, const ch /** * @brief Frees the elements of the passed Segment. Will not free the pointer itself - * - * @param segment + * + * @param segment */ void free_single_segment_elements(struct Segment *segment) { if (segment->includes != NULL) {