Skip to content

Commit c541d11

Browse files
MegaMechgithub-actions[bot]
authored andcommitted
clang format
1 parent 1f189df commit c541d11

File tree

202 files changed

+5147
-5072
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

202 files changed

+5147
-5072
lines changed

courses/big_donut/course_offsets.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,2 @@
11
#include <libultra/types.h>
22
#include "course_offsets.h"
3-
4-

courses/staff_ghost_data.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,4 @@ extern StaffGhost d_mario_raceway_staff_ghost[];
99
extern StaffGhost d_royal_raceway_staff_ghost[];
1010
extern StaffGhost d_luigi_raceway_staff_ghost[];
1111

12-
13-
14-
#endif // _STAFF_GHOST_DATA
12+
#endif // _STAFF_GHOST_DATA

courses/test_course/data.c

Lines changed: 52 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -12,63 +12,63 @@ Gfx test_course_data_dl[] = {
1212
};
1313

1414
TrackWaypoint test_course_path[] = {
15-
{ 0, 0, 0, 0},
16-
{ 0, 0, -100, 1},
17-
{ 0, 0, -200, 1},
18-
{ 0, 0, -300, 1},
19-
{ 0, 0, -400, 1},
20-
{ 0, 0, -500, 1},
21-
{ 0, 0, -600, 1},
22-
{ 0, 0, -700, 1},
23-
{ 0, 0, -800, 1},
24-
{ 0, 0, -900, 1},
25-
{ 0, 0, -1000, 1},
26-
{ 0, 0, -1096, 1}, // Main point 1
27-
{ 100, 0, -1090, 2},
28-
{ 200, 0, -1085, 2},
29-
{ 300, 0, -1080, 2},
30-
{ 400, 0, -1075, 2},
31-
{ 500, 0, -1072, 2}, // Curve begins to smooth here
32-
{ 600, 0, -1068, 2},
33-
{ 700, 0, -1065, 2},
34-
{ 800, 0, -1063, 2},
35-
{ 900, 0, -1061, 2},
36-
{ 984, 0, -1060, 2}, // Main point 2
37-
{ 990, 0, -900, 3},
38-
{ 995, 0, -800, 3},
39-
{ 997, 0, -700, 3},
40-
{ 998, 0, -600, 3},
41-
{ 999, 0, -500, 3},
42-
{ 999, 0, -400, 3},
43-
{ 999, 0, -300, 3},
44-
{ 999, 0, -200, 3},
45-
{ 999, 0, -100, 3},
46-
{ 999, 0, 0,3},
47-
{ 999, 0, 100, 3},
48-
{ 999, 0, 200, 3},
49-
{ 999, 0, 300, 3},
50-
{ 999, 0, 400, 3},
51-
{ 999, 0, 500, 3},
52-
{ 999, 0, 600, 3},
53-
{ 999, 0, 700, 3},
54-
{ 999, 0, 800, 3},
55-
{ 999, 0, 900, 3},
56-
{ 999, 0, 940, 3}, // Main point 3
57-
{ 900, 0, 945, 4},
58-
{ 800, 0, 945, 4},
59-
{ 700, 0, 947, 4},
60-
{ 600, 0, 948, 4},
61-
{ 500, 0, 949, 4},
62-
{ 400, 0, 949, 4},
63-
{ 300, 0, 949, 4},
64-
{ 200, 0, 950, 4},
65-
{ 100, 0, 950, 4},
15+
{ 0, 0, 0, 0 },
16+
{ 0, 0, -100, 1 },
17+
{ 0, 0, -200, 1 },
18+
{ 0, 0, -300, 1 },
19+
{ 0, 0, -400, 1 },
20+
{ 0, 0, -500, 1 },
21+
{ 0, 0, -600, 1 },
22+
{ 0, 0, -700, 1 },
23+
{ 0, 0, -800, 1 },
24+
{ 0, 0, -900, 1 },
25+
{ 0, 0, -1000, 1 },
26+
{ 0, 0, -1096, 1 }, // Main point 1
27+
{ 100, 0, -1090, 2 },
28+
{ 200, 0, -1085, 2 },
29+
{ 300, 0, -1080, 2 },
30+
{ 400, 0, -1075, 2 },
31+
{ 500, 0, -1072, 2 }, // Curve begins to smooth here
32+
{ 600, 0, -1068, 2 },
33+
{ 700, 0, -1065, 2 },
34+
{ 800, 0, -1063, 2 },
35+
{ 900, 0, -1061, 2 },
36+
{ 984, 0, -1060, 2 }, // Main point 2
37+
{ 990, 0, -900, 3 },
38+
{ 995, 0, -800, 3 },
39+
{ 997, 0, -700, 3 },
40+
{ 998, 0, -600, 3 },
41+
{ 999, 0, -500, 3 },
42+
{ 999, 0, -400, 3 },
43+
{ 999, 0, -300, 3 },
44+
{ 999, 0, -200, 3 },
45+
{ 999, 0, -100, 3 },
46+
{ 999, 0, 0, 3 },
47+
{ 999, 0, 100, 3 },
48+
{ 999, 0, 200, 3 },
49+
{ 999, 0, 300, 3 },
50+
{ 999, 0, 400, 3 },
51+
{ 999, 0, 500, 3 },
52+
{ 999, 0, 600, 3 },
53+
{ 999, 0, 700, 3 },
54+
{ 999, 0, 800, 3 },
55+
{ 999, 0, 900, 3 },
56+
{ 999, 0, 940, 3 }, // Main point 3
57+
{ 900, 0, 945, 4 },
58+
{ 800, 0, 945, 4 },
59+
{ 700, 0, 947, 4 },
60+
{ 600, 0, 948, 4 },
61+
{ 500, 0, 949, 4 },
62+
{ 400, 0, 949, 4 },
63+
{ 300, 0, 949, 4 },
64+
{ 200, 0, 950, 4 },
65+
{ 100, 0, 950, 4 },
6666

6767
// End of path
6868
{ -32768, -32768, -32768, 0 } // Terminator
6969
};
7070

