Merge c5d17115d9
into e163d5bc3d
This commit is contained in:
commit
882adea91a
|
@ -503,7 +503,7 @@ s16 func_80032CB4(s16* arg0, s16 arg1, s16 arg2, s16 arg3);
|
|||
void BodyBreak_Alloc(BodyBreak* bodyBreak, s32 count, PlayState* play);
|
||||
void BodyBreak_SetInfo(BodyBreak* bodyBreak, s32 limbIndex, s32 minLimbIndex, s32 maxLimbIndex, u32 count, Gfx** dList,
|
||||
s16 objectId);
|
||||
s32 BodyBreak_SpawnParts(Actor* actor, BodyBreak* bodyBreak, PlayState* play, s16 type);
|
||||
s32 BodyBreak_SpawnParts(Actor* actor, BodyBreak* bodyBreak, PlayState* play, s16 type, bool isFlex);
|
||||
void Actor_SpawnFloorDustRing(PlayState* play, Actor* actor, Vec3f* posXZ, f32 radius, s32 amountMinusOne,
|
||||
f32 randAccelWeight, s16 scale, s16 scaleStep, u8 useLighting);
|
||||
void func_80033480(PlayState* play, Vec3f* posBase, f32 randRangeDiameter, s32 amountMinusOne, s16 scaleBase,
|
||||
|
@ -1259,6 +1259,8 @@ void SkelAnime_DrawFlexLod(PlayState* play, void** skeleton, Vec3s* jointTable,
|
|||
s32 dListIndex);
|
||||
void SkelAnime_DrawSkeletonOpa(PlayState* play, SkelAnime* skelAnime, OverrideLimbDrawOpa overrideLimbDraw,
|
||||
PostLimbDrawOpa postLimbDraw, void* arg);
|
||||
Gfx* SkelAnime_DrawSkeleton2(PlayState* play, SkelAnime* skelAnime, OverrideLimbDrawOpa overrideLimbDraw,
|
||||
PostLimbDrawOpa postLimbDraw, void* arg, Gfx* gfx);
|
||||
void SkelAnime_DrawOpa(PlayState* play, void** skeleton, Vec3s* jointTable,
|
||||
OverrideLimbDrawOpa overrideLimbDraw, PostLimbDrawOpa postLimbDraw, void* arg);
|
||||
void SkelAnime_DrawFlexOpa(PlayState* play, void** skeleton, Vec3s* jointTable, s32 dListCount,
|
||||
|
|
|
@ -1405,6 +1405,10 @@ typedef struct PlayState {
|
|||
/* 0x1242B */ u8 unk_1242B;
|
||||
/* 0x1242C */ SceneTableEntry* loadedScene;
|
||||
/* 0x12430 */ char unk_12430[0xE8];
|
||||
|
||||
|
||||
Mtx** flexLimbOverrideMTX;
|
||||
|
||||
} PlayState; // size = 0x12518
|
||||
|
||||
typedef struct {
|
||||
|
|
|
@ -920,6 +920,8 @@ void DrawEnhancementsMenu() {
|
|||
UIWidgets::Tooltip("Disables grottos rotating with the camera. To be used in conjunction with mods that want to replace grottos with 3D objects.");
|
||||
UIWidgets::PaddedEnhancementCheckbox("Invisible Bunny Hood", "gHideBunnyHood", true, false);
|
||||
UIWidgets::Tooltip("Turns Bunny Hood invisible while still maintaining its effects.");
|
||||
UIWidgets::PaddedEnhancementCheckbox("Disable HUD Heart animations", "gNoHUDHeartAnimation", true, false);
|
||||
UIWidgets::Tooltip("Disables the beating animation of the hearts on the HUD.");
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
|
|
@ -3565,7 +3565,7 @@ void BodyBreak_SetInfo(BodyBreak* bodyBreak, s32 limbIndex, s32 minLimbIndex, s3
|
|||
bodyBreak->prevLimbIndex = limbIndex;
|
||||
}
|
||||
|
||||
s32 BodyBreak_SpawnParts(Actor* actor, BodyBreak* bodyBreak, PlayState* play, s16 type) {
|
||||
s32 BodyBreak_SpawnParts(Actor* actor, BodyBreak* bodyBreak, PlayState* play, s16 type, bool isFlex) {
|
||||
EnPart* spawnedEnPart;
|
||||
MtxF* mtx;
|
||||
s16 objBankIndex;
|
||||
|
@ -3592,8 +3592,11 @@ s32 BodyBreak_SpawnParts(Actor* actor, BodyBreak* bodyBreak, PlayState* play, s1
|
|||
spawnedEnPart = (EnPart*)Actor_SpawnAsChild(&play->actorCtx, actor, play, ACTOR_EN_PART, mtx->xw,
|
||||
mtx->yw, mtx->zw, 0, 0, objBankIndex, type);
|
||||
|
||||
if (spawnedEnPart != NULL) {
|
||||
Matrix_MtxFToYXZRotS(&bodyBreak->matrices[bodyBreak->count], &spawnedEnPart->actor.shape.rot, 0);
|
||||
if (spawnedEnPart != NULL)
|
||||
{
|
||||
if (!isFlex)
|
||||
Matrix_MtxFToYXZRotS(&bodyBreak->matrices[bodyBreak->count], &spawnedEnPart->actor.shape.rot, 0);
|
||||
|
||||
spawnedEnPart->displayList = bodyBreak->dLists[bodyBreak->count];
|
||||
spawnedEnPart->actor.scale = actor->scale;
|
||||
}
|
||||
|
|
|
@ -601,13 +601,24 @@ void HealthMeter_Draw(PlayState* play) {
|
|||
|
||||
{
|
||||
Mtx* matrix = Graph_Alloc(gfxCtx, sizeof(Mtx));
|
||||
Matrix_SetTranslateScaleMtx2(matrix,
|
||||
HeartsScale+(HeartsScale/3) - ((HeartsScale/3) * sp144),
|
||||
HeartsScale+(HeartsScale/3) - ((HeartsScale/3) * sp144),
|
||||
HeartsScale+(HeartsScale/3) - ((HeartsScale/3) * sp144),
|
||||
-130+offsetX, //Pos X
|
||||
(-94+offsetY) *-1, //Pos Y
|
||||
0.0f);
|
||||
|
||||
if (CVarGetInteger("gNoHUDHeartAnimation", 0)) {
|
||||
Matrix_SetTranslateScaleMtx2(matrix,
|
||||
HeartsScale, // Scale X
|
||||
HeartsScale, // Scale Y
|
||||
HeartsScale, // Scale Z
|
||||
-130 + offsetX, // Pos X
|
||||
(-94 + offsetY) * -1, // Pos Y
|
||||
0.0f);
|
||||
} else {
|
||||
Matrix_SetTranslateScaleMtx2(matrix, HeartsScale + (HeartsScale / 3) - ((HeartsScale / 3) * sp144),
|
||||
HeartsScale + (HeartsScale / 3) - ((HeartsScale / 3) * sp144),
|
||||
HeartsScale + (HeartsScale / 3) - ((HeartsScale / 3) * sp144),
|
||||
-130 + offsetX, // Pos X
|
||||
(-94 + offsetY) * -1, // Pos Y
|
||||
0.0f);
|
||||
}
|
||||
|
||||
gSPMatrix(OVERLAY_DISP++, matrix, G_MTX_MODELVIEW | G_MTX_LOAD);
|
||||
gSPVertex(OVERLAY_DISP++, sp154, 4, 0);
|
||||
gSP1Quadrangle(OVERLAY_DISP++, 0, 2, 3, 1, 0);
|
||||
|
|
|
@ -144,6 +144,8 @@ void SkelAnime_DrawFlexLimbLod(PlayState* play, s32 limbIndex, void** skeleton,
|
|||
|
||||
newDList = limbDList = limb->dLists[lod];
|
||||
|
||||
play->flexLimbOverrideMTX = mtx;
|
||||
|
||||
if ((overrideLimbDraw == NULL) || !overrideLimbDraw(play, limbIndex, &newDList, &pos, &rot, arg)) {
|
||||
Matrix_TranslateRotateZYX(&pos, &rot);
|
||||
if (newDList != NULL) {
|
||||
|
@ -212,6 +214,8 @@ void SkelAnime_DrawFlexLod(PlayState* play, void** skeleton, Vec3s* jointTable,
|
|||
|
||||
newDList = limbDList = rootLimb->dLists[lod];
|
||||
|
||||
play->flexLimbOverrideMTX = &mtx;
|
||||
|
||||
if ((overrideLimbDraw == 0) || !overrideLimbDraw(play, 1, &newDList, &pos, &rot, arg)) {
|
||||
Matrix_TranslateRotateZYX(&pos, &rot);
|
||||
if (newDList != NULL) {
|
||||
|
@ -298,6 +302,20 @@ void SkelAnime_DrawSkeletonOpa(PlayState* play, SkelAnime* skelAnime, OverrideLi
|
|||
}
|
||||
}
|
||||
|
||||
Gfx* SkelAnime_DrawSkeleton2(PlayState* play, SkelAnime* skelAnime, OverrideLimbDrawOpa overrideLimbDraw,
|
||||
PostLimbDrawOpa postLimbDraw, void* arg, Gfx* gfx)
|
||||
{
|
||||
if (skelAnime->skeletonHeader->skeletonType == SKELANIME_TYPE_NORMAL) {
|
||||
return SkelAnime_Draw(play, skelAnime->skeleton, skelAnime->jointTable, overrideLimbDraw, postLimbDraw, arg, gfx);
|
||||
} else if (skelAnime->skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX) {
|
||||
FlexSkeletonHeader* flexHeader = (FlexSkeletonHeader*)skelAnime->skeletonHeader;
|
||||
return SkelAnime_DrawFlex(play, skelAnime->skeleton, skelAnime->jointTable, flexHeader->dListCount,
|
||||
overrideLimbDraw, postLimbDraw, arg, gfx);
|
||||
}
|
||||
|
||||
return gfx;
|
||||
}
|
||||
|
||||
/**
|
||||
* Draw all limbs of type `StandardLimb` in a given skeleton to the polyOpa buffer
|
||||
*/
|
||||
|
@ -375,6 +393,8 @@ void SkelAnime_DrawFlexLimbOpa(PlayState* play, s32 limbIndex, void** skeleton,
|
|||
|
||||
newDList = limbDList = limb->dList;
|
||||
|
||||
play->flexLimbOverrideMTX = limbMatricies;
|
||||
|
||||
if ((overrideLimbDraw == NULL) || !overrideLimbDraw(play, limbIndex, &newDList, &pos, &rot, arg)) {
|
||||
Matrix_TranslateRotateZYX(&pos, &rot);
|
||||
if (newDList != NULL) {
|
||||
|
|
|
@ -1276,6 +1276,9 @@ s32 BossDodongo_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Ve
|
|||
f32 mtxScaleY;
|
||||
f32 mtxScaleZ;
|
||||
BossDodongo* this = (BossDodongo*)thisx;
|
||||
|
||||
|
||||
|
||||
|
||||
// required for matching
|
||||
if ((limbIndex == 6) || (limbIndex == 7)) {
|
||||
|
@ -1288,6 +1291,10 @@ block_1:
|
|||
if (*dList != NULL) {
|
||||
OPEN_DISPS(play->state.gfxCtx);
|
||||
|
||||
if (this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
MATRIX_TOMTX(*play->flexLimbOverrideMTX);
|
||||
|
||||
|
||||
mtxScaleZ = 1.0f;
|
||||
mtxScaleY = 1.0f;
|
||||
|
||||
|
@ -1308,12 +1315,21 @@ block_1:
|
|||
Matrix_RotateX(-(this->unk_25C[limbIndex] * 0.115f), MTXMODE_APPLY);
|
||||
}
|
||||
|
||||
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
if (this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
gSPMatrix(POLY_OPA_DISP++, *play->flexLimbOverrideMTX, G_MTX_LOAD);
|
||||
else
|
||||
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(POLY_OPA_DISP++, *dList);
|
||||
Matrix_Pop();
|
||||
|
||||
if (this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
(*play->flexLimbOverrideMTX)++;
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
||||
|
||||
}
|
||||
{ s32 pad; } // Required to match
|
||||
return 1;
|
||||
|
|
|
@ -2014,13 +2014,25 @@ s32 BossGoma_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f
|
|||
|
||||
Matrix_TranslateRotateZYX(pos, rot);
|
||||
|
||||
if (*dList != NULL) {
|
||||
if (*dList != NULL)
|
||||
{
|
||||
if (this->skelanime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
MATRIX_TOMTX(*play->flexLimbOverrideMTX);
|
||||
|
||||
|
||||
Matrix_Push();
|
||||
Matrix_Scale(this->eyeIrisScaleX, this->eyeIrisScaleY, 1.0f, MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
if (this->skelanime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
gSPMatrix(POLY_OPA_DISP++, *play->flexLimbOverrideMTX, G_MTX_LOAD);
|
||||
else
|
||||
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(POLY_OPA_DISP++, *dList);
|
||||
Matrix_Pop();
|
||||
|
||||
if (this->skelanime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)
|
||||
(*play->flexLimbOverrideMTX)++;
|
||||
}
|
||||
|
||||
doNotDrawLimb = true;
|
||||
|
@ -2033,15 +2045,24 @@ s32 BossGoma_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f
|
|||
case BOSSGOMA_LIMB_TAIL1:
|
||||
Matrix_TranslateRotateZYX(pos, rot);
|
||||
|
||||
if (*dList != NULL) {
|
||||
if (*dList != NULL)
|
||||
{
|
||||
MATRIX_TOMTX(*play->flexLimbOverrideMTX);
|
||||
|
||||
Matrix_Push();
|
||||
Matrix_Scale(this->tailLimbsScale[limbIndex - BOSSGOMA_LIMB_TAIL4],
|
||||
this->tailLimbsScale[limbIndex - BOSSGOMA_LIMB_TAIL4],
|
||||
this->tailLimbsScale[limbIndex - BOSSGOMA_LIMB_TAIL4], MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
//gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
|
||||
//G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPMatrix(POLY_OPA_DISP++, *play->flexLimbOverrideMTX, G_MTX_LOAD);
|
||||
|
||||
gSPDisplayList(POLY_OPA_DISP++, *dList);
|
||||
Matrix_Pop();
|
||||
|
||||
(*play->flexLimbOverrideMTX)++;
|
||||
}
|
||||
|
||||
doNotDrawLimb = true;
|
||||
|
|
|
@ -1055,7 +1055,7 @@ void DoorWarp1_DrawBlueCrystal(DoorWarp1* this, PlayState* play) {
|
|||
gDPSetPrimColor(POLY_XLU_DISP++, 0xFF, 0xFF, 200, 255, 255, (u8)this->crystalAlpha);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, (u8)this->crystalAlpha);
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime, NULL, NULL,
|
||||
&this->actor, POLY_XLU_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
@ -1079,7 +1079,7 @@ void DoorWarp1_DrawPurpleCrystal(DoorWarp1* this, PlayState* play) {
|
|||
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (u8)this->crystalAlpha);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 150, 0, 100, (u8)this->crystalAlpha);
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime, NULL, NULL,
|
||||
&this->actor, POLY_XLU_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
|
@ -491,7 +491,8 @@ void EnBb_Death(EnBb* this, PlayState* play) {
|
|||
enpartType = 11;
|
||||
}
|
||||
|
||||
if (!BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, enpartType)) {
|
||||
if (!BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, enpartType,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
return;
|
||||
}
|
||||
Item_DropCollectibleRandom(play, &this->actor, &this->actor.world.pos, 0xD0);
|
||||
|
|
|
@ -768,7 +768,7 @@ void EnBili_Draw(Actor* thisx, PlayState* play) {
|
|||
gSPSegment(POLY_XLU_DISP++, 0x09, D_809C1700);
|
||||
}
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnBili_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
}
|
||||
|
|
|
@ -947,7 +947,7 @@ void EnBox_Draw(Actor* thisx, PlayState* play) {
|
|||
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, EnBox_EmptyDList(play->state.gfxCtx));
|
||||
Gfx_SetupDL_25Opa(play->state.gfxCtx);
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable, NULL,
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelanime, NULL,
|
||||
EnBox_PostLimbDraw, this, POLY_OPA_DISP);
|
||||
} else if (this->alpha != 0) {
|
||||
gDPPipeSync(POLY_XLU_DISP++);
|
||||
|
@ -958,7 +958,7 @@ void EnBox_Draw(Actor* thisx, PlayState* play) {
|
|||
} else {
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, func_809CA4A0(play->state.gfxCtx));
|
||||
}
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable, NULL,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelanime, NULL,
|
||||
EnBox_PostLimbDraw, this, POLY_XLU_DISP);
|
||||
}
|
||||
|
||||
|
|
|
@ -856,7 +856,7 @@ void EnBw_Draw(Actor* thisx, PlayState* play2) {
|
|||
Gfx_SetupDL_25Opa(play->state.gfxCtx);
|
||||
gDPSetEnvColor(POLY_OPA_DISP++, this->color1.r, this->color1.g, this->color1.b, this->color1.a);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]);
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnBw_OverrideLimbDraw, NULL, this, POLY_OPA_DISP);
|
||||
} else {
|
||||
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
|
||||
|
@ -864,7 +864,7 @@ void EnBw_Draw(Actor* thisx, PlayState* play2) {
|
|||
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 0, 0, 0, this->color1.a);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, this->color1.r, this->color1.g, this->color1.b, this->color1.a);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, &D_80116280[0]);
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnBw_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
|
||||
}
|
||||
|
||||
|
|
|
@ -708,14 +708,14 @@ void EnEiyer_Draw(Actor* thisx, PlayState* play) {
|
|||
gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]);
|
||||
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255);
|
||||
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable,
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelanime,
|
||||
EnEiyer_OverrideLimbDraw, NULL, this, POLY_OPA_DISP);
|
||||
} else {
|
||||
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, D_80116280);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->actor.shape.shadowAlpha);
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelanime,
|
||||
EnEiyer_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
|
||||
}
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
|
@ -1540,7 +1540,7 @@ void EnElf_Draw(Actor* thisx, PlayState* play) {
|
|||
gSPEndDisplayList(dListHead++);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, (u8)this->outerColor.r, (u8)this->outerColor.g, (u8)this->outerColor.b,
|
||||
(u8)(envAlpha * alphaScale));
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnElf_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
|
@ -837,8 +837,9 @@ void EnFirefly_Draw(Actor* thisx, PlayState* play) {
|
|||
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
|
||||
}
|
||||
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
EnFirefly_OverrideLimbDraw, EnFirefly_PostLimbDraw, &this->actor, POLY_OPA_DISP);
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime, EnFirefly_OverrideLimbDraw, EnFirefly_PostLimbDraw,
|
||||
&this->actor, POLY_OPA_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
}
|
||||
|
||||
|
@ -854,7 +855,7 @@ void EnFirefly_DrawInvisible(Actor* thisx, PlayState* play) {
|
|||
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 255);
|
||||
}
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnFirefly_OverrideLimbDraw, EnFirefly_PostLimbDraw, this, POLY_XLU_DISP);
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
}
|
||||
|
|
|
@ -617,7 +617,8 @@ void func_80A75790(EnIk* this) {
|
|||
|
||||
void func_80A758B0(EnIk* this, PlayState* play) {
|
||||
Math_SmoothStepToF(&this->actor.speedXZ, 0.0f, 1.0f, 1.0f, 0.0f);
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 4)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 4,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
this->bodyBreak.val = BODYBREAK_STATUS_FINISHED;
|
||||
}
|
||||
if (SkelAnime_Update(&this->skelAnime)) {
|
||||
|
|
|
@ -858,7 +858,7 @@ void EnPartner_Draw(Actor* thisx, PlayState* play) {
|
|||
gSPEndDisplayList(dListHead++);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, (u8)this->outerColor.r, (u8)this->outerColor.g, (u8)this->outerColor.b,
|
||||
(u8)(envAlpha * alphaScale));
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPartner_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
|
@ -267,7 +267,7 @@ void EnPoDesert_Draw(Actor* thisx, PlayState* play) {
|
|||
} else {
|
||||
gSPSegment(POLY_XLU_DISP++, 0x0C, D_80116280 + 2);
|
||||
}
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoDesert_OverrideLimbDraw, EnPoDesert_PostLimbDraw, &this->actor, POLY_XLU_DISP);
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
}
|
||||
|
|
|
@ -944,15 +944,14 @@ void EnPoField_Draw(Actor* thisx, PlayState* play) {
|
|||
this->lightColor.a));
|
||||
gSPSegment(POLY_OPA_DISP++, 0x0C, D_80116280 + 2);
|
||||
POLY_OPA_DISP =
|
||||
SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoField_OverrideLimbDraw2, EnPoField_PostLimDraw2, &this->actor, POLY_OPA_DISP);
|
||||
} else {
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08,
|
||||
Gfx_EnvColor(play->state.gfxCtx, this->lightColor.r, this->lightColor.g, this->lightColor.b,
|
||||
this->lightColor.a));
|
||||
gSPSegment(POLY_XLU_DISP++, 0x0C, D_80116280);
|
||||
POLY_XLU_DISP =
|
||||
SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoField_OverrideLimbDraw2, EnPoField_PostLimDraw2, &this->actor, POLY_XLU_DISP);
|
||||
}
|
||||
gDPPipeSync(POLY_OPA_DISP++);
|
||||
|
|
|
@ -1373,14 +1373,12 @@ void EnPoSisters_Draw(Actor* thisx, PlayState* play) {
|
|||
if (this->unk_22E.a == 255 || this->unk_22E.a == 0) {
|
||||
gDPSetEnvColor(POLY_OPA_DISP++, this->unk_22E.r, this->unk_22E.g, this->unk_22E.b, this->unk_22E.a);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x09, D_80116280 + 2);
|
||||
POLY_OPA_DISP =
|
||||
SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
EnPoSisters_OverrideLimbDraw, EnPoSisters_PostLimbDraw, &this->actor, POLY_OPA_DISP);
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime, EnPoSisters_OverrideLimbDraw,
|
||||
EnPoSisters_PostLimbDraw, &this->actor, POLY_OPA_DISP);
|
||||
} else {
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->unk_22E.a);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x09, D_80116280);
|
||||
POLY_XLU_DISP =
|
||||
SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoSisters_OverrideLimbDraw, EnPoSisters_PostLimbDraw, &this->actor, POLY_XLU_DISP);
|
||||
}
|
||||
if (!(this->unk_199 & 0x80)) {
|
||||
|
|
|
@ -1085,12 +1085,12 @@ void EnPoh_DrawRegular(Actor* thisx, PlayState* play) {
|
|||
if (this->lightColor.a == 255 || this->lightColor.a == 0) {
|
||||
gDPSetEnvColor(POLY_OPA_DISP++, this->lightColor.r, this->lightColor.g, this->lightColor.b, this->lightColor.a);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, D_80116280 + 2);
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoh_OverrideLimbDraw, EnPoh_PostLimbDraw, &this->actor, POLY_OPA_DISP);
|
||||
} else {
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->lightColor.a);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, D_80116280);
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnPoh_OverrideLimbDraw, EnPoh_PostLimbDraw, &this->actor, POLY_XLU_DISP);
|
||||
}
|
||||
gDPPipeSync(POLY_OPA_DISP++);
|
||||
|
|
|
@ -451,7 +451,8 @@ void EnSb_Update(Actor* thisx, PlayState* play) {
|
|||
} else {
|
||||
this->actor.params = 1;
|
||||
}
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
if (!this->hitByWindArrow) {
|
||||
Item_DropCollectibleRandom(play, &this->actor, &this->actor.world.pos, 0x80);
|
||||
} else {
|
||||
|
|
|
@ -384,7 +384,9 @@ void func_80AFD6CC(EnSkb* this, PlayState* play) {
|
|||
u8* new_var;
|
||||
|
||||
new_var = &this->unk_283;
|
||||
if ((this->unk_283 != 1) || BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, 1)) {
|
||||
if ((this->unk_283 != 1) ||
|
||||
BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, 1,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
if ((*new_var) != 0) {
|
||||
this->unk_283 = (*new_var) | 2;
|
||||
}
|
||||
|
@ -421,7 +423,8 @@ void func_80AFD7B4(EnSkb* this, PlayState* play) {
|
|||
}
|
||||
|
||||
void func_80AFD880(EnSkb* this, PlayState* play) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, 1)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, 1,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
if (this->actor.scale.x == 0.01f) {
|
||||
Item_DropCollectibleRandom(play, &this->actor, &this->actor.world.pos, 0x10);
|
||||
} else if (this->actor.scale.x <= 0.015f) {
|
||||
|
|
|
@ -1504,7 +1504,8 @@ void func_80862E6C(EnTest* this, PlayState* play) {
|
|||
this->actor.home.rot.x = this->bodyBreak.count;
|
||||
}
|
||||
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 8)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 8,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
this->actor.child = &this->actor;
|
||||
}
|
||||
} else {
|
||||
|
@ -1630,7 +1631,8 @@ void EnTest_Rise(EnTest* this, PlayState* play) {
|
|||
void func_808633E8(EnTest* this, PlayState* play) {
|
||||
this->actor.params = STALFOS_TYPE_1;
|
||||
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
Item_DropCollectibleRandom(play, &this->actor, &this->actor.world.pos, 0xD0);
|
||||
|
||||
if (this->actor.parent != NULL) {
|
||||
|
|
|
@ -764,7 +764,8 @@ void EnTite_DeathCry(EnTite* this, PlayState* play) {
|
|||
* Spawn EnPart and drop items
|
||||
*/
|
||||
void EnTite_FallApart(EnTite* this, PlayState* play) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 0xB)) {
|
||||
if (BodyBreak_SpawnParts(&this->actor, &this->bodyBreak, play, this->actor.params + 0xB,
|
||||
this->skelAnime.skeletonHeader->skeletonType == SKELANIME_TYPE_FLEX)) {
|
||||
if (this->actor.params == TEKTITE_BLUE) {
|
||||
Item_DropCollectibleRandom(play, &this->actor, &this->actor.world.pos, 0xE0);
|
||||
} else {
|
||||
|
|
|
@ -814,7 +814,7 @@ void EnVali_Draw(Actor* thisx, PlayState* play) {
|
|||
|
||||
EnVali_DrawBody(this, play);
|
||||
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnVali_OverrideLimbDraw, EnVali_PostLimbDraw, this, POLY_XLU_DISP);
|
||||
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
|
@ -624,6 +624,8 @@ void EnWeiyer_Update(Actor* thisx, PlayState* play) {
|
|||
|
||||
s32 EnWeiyer_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
|
||||
Gfx** gfx) {
|
||||
return 0;
|
||||
|
||||
if (limbIndex == 1) {
|
||||
pos->z += 2000.0f;
|
||||
}
|
||||
|
@ -640,13 +642,13 @@ void EnWeiyer_Draw(Actor* thisx, PlayState* play) {
|
|||
Gfx_SetupDL_25Opa(play->state.gfxCtx);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]);
|
||||
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255);
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
EnWeiyer_OverrideLimbDraw, NULL, &this->actor, POLY_OPA_DISP);
|
||||
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime, EnWeiyer_OverrideLimbDraw, NULL, &this->actor, POLY_OPA_DISP);
|
||||
} else {
|
||||
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, &D_80116280[0]);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->actor.shape.shadowAlpha);
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnWeiyer_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
|
||||
}
|
||||
|
||||
|
|
|
@ -2252,7 +2252,7 @@ void EnZf_Draw(Actor* thisx, PlayState* play) {
|
|||
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->alpha);
|
||||
gSPSegment(POLY_OPA_DISP++, 0x09, &D_80116280[2]);
|
||||
|
||||
POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_OPA_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnZf_OverrideLimbDraw, EnZf_PostLimbDraw, this, POLY_OPA_DISP);
|
||||
|
||||
if (this->iceTimer != 0) {
|
||||
|
@ -2271,7 +2271,7 @@ void EnZf_Draw(Actor* thisx, PlayState* play) {
|
|||
gDPPipeSync(POLY_XLU_DISP++);
|
||||
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha);
|
||||
gSPSegment(POLY_XLU_DISP++, 0x09, &D_80116280[0]);
|
||||
POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable,
|
||||
POLY_XLU_DISP = SkelAnime_DrawSkeleton2(play, &this->skelAnime,
|
||||
EnZf_OverrideLimbDraw, EnZf_PostLimbDraw, this, POLY_XLU_DISP);
|
||||
}
|
||||
CLOSE_DISPS(play->state.gfxCtx);
|
||||
|
|
Loading…
Reference in New Issue