Skip to content

Commit

Permalink
Document Vehicles (#641)
Browse files Browse the repository at this point in the history
* start doc collision

* fix merge

* finish rename fonction related to vehicle

* document around waypoint of vehicle

* make some modification

* make some change and rename one

* copy_ to oldPos

* doc smoke ferry and train

* some rename

* fix some renaming

* precise index

* rename a funciton

* simplify waypoint_vehicles

* change some name

* change some name

* rename move_to_point_direction

* fix some conflict

* Update code_80005FD0.c

* Update code_80005FD0.h

---------

Co-authored-by: MegaMech <[email protected]>
  • Loading branch information
coco875 and MegaMech authored Aug 23, 2024
1 parent 7025ff0 commit 40f677d
Show file tree
Hide file tree
Showing 23 changed files with 548 additions and 539 deletions.
2 changes: 1 addition & 1 deletion courses/dks_jungle_parkway/course_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -4181,7 +4181,7 @@ TrackWaypoint d_course_dks_jungle_parkway_unknown_waypoints[] = {
{-32768, 0, 0, 0},
};

TrackWaypoint d_course_dks_jungle_parkway_unknown_waypoints2[] = {
TrackWaypoint d_course_dks_jungle_parkway_ferry_waypoints[] = {
{1237, 0, -1373, 0},
{1206, 0, -1365, 0},
{877, 0, -1272, 0},
Expand Down
1 change: 1 addition & 0 deletions courses/dks_jungle_parkway/course_data.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ extern Gfx d_course_dks_jungle_parkway_dl_7008[];
extern Gfx d_course_dks_jungle_parkway_dl_7080[];
extern Gfx d_course_dks_jungle_parkway_dl_7108[];
extern TrackWaypoint d_course_dks_jungle_parkway_unknown_waypoints[];
extern TrackWaypoint d_course_dks_jungle_parkway_ferry_waypoints[];
extern TrackWaypoint d_course_dks_jungle_parkway_track_waypoints[];
extern Vtx d_course_dks_jungle_parkway_paddle_boat_model1[];
extern Vtx d_course_dks_jungle_parkway_paddle_boat_model2[];
Expand Down
2 changes: 1 addition & 1 deletion courses/kalimari_desert/course_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -3801,7 +3801,7 @@ TrackWaypoint d_course_kalimari_desert_unknown_waypoints[] = {
{-32768, 0, 0, 0},
};

TrackWaypoint d_course_kalimari_desert_track_unknown_waypoints[] = {
TrackWaypoint d_course_kalimari_desert_train_waypoints[] = {
{-741, 0, 2114, 0},
{-741, 0, 2130, 0},
{-741, 0, 2364, 0},
Expand Down
2 changes: 1 addition & 1 deletion courses/kalimari_desert/course_data.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ extern Gfx d_course_kalimari_desert_dl_66F0[];
extern Gfx d_course_kalimari_desert_dl_6838[];
extern Gfx d_course_kalimari_desert_dl_6940[];
extern TrackWaypoint d_course_kalimari_desert_unknown_waypoints[];
extern TrackWaypoint d_course_kalimari_desert_track_unknown_waypoints[];
extern TrackWaypoint d_course_kalimari_desert_train_waypoints[];
extern TrackWaypoint d_course_kalimari_desert_track_waypoints[];
extern u8 d_course_kalimari_desert_tree_tlut[];
extern Vtx d_course_kalimari_desert_cactus_model1[];
Expand Down
4 changes: 1 addition & 3 deletions include/common_structs.h
Original file line number Diff line number Diff line change
Expand Up @@ -263,9 +263,7 @@ typedef struct {
/* 0x0010 */ s16 currentItemCopy; // Has no effect on what item the players has, It is just a synced copy
/* 0x0012 */ s16 unk_012;
/* 0x0014 */ Vec3f pos;
/* 0x0020 */ f32 copy_rotation_x;
/* 0x0024 */ f32 copy_rotation_y;
/* 0x0028 */ f32 copy_rotation_z;
/* 0x0020 */ Vec3f oldPos;
/* 0x002C */ Vec3s rotation;
/* 0x0032 */ char unk_032[0x2];
/* 0x0034 */ Vec3f velocity;
Expand Down
6 changes: 3 additions & 3 deletions include/vehicles.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ typedef struct {
/* 0x000 */ TrainCarStuff locomotive;
/* 0x024 */ TrainCarStuff tender;
/* 0x048 */ TrainCarStuff passengerCars[NUM_PASSENGER_CAR_ENTRIES];
/* 0x0FC */ f32 someMultiplier;
/* 0x0FC */ f32 speed;
/* 0x100 */ s32 someFlags;
/* 0x104 */ s32 numCars; // Non-locomotive car count?
/* 0x108 */ s32 unused; // Not read or written. Could be padding?
Expand All @@ -62,7 +62,7 @@ typedef struct {
/* 0x10 */ Vec3f velocity; //
/* 0x1C */ u16 waypointIndex; //
/* 0x1E */ s16 actorIndex; //
/* 0x20 */ f32 someMultiplier; //
/* 0x20 */ f32 speed; //
/* 0x24 */ s16 rotY; // Only Y rotation is tracked in this struct
/* 0x26 */ // s16 compilerPadding2;
/**
Expand All @@ -79,7 +79,7 @@ typedef struct {
/* 0x10 */ Vec3f velocity;
/* 0x1C */ u16 waypointIndex;
/* 0x1E */ s16 actorIndex;
/* 0x20 */ f32 someMultiplier; //
/* 0x20 */ f32 speed; //
/* 0x24 */ f32 someMultiplierTheSequel; //
/* 0x28 */ Vec3s rotation;
/* 0x2E */ s16 someType; //
Expand Down
2 changes: 1 addition & 1 deletion include/waypoints.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ typedef struct {
/* 0x00 */ s16 posX;
/* 0x02 */ s16 posY;
/* 0x04 */ s16 posZ;
/* 0x06 */ u16 trackSegment;
/* 0x06 */ u16 trackSectionId;
} TrackWaypoint; // size = 0x08

/**
Expand Down
Loading

0 comments on commit 40f677d

Please sign in to comment.