diff options
| author | AdamKiddle <54328813+AdamKiddle@users.noreply.github.com> | 2020-08-08 16:23:16 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-08 11:23:16 -0400 |
| commit | 54f762b419353090d81e7d028a14947d64a311c8 (patch) | |
| tree | 303da5544f131bd46c48d39f514ef5d28cbd6f6e /src/code/z_actor.c | |
| parent | 34c73dda62f973aaa940ffc7c8165cc645324c28 (diff) | |
z_skin_matrix.c decompiled (1 non matching, 1 non equivalent) (#243)
* func_800A7BE4 and func_800A7C20 done
- func_800A7BE4 copy of "Math_Vec3f_ToVec3s" in z_lib.c
- func_800A7C20 copy of "Math_Vec3s_ToVec3f" in z_lib.c
* done func_800A7A24
* func_800A76A4 done
* func_800A6E10 done
* func_800A6EF4 done
* func_800A6FA0 done
* func_800A72FC done
* Deleted z_skin_matrix.data.s and updated spec
* func_800A730C done
* func_800A735C done
* func_800A7E70 done, func_800A7C60 matching but I'm not happy with it (weird types in function params)
* Corrections. func_800A7C60 in skin_matrix done, Matrix_MtxFToMtx in sys_matrix done.
* func_800A7EC0 nonmatching
* func_800A8030 nonmatching but VERY close (two registers swapped)
* func_800A8030 done
* updating comments
* func_800A7704 done
* func_800A7894 done
* halfway through deciphering mips_to_c for func_800A73E0
* func_800A73E0 functional but non-matching (saved register differences and probably regalloc)
* Renaming some arguments and rewriting comments
* Renamed files across whole project and deleted asm nonmatchings
* ran format.sh
* fixed function name
* fixing multiplcation order in SkinMatrix_MtxFMtxFMult
* Corrections in SkinMatrix_MtxFMtxFMult
* Formatting changes after review
* Changes as per code review
* fixing rename error
* fixing rename error
* rename fixes
* fixing function rename error
* ran ./format.sh
* last couple of changes as per code review
* renamed SetScaling -> SetScale
* Skin_Matrix_Invert -> SkinMatrix_Invert
* Renaming and fixing debug message print
* Renamed argument "mf" to more specific "clear" in SkinMatrix_GetClear
* renamed again to "mfp"
* snake case to camel case changes
Diffstat (limited to 'src/code/z_actor.c')
| -rw-r--r-- | src/code/z_actor.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/code/z_actor.c b/src/code/z_actor.c index 6f4973a3d..fc9a8e362 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -228,7 +228,7 @@ void func_8002BDB0(Actor* actor, s32 arg1, s32 arg2, UNK_PTR arg3, s32 arg4, UNK } void func_8002BE04(GlobalContext* globalCtx, Vec3f* arg1, Vec3f* arg2, f32* arg3) { - func_800A6E10(&globalCtx->mf_11D60, arg1, arg2, arg3); + SkinMatrix_Vec3fMtxFMultXYZW(&globalCtx->mf_11D60, arg1, arg2, arg3); *arg3 = (*arg3 < 1.0f) ? 1.0f : (1.0f / *arg3); } @@ -2400,7 +2400,8 @@ void func_800315AC(GlobalContext* globalCtx, ActorContext* actorCtx) { HREG(66) = i; if ((HREG(64) != 1) || ((HREG(65) != -1) && (HREG(65) != HREG(66))) || (HREG(68) == 0)) { - func_800A6E10(&globalCtx->mf_11D60, &actor->posRot.pos, &actor->projectedPos, &actor->projectedW); + SkinMatrix_Vec3fMtxFMultXYZW(&globalCtx->mf_11D60, &actor->posRot.pos, &actor->projectedPos, + &actor->projectedW); } if ((HREG(64) != 1) || ((HREG(65) != -1) && (HREG(65) != HREG(66))) || (HREG(69) == 0)) { |
