summaryrefslogtreecommitdiff
path: root/src/render_objects.c
diff options
context:
space:
mode:
authorcoco875 <59367621+coco875@users.noreply.github.com>2024-08-23 02:20:13 +0200
committerGitHub <noreply@github.com>2024-08-22 18:20:13 -0600
commite135178097f416bc54e36058e10d9b1c013929fd (patch)
tree0903c79b59ed716497e55618631d5e76611fe032 /src/render_objects.c
parent3781ce2830a143df855003b65fe069d2e26215d9 (diff)
Update from decomp (#34)
* Update menus.c (#634) * Update common_data.yml (#635) * Renames for screenId and other changes (#636) * screenId renames * Rename surface map to collision mesh (#637) * Rename some stack vars (#638) * Fix syntax error (#639) * Rename some stack vars * Update collision.c * Collision Documentation (#640) * Collision related renames * update doxygen (#649) * change bool (#644) * Update (#642) * Delete trig_tables_bss.c (#650) * fix typo audio (#656) * fix typo src actor (#657) * fix typo include (#658) * fix course (#659) * fix typo debug (#660) * fix typo data (#661) * Update common_structs.h * replace number with const (#665) * fix typo buffers (#655) * fix typo buffers * tweak ld file * rename to sMemoryPool * add a warning --------- * fix typo src (#654) * fix typo src * fix non matcing * Update code_80091750.c --------- * fix typo racing (#653) * fix typo racing * get it match * replace G_LINE3D to G_QUAD --------- * fix typo src (#652) * fix ending typo (#651) * Action more info when it doesn't match and fix first diff (#662) * Update linux-compile.yml * fix first-diff * Update first-diff.py --------- * document texture of kart (#663) * document texture of kart * change screenPlayerId to screenId * some documentation around object * Revert "some documentation around object" This reverts commit cbb39078e036bf2a417bed67359e910213acab28. * more rename --------- * Make evaluate_collision_players_palm_tree better (#667) This matches just the same as before, but using those two casts instead of shifts seems more likely to be accurate to the original source code Signed-off-by: Gabriel Ravier <gabravier@gmail.com> * add fedora instruciton (#666) * start documenting animation (#668) * start documenting animation * Update course_data.c * change comment * fix error of compilation * fix error of compilation * Update animation.c
Diffstat (limited to 'src/render_objects.c')
-rw-r--r--src/render_objects.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/render_objects.c b/src/render_objects.c
index e61f7526e..7dff32431 100644
--- a/src/render_objects.c
+++ b/src/render_objects.c
@@ -20,7 +20,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"
@@ -3947,9 +3947,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);
}
}
}
@@ -3972,9 +3972,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);
}
}
}
@@ -4074,7 +4074,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);
@@ -4082,7 +4082,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);
}
}
@@ -4146,7 +4146,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);
}
}
}
@@ -4155,7 +4155,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) {