1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-22 23:11:20 +00:00

Document Attention/Lock-on Related Actor Flags (#2161)

* document actor flags 0, 2, 3, and 27

* format

* fly -> hover

* wodring
This commit is contained in:
fig02 2024-09-07 17:53:48 -04:00 committed by GitHub
parent a039aeffb7
commit 2056ae5f1a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
181 changed files with 616 additions and 597 deletions

View file

@ -7,7 +7,7 @@
#include "z_en_ba.h"
#include "assets/objects/object_bxa/object_bxa.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4)
#define FLAGS (ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE | ACTOR_FLAG_4)
void EnBa_Init(Actor* thisx, PlayState* play);
void EnBa_Destroy(Actor* thisx, PlayState* play);
@ -146,7 +146,7 @@ void EnBa_Idle(EnBa* this, PlayState* play) {
if ((this->actor.colChkInfo.mass == MASS_IMMOVABLE) && (this->actor.xzDistToPlayer > 175.0f)) {
Math_SmoothStepToF(&this->actor.world.pos.y, this->actor.home.pos.y + 330.0f, 1.0f, 7.0f, 0.0f);
} else {
this->actor.flags |= ACTOR_FLAG_0;
this->actor.flags |= ACTOR_FLAG_ATTENTION_ENABLED;
Math_SmoothStepToF(&this->actor.world.pos.y, this->actor.home.pos.y + 100.0f, 1.0f, 10.0f, 0.0f);
}
this->unk_2FC = this->actor.world.pos;
@ -402,7 +402,7 @@ void func_809B75A0(EnBa* this, PlayState* play2) {
Matrix_Translate(this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, MTXMODE_NEW);
Matrix_RotateZYX(this->actor.shape.rot.x - 0x8000, this->actor.shape.rot.y, 0, MTXMODE_APPLY);
Matrix_MultVec3f(&D_809B8080, &this->unk_158[0]);
this->actor.flags &= ~ACTOR_FLAG_0;
this->actor.flags &= ~ACTOR_FLAG_ATTENTION_ENABLED;
for (i = 5; i < 13; i++) {
Math_SmoothStepToS(&this->unk_2A8[i].x, this->unk_2A8[5].x, 1, this->unk_31C, 0);
Math_SmoothStepToS(&this->unk_2A8[i].y, this->unk_2A8[5].y, 1, this->unk_31C, 0);