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

Angle cleanup - RADF_TO_BINANG (#1155)

* Run formatter

* Touch up angle macros (parentheses and hex constants)

* Use `RADF_TO_BINANG` more
This commit is contained in:
Dragorn421 2022-03-13 19:46:46 +01:00 committed by GitHub
parent aab5bc9211
commit 61b864a89c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
45 changed files with 120 additions and 128 deletions

View file

@ -550,10 +550,10 @@ void DemoGj_SetupMovement(DemoGj* this, GlobalContext* globalCtx) {
zDistance = player->actor.world.pos.z - pos->z;
if (xDistance != 0.0f || zDistance != 0.0f) {
actor->world.rot.y = (Math_FAtan2F(xDistance, zDistance) * (0x8000 / M_PI));
actor->world.rot.y = RADF_TO_BINANG(Math_FAtan2F(xDistance, zDistance));
}
} else {
actor->world.rot.y = (Math_FAtan2F(xDistance, zDistance) * (0x8000 / M_PI));
actor->world.rot.y = RADF_TO_BINANG(Math_FAtan2F(xDistance, zDistance));
}
}
}