mirror of
https://github.com/zeldaret/oot.git
synced 2024-12-04 08:46:07 +00:00
rename eyeIdx
-> eyeTexIndex
Mido has two eyes and different textures for them
This commit is contained in:
parent
91732239da
commit
0a6c724857
2 changed files with 6 additions and 6 deletions
|
@ -544,10 +544,10 @@ u8 EnMd_ShouldSpawn(EnMd* this, PlayState* play) {
|
|||
|
||||
void EnMd_UpdateEyes(EnMd* this) {
|
||||
if (DECR(this->blinkTimer) == 0) {
|
||||
this->eyeIdx++;
|
||||
if (this->eyeIdx > ENMD_EYE_CLOSED) {
|
||||
this->eyeTexIndex++;
|
||||
if (this->eyeTexIndex > ENMD_EYE_CLOSED) {
|
||||
this->blinkTimer = Rand_S16Offset(30, 30);
|
||||
this->eyeIdx = ENMD_EYE_OPEN;
|
||||
this->eyeTexIndex = ENMD_EYE_OPEN;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -897,10 +897,10 @@ void EnMd_Draw(Actor* thisx, PlayState* play) {
|
|||
OPEN_DISPS(play->state.gfxCtx, "../z_en_md.c", 1280);
|
||||
|
||||
if (this->alpha == 255) {
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIdx]));
|
||||
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeTexIndex]));
|
||||
func_80034BA0(play, &this->skelAnime, EnMd_OverrideLimbDraw, EnMd_PostLimbDraw, &this->actor, this->alpha);
|
||||
} else if (this->alpha != 0) {
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIdx]));
|
||||
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeTexIndex]));
|
||||
func_80034CC4(play, &this->skelAnime, EnMd_OverrideLimbDraw, EnMd_PostLimbDraw, &this->actor, this->alpha);
|
||||
}
|
||||
|
||||
|
|
|
@ -49,7 +49,7 @@ typedef struct EnMd {
|
|||
/* 0x020A */ u8 animEntry; // each one changes animation info and waits
|
||||
/* 0x020B */ u8 animState; // defines a sequence of animation entries
|
||||
/* 0x020C */ s16 blinkTimer;
|
||||
/* 0x020E */ s16 eyeIdx;
|
||||
/* 0x020E */ s16 eyeTexIndex;
|
||||
/* 0x0210 */ s16 alpha;
|
||||
/* 0x0212 */ s16 waypoint;
|
||||
/* 0x0214 */ s16 unk_214[ENMD_LIMB_MAX];
|
||||
|
|
Loading…
Reference in a new issue