1
0
mirror of https://github.com/zeldaret/oot.git synced 2024-09-21 12:54:51 +00:00

z_en_syateki_niw doc (#1449)

* SyatekiNiw doc

started id'ing funcs and fields for SyatekiNiw

* `z_en_syateki_niw` doc

* `z_en_syateki_niw1: (almost) all fields/funcs doc'd

* `z_en_syateki_niw` update

changes based on feedback.

* `z_en_syateki_niw`: limb fields renamed

* Update z_en_syateki_niw.h

renamed fields as suggested.

* Update src/overlays/actors/ovl_En_Syateki_Niw/z_en_syateki_niw.h

fix typo in comment.

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>

* Update z_en_bom_bowl_man.c

add minigame enum to actor spawn param

* `z_en_syateki_niw`: updated based on feedback

renamed local vars for claritey, added more comments to struct.

* Update z_en_syateki_niw.c

renamed function and var based on feedback

---------

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
This commit is contained in:
blackgamma7 2023-08-23 16:50:09 -04:00 committed by GitHub
parent fc3e0f080b
commit b2787995f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 401 additions and 396 deletions

View File

@ -69,10 +69,10 @@ void EnBomBowlMan_Init(Actor* thisx, PlayState* play2) {
for (i = 0; i < 2; i++) { for (i = 0; i < 2; i++) {
cucco = (EnSyatekiNiw*)Actor_Spawn(&play->actorCtx, play, ACTOR_EN_SYATEKI_NIW, cuccoSpawnPos[i].x, cucco = (EnSyatekiNiw*)Actor_Spawn(&play->actorCtx, play, ACTOR_EN_SYATEKI_NIW, cuccoSpawnPos[i].x,
cuccoSpawnPos[i].y, cuccoSpawnPos[i].z, 0, 0, 0, 1); cuccoSpawnPos[i].y, cuccoSpawnPos[i].z, 0, 0, 0,
SYATEKI_MINIGAME_ALLEY);
if (cucco != NULL) { if (cucco != NULL) {
cucco->unk_2F4 = cuccoScales[i]; cucco->scale = cuccoScales[i];
cucco->collider.dim.radius = (s16)cuccoColliderDims[i][0]; cucco->collider.dim.radius = (s16)cuccoColliderDims[i][0];
cucco->collider.dim.height = (s16)cuccoColliderDims[i][1]; cucco->collider.dim.height = (s16)cuccoColliderDims[i][1];
} }

File diff suppressed because it is too large Load Diff

View File

@ -9,15 +9,15 @@ struct EnSyatekiNiw;
typedef void (*EnSyatekiNiwActionFunc)(struct EnSyatekiNiw*, PlayState*); typedef void (*EnSyatekiNiwActionFunc)(struct EnSyatekiNiw*, PlayState*);
typedef struct { typedef struct {
/* 0x00 */ u8 unk_00; /* 0x00 */ u8 state;
/* 0x0C */ Vec3f unk_04; /* 0x0C */ Vec3f pos;
/* 0x10 */ Vec3f unk_10; /* 0x10 */ Vec3f vel;
/* 0x1C */ Vec3f unk_1C; /* 0x1C */ Vec3f accel;
/* 0x28 */ s16 unk_28; /* 0x28 */ s16 lifespan;
/* 0x2A */ s16 unk_2A; /* 0x2A */ s16 rotPulse;
/* 0x2C */ f32 unk_2C; /* 0x2C */ f32 scale;
/* 0x30 */ f32 unk_30; /* 0x30 */ f32 rot;
/* 0x34 */ u8 unk_34; /* 0x34 */ u8 timer;
} EnSyatekiNiwEffect; // size = 0x38 } EnSyatekiNiwEffect; // size = 0x38
#define EN_SYATEKI_NIW_EFFECT_COUNT 5 #define EN_SYATEKI_NIW_EFFECT_COUNT 5
@ -28,46 +28,51 @@ typedef struct EnSyatekiNiw {
/* 0x0190 */ Vec3s jointTable[16]; /* 0x0190 */ Vec3s jointTable[16];
/* 0x01F0 */ Vec3s morphTable[16]; /* 0x01F0 */ Vec3s morphTable[16];
/* 0x0250 */ EnSyatekiNiwActionFunc actionFunc; /* 0x0250 */ EnSyatekiNiwActionFunc actionFunc;
/* 0x0254 */ s16 unk_254; /* 0x0254 */ s16 peckTimer; // intervals of bobbing head on ground
/* 0x0256 */ s16 unk_256; /* 0x0256 */ s16 timer1; // sometimes set alongside peckTimer, never read.
/* 0x0258 */ s16 unk_258; /* 0x0258 */ s16 flapTimer; // intervals of beating wings
/* 0x025A */ s16 unk_25A; /* 0x025A */ s16 archeryTimer;
/* 0x025C */ s16 unk_25C; /* 0x025C */ s16 hopTimer; // intervals of jumping
/* 0x025E */ s16 unk_25E; /* 0x025E */ s16 movementTimer; // intervals of changing location
/* 0x0260 */ s16 unk_260; /* 0x0260 */ s16 sootTimer; // cucco is covered in soot, smoke emmits
/* 0x0262 */ s16 unk_262; /* 0x0262 */ s16 cluckTimer; // intervals of clucking SFX
/* 0x0264 */ f32 unk_264; /* 0x0264 */ f32 headRotXTarget;
/* 0x0268 */ f32 unk_268; /* 0x0268 */ f32 rightWingRotXTarget;
/* 0x026C */ f32 unk_26C; /* 0x026C */ f32 leftWingRotXTarget;
/* 0x0270 */ char unk_270[0x8]; /* 0x0270 */ char unk_270[0x8];
/* 0x0278 */ f32 unk_278; /* 0x0278 */ f32 rightWingRotYTarget;
/* 0x027C */ f32 unk_27C; /* 0x027C */ f32 rightWingRotZTarget;
/* 0x0284 */ f32 unk_280; /* 0x0284 */ f32 leftWingRotYTarget;
/* 0x0280 */ f32 unk_284; /* 0x0280 */ f32 leftWingRotZTarget;
/* 0x0288 */ f32 unk_288; /* 0x0288 */ f32 unkArcheryFloat; // set, but never used. another rot target?
/* 0x028C */ s16 unk_28C; /* 0x028C */ s16 lifetime; // always ticks up, never read
/* 0x028E */ s16 unk_28E; /* 0x028E */ s16 headRotXState;
/* 0x0290 */ s16 unk_290; /* 0x0290 */ s16 unk_290; // set to 0, never read.
/* 0x0292 */ s16 unk_292; /* 0x0292 */ s16 wingsRotState;
/* 0x0294 */ s16 unk_294; /* 0x0294 */ s16 targetPosTimer;
/* 0x0296 */ s16 unk_296; /* 0x0296 */ s16 archeryAnimationType;
/* 0x0298 */ s16 unk_298; /* 0x0298 */ s16 rotYFlip;
/* 0x029C */ s16 unk_29A; /* 0x029C */ s16 archeryState; // state index for "Archery" action
/* 0x029C */ s16 unk_29C; /* 0x029C */ s16 isFalling; // set when hit in archery game
/* 0x029E */ s16 unk_29E; /* 0x029E */ s16 minigameType; // uses EnSyatekiMinigame from params
/* 0x02A0 */ s16 unk_2A0; /* 0x02A0 */ s16 spawnFeathers; // triggers feather particles
/* 0x02A4 */ Vec3f unk_2A4; /* 0x02A4 */ Vec3f leftWingRot;
/* 0x02B0 */ Vec3f unk_2B0; /* 0x02B0 */ Vec3f rightWingRot;
/* 0x02BC */ Vec3f unk_2BC; /* 0x02BC */ Vec3f headRot;
/* 0x02C8 */ Vec3f unk_2C8; /* 0x02C8 */ Vec3f posRotStep;
/* 0x02D4 */ f32 unk_2D4; /* 0x02D4 */ f32 focusYOffset;
/* 0x02D8 */ f32 unk_2D8; /* 0x02D8 */ f32 removeStateYaw;
/* 0x02DC */ Vec3f unk_2DC; /* 0x02DC */ Vec3f initPos;
/* 0x02E8 */ Vec3f unk_2E8; /* 0x02E8 */ Vec3f targetPos;
/* 0x02F4 */ f32 unk_2F4; /* 0x02F4 */ f32 scale;
/* 0x02F8 */ u8 unk_2F8; /* 0x02F8 */ u8 unkAlleyHitByte; // Set when hit in Bombchu Alley. Never read.
/* 0x02FC */ ColliderCylinder collider; /* 0x02FC */ ColliderCylinder collider;
/* 0x0348 */ EnSyatekiNiwEffect effects[EN_SYATEKI_NIW_EFFECT_COUNT]; /* 0x0348 */ EnSyatekiNiwEffect effects[EN_SYATEKI_NIW_EFFECT_COUNT]; // feather particles
} EnSyatekiNiw; // size = 0x0460 } EnSyatekiNiw; // size = 0x0460
typedef enum {
SYATEKI_MINIGAME_ARCHERY, // unused archery game behavior
SYATEKI_MINIGAME_ALLEY // Bombchu Alley behavior
} EnSyatekiMinigame;
#endif #endif