This commit is contained in:
blackgamma7 2025-12-11 08:38:15 +09:00 committed by GitHub
commit bedd5ef0a6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 730 additions and 665 deletions

View File

@ -6,6 +6,8 @@
#include "z_bg_po_event.h"
#include "overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.h"
#include "libc64/qrand.h"
#include "array_count.h"
#include "gfx.h"
@ -353,7 +355,7 @@ void BgPoEvent_BlockIdle(BgPoEvent* this, PlayState* play) {
if ((this->type == 0) && (this->index == 0)) {
amy = Actor_Spawn(&play->actorCtx, play, ACTOR_EN_PO_SISTERS, this->dyna.actor.world.pos.x + 30.0f,
this->dyna.actor.world.pos.y - 30.0f, this->dyna.actor.world.pos.z + 30.0f, 0,
this->dyna.actor.shape.rot.y, 0, this->dyna.actor.params + 0x300);
this->dyna.actor.shape.rot.y, 0, this->dyna.actor.params + EN_PO_SISTERS_PARAM(AMY));
if (amy != NULL) {
OnePointCutscene_Init(play, 3170, 30, amy, CAM_ID_MAIN);
}
@ -549,7 +551,8 @@ void BgPoEvent_PaintingPresent(BgPoEvent* this, PlayState* play) {
} else if (this->collider.base.acFlags & AC_HIT) {
if (!BgPoEvent_NextPainting(this)) {
Actor_Spawn(&play->actorCtx, play, ACTOR_EN_PO_SISTERS, thisx->world.pos.x, thisx->world.pos.y - 40.0f,
thisx->world.pos.z, 0, thisx->shape.rot.y, 0, thisx->params + ((this->type - 1) << 8));
thisx->world.pos.z, 0, thisx->shape.rot.y, 0,
thisx->params + EN_PO_SISTERS_PARAM_N((this->type - 1)));
OnePointCutscene_Init(play, 3160, 80, thisx, CAM_ID_MAIN);
Sfx_PlaySfxCentered(NA_SE_SY_CORRECT_CHIME);

View File

@ -6,6 +6,8 @@
#include "z_bg_po_syokudai.h"
#include "overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.h"
#include "libc64/qrand.h"
#include "gfx.h"
#include "gfx_setupdl.h"
@ -116,7 +118,8 @@ void BgPoSyokudai_Init(Actor* thisx, PlayState* play) {
} else if (!Flags_GetSwitch(play, POE_TORCH_FLAG + POE_FLAME_PURPLE) && !Flags_GetSwitch(play, 0x1B)) {
Actor_Spawn(&play->actorCtx, play, ACTOR_EN_PO_SISTERS, thisx->world.pos.x, thisx->world.pos.y + 52.0f,
thisx->world.pos.z, 0, 0, 0, (this->flameColor << 8) + thisx->params + 0x1000);
thisx->world.pos.z, 0, 0, 0,
EN_PO_SISTERS_PARAM_N(this->flameColor) + thisx->params + EN_PO_SISTERS_INTRO_PARAM);
} else if (!Flags_GetSwitch(play, thisx->params)) {
if (play->envCtx.lightSettingOverride == LIGHT_SETTING_OVERRIDE_NONE) {

File diff suppressed because it is too large Load Diff

View File

@ -13,23 +13,39 @@ typedef struct EnPoSisters {
/* 0x0000 */ Actor actor;
/* 0x014C */ SkelAnime skelAnime;
/* 0x0190 */ EnPoSistersActionFunc actionFunc;
/* 0x0194 */ u8 unk_194;
/* 0x0195 */ u8 unk_195;
/* 0x0196 */ u8 unk_196;
/* 0x0197 */ u8 unk_197;
/* 0x0198 */ u8 unk_198;
/* 0x0199 */ u8 unk_199;
/* 0x019A */ s16 unk_19A;
/* 0x019A */ s16 unk_19C;
/* 0x0194 */ u8 sisterID; // which Poe sister this is
/* 0x0195 */ u8 decoyID; // if non-zero, index of Meg's decoy
/* 0x0196 */ u8 hoverPulse;
/* 0x0197 */ u8 vanishTimer;
/* 0x0198 */ u8 torchFlames; // number of torch flames to draw
/* 0x0199 */ u8 flags; // uses EnPoSisterFlags
/* 0x019A */ s16 timer; // timer used for various situations
/* 0x019C */ s16 sisterVar; // Used as a decoy counter for Meg, her sisters a reveal timer
/* 0x019E */ Vec3s jointTable[12];
/* 0x01E6 */ Vec3s morphTable[12];
/* 0x022E */ Color_RGBA8 unk_22E;
/* 0x0234 */ Vec3f unk_234[8];
/* 0x0294 */ f32 unk_294;
/* 0x022E */ Color_RGBA8 color; // (rgb) for eyes, (a) for rest of body
/* 0x0234 */ Vec3f torchPos[8]; // positions of the torch flame and smaller circling flames
/* 0x0294 */ f32 circleDist; // distance of Meg when circling Link.
/* 0x0298 */ LightNode* lightNode;
/* 0x029C */ LightInfo lightInfo;
/* 0x02AC */ ColliderCylinder collider;
/* 0x02F8 */ MtxF unk_2F8;
/* 0x02F8 */ MtxF torchMtxF;
} EnPoSisters; // size = 0x0338
typedef enum EnPoSisterNames {
EN_PO_SISTERS_MEG, // purple sister, circles Link with decoys
EN_PO_SISTERS_JOELLE, // red sister, hides in portraits
EN_PO_SISTERS_BETH, // blue sister, hides in portraits
EN_PO_SISTERS_AMY, // green sister, hides in block puzzle
} EnPoSisterNames;
#define POE_SISTER_GET_ID(x) PARAMS_GET_U(x->params, 8, 2)
#define POE_SISTER_GET_DECOY(x) PARAMS_GET_U(x->params, 10, 2)
#define POE_SISTER_GET_INTRO(x) PARAMS_GET_NOSHIFT(x->actor.params, 12, 1)
#define EN_PO_SISTERS_PARAM_N(n) (n << 8) // param for which sister by number
#define EN_PO_SISTERS_PARAM(name) (EN_PO_SISTERS_##name << 8) // param for which sister by name
#define EN_PO_SISTERS_DECOY_PARAM(n) (n << 10) // param for Meg's decoys
#define EN_PO_SISTERS_INTRO_PARAM (1 << 12) // param for Poe Sisters when first entering foyer
#endif