diff options
| author | Tharo <17233964+Thar0@users.noreply.github.com> | 2020-12-03 21:51:22 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-12-03 16:51:22 -0500 |
| commit | 579b87dceb94410c8d115fc75789c106cf08d5ca (patch) | |
| tree | 0e55f2e0635a86ce366726af95d0f262698520c9 /src/code | |
| parent | cbb0c6da06657a0caebf3e317c1fed9ad7d43f25 (diff) | |
ovl_En_Door (#402)
* Decompiled, two non-matchings remaining
* Fix merge
* Cleanups
* Some documentation, remove unused asm
* Remove unused data.s, review suggestions
* Ran formatter, further review suggestions
* Make some data static
* Match EnDoor_Init
* Remove asm for EnDoor_Init
* Changes from review
Co-authored-by: petrie911 <69443847+petrie911@users.noreply.github.com>
* More variables static, remove unnecessary s8 cast
* PR Suggestions
* review
Co-authored-by: petrie911 <69443847+petrie911@users.noreply.github.com>
Co-authored-by: fig <fig02srl@gmail.com>
Diffstat (limited to 'src/code')
| -rw-r--r-- | src/code/z_actor.c | 10 | ||||
| -rw-r--r-- | src/code/z_skelanime.c | 4 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/code/z_actor.c b/src/code/z_actor.c index 17aa8a714..d170b65c0 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -3499,7 +3499,7 @@ struct_801160DC D_801160DC[] = { { 0.64000005f, 8500.0f, 8000.0f, 1.75f, 0.1f, 0x050011F0, 0x05001100 }, }; -void func_80033F54(GlobalContext* globalCtx, s32 arg1, s32 arg2) { +void Actor_DrawDoorLock(GlobalContext* globalCtx, s32 frame, s32 type) { struct_801160DC* entry; s32 i; MtxF spB0; @@ -3508,7 +3508,7 @@ void func_80033F54(GlobalContext* globalCtx, s32 arg1, s32 arg2) { f32 temp2; f32 temp3; - entry = &D_801160DC[arg2]; + entry = &D_801160DC[type]; var = entry->unk_10; OPEN_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8265); @@ -3516,8 +3516,8 @@ void func_80033F54(GlobalContext* globalCtx, s32 arg1, s32 arg2) { Matrix_Translate(0.0f, entry->unk_08, 500.0f, MTXMODE_APPLY); Matrix_Get(&spB0); - temp1 = sinf(entry->unk_00 - var) * -(10 - arg1) * 0.1f * entry->unk_04; - temp2 = cosf(entry->unk_00 - var) * (10 - arg1) * 0.1f * entry->unk_04; + temp1 = sinf(entry->unk_00 - var) * -(10 - frame) * 0.1f * entry->unk_04; + temp2 = cosf(entry->unk_00 - var) * (10 - frame) * 0.1f * entry->unk_04; for (i = 0; i < 4; i++) { Matrix_Put(&spB0); @@ -3542,7 +3542,7 @@ void func_80033F54(GlobalContext* globalCtx, s32 arg1, s32 arg2) { } Matrix_Put(&spB0); - Matrix_Scale(arg1 * 0.1f, arg1 * 0.1f, arg1 * 0.1f, MTXMODE_APPLY); + Matrix_Scale(frame * 0.1f, frame * 0.1f, frame * 0.1f, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 8314), G_MTX_MODELVIEW | G_MTX_LOAD); diff --git a/src/code/z_skelanime.c b/src/code/z_skelanime.c index cf63e6798..61ab1fdf6 100644 --- a/src/code/z_skelanime.c +++ b/src/code/z_skelanime.c @@ -1271,8 +1271,8 @@ s32 func_800A4530(SkelAnime* skelAnime, f32 arg1) { return func_800A4478(skelAnime, arg1, updateRate); } -void SkelAnime_Init(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg, - AnimationHeader* animationSeg, Vec3s* limbDrawTbl, Vec3s* transitionDrawTable, s32 limbCount) { +s32 SkelAnime_Init(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg, + AnimationHeader* animationSeg, Vec3s* limbDrawTbl, Vec3s* transitionDrawTable, s32 limbCount) { SkeletonHeader* skeletonHeader = SEGMENTED_TO_VIRTUAL(skeletonHeaderSeg); skelAnime->limbCount = skeletonHeader->limbCount + 1; |