7171
TrackSections test_course_addr[] = {
72-
{ mario_Plane_001_mesh, 255, 255, 0x0000 },
72+
{ mario_Plane_001_mesh, 255, 255, 0x0000 },
7373
{ 0x00000000, 0, 0, 0x00000 },
7474
};

courses/test_course/model.c

Lines changed: 347 additions & 354 deletions
Large diffs are not rendered by default.

courses/test_course/vtx.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33

44
CourseVtx test_course_vertices[] = {
55
// Top-left vertex (x, y, z), texture coord (tc), color and alpha (ca)
6-
{{ -100, 100, 0}, { 0, 0}, {MACRO_COLOR_FLAG(0xFF, 0x00, 0x00, 0), 0x00}}, // Red
6+
{ { -100, 100, 0 }, { 0, 0 }, { MACRO_COLOR_FLAG(0xFF, 0x00, 0x00, 0), 0x00 } }, // Red
77

88
// Top-right vertex
9-
{{ 100, 100, 0}, { 1024, 0}, {MACRO_COLOR_FLAG(0x00, 0xFF, 0x00, 0), 0x00}}, // Green
9+
{ { 100, 100, 0 }, { 1024, 0 }, { MACRO_COLOR_FLAG(0x00, 0xFF, 0x00, 0), 0x00 } }, // Green
1010

1111
// Bottom-right vertex
12-
{{ 100, -100, 0}, { 1024, 1024}, {MACRO_COLOR_FLAG(0x00, 0x00, 0xFF, 0), 0x00}}, // Blue
12+
{ { 100, -100, 0 }, { 1024, 1024 }, { MACRO_COLOR_FLAG(0x00, 0x00, 0xFF, 0), 0x00 } }, // Blue
1313

1414
// Bottom-left vertex
15-
{{ -100, -100, 0}, { 0, 1024}, {MACRO_COLOR_FLAG(0xFF, 0xFF, 0x00, 0), 0x00}}, // Yellow
15+
{ { -100, -100, 0 }, { 0, 1024 }, { MACRO_COLOR_FLAG(0xFF, 0xFF, 0x00, 0), 0x00 } }, // Yellow
1616
};

