Convert Asset20 to Object_Boost and convert unk80068514_arg4 to Sprite (#569)

* Convert Asset20 to Object_Boost and convert unk80068514_arg4 to Sprite

* clean up some SoundHandle warnings

* Fix many warnings

* Rename racer_sound_init

* Fix last warning and format
This commit is contained in:
Ryan Myers
2025-05-13 20:33:44 -04:00
committed by GitHub
parent 8a58156c3d
commit 0f5d0e0e43
21 changed files with 175 additions and 95 deletions
+3 -4
View File
@@ -1031,8 +1031,7 @@ void sprite_anim_off(s32 setting) {
/**
* Calculates angle from object to camera, then renders the sprite as a billboard, facing the camera.
*/
s32 render_sprite_billboard(Gfx **dList, MatrixS **mtx, Vertex **vertexList, Object *obj, unk80068514_arg4 *arg4,
s32 flags) {
s32 render_sprite_billboard(Gfx **dList, MatrixS **mtx, Vertex **vertexList, Object *obj, Sprite *arg4, s32 flags) {
f32 diffX;
f32 diffY;
Vertex *v;
@@ -1128,7 +1127,7 @@ s32 render_sprite_billboard(Gfx **dList, MatrixS **mtx, Vertex **vertexList, Obj
gDkrEnableBillboard((*dList)++);
}
if (gSpriteAnimOff == FALSE) {
textureFrame = ((textureFrame & 0xFF) * arg4->textureCount) >> 8;
textureFrame = ((textureFrame & 0xFF) * arg4->baseTextureId) >> 8;
}
flags &= ~RENDER_VEHICLE_PART;
if (flags & RENDER_SEMI_TRANSPARENT) {
@@ -1139,7 +1138,7 @@ s32 render_sprite_billboard(Gfx **dList, MatrixS **mtx, Vertex **vertexList, Obj
if (!(flags & RENDER_Z_UPDATE)) {
gDPSetPrimColor((*dList)++, 0, 0, 255, 255, 255, 255);
}
gSPDisplayList((*dList)++, arg4->unk8[textureFrame + 1]);
gSPDisplayList((*dList)++, arg4->gfx[textureFrame + 1]);
gModelMatrixStackPos--;
if (gModelMatrixStackPos == 0) {
textureFrame = 0;