1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-20 14:01:15 +00:00

Use defines for actor flags (#873)

* Add ACTOR_FLAG_ defines

* Add ACTOR_FLAGS_ALL macro and use ACTOR_FLAG_* constants everywhere

* Remove unused ACTOR_FLAG_* constants

* actor flags in bigokuta & ko

* actor flags in obj_mure

* actor flags in stalfos, twinrova & ganon2

* actor flags in morpha & barinade

* name some previously missed actor flags

* found some comments using hex for actor flags

* Actor flags in ovl_En_Ganon_Mant

* Actor flags in EnWf

* Flags in en_zf

* Actor flags in BossGanon (FeelsOKMan)

* Remove `ACTOR_FLAG_NONE`

* Wrap expansion of `FLAGS` in parentheses

* `ACTOR_FLAGS_ALL` -> `CHECK_FLAG_ALL`

* Move `CHECK_FLAG_ALL` to `macros.h`

* Run formatter
This commit is contained in:
Dragorn421 2021-12-06 01:11:38 +01:00 committed by GitHub
parent 79220ba58a
commit a9284494f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
439 changed files with 1342 additions and 1304 deletions

View file

@ -7,7 +7,7 @@
#include "z_en_elf.h"
#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x02000030
#define FLAGS (ACTOR_FLAG_4 | ACTOR_FLAG_5 | ACTOR_FLAG_25)
#define FAIRY_FLAG_TIMED (1 << 8)
#define FAIRY_FLAG_BIG (1 << 9)
@ -1379,7 +1379,7 @@ void func_80A053F0(Actor* thisx, GlobalContext* globalCtx) {
}
} else if (player->naviTextId < 0) {
// trigger dialog instantly for negative message IDs
thisx->flags |= 0x10000;
thisx->flags |= ACTOR_FLAG_16;
}
if (Actor_ProcessTalkRequest(thisx, globalCtx)) {
@ -1397,10 +1397,10 @@ void func_80A053F0(Actor* thisx, GlobalContext* globalCtx) {
func_80A01C38(this, 3);
if (this->elfMsg != NULL) {
this->elfMsg->actor.flags |= 0x100;
this->elfMsg->actor.flags |= ACTOR_FLAG_8;
}
thisx->flags &= ~0x10000;
thisx->flags &= ~ACTOR_FLAG_16;
} else {
this->actionFunc(this, globalCtx);
thisx->shape.rot.y = this->unk_2BC;