include/actor_types.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ struct RailroadCrossing {
163163
/* 0x00 */ s16 type;
164164
/* 0x02 */ s16 flags;
165165
/* 0x04 */ s16 someTimer;
166-
/* 0x06 */ s16 crossingId; // unused now
166+
/* 0x06 */ s16 crossingId; // unused now
167167
/* 0x08 */ void* crossingTrigger; // Crossing Trigger Class
168168
/* 0x10 */ Vec3s rot;
169169
/* 0x16 */ s16 unk_16;
@@ -173,7 +173,8 @@ struct RailroadCrossing {
173173
}; // size = 0x70
174174

175175
// crossingTrigger might ruin struct size when compiled on 32 bit
176-
static_assert(sizeof(struct RailroadCrossing) == sizeof(struct Actor), "RailroadCrossing struct size does not match base struct size");
176+
static_assert(sizeof(struct RailroadCrossing) == sizeof(struct Actor),
177+
"RailroadCrossing struct size does not match base struct size");
177178

178179
struct FallingRock {
179180
/* 0x00 */ s16 type;

include/common_structs.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ typedef struct {
393393
s32 nCharacter; // Networked character choice
394394
s32 nStartingRank;
395395
u32 nHasAuthority;
396-
} Player; // size = 0xDD8
396+
} Player; // size = 0xDD8
397397

398398
typedef struct {
399399
// Something related to time trial ghost data?
@@ -410,7 +410,6 @@ typedef struct {
410410
uint8_t r, g, b;
411411
} RGB8;
412412

413-
414413
typedef struct {
415414
/* 0x00 */ u16 red;
416415
/* 0x02 */ u16 green;

include/course_offsets.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@
88
#include "animation.h"
99

1010
typedef struct {
11-
const char* addr; // segmented address texture file
12-
u32 file_size; // compressed file size
13-
u32 data_size; // uncompressed texture size
14-
u32 padding; // always zero
11+
const char* addr; // segmented address texture file
12+
u32 file_size; // compressed file size
13+
u32 data_size; // uncompressed texture size
14+
u32 padding; // always zero
1515
} course_texture;
1616

1717
extern uintptr_t d_course_sherbet_land_unk_data1[];

include/defines.h

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@
4848
#define HOLD_ALL_DPAD_AND_C_BUTTONS \
4949
(U_JPAD | L_JPAD | R_JPAD | D_JPAD | U_CBUTTONS | L_CBUTTONS | R_CBUTTONS | D_CBUTTONS)
5050

51-
5251
/**
5352
* @brief Jump to demo mode from the debug menu using L and A
5453
*/
@@ -207,7 +206,6 @@ enum { COURSE_ONE, COURSE_TWO, COURSE_THREE, COURSE_FOUR };
207206
#define RACE_UNK 6
208207
#define RACE_EXIT 7
209208

210-
211209
/**
212210
* @brief Options for gScreenModeSelection and gActiveScreenMode
213211
*/
@@ -305,12 +303,7 @@ enum KART_AI_BEHAVIOURS {
305303
BEHAVIOUR_MAX_SPEED
306304
};
307305

308-
enum DIRECTION {
309-
NORTH,
310-
EAST,
311-
SOUTH,
312-
WEST
313-
};
306+
enum DIRECTION { NORTH, EAST, SOUTH, WEST };
314307

315308
/**
316309
* @brief Balloon status
@@ -370,7 +363,6 @@ enum DIRECTION {
370363
#define COLOR_LAVA GPACK_RGB888(0x34, 0x00, 0x00)
371364
#define COLOR_BLACK GPACK_RGB888(0, 0, 0)
372365

373-
374366
/**
375367
*
376368
* Collision mesh flags
@@ -383,4 +375,4 @@ enum DIRECTION {
383375
#define FACING_X_AXIS 0x8000
384376
#define FACING_Z_AXIS 0x2000
385377

386-
#endif // DEFINES_H
378+
#endif // DEFINES_H

include/vehicles.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ typedef struct {
5656
/* 0x048 */ TrainCarStuff passengerCars[NUM_PASSENGER_CAR_ENTRIES];
5757
/* 0x0FC */ f32 speed;
5858
/* 0x100 */ s32 someFlags;
59-
s32 numCarriages;
59+
s32 numCarriages;
6060
/* 0x104 */ s32 numCars; // Non-locomotive car count?
6161
/* 0x108 */ s32 unused; // Not read or written. Could be padding?
6262
} TrainStuff; // size = 0x10C

0 commit comments

Comments
 (0)