1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-07-15 04:14:34 +00:00

Document undocumented matrix functions (#955)

* Document `func_800D1694` as `Matrix_TranslateRotateYXZ`

* Document `func_800D1FD4` as `Matrix_ReplaceRotation`

* Cleanup `Matrix_RotateAxis`

* Document `func_800A7EC0` as `SkinMatrix_SetRotateAxis`

* Document `func_800D2A34` and `func_800D2A98` as `Matrix_SetTranslateScaleMtx`(`F`)

* Document mostly unused functions at the end of `sys_matrix.c`

* Add in-use renamed functions to `namefixer.py`

* Add `Matrix_SetTranslateScaleMtx2` to `namefixer.py`

* Run formatter

* Fix namefixer.py mistake from #952

* Format clang-11.1

* Fix `Matrix_TranslateRotateYXZ` wrongly documented, it actually is `Matrix_SetTranslateRotateYXZ`

* VS Code is stellar at refactoring (no)

* Run formatter

* Come on VS Code

* Improve `Matrix_ReplaceRotation` docs

* Fix typo

* Fix namefixer.py
This commit is contained in:
Dragorn421 2022-01-11 00:28:01 +01:00 committed by GitHub
parent 0b8edc21c0
commit b1d3844325
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
63 changed files with 403 additions and 374 deletions

View file

@ -2165,13 +2165,13 @@ void Actor_Draw(GlobalContext* globalCtx, Actor* actor) {
Lights_Draw(lights, globalCtx->state.gfxCtx);
if (actor->flags & ACTOR_FLAG_12) {
func_800D1694(actor->world.pos.x + globalCtx->mainCamera.skyboxOffset.x,
actor->world.pos.y +
(f32)((actor->shape.yOffset * actor->scale.y) + globalCtx->mainCamera.skyboxOffset.y),
actor->world.pos.z + globalCtx->mainCamera.skyboxOffset.z, &actor->shape.rot);
Matrix_SetTranslateRotateYXZ(
actor->world.pos.x + globalCtx->mainCamera.skyboxOffset.x,
actor->world.pos.y + (f32)((actor->shape.yOffset * actor->scale.y) + globalCtx->mainCamera.skyboxOffset.y),
actor->world.pos.z + globalCtx->mainCamera.skyboxOffset.z, &actor->shape.rot);
} else {
func_800D1694(actor->world.pos.x, actor->world.pos.y + (actor->shape.yOffset * actor->scale.y),
actor->world.pos.z, &actor->shape.rot);
Matrix_SetTranslateRotateYXZ(actor->world.pos.x, actor->world.pos.y + (actor->shape.yOffset * actor->scale.y),
actor->world.pos.z, &actor->shape.rot);
}
Matrix_Scale(actor->scale.x, actor->scale.y, actor->scale.z, MTXMODE_APPLY);