mirror of
https://github.com/n64decomp/mk64.git
synced 2024-10-06 18:13:28 +00:00
start documenting animation (#668)
* start documenting animation * Update course_data.c * change comment
This commit is contained in:
parent
1ae52f2fcd
commit
8733751fb5
@ -6,7 +6,7 @@
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include <mk64.h>
|
||||
#include <code_80004740.h>
|
||||
#include <animation.h>
|
||||
|
||||
#include "course_displaylists.inc.h"
|
||||
|
||||
@ -8310,7 +8310,7 @@ s16 d_course_koopa_troopa_beach_unk_data2[] = {
|
||||
};
|
||||
|
||||
// 0x06014B50
|
||||
animation_type_3_triplet d_course_koopa_troopa_beach_unk_data3[] = {
|
||||
AnimationLimbVector d_course_koopa_troopa_beach_unk_data3[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0037, 0x0001 },
|
||||
@ -8369,7 +8369,7 @@ animation_type_3_triplet d_course_koopa_troopa_beach_unk_data3[] = {
|
||||
};
|
||||
|
||||
// 0x06014BD4
|
||||
animation_type_2 d_course_koopa_troopa_beach_unk_data4 = {
|
||||
Animation d_course_koopa_troopa_beach_unk_data4 = {
|
||||
0x00010000,
|
||||
0x00000000,
|
||||
0x0037,
|
||||
@ -8541,146 +8541,67 @@ Gfx d_course_koopa_troopa_beach_dl_16990[] =
|
||||
|
||||
//! 0x60169b
|
||||
u32 d_course_koopa_troopa_beach_unk4[] = {
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_ADD_POS(0x00000000, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_16630,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_koopa_troopa_beach_dl_16630),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0xfffffffb,
|
||||
0x00000005,
|
||||
ANIMATION_ADD_POS(0x00000000, -0x00000005, 0x00000005),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_16850,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_koopa_troopa_beach_dl_16850),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_168F0,
|
||||
0x00000024,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_koopa_troopa_beach_dl_168F0, 0x00000024, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_16990,
|
||||
0x00000019,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_koopa_troopa_beach_dl_16990, 0x00000019, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0xfffffffb,
|
||||
0xfffffffb,
|
||||
ANIMATION_ADD_POS(0x00000000, -0x00000005, -0x00000005),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_16850,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_koopa_troopa_beach_dl_16850),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_168F0,
|
||||
0x00000024,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_koopa_troopa_beach_dl_168F0, 0x00000024, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_koopa_troopa_beach_dl_16990,
|
||||
0x00000019,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_koopa_troopa_beach_dl_16990, 0x00000019, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000003,
|
||||
0x00000002,
|
||||
ANIMATION_STOP,
|
||||
};
|
||||
|
||||
// 0x06016B60
|
||||
animation_type_2 *d_course_koopa_troopa_beach_unk_data5[] = {
|
||||
Animation *d_course_koopa_troopa_beach_unk_data5[] = {
|
||||
&d_course_koopa_troopa_beach_unk_data4,
|
||||
};
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
|
||||
extern Gfx d_course_koopa_troopa_beach_dl_0[];
|
||||
extern Gfx d_course_koopa_troopa_beach_dl_48[];
|
||||
@ -314,8 +314,8 @@ extern u8 d_course_koopa_troopa_beach_crab_tlut[];
|
||||
extern u8 d_course_koopa_troopa_beach_crab_frames[][4096];
|
||||
extern u32 d_course_koopa_troopa_beach_unk_data1[];
|
||||
extern s16 d_course_koopa_troopa_beach_unk_data2[];
|
||||
extern animation_type_3_triplet d_course_koopa_troopa_beach_unk_data3[];
|
||||
extern animation_type_2 d_course_koopa_troopa_beach_unk_data4;
|
||||
extern AnimationLimbVector d_course_koopa_troopa_beach_unk_data3[];
|
||||
extern Animation d_course_koopa_troopa_beach_unk_data4;
|
||||
extern Lights1 d_course_koopa_troopa_beach_light1;
|
||||
extern u8 d_course_koopa_troopa_beach_bird_wing[];
|
||||
extern u8 d_course_koopa_troopa_beach_bird_eye[];
|
||||
@ -332,7 +332,7 @@ extern Gfx d_course_koopa_troopa_beach_dl_168F0[];
|
||||
extern Vtx d_course_koopa_troopa_beach_bird_wing_3_model[];
|
||||
extern Gfx d_course_koopa_troopa_beach_dl_16990[];
|
||||
extern u32 d_course_koopa_troopa_beach_unk4[];
|
||||
extern animation_type_2 *d_course_koopa_troopa_beach_unk_data5[];
|
||||
extern Animation *d_course_koopa_troopa_beach_unk_data5[];
|
||||
extern u32 d_course_koopa_troopa_beach_unk_data6[];
|
||||
extern Lights1 d_course_koopa_troopa_beach_light2;
|
||||
extern Vtx d_course_koopa_troopa_beach_tree_model[];
|
||||
|
@ -5,7 +5,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include <code_80004740.h>
|
||||
#include <animation.h>
|
||||
#include <mk64.h>
|
||||
|
||||
#include "course_displaylists.inc.h"
|
||||
@ -3415,7 +3415,7 @@ Gfx d_course_rainbow_road_dl_15F18[] =
|
||||
};
|
||||
|
||||
// 0x06015FC8
|
||||
s16 d_rainbow_road_chomp_jaw_animation[] = {
|
||||
s16 d_rainbow_road_chomp_angle[] = {
|
||||
0x0000, 0x3fff,
|
||||
0x9602, 0x9483,
|
||||
0x90d2, 0x8c1b,
|
||||
@ -3471,7 +3471,7 @@ s16 d_rainbow_road_chomp_jaw_animation[] = {
|
||||
};
|
||||
|
||||
// 0x06016098
|
||||
animation_type_3_triplet d_rainbow_road_unk1[] = {
|
||||
AnimationLimbVector d_rainbow_road_chomp_animation_matrix[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0001, 0x0000 },
|
||||
@ -3515,98 +3515,49 @@ animation_type_3_triplet d_rainbow_road_unk1[] = {
|
||||
};
|
||||
|
||||
// 0x060160F8
|
||||
animation_type_2 d_rainbow_road_unk2 = {
|
||||
Animation d_rainbow_road_unk2 = {
|
||||
0x00010000,
|
||||
0x00000000,
|
||||
0x0014,
|
||||
0x0007,
|
||||
d_rainbow_road_chomp_jaw_animation,
|
||||
d_rainbow_road_unk1,
|
||||
d_rainbow_road_chomp_angle,
|
||||
d_rainbow_road_chomp_animation_matrix,
|
||||
};
|
||||
|
||||
// 0x0601610C
|
||||
animation_type_2 *d_rainbow_road_unk3[] = {
|
||||
Animation *d_rainbow_road_unk3[] = {
|
||||
&d_rainbow_road_unk2,
|
||||
};
|
||||
|
||||
// 0x06016110
|
||||
u32 d_rainbow_road_unk4[] = {
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x0000023a,
|
||||
0x00000000,
|
||||
ANIMATION_ADD_POS(0x00000000, 0x0000023a, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_rainbow_road_dl_15550,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_rainbow_road_dl_15550),
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_rainbow_road_dl_151A8,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_rainbow_road_dl_151A8),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x0000023a,
|
||||
0x00000000,
|
||||
ANIMATION_ADD_POS(0x00000000, 0x0000023a, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_rainbow_road_dl_15C68,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_rainbow_road_dl_15C68),
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_rainbow_road_dl_158C0,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_rainbow_road_dl_158C0),
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_rainbow_road_dl_15F18,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_rainbow_road_dl_15F18),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000003,
|
||||
0x00000002,
|
||||
ANIMATION_STOP,
|
||||
};
|
||||
|
||||
// No idea what this stuff is
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
|
||||
extern Gfx d_course_rainbow_road_dl_0[];
|
||||
extern Gfx d_course_rainbow_road_dl_80[];
|
||||
@ -90,10 +90,10 @@ extern Vtx d_course_rainbow_road_chomp_body_upper_back_model3[];
|
||||
extern Gfx d_course_rainbow_road_dl_15C68[];
|
||||
extern Vtx d_course_rainbow_road_chomp_eyes_model[];
|
||||
extern Gfx d_course_rainbow_road_dl_15F18[];
|
||||
extern s16 d_rainbow_road_chomp_jaw_animation[];
|
||||
extern animation_type_3_triplet d_rainbow_road_unk1[];
|
||||
extern animation_type_2 d_rainbow_road_unk2;
|
||||
extern animation_type_2 *d_rainbow_road_unk3[];
|
||||
extern s16 d_rainbow_road_chomp_angle[];
|
||||
extern AnimationLimbVector d_rainbow_road_chomp_animation_matrix[];
|
||||
extern Animation d_rainbow_road_unk2;
|
||||
extern Animation *d_rainbow_road_unk3[];
|
||||
extern u32 d_rainbow_road_unk4[];
|
||||
extern u32 d_rainbow_road_unk5[];
|
||||
extern Gfx d_course_rainbow_road_dl_16220[];
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include <mk64.h>
|
||||
#include <code_80004740.h>
|
||||
#include <animation.h>
|
||||
|
||||
#include "course_displaylists.inc.h"
|
||||
|
||||
@ -4290,138 +4290,57 @@ Gfx d_course_sherbet_land_dl_8E00[] =
|
||||
|
||||
// 0x06008EB0
|
||||
u32 d_course_sherbet_land_unk_data1[] = {
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008D00,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_sherbet_land_dl_8D00),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0xFFFFFFCD,
|
||||
0x00000054,
|
||||
0xFFFFFFF3,
|
||||
ANIMATION_ADD_POS(-0x00000033, 0x00000054, -0x0000000d),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008730,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_sherbet_land_dl_8730),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000033,
|
||||
0x00000054,
|
||||
0xFFFFFFF3,
|
||||
ANIMATION_ADD_POS(0x00000033, 0x00000054, -0x0000000d),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008808,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(&wut),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0xFFFFFFDA,
|
||||
0xFFFFFFCA,
|
||||
0xFFFFFFF3,
|
||||
ANIMATION_ADD_POS(-0x00000026, -0x00000036, -0x0000000d),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008930,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_sherbet_land_dl_8930),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000026,
|
||||
0xFFFFFFCA,
|
||||
0xFFFFFFF3,
|
||||
ANIMATION_ADD_POS(0x00000026, -0x00000036, -0x0000000d),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008A78,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_sherbet_land_dl_8A78),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x0000006F,
|
||||
0xFFFFFFED,
|
||||
ANIMATION_ADD_POS(0x00000000, 0x0000006F, -0x00000013),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x06008E00,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_sherbet_land_dl_8E00),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000003,
|
||||
0x00000002,
|
||||
ANIMATION_STOP,
|
||||
};
|
||||
|
||||
// 0x0600905C
|
||||
@ -4618,7 +4537,7 @@ s16 d_course_sherbet_land_unk_data2[] = {
|
||||
};
|
||||
|
||||
// 0x06009350
|
||||
animation_type_3_triplet d_course_sherbet_land_unk_data3[] = {
|
||||
AnimationLimbVector d_course_sherbet_land_unk_data3[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0001, 0x0001 },
|
||||
@ -4682,7 +4601,7 @@ animation_type_3_triplet d_course_sherbet_land_unk_data3[] = {
|
||||
};
|
||||
|
||||
// 0x060093E0
|
||||
animation_type_2 d_course_sherbet_land_unk_data4 = {
|
||||
Animation d_course_sherbet_land_unk_data4 = {
|
||||
0x00010000,
|
||||
0x00050000,
|
||||
0x0013,
|
||||
@ -4843,7 +4762,7 @@ s16 d_course_sherbet_land_unk_data5[] = {
|
||||
};
|
||||
|
||||
// 0x06009640
|
||||
animation_type_3_triplet d_course_sherbet_land_unk_data6[] = {
|
||||
AnimationLimbVector d_course_sherbet_land_unk_data6[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0019, 0x0001 },
|
||||
@ -4907,7 +4826,7 @@ animation_type_3_triplet d_course_sherbet_land_unk_data6[] = {
|
||||
};
|
||||
|
||||
// 0x060096D0
|
||||
animation_type_2 d_course_sherbet_land_unk_data7 = {
|
||||
Animation d_course_sherbet_land_unk_data7 = {
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x0019,
|
||||
@ -5129,7 +5048,7 @@ s16 d_course_sherbet_land_unk_data8[] = {
|
||||
};
|
||||
|
||||
// 0x06009A24
|
||||
animation_type_3_triplet d_course_sherbet_land_unk_data9[] = {
|
||||
AnimationLimbVector d_course_sherbet_land_unk_data9[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0019, 0x0001 },
|
||||
@ -5193,7 +5112,7 @@ animation_type_3_triplet d_course_sherbet_land_unk_data9[] = {
|
||||
};
|
||||
|
||||
// 0x06009AB4
|
||||
animation_type_2 d_course_sherbet_land_unk_data10 = {
|
||||
Animation d_course_sherbet_land_unk_data10 = {
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x0019,
|
||||
@ -5203,7 +5122,7 @@ animation_type_2 d_course_sherbet_land_unk_data10 = {
|
||||
};
|
||||
|
||||
// 0x06009AC8
|
||||
animation_type_2 *d_course_sherbet_land_unk_data11[] = {
|
||||
Animation *d_course_sherbet_land_unk_data11[] = {
|
||||
&d_course_sherbet_land_unk_data4,
|
||||
&d_course_sherbet_land_unk_data7,
|
||||
&d_course_sherbet_land_unk_data10,
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
|
||||
extern Gfx d_course_sherbet_land_dl_0[];
|
||||
extern Gfx d_course_sherbet_land_dl_C0[];
|
||||
@ -196,15 +196,15 @@ extern Gfx d_course_sherbet_land_dl_8D00[];
|
||||
extern Gfx d_course_sherbet_land_dl_8E00[];
|
||||
extern u32 d_course_sherbet_land_unk_data1[];
|
||||
extern s16 d_course_sherbet_land_unk_data2[];
|
||||
extern animation_type_3_triplet d_course_sherbet_land_unk_data3[];
|
||||
extern animation_type_2 d_course_sherbet_land_unk_data4;
|
||||
extern AnimationLimbVector d_course_sherbet_land_unk_data3[];
|
||||
extern Animation d_course_sherbet_land_unk_data4;
|
||||
extern s16 d_course_sherbet_land_unk_data5[];
|
||||
extern animation_type_3_triplet d_course_sherbet_land_unk_data6[];
|
||||
extern animation_type_2 d_course_sherbet_land_unk_data7;
|
||||
extern AnimationLimbVector d_course_sherbet_land_unk_data6[];
|
||||
extern Animation d_course_sherbet_land_unk_data7;
|
||||
extern s16 d_course_sherbet_land_unk_data8[];
|
||||
extern animation_type_3_triplet d_course_sherbet_land_unk_data9[];
|
||||
extern animation_type_2 d_course_sherbet_land_unk_data10;
|
||||
extern animation_type_2 *d_course_sherbet_land_unk_data11[];
|
||||
extern AnimationLimbVector d_course_sherbet_land_unk_data9[];
|
||||
extern Animation d_course_sherbet_land_unk_data10;
|
||||
extern Animation *d_course_sherbet_land_unk_data11[];
|
||||
extern u32 d_course_sherbet_land_unk_data12[];
|
||||
extern Gfx d_course_sherbet_land_dl_9AE8[];
|
||||
extern struct ActorSpawnData d_course_sherbet_land_item_box_spawns[];
|
||||
|
@ -5,7 +5,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include <code_80004740.h>
|
||||
#include <animation.h>
|
||||
#include <mk64.h>
|
||||
|
||||
#include "course_displaylists.inc.h"
|
||||
@ -10805,7 +10805,7 @@ s16 d_course_yoshi_valley_unk1[] = {
|
||||
};
|
||||
|
||||
// 0x06014714
|
||||
animation_type_3_triplet d_course_yoshi_valley_unk2[] = {
|
||||
AnimationLimbVector d_course_yoshi_valley_unk2[] = {
|
||||
{
|
||||
{ 0x0001, 0x0000 },
|
||||
{ 0x0001, 0x0000 },
|
||||
@ -10854,7 +10854,7 @@ animation_type_3_triplet d_course_yoshi_valley_unk2[] = {
|
||||
};
|
||||
|
||||
// 0x06014780
|
||||
animation_type_2 d_course_yoshi_valley_unk3 = {
|
||||
Animation d_course_yoshi_valley_unk3 = {
|
||||
0x00010000,
|
||||
0x00000000,
|
||||
0x001d,
|
||||
@ -10864,126 +10864,61 @@ animation_type_2 d_course_yoshi_valley_unk3 = {
|
||||
};
|
||||
|
||||
// 0x06014794
|
||||
animation_type_2 *d_course_yoshi_valley_unk4[] = {
|
||||
Animation *d_course_yoshi_valley_unk4[] = {
|
||||
&d_course_yoshi_valley_unk3,
|
||||
};
|
||||
|
||||
//! 0x06014798
|
||||
u32 d_course_yoshi_valley_unk5[] = {
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_ADD_POS(0x00000000, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_142C0,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_yoshi_valley_dl_142C0),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x000007f8,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_ADD_POS(0x000007f8, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_143C8,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL(d_course_yoshi_valley_dl_143C8),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_144A8,
|
||||
0x000001cc,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_yoshi_valley_dl_144A8, 0x000001cc, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_14500,
|
||||
0x000001cc,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_yoshi_valley_dl_14500, 0x000001cc, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_14558,
|
||||
0x00000158,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_yoshi_valley_dl_14558, 0x00000158, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000001,
|
||||
0x00000002,
|
||||
ANIMATION_DISABLE_AUTOMATIC_POP,
|
||||
|
||||
0x00000000,
|
||||
0x00000007,
|
||||
0x00000000,
|
||||
(u32) d_course_yoshi_valley_dl_145D0,
|
||||
0x00000120,
|
||||
0x00000000,
|
||||
0x00000000,
|
||||
ANIMATION_RENDER_MODEL_AT(d_course_yoshi_valley_dl_145D0, 0x00000120, 0x00000000, 0x00000000),
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000002,
|
||||
0x00000002,
|
||||
ANIMATION_POP_MATRIX,
|
||||
|
||||
0x00000003,
|
||||
0x00000002,
|
||||
ANIMATION_STOP,
|
||||
};
|
||||
|
||||
// No idea what this stuff is
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include <actor_types.h>
|
||||
#include <waypoints.h>
|
||||
#include <course.h>
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
|
||||
extern Gfx d_course_yoshi_valley_dl_0[];
|
||||
extern Gfx d_course_yoshi_valley_dl_20[];
|
||||
@ -162,9 +162,9 @@ extern Gfx d_course_yoshi_valley_dl_14558[];
|
||||
extern Vtx d_course_yoshi_valley_flag_5_model[];
|
||||
extern Gfx d_course_yoshi_valley_dl_145D0[];
|
||||
extern s16 d_course_yoshi_valley_unk1[];
|
||||
extern animation_type_3_triplet d_course_yoshi_valley_unk2[];
|
||||
extern animation_type_2 d_course_yoshi_valley_unk3;
|
||||
extern animation_type_2 *d_course_yoshi_valley_unk4[];
|
||||
extern AnimationLimbVector d_course_yoshi_valley_unk2[];
|
||||
extern Animation d_course_yoshi_valley_unk3;
|
||||
extern Animation *d_course_yoshi_valley_unk4[];
|
||||
extern u32 d_course_yoshi_valley_unk5[];
|
||||
extern u32 d_course_yoshi_valley_unk6[];
|
||||
extern u8 d_course_yoshi_valley_hedgehog_tlut[];
|
||||
|
@ -65,7 +65,7 @@
|
||||
#include "src/camera.h"
|
||||
#include "src/camera_junk.h"
|
||||
#include "src/code_800029B0.h"
|
||||
#include "src/code_80004740.h"
|
||||
#include "src/animation.h"
|
||||
#include "src/code_80005FD0.h"
|
||||
#include "src/code_8003DC40.h"
|
||||
#include "src/code_80057C60.h"
|
||||
|
6
mk64.ld
6
mk64.ld
@ -49,7 +49,7 @@ SECTIONS
|
||||
BUILD_DIR/src/code_800029B0.o(.text*);
|
||||
BUILD_DIR/src/profiler.o(.text*);
|
||||
BUILD_DIR/src/crash_screen.o(.text*);
|
||||
BUILD_DIR/src/code_80004740.o(.text*);
|
||||
BUILD_DIR/src/animation.o(.text*);
|
||||
BUILD_DIR/src/staff_ghosts.o(.text*);
|
||||
BUILD_DIR/asm/unused_overflow_check.o(.text);
|
||||
BUILD_DIR/src/code_80005FD0.jp.o(.text*);
|
||||
@ -267,7 +267,7 @@ SECTIONS
|
||||
BUILD_DIR/src/os/osViData.o(.data*);
|
||||
BUILD_DIR/src/os/_Litob.o(.data*);
|
||||
BUILD_DIR/src/main.o(.rodata*);
|
||||
BUILD_DIR/src/code_80004740.o(.rodata*);
|
||||
BUILD_DIR/src/animation.o(.rodata*);
|
||||
BUILD_DIR/src/code_800029B0.o(.rodata*);
|
||||
BUILD_DIR/src/code_80005FD0.jp.o(.rodata*);
|
||||
BUILD_DIR/src/camera.o(.rodata*);
|
||||
@ -326,7 +326,7 @@ SECTIONS
|
||||
BUILD_DIR/src/code_800029B0.o(.bss*);
|
||||
BUILD_DIR/src/profiler.o(.bss*);
|
||||
BUILD_DIR/src/crash_screen.o(.bss*);
|
||||
BUILD_DIR/src/code_80004740.o(.bss*);
|
||||
BUILD_DIR/src/animation.o(.bss*);
|
||||
BUILD_DIR/src/staff_ghosts.o(.bss*);
|
||||
BUILD_DIR/src/code_80005FD0.jp.o(.bss*);
|
||||
BUILD_DIR/src/camera.o(.bss*);
|
||||
|
@ -8,7 +8,7 @@ SAFE_C_FILES := \
|
||||
build/us/src/effects.o \
|
||||
build/us/src/code_80057C60_var.o \
|
||||
build/us/src/code_800029B0.o \
|
||||
build/us/src/code_80004740.o \
|
||||
build/us/src/animation.o \
|
||||
build/us/src/player_controller.o \
|
||||
build/us/src/profiler.o \
|
||||
build/us/src/render_player.o \
|
||||
|
177
src/animation.c
Normal file
177
src/animation.c
Normal file
@ -0,0 +1,177 @@
|
||||
#include <ultra64.h>
|
||||
#include <macros.h>
|
||||
#include <mk64.h>
|
||||
#include "math_util.h"
|
||||
#include "animation.h"
|
||||
#include "memory.h"
|
||||
#include <main.h>
|
||||
#include <PR/gbi.h>
|
||||
#include "code_80057C60.h"
|
||||
|
||||
Vec3s sOriginalPosAnimation;
|
||||
s16 isNotTheFirst;
|
||||
s16 sMatrixShouldNotPop;
|
||||
s16 sMatrixStackSize;
|
||||
|
||||
void convert_to_fixed_point_matrix_animation(Mtx *dest, Mat4 src) {
|
||||
#ifdef AVOID_UB
|
||||
// Avoid type-casting which is technically UB by calling the equivalent
|
||||
// guMtxF2L function. This helps little-endian systems, as well.
|
||||
guMtxF2L(src, dest);
|
||||
#else
|
||||
s32 asFixedPoint;
|
||||
register s32 i;
|
||||
register s16 *a3 = (s16 *) dest; // all integer parts stored in first 16 bytes
|
||||
register s16 *t0 = (s16 *) dest + 16; // all fraction parts stored in last 16 bytes
|
||||
register f32 *t1 = (f32 *) src;
|
||||
|
||||
for (i = 0; i < 16; i++) {
|
||||
asFixedPoint = *t1++ * (1 << 16); //! float-to-integer conversion responsible for PU crashes
|
||||
*a3++ = GET_HIGH_S16_OF_32(asFixedPoint); // integer part
|
||||
*t0++ = GET_LOW_S16_OF_32(asFixedPoint); // fraction part
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void mtxf_translate_rotate2(Mat4 dest, Vec3f pos, Vec3s angle) {
|
||||
register f32 sx = sins(angle[0]);
|
||||
register f32 cx = coss(angle[0]);
|
||||
|
||||
register f32 sy = sins(angle[1]);
|
||||
register f32 cy = coss(angle[1]);
|
||||
|
||||
register f32 sz = sins(angle[2]);
|
||||
register f32 cz = coss(angle[2]);
|
||||
|
||||
dest[0][0] = cy * cz;
|
||||
dest[0][1] = cy * sz;
|
||||
dest[0][2] = -sy;
|
||||
dest[0][3] = 0.0f;
|
||||
|
||||
dest[1][0] = sx * sy * cz - cx * sz;
|
||||
dest[1][1] = sx * sy * sz + cx * cz;
|
||||
dest[1][2] = sx * cy;
|
||||
dest[1][3] = 0.0f;
|
||||
|
||||
dest[2][0] = cx * sy * cz + sx * sz;
|
||||
dest[2][1] = cx * sy * sz - sx * cz;
|
||||
dest[2][2] = cx * cy;
|
||||
dest[2][3] = 0.0f;
|
||||
|
||||
dest[3][0] = pos[0];
|
||||
dest[3][1] = pos[1];
|
||||
dest[3][2] = pos[2];
|
||||
dest[3][3] = 1.0f;
|
||||
}
|
||||
|
||||
void render_limb_or_add_mtx(Armature *arg0, s16 *arg1, AnimationLimbVector arg2, s32 timeCycle) {
|
||||
Vec3f pos;
|
||||
Vec3s angle;
|
||||
Mat4 modelMatrix;
|
||||
s32 i;
|
||||
s32 some_offset;
|
||||
Gfx *model;
|
||||
Gfx *virtualModel;
|
||||
virtualModel = arg0->model;
|
||||
if (isNotTheFirst == 0) {
|
||||
for (i = 0; i < 3; i++) {
|
||||
pos[i] = sOriginalPosAnimation[i] + arg0->pos[i];
|
||||
}
|
||||
isNotTheFirst += 1;
|
||||
} else {
|
||||
for (i = 0; i < 3; i++) {
|
||||
pos[i] = arg0->pos[i];
|
||||
}
|
||||
}
|
||||
for (i = 0; i < 3; i++) {
|
||||
if (timeCycle < arg2[i].animation_length) {
|
||||
some_offset = timeCycle;
|
||||
} else {
|
||||
some_offset = 0;
|
||||
}
|
||||
angle[i] = arg1[arg2[i].indexCycle + some_offset];
|
||||
}
|
||||
|
||||
mtxf_translate_rotate2(modelMatrix, pos, angle);
|
||||
convert_to_fixed_point_matrix_animation(&gGfxPool->mtxHud[gMatrixHudCount], modelMatrix);
|
||||
sMatrixStackSize += 1;
|
||||
gSPMatrix(gDisplayListHead++, VIRTUAL_TO_PHYSICAL2(&gGfxPool->mtxHud[gMatrixHudCount++]), G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
|
||||
if (virtualModel != NULL) {
|
||||
model = segmented_to_virtual(virtualModel);
|
||||
gSPDisplayList(gDisplayListHead++, model);
|
||||
}
|
||||
}
|
||||
|
||||
void render_armature(Armature *animation, Animation *arg1, s16 timeCycle) {
|
||||
UNUSED u32 *temp;
|
||||
s16 *angle_array;
|
||||
s32 some_offset;
|
||||
AnimationLimbVector *animation_cycle_list;
|
||||
s32 animation_type;
|
||||
s32 someIndex;
|
||||
|
||||
angle_array = segmented_to_virtual(arg1->angle_array);
|
||||
animation_cycle_list = segmented_to_virtual(arg1->animation_cycle_spec_vector);
|
||||
sMatrixStackSize = 0;
|
||||
isNotTheFirst = 0;
|
||||
for (someIndex = 0; someIndex < 3; someIndex++) {
|
||||
if (timeCycle < (*animation_cycle_list)[someIndex].animation_length) {
|
||||
some_offset = timeCycle;
|
||||
} else {
|
||||
some_offset = 0;
|
||||
}
|
||||
sOriginalPosAnimation[someIndex] = angle_array[(*animation_cycle_list)[someIndex].indexCycle + some_offset];
|
||||
}
|
||||
animation_cycle_list++;
|
||||
sMatrixShouldNotPop = 0;
|
||||
do {
|
||||
animation_type = animation->type;
|
||||
switch (animation_type) { /* irregular */
|
||||
case STOP_ANIMATION:
|
||||
break;
|
||||
case DISABLE_AUTOMATIC_POP_MATRIX:
|
||||
sMatrixShouldNotPop = 1;
|
||||
break;
|
||||
case POP_MATRIX:
|
||||
gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW);
|
||||
sMatrixStackSize -= 1;
|
||||
break;
|
||||
case RENDER_MODEL_OR_ADD_POS:
|
||||
if (sMatrixShouldNotPop == 0) {
|
||||
gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW);
|
||||
sMatrixStackSize -= 1;
|
||||
}
|
||||
render_limb_or_add_mtx(animation, angle_array, *animation_cycle_list, (s32) timeCycle);
|
||||
sMatrixShouldNotPop = 0;
|
||||
animation_cycle_list++;
|
||||
break;
|
||||
}
|
||||
animation = (Armature *) ((u32 *) animation + animation->size);
|
||||
} while (animation_type != STOP_ANIMATION);
|
||||
}
|
||||
|
||||
s16 render_animated_model(Armature *virtualArmature, Animation **virtualListAnimation, s16 animationIndex, s16 timeCycle) {
|
||||
Armature *armature;
|
||||
Animation *animation;
|
||||
Animation **listAnimation;
|
||||
|
||||
armature = segmented_to_virtual(virtualArmature);
|
||||
listAnimation = segmented_to_virtual(virtualListAnimation); // Convert the array's address
|
||||
animation = segmented_to_virtual(listAnimation[animationIndex]); // Convert an array element's address
|
||||
if (timeCycle >= animation->animation_length) {
|
||||
timeCycle = 0;
|
||||
}
|
||||
render_armature(armature, animation, timeCycle);
|
||||
timeCycle++;
|
||||
if (timeCycle >= animation->animation_length) {
|
||||
timeCycle = 0;
|
||||
}
|
||||
return timeCycle;
|
||||
}
|
||||
|
||||
s16 get_animation_length(Animation **addr, s16 offset) {
|
||||
Animation **item = segmented_to_virtual(addr);
|
||||
Animation *temp = (Animation *) segmented_to_virtual((void *) item[offset]);
|
||||
|
||||
return temp->animation_length - 1;
|
||||
}
|
@ -8,12 +8,12 @@ What I know about animation stuff so far
|
||||
|
||||
Its not clear to me exactly what animations even are in MK64, my speculation is that their some form of matrix manipulation sequence.
|
||||
Presumably the "models" of the objects that are getting animated are a bunch of matrices and the animations somehow change them.
|
||||
code_80004740 appears to be responsible for the handling of animations.
|
||||
animation appears to be responsible for the handling of animations.
|
||||
Animation seem to be reserved for objects, namely: seagulls in KTB, flags in YV, chain chomps in RR, and penguins in SL.
|
||||
|
||||
Each object has 2 pointers of interest, at offsets 0x70 and 0x74 (unk_070 and unk_074).
|
||||
These are passed to func_80004DFC, along with what appears to be an index and a timer.
|
||||
func_80004DFC(unk70, unk74, index, timer)
|
||||
These are passed to render_animated_model, along with what appears to be an index and a timer.
|
||||
render_animated_model(unk70, unk74, index, timer)
|
||||
|
||||
unk_070 points to what I will call a "Type 1" array.
|
||||
I call it an array, but I don't think that's entirely accurate.
|
||||
@ -32,7 +32,7 @@ struct {
|
||||
}
|
||||
Again, note that types 1, 2, and 3 only have the "type" and "size" elements.
|
||||
|
||||
They are handled in func_80004C30.
|
||||
They are handled in render_armature.
|
||||
Each "type" indicates a different action to take while iterating over the array.
|
||||
Type 1: Only used to modify Type 0's behaviour
|
||||
Type 2: Pop a matrix
|
||||
@ -91,7 +91,7 @@ This is why I don't think referring to this as an "array" is really correct.
|
||||
Iterating over this data not like iterating over a proper array at all.
|
||||
|
||||
I don't really understand the "thing" entries yet.
|
||||
They seem to be used in func_80004A1C to set some values in Vec3f which is then used to set some values in a Mat4.
|
||||
They seem to be used in render_limb_or_add_mtx to set some values in Vec3f which is then used to set some values in a Mat4.
|
||||
This, I assume, is related to the matrix maniplation stuff that's used to actually accomplish the animation.
|
||||
|
||||
The unk_074 pointer points to a list of other pointers.
|
||||
@ -103,8 +103,8 @@ struct {
|
||||
s32 always_zero_never_used;
|
||||
s/u16 animation_length;
|
||||
s/u16 has_value_but_never_used;
|
||||
s32 type_2_array_pointer;
|
||||
s32 type_3_array_pointer;
|
||||
s32 angle_array;
|
||||
s32 AnimationCycleSpecVector;
|
||||
}
|
||||
|
||||
I will refer to these structs as Struct 2's.
|
||||
@ -115,15 +115,15 @@ Their use will be discussed later
|
||||
Type 3 arrays appear to be arrays of pairs of s/u16 numbers that look like this struct:
|
||||
|
||||
struct {
|
||||
s/u16 some_limiter;
|
||||
s/u16 some_offset;
|
||||
s/u16 animation_length;
|
||||
s/u16 indexCycle;
|
||||
};
|
||||
|
||||
Type 3 entires are interesting.
|
||||
They're used in func_80004C30 and func_80004A1C, and they're always used in triples
|
||||
The `timer` argument to func_80004DFC is compared to the `some_limiter` entry.
|
||||
They're used in render_armature and render_limb_or_add_mtx, and they're always used in triples
|
||||
The `timer` argument to render_animated_model is compared to the `animation_length` entry.
|
||||
If it less than the limiter then its value it used elsewhere, otherwise 0 is used (more details below).
|
||||
The `some_offset` value is always used.
|
||||
The `indexCycle` value is always used.
|
||||
|
||||
Then, the 2 chosen values are used to select a value from the Type 2 array.
|
||||
So, for example, if you have a Struct 2 like:
|
||||
@ -148,53 +148,70 @@ In practice the limiter value is always 1 or the animation length, meaning that
|
||||
There's never a situation where you will choose the animation timer until it hits X and then swap to 0.
|
||||
Its always one or the other, never swapping.
|
||||
|
||||
The first triplet is used in func_80004C30 to access the Type 2 array and the values accessed is placed into D_80162D70.
|
||||
D_80162D70 is a Vec3s is then used to set the values of some Vec3f in func_80004A1C.
|
||||
All further triplets are used in func_80004A1C to collect Type 2 values to another Vec3s local to the function.
|
||||
The first triplet is used in render_armature to access the Type 2 array and the values accessed is placed into sOriginalPosAnimation.
|
||||
sOriginalPosAnimation is a Vec3s is then used to set the values of some Vec3f in render_limb_or_add_mtx.
|
||||
All further triplets are used in render_limb_or_add_mtx to collect Type 2 values to another Vec3s local to the function.
|
||||
Both the local Vec3s and Vec3f are used to create a Mat4, which is then converted to a Mtx, which is then pushed into the matrix pool.
|
||||
|
||||
The chosen values are then used to access the Type 2 array and the value accessed is placed into D_80162D70.
|
||||
D_80162D70 is a Vec3s that is used to set values in the some Vec3f that goes on to be used to modify the same Mat4 that the `thing` values are placed into.
|
||||
The chosen values are then used to access the Type 2 array and the value accessed is placed into sOriginalPosAnimation.
|
||||
sOriginalPosAnimation is a Vec3s that is used to set values in the some Vec3f that goes on to be used to modify the same Mat4 that the `thing` values are placed into.
|
||||
|
||||
*/
|
||||
|
||||
#define SIMPLE_ANIMATION_INSTRUCTION(x) x, 0x00000002
|
||||
|
||||
#define ANIMATION_DISABLE_AUTOMATIC_POP SIMPLE_ANIMATION_INSTRUCTION(DISABLE_AUTOMATIC_POP_MATRIX)
|
||||
#define ANIMATION_POP_MATRIX SIMPLE_ANIMATION_INSTRUCTION(POP_MATRIX)
|
||||
#define ANIMATION_STOP SIMPLE_ANIMATION_INSTRUCTION(STOP_ANIMATION)
|
||||
//! the pos is relative to the previous RENDER_MODEL_OR_ADD_POS if ANIMATION_DISABLE_AUTOMATIC_POP is used
|
||||
#define ANIMATION_RENDER_MODEL_AT(model, x, y, z) RENDER_MODEL_OR_ADD_POS, 0x00000007, 0x00000000, (u32) model, x, y, z
|
||||
//! use RENDER_MODEL_OR_ADD_POS
|
||||
#define ANIMATION_RENDER_MODEL(model) ANIMATION_RENDER_MODEL_AT(model, 0x00000000, 0x00000000, 0x00000000)
|
||||
//! use RENDER_MODEL_OR_ADD_POS
|
||||
#define ANIMATION_ADD_POS(x,y,z) ANIMATION_RENDER_MODEL_AT((u32)NULL, x, y, z)
|
||||
|
||||
enum animation_type {
|
||||
RENDER_MODEL_OR_ADD_POS,
|
||||
DISABLE_AUTOMATIC_POP_MATRIX,
|
||||
POP_MATRIX,
|
||||
STOP_ANIMATION
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief The armature is associated with an AnimationLimbVector which is equal to the number of RENDER_MODEL_OR_ADD_POS in the armature
|
||||
*/
|
||||
typedef struct {
|
||||
/* 0x00 */ s32 type;
|
||||
/* 0x04 */ s32 size;
|
||||
/* 0x08 */ s32 always_zero_never_used;
|
||||
/* 0x0C */ Gfx *optional_segmented_dl_address;
|
||||
/* 0x10 */ s32 thing[3];
|
||||
} animation_type_1;
|
||||
/* 0x0C */ Gfx *model;
|
||||
/* 0x10 */ s32 pos[3];
|
||||
} Armature;
|
||||
|
||||
typedef struct {
|
||||
/* 0x00 */ u16 some_limiter;
|
||||
/* 0x02 */ u16 some_offset;
|
||||
} animation_type_3;
|
||||
/* 0x00 */ u16 animation_length;
|
||||
/* 0x02 */ u16 indexCycle;
|
||||
} AnimationCycleSpec;
|
||||
|
||||
typedef animation_type_3 animation_type_3_triplet[3];
|
||||
//! the first are the original position and other are animation specification for each "limb" who correspond to each RENDER_MODEL_OR_ADD_POS so ANIMATION_RENDER_MODEL and ANIMATION_ADD_POS
|
||||
typedef AnimationCycleSpec AnimationLimbVector[3];
|
||||
|
||||
typedef struct {
|
||||
/* 0x00 */ s32 always_set_to_something_but_never_used;
|
||||
/* 0x04 */ s32 always_zero_never_used;
|
||||
/* 0x08 */ s16 animation_length;
|
||||
/* 0x0A */ u16 has_value_but_never_used;
|
||||
/* 0x0C */ s16 *type_2_array_pointer;
|
||||
/* 0x10 */ animation_type_3_triplet *type_3_array_pointer;
|
||||
} animation_type_2;
|
||||
|
||||
struct stru_80004EAC {
|
||||
s32 unk0;
|
||||
s32 unk4;
|
||||
s16 unk8;
|
||||
};
|
||||
/* 0x0C */ s16 *angle_array;
|
||||
/* 0x10 */ AnimationLimbVector *animation_cycle_spec_vector;
|
||||
} Animation;
|
||||
|
||||
/* Function Prototypes */
|
||||
|
||||
void func_80004740(Mtx *dest, Mat4 src);
|
||||
void convert_to_fixed_point_matrix_animation(Mtx *dest, Mat4 src);
|
||||
void mtxf_translate_rotate2(Mat4 dest, Vec3f b, Vec3s c);
|
||||
s16 func_80004EAC(void*, s16);
|
||||
void func_80004A1C(animation_type_1*, s16*, animation_type_3_triplet, s32);
|
||||
void func_80004C30(animation_type_1*, animation_type_2*, s16);
|
||||
s16 func_80004DFC(animation_type_1*, animation_type_2**, s16, s16);
|
||||
s16 get_animation_length(Animation **, s16);
|
||||
void render_limb_or_add_mtx(Armature*, s16*, AnimationLimbVector, s32);
|
||||
void render_armature(Armature*, Animation*, s16);
|
||||
s16 render_animated_model(Armature*, Animation**, s16, s16);
|
||||
|
||||
#endif
|
@ -1,177 +0,0 @@
|
||||
#include <ultra64.h>
|
||||
#include <macros.h>
|
||||
#include <mk64.h>
|
||||
#include "math_util.h"
|
||||
#include "code_80004740.h"
|
||||
#include "memory.h"
|
||||
#include <main.h>
|
||||
#include <PR/gbi.h>
|
||||
#include "code_80057C60.h"
|
||||
|
||||
Vec3s D_80162D70;
|
||||
s16 D_80162D76;
|
||||
s16 D_80162D78;
|
||||
s16 D_80162D7A;
|
||||
|
||||
void func_80004740(Mtx *dest, Mat4 src) {
|
||||
#ifdef AVOID_UB
|
||||
// Avoid type-casting which is technically UB by calling the equivalent
|
||||
// guMtxF2L function. This helps little-endian systems, as well.
|
||||
guMtxF2L(src, dest);
|
||||
#else
|
||||
s32 asFixedPoint;
|
||||
register s32 i;
|
||||
register s16 *a3 = (s16 *) dest; // all integer parts stored in first 16 bytes
|
||||
register s16 *t0 = (s16 *) dest + 16; // all fraction parts stored in last 16 bytes
|
||||
register f32 *t1 = (f32 *) src;
|
||||
|
||||
for (i = 0; i < 16; i++) {
|
||||
asFixedPoint = *t1++ * (1 << 16); //! float-to-integer conversion responsible for PU crashes
|
||||
*a3++ = GET_HIGH_S16_OF_32(asFixedPoint); // integer part
|
||||
*t0++ = GET_LOW_S16_OF_32(asFixedPoint); // fraction part
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void mtxf_translate_rotate2(Mat4 dest, Vec3f b, Vec3s c) {
|
||||
register f32 sx = sins(c[0]);
|
||||
register f32 cx = coss(c[0]);
|
||||
|
||||
register f32 sy = sins(c[1]);
|
||||
register f32 cy = coss(c[1]);
|
||||
|
||||
register f32 sz = sins(c[2]);
|
||||
register f32 cz = coss(c[2]);
|
||||
|
||||
dest[0][0] = cy * cz;
|
||||
dest[0][1] = cy * sz;
|
||||
dest[0][2] = -sy;
|
||||
dest[0][3] = 0.0f;
|
||||
|
||||
dest[1][0] = sx * sy * cz - cx * sz;
|
||||
dest[1][1] = sx * sy * sz + cx * cz;
|
||||
dest[1][2] = sx * cy;
|
||||
dest[1][3] = 0.0f;
|
||||
|
||||
dest[2][0] = cx * sy * cz + sx * sz;
|
||||
dest[2][1] = cx * sy * sz - sx * cz;
|
||||
dest[2][2] = cx * cy;
|
||||
dest[2][3] = 0.0f;
|
||||
|
||||
dest[3][0] = b[0];
|
||||
dest[3][1] = b[1];
|
||||
dest[3][2] = b[2];
|
||||
dest[3][3] = 1.0f;
|
||||
}
|
||||
|
||||
void func_80004A1C(animation_type_1 *arg0, s16 *arg1, animation_type_3_triplet arg2, s32 arg3) {
|
||||
Vec3f sp94;
|
||||
Vec3s sp8C;
|
||||
Mat4 sp4C;
|
||||
s32 someIndex;
|
||||
s32 some_offset;
|
||||
Gfx *some_dl;
|
||||
Gfx *some_segmented_dl;
|
||||
some_segmented_dl = arg0->optional_segmented_dl_address;
|
||||
if (D_80162D76 == 0) {
|
||||
for (someIndex = 0; someIndex < 3; someIndex++) {
|
||||
sp94[someIndex] = D_80162D70[someIndex] + arg0->thing[someIndex];
|
||||
}
|
||||
D_80162D76 += 1;
|
||||
} else {
|
||||
for (someIndex = 0; someIndex < 3; someIndex++) {
|
||||
sp94[someIndex] = arg0->thing[someIndex];
|
||||
}
|
||||
}
|
||||
for (someIndex = 0; someIndex < 3; someIndex++) {
|
||||
if (arg3 < arg2[someIndex].some_limiter) {
|
||||
some_offset = arg3;
|
||||
} else {
|
||||
some_offset = 0;
|
||||
}
|
||||
sp8C[someIndex] = arg1[arg2[someIndex].some_offset + some_offset];
|
||||
}
|
||||
|
||||
mtxf_translate_rotate2(sp4C, sp94, sp8C);
|
||||
func_80004740(&gGfxPool->mtxHud[gMatrixHudCount], sp4C);
|
||||
D_80162D7A += 1;
|
||||
gSPMatrix(gDisplayListHead++, VIRTUAL_TO_PHYSICAL2(&gGfxPool->mtxHud[gMatrixHudCount++]), G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
|
||||
if (some_segmented_dl != NULL) {
|
||||
some_dl = segmented_to_virtual(some_segmented_dl);
|
||||
gSPDisplayList(gDisplayListHead++, some_dl);
|
||||
}
|
||||
}
|
||||
|
||||
void func_80004C30(animation_type_1 *arg0, animation_type_2 *arg1, s16 timeCycle) {
|
||||
UNUSED u32 *temp;
|
||||
s16 *sp40;
|
||||
s32 some_offset;
|
||||
animation_type_3_triplet *temp_v0;
|
||||
s32 new_var;
|
||||
s32 someIndex;
|
||||
|
||||
sp40 = segmented_to_virtual(arg1->type_2_array_pointer);
|
||||
temp_v0 = segmented_to_virtual(arg1->type_3_array_pointer);
|
||||
D_80162D7A = 0;
|
||||
D_80162D76 = 0;
|
||||
for (someIndex = 0; someIndex < 3; someIndex++) {
|
||||
if (timeCycle < (*temp_v0)[someIndex].some_limiter) {
|
||||
some_offset = timeCycle;
|
||||
} else {
|
||||
some_offset = 0;
|
||||
}
|
||||
D_80162D70[someIndex] = sp40[(*temp_v0)[someIndex].some_offset + some_offset];
|
||||
}
|
||||
temp_v0++;
|
||||
D_80162D78 = 0;
|
||||
do {
|
||||
new_var = arg0->type;
|
||||
switch (new_var) { /* irregular */
|
||||
case 3:
|
||||
break;
|
||||
case 1:
|
||||
D_80162D78 = 1;
|
||||
break;
|
||||
case 2:
|
||||
gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW);
|
||||
D_80162D7A -= 1;
|
||||
break;
|
||||
case 0:
|
||||
if (D_80162D78 == 0) {
|
||||
gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW);
|
||||
D_80162D7A -= 1;
|
||||
}
|
||||
func_80004A1C(arg0, sp40, *temp_v0, (s32) timeCycle);
|
||||
D_80162D78 = 0;
|
||||
temp_v0++;
|
||||
break;
|
||||
}
|
||||
arg0 = (animation_type_1 *) ((u32 *) arg0 + arg0->size);
|
||||
} while (new_var != 3);
|
||||
}
|
||||
|
||||
s16 func_80004DFC(animation_type_1 *arg0, animation_type_2 **arg1, s16 arg2, s16 timeCycle) {
|
||||
animation_type_1 *sp24;
|
||||
animation_type_2 *temp_v0;
|
||||
animation_type_2 **sp20;
|
||||
|
||||
sp24 = segmented_to_virtual(arg0);
|
||||
sp20 = segmented_to_virtual(arg1); // Convert the array's address
|
||||
temp_v0 = segmented_to_virtual(sp20[arg2]); // Convert an array element's address
|
||||
if (timeCycle >= temp_v0->animation_length) {
|
||||
timeCycle = 0;
|
||||
}
|
||||
func_80004C30(sp24, temp_v0, timeCycle);
|
||||
timeCycle++;
|
||||
if (timeCycle >= temp_v0->animation_length) {
|
||||
timeCycle = 0;
|
||||
}
|
||||
return timeCycle;
|
||||
}
|
||||
|
||||
s16 func_80004EAC(void *addr, s16 offset) {
|
||||
uintptr_t *item = segmented_to_virtual(addr);
|
||||
struct stru_80004EAC *temp = (struct stru_80004EAC *) segmented_to_virtual((void *) item[offset]);
|
||||
|
||||
return temp->unk8 - 1;
|
||||
}
|
@ -11,7 +11,7 @@
|
||||
#include <camera_junk.h>
|
||||
#include <ceremony_and_credits.h>
|
||||
#include <code_800029B0.h>
|
||||
#include <code_80004740.h>
|
||||
#include <animation.h>
|
||||
#include <code_80005FD0.h>
|
||||
#include <render_player.h>
|
||||
#include <player_controller.h>
|
||||
|
@ -19,7 +19,7 @@
|
||||
#include "bomb_kart.h"
|
||||
#include <assets/common_data.h>
|
||||
#include "render_player.h"
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
#include "code_80005FD0.h"
|
||||
#include "code_80057C60.h"
|
||||
#include "code_8006E9C0.h"
|
||||
@ -3854,9 +3854,9 @@ void func_80055164(s32 objectIndex) {
|
||||
gSPDisplayList(gDisplayListHead++, D_0D0077A0);
|
||||
rsp_set_matrix_transformation(gObjectList[objectIndex].pos, gObjectList[objectIndex].direction_angle, gObjectList[objectIndex].sizeScaling);
|
||||
if (gIsGamePaused == 0) {
|
||||
gObjectList[objectIndex].unk_0A2 = func_80004DFC((animation_type_1 *) gObjectList[objectIndex].model, (animation_type_2 **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
gObjectList[objectIndex].unk_0A2 = render_animated_model((Armature *) gObjectList[objectIndex].model, (Animation **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
} else {
|
||||
func_80004DFC((animation_type_1 *) gObjectList[objectIndex].model, (animation_type_2 **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
render_animated_model((Armature *) gObjectList[objectIndex].model, (Animation **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3879,9 +3879,9 @@ void func_800552BC(s32 objectIndex) {
|
||||
rsp_set_matrix_transformation(gObjectList[objectIndex].pos, gObjectList[objectIndex].direction_angle, gObjectList[objectIndex].sizeScaling);
|
||||
gSPDisplayList(gDisplayListHead++, D_0D0077D0);
|
||||
if (gIsGamePaused == 0) {
|
||||
gObjectList[objectIndex].unk_0A2 = func_80004DFC((animation_type_1 *) gObjectList[objectIndex].model, (animation_type_2 **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
gObjectList[objectIndex].unk_0A2 = render_animated_model((Armature *) gObjectList[objectIndex].model, (Animation **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
} else {
|
||||
func_80004DFC((animation_type_1 *) gObjectList[objectIndex].model, (animation_type_2 **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
render_animated_model((Armature *) gObjectList[objectIndex].model, (Animation **) gObjectList[objectIndex].vertex, 0, gObjectList[objectIndex].unk_0A2);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3980,7 +3980,7 @@ void func_800557B4(s32 objectIndex, u32 arg1, u32 arg2) {
|
||||
sp34[2] = object->pos[2];
|
||||
rsp_set_matrix_transformation_inverted_x_y_orientation(sp34, object->orientation, object->sizeScaling);
|
||||
gSPDisplayList(gDisplayListHead++, D_0D0077D0);
|
||||
func_80004DFC((animation_type_1 *) object->model, (animation_type_2 **) object->vertex, (s16) object->unk_0D8, (s16) object->itemDisplay);
|
||||
render_animated_model((Armature *) object->model, (Animation **) object->vertex, (s16) object->unk_0D8, (s16) object->itemDisplay);
|
||||
}
|
||||
} else if (arg1 < 0x15F91U) {
|
||||
func_8004A7AC(objectIndex, 1.5f);
|
||||
@ -3988,7 +3988,7 @@ void func_800557B4(s32 objectIndex, u32 arg1, u32 arg2) {
|
||||
}
|
||||
rsp_set_matrix_transformation(object->pos, object->orientation, object->sizeScaling);
|
||||
gSPDisplayList(gDisplayListHead++, D_0D0077D0);
|
||||
func_80004DFC((animation_type_1 *) object->model, (animation_type_2 **) object->vertex, (s16) object->unk_0D8, (s16) object->itemDisplay);
|
||||
render_animated_model((Armature *) object->model, (Animation **) object->vertex, (s16) object->unk_0D8, (s16) object->itemDisplay);
|
||||
}
|
||||
}
|
||||
|
||||
@ -4052,7 +4052,7 @@ void func_80055AB8(s32 objectIndex, s32 cameraId) {
|
||||
} else {
|
||||
rsp_set_matrix_transformation(gObjectList[objectIndex].pos, gObjectList[objectIndex].direction_angle, gObjectList[objectIndex].sizeScaling);
|
||||
gSPDisplayList(gDisplayListHead++, D_0D0077D0);
|
||||
func_80004DFC((animation_type_1 *) gObjectList[objectIndex].model, (animation_type_2 **) gObjectList[objectIndex].vertex, 0, (s16) gObjectList[objectIndex].itemDisplay);
|
||||
render_animated_model((Armature *) gObjectList[objectIndex].model, (Animation **) gObjectList[objectIndex].vertex, 0, (s16) gObjectList[objectIndex].itemDisplay);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -4061,7 +4061,7 @@ void render_object_chain_chomps(s32 cameraId) {
|
||||
s32 var_s1;
|
||||
s32 objectIndex;
|
||||
|
||||
for (var_s1 = 0; var_s1 < 3; var_s1++) {
|
||||
for (var_s1 = 0; var_s1 < NUM_CHAIN_CHOMPS; var_s1++) {
|
||||
objectIndex = indexObjectList2[var_s1];
|
||||
func_8008A1D0(objectIndex, cameraId, 0x000005DC, 0x000009C4);
|
||||
if (is_obj_flag_status_active(objectIndex, VISIBLE) != 0) {
|
||||
|
@ -7059,7 +7059,7 @@ void func_80084430(s32 objectIndex, UNUSED s32 arg1) {
|
||||
func_80086EF0(objectIndex);
|
||||
object->spline = D_800E672C[0];
|
||||
set_object_flag_status_true(objectIndex, 0x04000800);
|
||||
object->type = func_80004EAC(d_course_sherbet_land_unk_data11, 0);
|
||||
object->type = get_animation_length(d_course_sherbet_land_unk_data11, 0);
|
||||
func_80072488(objectIndex);
|
||||
}
|
||||
|
||||
@ -7177,7 +7177,7 @@ void func_800845C8(s32 objectIndex, s32 arg1) {
|
||||
}
|
||||
func_80086EF0(objectIndex);
|
||||
object->unk_034 = 0.0f;
|
||||
object->type = func_80004EAC(d_course_sherbet_land_unk_data11, 0);
|
||||
object->type = get_animation_length(d_course_sherbet_land_unk_data11, 0);
|
||||
func_80072488(objectIndex);
|
||||
}
|
||||
|
||||
@ -7250,7 +7250,7 @@ void func_80084D2C(s32 objectIndex, s32 arg1) {
|
||||
gObjectList[objectIndex].unk_09C = 1;
|
||||
gObjectList[objectIndex].unk_0D8 = 1;
|
||||
gObjectList[objectIndex].itemDisplay = 0;
|
||||
gObjectList[objectIndex].type = func_80004EAC(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
gObjectList[objectIndex].type = get_animation_length(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
func_800726CC(objectIndex, 3);
|
||||
func_80086FD4(objectIndex);
|
||||
if (func_80072354(objectIndex, 0x00000020) != 0) {
|
||||
@ -7290,7 +7290,7 @@ void func_80084D2C(s32 objectIndex, s32 arg1) {
|
||||
func_800722A4(objectIndex, 2);
|
||||
gObjectList[objectIndex].unk_0D8 = 2;
|
||||
gObjectList[objectIndex].itemDisplay = 0;
|
||||
gObjectList[objectIndex].type = func_80004EAC(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
gObjectList[objectIndex].type = get_animation_length(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
func_800726CC(objectIndex, 3);
|
||||
func_80086FD4(objectIndex);
|
||||
}
|
||||
@ -7299,7 +7299,7 @@ void func_80084D2C(s32 objectIndex, s32 arg1) {
|
||||
if (func_80072354(objectIndex, 2) != 0) {
|
||||
gObjectList[objectIndex].unk_0D8 = 0;
|
||||
gObjectList[objectIndex].itemDisplay = 0;
|
||||
gObjectList[objectIndex].type = func_80004EAC(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
gObjectList[objectIndex].type = get_animation_length(d_course_sherbet_land_unk_data11, gObjectList[objectIndex].unk_0D8);
|
||||
gObjectList[objectIndex].unk_0C6 += 0x8000;
|
||||
func_800726CC(objectIndex, 2);
|
||||
func_8008701C(objectIndex, 1);
|
||||
@ -7513,7 +7513,7 @@ void func_80085878(s32 objectIndex, s32 arg1) {
|
||||
set_obj_origin_offset(objectIndex, temp_v0->posX, temp_v0->posY, temp_v0->posZ);
|
||||
set_obj_direction_angle(objectIndex, 0U, 0U, 0U);
|
||||
object->unk_034 = 4.0f;
|
||||
object->type = func_80004EAC(d_rainbow_road_unk3, 0);
|
||||
object->type = get_animation_length(d_rainbow_road_unk3, 0);
|
||||
func_80072488(objectIndex);
|
||||
}
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef UPDATE_OBJECTS_H
|
||||
#define UPDATE_OBJECTS_H
|
||||
|
||||
#include "code_80004740.h"
|
||||
#include "animation.h"
|
||||
#include <common_structs.h>
|
||||
#include "camera.h"
|
||||
#include "objects.h"
|
||||
|
@ -48,7 +48,7 @@ segments:
|
||||
- [0x3590, c, code_80002990]
|
||||
- [0x4130, c, profiler]
|
||||
- [0x4CA0, c, crash_screen]
|
||||
- [0x5320, c, code_80004740]
|
||||
- [0x5320, c, animation]
|
||||
- [0x5AD0, c, staff_ghosts]
|
||||
- [0x6B90, asm, unused_overflow_check]
|
||||
- [0x6BB0, c, code_80005FD0]
|
||||
|
@ -47,7 +47,7 @@ segments:
|
||||
- [0x35B0, c, code_800029B0]
|
||||
- [0x4150, c, profiler]
|
||||
- [0x4CC0, c, crash_screen]
|
||||
- [0x5340, c, code_80004740]
|
||||
- [0x5340, c, animation]
|
||||
- [0x5AF0, c, staff_ghosts]
|
||||
- [0x6BB0, asm, unused_overflow_check]
|
||||
- [0x6BD0, c, code_80005FD0]
|
||||
|
Loading…
Reference in New Issue
Block a user