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

Generic actor params getters (#1359)

* Initial PARAMS_GET macros

* NOSHIFT macro

* Use number of bits rather than raw mask values

* Add descriptions for each generic macro

* Reformat

* Adjust comment

* format

* edit en_door macro names

* edit redead macro name

* edit bdan switch macro name, and remove unneeded comments in go2

* mizushutter macro names

* remove PARAMS_GET_S, rework ishi switch flag handling

* actually remove PARAMS_GET_S

* remove PARAMS_GET2_S

* PARAMS_GET_U and PARAMS_GET_S

* format

* fix merge

* format

---------

Co-authored-by: fig02 <fig02srl@gmail.com>
Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
This commit is contained in:
Tharo 2024-08-14 20:29:43 +01:00 committed by GitHub
parent 137e0d2a10
commit eaf955ad22
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
200 changed files with 1113 additions and 1045 deletions

View file

@ -59,7 +59,7 @@ void EnHeishi4_Init(Actor* thisx, PlayState* play) {
EnHeishi4* this = (EnHeishi4*)thisx;
Actor_SetScale(thisx, 0.01f);
this->type = thisx->params & 0xFF;
this->type = PARAMS_GET_U(thisx->params, 0, 8);
thisx->colChkInfo.mass = MASS_IMMOVABLE;
this->pos = thisx->world.pos;
thisx->targetMode = 6;
@ -93,11 +93,11 @@ void EnHeishi4_Init(Actor* thisx, PlayState* play) {
this->actionFunc = func_80A56544;
break;
}
this->unk_27C = (thisx->params >> 8) & 0xFF;
this->unk_27C = PARAMS_GET_U(thisx->params, 8, 8);
PRINTF("\n\n");
PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 兵士2セット完了! ☆☆☆☆☆ %d\n" VT_RST, thisx->params);
PRINTF(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 識別完了!\t ☆☆☆☆☆ %d\n" VT_RST, this->type);
PRINTF(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ メッセージ完了! ☆☆☆☆☆ %x\n\n" VT_RST, (thisx->params >> 8) & 0xF);
PRINTF(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ メッセージ完了! ☆☆☆☆☆ %x\n\n" VT_RST, PARAMS_GET_U(thisx->params, 8, 4));
PRINTF("\n\n");
}