mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-23 13:59:40 +00:00
z_actor
documentation pass (#1445)
* Actor_Offer* and Actor_SetClosestSecretDistance * color filter stuff * KillAll * format * comment * Update src/code/z_actor.c Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * review Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * format * COLORFILTER_INTENSITY_FLAG * Remove - Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * yeet COLORFILTER_GET_XLUFLAG * bug * frug * Undo Actor_KillAllFromUnloadedRooms * update Actor_OfferGetItem comment * Update Actor_OfferGetItem description * diving Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
This commit is contained in:
parent
83163f4d4b
commit
c420885513
@ -414,12 +414,12 @@ u32 Actor_TextboxIsClosing(Actor* actor, PlayState* play);
|
||||
s8 func_8002F368(PlayState* play);
|
||||
void Actor_GetScreenPos(PlayState* play, Actor* actor, s16* x, s16* y);
|
||||
u32 Actor_HasParent(Actor* actor, PlayState* play);
|
||||
s32 func_8002F434(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange, f32 yRange);
|
||||
void func_8002F554(Actor* actor, PlayState* play, s32 getItemId);
|
||||
void func_8002F580(Actor* actor, PlayState* play);
|
||||
s32 Actor_OfferGetItem(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange, f32 yRange);
|
||||
s32 Actor_OfferGetItemNearby(Actor* actor, PlayState* play, s32 getItemId);
|
||||
s32 Actor_OfferCarry(Actor* actor, PlayState* play);
|
||||
u32 Actor_HasNoParent(Actor* actor, PlayState* play);
|
||||
void func_8002F5C4(Actor* actorA, Actor* actorB, PlayState* play);
|
||||
void func_8002F5F0(Actor* actor, PlayState* play);
|
||||
void Actor_SetClosestSecretDistance(Actor* actor, PlayState* play);
|
||||
s32 Actor_IsMounted(PlayState* play, Actor* horse);
|
||||
u32 Actor_SetRideActor(PlayState* play, Actor* horse, s32 mountSide);
|
||||
s32 Actor_NotMounted(PlayState* play, Actor* horse);
|
||||
@ -442,7 +442,7 @@ void Actor_InitContext(PlayState* play, ActorContext* actorCtx, ActorEntry* play
|
||||
void Actor_UpdateAll(PlayState* play, ActorContext* actorCtx);
|
||||
s32 func_800314D4(PlayState* play, Actor* actor, Vec3f* arg2, f32 arg3);
|
||||
void func_800315AC(PlayState* play, ActorContext* actorCtx);
|
||||
void func_80031A28(PlayState* play, ActorContext* actorCtx);
|
||||
void Actor_KillAllWithMissingObject(PlayState* play, ActorContext* actorCtx);
|
||||
void func_80031B14(PlayState* play, ActorContext* actorCtx);
|
||||
void func_80031C3C(ActorContext* actorCtx, PlayState* play);
|
||||
Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 posX, f32 posY, f32 posZ,
|
||||
@ -481,7 +481,7 @@ f32 Rand_ZeroFloat(f32 f);
|
||||
f32 Rand_CenteredFloat(f32 f);
|
||||
void Actor_DrawDoorLock(PlayState* play, s32 frame, s32 type);
|
||||
void func_8003424C(PlayState* play, Vec3f* arg1);
|
||||
void Actor_SetColorFilter(Actor* actor, s16 colorFlag, s16 colorIntensityMax, s16 xluFlag, s16 duration);
|
||||
void Actor_SetColorFilter(Actor* actor, s16 colorFlag, s16 colorIntensityMax, s16 bufFlag, s16 duration);
|
||||
Hilite* func_800342EC(Vec3f* object, PlayState* play);
|
||||
Hilite* func_8003435C(Vec3f* object, PlayState* play);
|
||||
s32 Npc_UpdateTalking(PlayState* play, Actor* actor, s16* talkState, f32 interactRange,
|
||||
|
@ -169,6 +169,18 @@ typedef struct {
|
||||
#define ACTOR_FLAG_27 (1 << 27)
|
||||
#define ACTOR_FLAG_28 (1 << 28)
|
||||
|
||||
#define COLORFILTER_GET_COLORINTENSITY(colorFilterParams) (((colorFilterParams) & 0x1F00) >> 5)
|
||||
#define COLORFILTER_GET_DURATION(colorFilterParams) ((colorFilterParams) & 0xFF)
|
||||
|
||||
#define COLORFILTER_COLORFLAG_GRAY 0x8000
|
||||
#define COLORFILTER_COLORFLAG_RED 0x4000
|
||||
#define COLORFILTER_COLORFLAG_BLUE 0x0000
|
||||
|
||||
#define COLORFILTER_INTENSITY_FLAG 0x8000
|
||||
|
||||
#define COLORFILTER_BUFFLAG_XLU 0x2000
|
||||
#define COLORFILTER_BUFFLAG_OPA 0x0000
|
||||
|
||||
#define BGCHECKFLAG_GROUND (1 << 0) // Standing on the ground
|
||||
#define BGCHECKFLAG_GROUND_TOUCH (1 << 1) // Has touched the ground (only active for 1 frame)
|
||||
#define BGCHECKFLAG_GROUND_LEAVE (1 << 2) // Has left the ground (only active for 1 frame)
|
||||
|
@ -556,7 +556,7 @@ typedef struct Player {
|
||||
/* 0x0698 */ f32 targetActorDistance;
|
||||
/* 0x069C */ char unk_69C[0x004];
|
||||
/* 0x06A0 */ f32 unk_6A0;
|
||||
/* 0x06A4 */ f32 unk_6A4;
|
||||
/* 0x06A4 */ f32 closestSecretDistSq;
|
||||
/* 0x06A8 */ Actor* unk_6A8;
|
||||
/* 0x06AC */ s8 unk_6AC;
|
||||
/* 0x06AD */ u8 unk_6AD;
|
||||
|
@ -1570,7 +1570,30 @@ u32 Actor_HasParent(Actor* actor, PlayState* play) {
|
||||
}
|
||||
}
|
||||
|
||||
s32 func_8002F434(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange, f32 yRange) {
|
||||
/**
|
||||
* This function covers various interactions with the player actor, using Get Item IDs (see `GetItemID` enum).
|
||||
* It is typically used to give items to the player, but also has other purposes.
|
||||
*
|
||||
* This function carries a get item request to the player actor if context allows it (e.g. the player is in range and
|
||||
* not busy with certain things). The player actor performs the requested action itself.
|
||||
*
|
||||
* The following description of what the `getItemId` values can do is provided here for completeness, but these
|
||||
* behaviors are entirely out of the scope of this function. All behavior is defined by the player actor.
|
||||
*
|
||||
* - Positive values (`GI_NONE < getItemId < GI_MAX`):
|
||||
* Give an item to the player. The player may not get it immediately (for example if diving), but is expected to
|
||||
* in the near future.
|
||||
* - Negative values (`-GI_MAX < getItemId < GI_NONE`):
|
||||
* Used by treasure chests to indicate the chest can be opened (by pressing A).
|
||||
* The item gotten corresponds to the positive Get Item ID `abs(getItemId)`.
|
||||
* - `GI_NONE`:
|
||||
* Allows the player to pick up the actor (by pressing A), to carry it around.
|
||||
* - `GI_MAX`:
|
||||
* Allows the player to catch specific actors in a bottle.
|
||||
*
|
||||
* @return true If the player actor is capable of accepting the offer.
|
||||
*/
|
||||
s32 Actor_OfferGetItem(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange, f32 yRange) {
|
||||
Player* player = GET_PLAYER(play);
|
||||
|
||||
if (!(player->stateFlags1 & (PLAYER_STATE1_7 | PLAYER_STATE1_12 | PLAYER_STATE1_13 | PLAYER_STATE1_14 |
|
||||
@ -1596,12 +1619,12 @@ s32 func_8002F434(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange, f32
|
||||
return false;
|
||||
}
|
||||
|
||||
void func_8002F554(Actor* actor, PlayState* play, s32 getItemId) {
|
||||
func_8002F434(actor, play, getItemId, 50.0f, 10.0f);
|
||||
s32 Actor_OfferGetItemNearby(Actor* actor, PlayState* play, s32 getItemId) {
|
||||
return Actor_OfferGetItem(actor, play, getItemId, 50.0f, 10.0f);
|
||||
}
|
||||
|
||||
void func_8002F580(Actor* actor, PlayState* play) {
|
||||
func_8002F554(actor, play, GI_NONE);
|
||||
s32 Actor_OfferCarry(Actor* actor, PlayState* play) {
|
||||
return Actor_OfferGetItemNearby(actor, play, GI_NONE);
|
||||
}
|
||||
|
||||
u32 Actor_HasNoParent(Actor* actor, PlayState* play) {
|
||||
@ -1627,11 +1650,11 @@ void func_8002F5C4(Actor* actorA, Actor* actorB, PlayState* play) {
|
||||
actorA->parent = NULL;
|
||||
}
|
||||
|
||||
void func_8002F5F0(Actor* actor, PlayState* play) {
|
||||
void Actor_SetClosestSecretDistance(Actor* actor, PlayState* play) {
|
||||
Player* player = GET_PLAYER(play);
|
||||
|
||||
if (actor->xyzDistToPlayerSq < player->unk_6A4) {
|
||||
player->unk_6A4 = actor->xyzDistToPlayerSq;
|
||||
if (actor->xyzDistToPlayerSq < player->closestSecretDistSq) {
|
||||
player->closestSecretDistSq = actor->xyzDistToPlayerSq;
|
||||
}
|
||||
}
|
||||
|
||||
@ -2218,25 +2241,25 @@ void Actor_Draw(PlayState* play, Actor* actor) {
|
||||
if (actor->colorFilterTimer != 0) {
|
||||
Color_RGBA8 color = { 0, 0, 0, 255 };
|
||||
|
||||
if (actor->colorFilterParams & 0x8000) {
|
||||
color.r = color.g = color.b = ((actor->colorFilterParams & 0x1F00) >> 5) | 7;
|
||||
} else if (actor->colorFilterParams & 0x4000) {
|
||||
color.r = ((actor->colorFilterParams & 0x1F00) >> 5) | 7;
|
||||
if (actor->colorFilterParams & COLORFILTER_COLORFLAG_GRAY) {
|
||||
color.r = color.g = color.b = COLORFILTER_GET_COLORINTENSITY(actor->colorFilterParams) | 7;
|
||||
} else if (actor->colorFilterParams & COLORFILTER_COLORFLAG_RED) {
|
||||
color.r = COLORFILTER_GET_COLORINTENSITY(actor->colorFilterParams) | 7;
|
||||
} else {
|
||||
color.b = ((actor->colorFilterParams & 0x1F00) >> 5) | 7;
|
||||
color.b = COLORFILTER_GET_COLORINTENSITY(actor->colorFilterParams) | 7;
|
||||
}
|
||||
|
||||
if (actor->colorFilterParams & 0x2000) {
|
||||
func_80026860(play, &color, actor->colorFilterTimer, actor->colorFilterParams & 0xFF);
|
||||
if (actor->colorFilterParams & COLORFILTER_BUFFLAG_XLU) {
|
||||
func_80026860(play, &color, actor->colorFilterTimer, COLORFILTER_GET_DURATION(actor->colorFilterParams));
|
||||
} else {
|
||||
func_80026400(play, &color, actor->colorFilterTimer, actor->colorFilterParams & 0xFF);
|
||||
func_80026400(play, &color, actor->colorFilterTimer, COLORFILTER_GET_DURATION(actor->colorFilterParams));
|
||||
}
|
||||
}
|
||||
|
||||
actor->draw(actor, play);
|
||||
|
||||
if (actor->colorFilterTimer != 0) {
|
||||
if (actor->colorFilterParams & 0x2000) {
|
||||
if (actor->colorFilterParams & COLORFILTER_BUFFLAG_XLU) {
|
||||
func_80026A6C(play);
|
||||
} else {
|
||||
func_80026608(play);
|
||||
@ -2500,7 +2523,10 @@ void func_800315AC(PlayState* play, ActorContext* actorCtx) {
|
||||
CLOSE_DISPS(play->state.gfxCtx, "../z_actor.c", 6563);
|
||||
}
|
||||
|
||||
void func_80031A28(PlayState* play, ActorContext* actorCtx) {
|
||||
/**
|
||||
* Kill every actor which depends on an object that is not loaded.
|
||||
*/
|
||||
void Actor_KillAllWithMissingObject(PlayState* play, ActorContext* actorCtx) {
|
||||
Actor* actor;
|
||||
s32 i;
|
||||
|
||||
@ -2530,6 +2556,9 @@ void Actor_FreezeAllEnemies(PlayState* play, ActorContext* actorCtx, s32 duratio
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Kill actors on room change and update flags accordingly
|
||||
*/
|
||||
void func_80031B14(PlayState* play, ActorContext* actorCtx) {
|
||||
Actor* actor;
|
||||
s32 i;
|
||||
@ -3633,12 +3662,12 @@ void func_8003424C(PlayState* play, Vec3f* arg1) {
|
||||
CollisionCheck_SpawnShieldParticlesMetal(play, arg1);
|
||||
}
|
||||
|
||||
void Actor_SetColorFilter(Actor* actor, s16 colorFlag, s16 colorIntensityMax, s16 xluFlag, s16 duration) {
|
||||
if ((colorFlag == 0x8000) && !(colorIntensityMax & 0x8000)) {
|
||||
void Actor_SetColorFilter(Actor* actor, s16 colorFlag, s16 colorIntensityMax, s16 bufFlag, s16 duration) {
|
||||
if ((colorFlag == COLORFILTER_COLORFLAG_GRAY) && !(colorIntensityMax & COLORFILTER_INTENSITY_FLAG)) {
|
||||
Audio_PlayActorSfx2(actor, NA_SE_EN_LIGHT_ARROW_HIT);
|
||||
}
|
||||
|
||||
actor->colorFilterParams = colorFlag | xluFlag | ((colorIntensityMax & 0xF8) << 5) | duration;
|
||||
actor->colorFilterParams = colorFlag | bufFlag | ((colorIntensityMax & 0xF8) << 5) | duration;
|
||||
actor->colorFilterTimer = duration;
|
||||
}
|
||||
|
||||
@ -4061,7 +4090,7 @@ s32 func_80035124(Actor* actor, PlayState* play) {
|
||||
ret = 1;
|
||||
} else {
|
||||
actor->shape.rot.x = actor->shape.rot.z = 0;
|
||||
func_8002F580(actor, play);
|
||||
Actor_OfferCarry(actor, play);
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
|
@ -351,7 +351,7 @@ void EnItem00_Init(Actor* thisx, PlayState* play) {
|
||||
}
|
||||
|
||||
if ((getItemId != GI_NONE) && !Actor_HasParent(&this->actor, play)) {
|
||||
func_8002F554(&this->actor, play, getItemId);
|
||||
Actor_OfferGetItemNearby(&this->actor, play, getItemId);
|
||||
}
|
||||
|
||||
EnItem00_SetupAction(this, EnItem00_Collected);
|
||||
@ -498,7 +498,7 @@ void EnItem00_Collected(EnItem00* this, PlayState* play) {
|
||||
|
||||
if (this->getItemId != GI_NONE) {
|
||||
if (!Actor_HasParent(&this->actor, play)) {
|
||||
func_8002F434(&this->actor, play, this->getItemId, 50.0f, 80.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 50.0f, 80.0f);
|
||||
this->despawnTimer++;
|
||||
} else {
|
||||
this->getItemId = GI_NONE;
|
||||
@ -696,7 +696,7 @@ void EnItem00_Update(Actor* thisx, PlayState* play) {
|
||||
params = &this->actor.params;
|
||||
|
||||
if ((getItemId != GI_NONE) && !Actor_HasParent(&this->actor, play)) {
|
||||
func_8002F554(&this->actor, play, getItemId);
|
||||
Actor_OfferGetItemNearby(&this->actor, play, getItemId);
|
||||
}
|
||||
|
||||
switch (*params) {
|
||||
|
@ -269,7 +269,7 @@ void Scene_CommandObjectList(PlayState* play, SceneCmd* cmd) {
|
||||
status2++;
|
||||
}
|
||||
play->objectCtx.num = i;
|
||||
func_80031A28(play, &play->actorCtx);
|
||||
Actor_KillAllWithMissingObject(play, &play->actorCtx);
|
||||
|
||||
continue;
|
||||
}
|
||||
|
@ -449,7 +449,7 @@ void BgPoEvent_AmyWait(BgPoEvent* this, PlayState* play) {
|
||||
if (this->collider.base.acFlags & AC_HIT) {
|
||||
sPuzzleState |= 0x20;
|
||||
this->timer = 5;
|
||||
Actor_SetColorFilter(&this->dyna.actor, 0x4000, 0xFF, 0, 5);
|
||||
Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 5);
|
||||
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EN_PO_LAUGH2);
|
||||
this->actionFunc = BgPoEvent_AmyPuzzle;
|
||||
}
|
||||
|
@ -114,7 +114,7 @@ void func_808BAF40(BgTokiSwd* this, PlayState* play) {
|
||||
BgTokiSwd_SetupAction(this, func_808BB0AC);
|
||||
} else {
|
||||
if (Actor_IsFacingPlayer(&this->actor, 0x2000)) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -814,7 +814,8 @@ void BossSst_HeadUnfreezeHand(BossSst* this, PlayState* play) {
|
||||
|
||||
void BossSst_HeadSetupStunned(BossSst* this) {
|
||||
Animation_MorphToPlayOnce(&this->skelAnime, &gBongoHeadKnockoutAnim, -5.0f);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, Animation_GetLastFrame(&gBongoHeadKnockoutAnim));
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gBongoHeadKnockoutAnim));
|
||||
this->colliderJntSph.base.atFlags &= ~(AT_ON | AT_HIT);
|
||||
this->colliderCyl.base.acFlags &= ~AC_ON;
|
||||
this->vVanish = false;
|
||||
@ -904,9 +905,12 @@ void BossSst_HeadVulnerable(BossSst* this, PlayState* play) {
|
||||
|
||||
void BossSst_HeadSetupDamage(BossSst* this) {
|
||||
Animation_MorphToPlayOnce(&this->skelAnime, &gBongoHeadDamageAnim, -3.0f);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
Actor_SetColorFilter(&sHands[LEFT]->actor, 0x4000, 0xFF, 0, Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
Actor_SetColorFilter(&sHands[RIGHT]->actor, 0x4000, 0xFF, 0, Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
Actor_SetColorFilter(&sHands[LEFT]->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
Actor_SetColorFilter(&sHands[RIGHT]->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gBongoHeadDamageAnim));
|
||||
this->colliderCyl.base.acFlags &= ~AC_ON;
|
||||
BossSst_HeadSfx(this, NA_SE_EN_SHADEST_DAMAGE);
|
||||
this->actionFunc = BossSst_HeadDamage;
|
||||
@ -1007,9 +1011,9 @@ void BossSst_HeadSetupDeath(BossSst* this, PlayState* play) {
|
||||
|
||||
Animation_MorphToLoop(&this->skelAnime, &gBongoHeadEyeOpenIdleAnim, -5.0f);
|
||||
BossSst_HeadSfx(this, NA_SE_EN_SHADEST_DEAD);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 60);
|
||||
Actor_SetColorFilter(&sHands[LEFT]->actor, 0x4000, 0xFF, 0, 60);
|
||||
Actor_SetColorFilter(&sHands[RIGHT]->actor, 0x4000, 0xFF, 0, 60);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 60);
|
||||
Actor_SetColorFilter(&sHands[LEFT]->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 60);
|
||||
Actor_SetColorFilter(&sHands[RIGHT]->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 60);
|
||||
this->timer = 60;
|
||||
this->colliderCyl.base.acFlags &= ~AC_ON;
|
||||
this->colliderJntSph.base.ocFlags1 &= ~OC1_ON;
|
||||
@ -1962,7 +1966,7 @@ void BossSst_HandSetupReel(BossSst* this) {
|
||||
Animation_MorphToPlayOnce(&this->skelAnime, sHandFlatPoses[this->actor.params], 4.0f);
|
||||
this->timer = 36;
|
||||
Math_Vec3f_Copy(&this->center, &this->actor.world.pos);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 200);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 200);
|
||||
this->actionFunc = BossSst_HandReel;
|
||||
}
|
||||
|
||||
@ -2086,7 +2090,8 @@ void BossSst_HandSetupStunned(BossSst* hand) {
|
||||
hand->colliderJntSph.base.atFlags &= ~(AT_ON | AT_HIT);
|
||||
hand->colliderJntSph.base.acFlags |= AC_ON;
|
||||
BossSst_HandSetInvulnerable(hand, true);
|
||||
Actor_SetColorFilter(&hand->actor, 0, 0xFF, 0, Animation_GetLastFrame(&gBongoHeadKnockoutAnim));
|
||||
Actor_SetColorFilter(&hand->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gBongoHeadKnockoutAnim));
|
||||
hand->actionFunc = BossSst_HandStunned;
|
||||
}
|
||||
|
||||
@ -2286,7 +2291,7 @@ void BossSst_HandSetupFrozen(BossSst* this) {
|
||||
}
|
||||
|
||||
BossSst_SpawnIceCrystal(this, 0);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0xA);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 10);
|
||||
this->handAngSpeed = 0;
|
||||
this->actionFunc = BossSst_HandFrozen;
|
||||
}
|
||||
|
@ -1075,7 +1075,7 @@ void BossVa_BodyPhase1(BossVa* this, PlayState* play) {
|
||||
|
||||
if (sBodyState & 0x7F) {
|
||||
this->skelAnime.curFrame = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_DAMAGE);
|
||||
}
|
||||
|
||||
@ -1126,7 +1126,7 @@ void BossVa_BodyPhase2(BossVa* this, PlayState* play) {
|
||||
if (this->actor.colorFilterTimer == 0) {
|
||||
sPhase2Timer++;
|
||||
if ((this->invincibilityTimer != 0) && (this->actor.colorFilterParams & 0x4000)) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 160);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 160);
|
||||
this->actor.colorFilterTimer = this->invincibilityTimer;
|
||||
} else {
|
||||
this->colliderBody.info.bumper.dmgFlags = DMG_BOOMERANG;
|
||||
@ -1138,7 +1138,7 @@ void BossVa_BodyPhase2(BossVa* this, PlayState* play) {
|
||||
|
||||
if (this->colliderBody.base.ac->id == ACTOR_EN_BOOM) {
|
||||
sPhase2Timer &= 0xFE00;
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 160);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 160);
|
||||
this->colliderBody.info.bumper.dmgFlags = DMG_SWORD | DMG_BOOMERANG | DMG_DEKU_STICK;
|
||||
} else {
|
||||
sKillBari++;
|
||||
@ -1149,7 +1149,7 @@ void BossVa_BodyPhase2(BossVa* this, PlayState* play) {
|
||||
}
|
||||
}
|
||||
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
}
|
||||
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_FAINT);
|
||||
@ -1243,7 +1243,7 @@ void BossVa_BodyPhase3(BossVa* this, PlayState* play) {
|
||||
|
||||
if (this->colliderBody.base.acFlags & AC_HIT) {
|
||||
this->skelAnime.curFrame = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_FAINT);
|
||||
sBodyState = 1;
|
||||
this->timer = 131;
|
||||
@ -1374,7 +1374,7 @@ void BossVa_BodyPhase4(BossVa* this, PlayState* play) {
|
||||
if (this->actor.colChkInfo.damageEffect != 1) {
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_DAMAGE);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
sPhase4HP -= this->actor.colChkInfo.damage;
|
||||
if (sPhase4HP <= 0) {
|
||||
this->timer = 0;
|
||||
@ -1392,7 +1392,7 @@ void BossVa_BodyPhase4(BossVa* this, PlayState* play) {
|
||||
this->timer = (s16)Rand_CenteredFloat(40.0f) + 160;
|
||||
this->vaBodySpinRate = 0;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 125, 0, 255);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 125, COLORFILTER_BUFFLAG_OPA, 255);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_FAINT);
|
||||
}
|
||||
}
|
||||
@ -1718,7 +1718,7 @@ void BossVa_SetupSupportAttached(BossVa* this, PlayState* play) {
|
||||
void BossVa_SupportAttached(BossVa* this, PlayState* play) {
|
||||
this->timer++;
|
||||
if (sBodyState & 0x7F) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
if (Rand_ZeroOne() > 0.5f) {
|
||||
Animation_Change(&this->skelAnime, &gBarinadeSupportDamage1Anim, 1.0f, 0.0f,
|
||||
Animation_GetLastFrame(&gBarinadeSupportDamage1Anim), ANIMMODE_ONCE, 0.0f);
|
||||
@ -2114,7 +2114,7 @@ void BossVa_SetupZapperDamaged(BossVa* this, PlayState* play) {
|
||||
Animation_GetLastFrame(&gBarinadeZapperDamage2Anim), ANIMMODE_ONCE_INTERP, 4.0f);
|
||||
}
|
||||
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
this->burst = false;
|
||||
BossVa_SetupAction(this, BossVa_ZapperDamaged);
|
||||
}
|
||||
@ -2687,7 +2687,8 @@ void BossVa_BariPhase2Attack(BossVa* this, PlayState* play) {
|
||||
} else {
|
||||
this->unk_1AC = 0;
|
||||
if (this->actor.colorFilterTimer == 0) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0x2000, GET_BODY(this)->actor.colorFilterTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU,
|
||||
GET_BODY(this)->actor.colorFilterTimer);
|
||||
}
|
||||
}
|
||||
|
||||
@ -2722,7 +2723,7 @@ void BossVa_BariPhase2Attack(BossVa* this, PlayState* play) {
|
||||
void BossVa_SetupBariPhase3Stunned(BossVa* this, PlayState* play) {
|
||||
this->actor.flags |= ACTOR_FLAG_0;
|
||||
this->timer = GET_BODY(this)->timer;
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0x2000, this->timer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU, this->timer);
|
||||
BossVa_SetupAction(this, BossVa_BariPhase3Stunned);
|
||||
}
|
||||
|
||||
|
@ -118,7 +118,7 @@ void DoorAna_WaitClosed(DoorAna* this, PlayState* play) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_CORRECT_CHIME, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
}
|
||||
func_8002F5F0(&this->actor, play);
|
||||
Actor_SetClosestSecretDistance(&this->actor, play);
|
||||
}
|
||||
|
||||
// update routine for grottos that are open
|
||||
|
@ -379,7 +379,7 @@ void EnAm_Sleep(EnAm* this, PlayState* play) {
|
||||
if (this->textureBlend == 0) {
|
||||
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EN_AMOS_WAVE);
|
||||
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EN_AMOS_VOICE);
|
||||
Actor_SetColorFilter(&this->dyna.actor, 0x4000, 255, 0, 8);
|
||||
Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
}
|
||||
|
||||
if (this->textureBlend >= 240) {
|
||||
@ -717,7 +717,7 @@ void EnAm_SetupStunned(EnAm* this, PlayState* play) {
|
||||
this->dyna.actor.speedXZ = -6.0f;
|
||||
}
|
||||
|
||||
Actor_SetColorFilter(&this->dyna.actor, 0, 120, 0, 100);
|
||||
Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 100);
|
||||
|
||||
if (this->damageEffect == AM_DMGEFF_ICE) {
|
||||
this->iceTimer = 48;
|
||||
@ -881,7 +881,7 @@ void EnAm_Update(Actor* thisx, PlayState* play) {
|
||||
}
|
||||
|
||||
if ((this->deathTimer % 4) == 0) {
|
||||
Actor_SetColorFilter(&this->dyna.actor, 0x4000, 255, 0, 4);
|
||||
Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 4);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -125,7 +125,7 @@ void func_809B0558(EnAni* this, PlayState* play) {
|
||||
}
|
||||
SET_ITEMGETINF(ITEMGETINF_15);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, 10000.0f, 200.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, 10000.0f, 200.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -133,7 +133,7 @@ void func_809B05F0(EnAni* this, PlayState* play) {
|
||||
if (Actor_TextboxIsClosing(&this->actor, play)) {
|
||||
EnAni_SetupAction(this, func_809B0558);
|
||||
}
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, 10000.0f, 200.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, 10000.0f, 200.0f);
|
||||
}
|
||||
|
||||
void func_809B064C(EnAni* this, PlayState* play) {
|
||||
|
@ -344,7 +344,7 @@ void EnAnubice_Die(EnAnubice* this, PlayState* play) {
|
||||
rotatedFireEffectPos.x += this->actor.world.pos.x + Rand_CenteredFloat(40.0f);
|
||||
rotatedFireEffectPos.y += this->actor.world.pos.y + Rand_CenteredFloat(40.0f);
|
||||
rotatedFireEffectPos.z += this->actor.world.pos.z + Rand_CenteredFloat(30.0f);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 128, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 128, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
EffectSsEnFire_SpawnVec3f(play, &this->actor, &rotatedFireEffectPos, 100, 0, 0, -1);
|
||||
|
||||
if ((this->animLastFrame <= curFrame) && (this->actor.bgCheckFlags & BGCHECKFLAG_GROUND)) {
|
||||
|
@ -325,7 +325,7 @@ void func_809B7174(EnBa* this) {
|
||||
this->actor.colChkInfo.mass = MASS_IMMOVABLE;
|
||||
this->actor.speedXZ = 10.0f;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BALINADE_HAND_DAMAGE);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 12);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
EnBa_SetupAction(this, EnBa_RecoilFromDamage);
|
||||
}
|
||||
|
||||
|
@ -516,7 +516,7 @@ void EnBb_SetupDamage(EnBb* this) {
|
||||
if (this->actor.params == ENBB_RED) {
|
||||
EnBb_KillFlameTrail(this);
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
this->timer = 5;
|
||||
EnBb_SetupAction(this, EnBb_Damage);
|
||||
}
|
||||
@ -1083,14 +1083,14 @@ void EnBb_SetupStunned(EnBb* this) {
|
||||
}
|
||||
switch (this->dmgEffect) {
|
||||
case 8:
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0xC8, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 200, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
break;
|
||||
case 9:
|
||||
this->fireIceTimer = 0x30;
|
||||
FALLTHROUGH;
|
||||
case 15:
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xB4, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 180, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
break;
|
||||
}
|
||||
this->actor.bgCheckFlags &= ~BGCHECKFLAG_GROUND;
|
||||
@ -1205,7 +1205,7 @@ void EnBb_CollisionCheck(EnBb* this, PlayState* play) {
|
||||
//! the bug in EnBb_Draw below to crash the game.
|
||||
} else if ((this->actor.params == ENBB_WHITE) &&
|
||||
((this->action == BB_WHITE) || (this->action == BB_STUNNED))) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
this->actor.speedXZ = -8.0f;
|
||||
this->maxSpeed = 0.0f;
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
|
@ -340,7 +340,7 @@ void func_809BD524(EnBigokuta* this) {
|
||||
this->unk_195 = false;
|
||||
this->unk_196 = 80;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, this->unk_196);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, this->unk_196);
|
||||
this->actionFunc = func_809BE058;
|
||||
}
|
||||
|
||||
@ -349,7 +349,7 @@ void func_809BD5E0(EnBigokuta* this) {
|
||||
this->unk_196 = 24;
|
||||
this->unk_19A = 0;
|
||||
this->cylinder[0].base.atFlags &= ~AT_ON;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 24);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 24);
|
||||
this->actionFunc = func_809BE180;
|
||||
}
|
||||
void func_809BD658(EnBigokuta* this) {
|
||||
|
@ -221,7 +221,7 @@ void EnBili_SetupBurnt(EnBili* this) {
|
||||
this->collider.base.acFlags &= ~AC_ON;
|
||||
this->actor.flags |= ACTOR_FLAG_4;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0x2000, 0x14);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_XLU, 20);
|
||||
this->actionFunc = EnBili_Burnt;
|
||||
}
|
||||
|
||||
@ -240,7 +240,7 @@ void EnBili_SetupStunned(EnBili* this) {
|
||||
this->collider.info.bumper.effect = 0;
|
||||
this->actor.gravity = -1.0f;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x96, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 150, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->collider.base.atFlags &= ~AT_ON;
|
||||
this->actionFunc = EnBili_Stunned;
|
||||
@ -268,7 +268,7 @@ void EnBili_SetupFrozen(EnBili* this, PlayState* play) {
|
||||
}
|
||||
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x96, 0x2000, 0xA);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 150, COLORFILTER_BUFFLAG_XLU, 10);
|
||||
this->collider.base.atFlags &= ~AT_ON;
|
||||
this->collider.base.acFlags &= ~AC_ON;
|
||||
this->timer = 300;
|
||||
@ -566,7 +566,7 @@ void EnBili_UpdateDamage(EnBili* this, PlayState* play) {
|
||||
}
|
||||
} else if (damageEffect == BIRI_DMGEFF_SWORD) {
|
||||
if (this->actionFunc != EnBili_Stunned) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0x2000, 0xA);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_XLU, 10);
|
||||
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
this->actor.params = EN_BILI_TYPE_DYING;
|
||||
|
@ -150,7 +150,7 @@ void EnBom_Move(EnBom* this, PlayState* play) {
|
||||
this->actor.velocity.y *= -0.3f;
|
||||
this->actor.bgCheckFlags &= ~BGCHECKFLAG_GROUND_TOUCH;
|
||||
} else if (this->timer >= 4) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -186,7 +186,7 @@ void EnBomBowlPit_GivePrize(EnBomBowlPit* this, PlayState* play) {
|
||||
|
||||
player->stateFlags1 &= ~PLAYER_STATE1_29;
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
player->stateFlags1 |= PLAYER_STATE1_29;
|
||||
this->actionFunc = EnBomBowlPit_WaitTillPrizeGiven;
|
||||
}
|
||||
@ -195,7 +195,7 @@ void EnBomBowlPit_WaitTillPrizeGiven(EnBomBowlPit* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = EnBomBowlPit_Reset;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -191,7 +191,7 @@ void EnBombf_GrowBomb(EnBombf* this, PlayState* play) {
|
||||
}
|
||||
} else {
|
||||
if (!Actor_HasParent(&this->actor, play)) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
} else {
|
||||
player->actor.child = NULL;
|
||||
player->heldActor = NULL;
|
||||
@ -241,7 +241,7 @@ void EnBombf_Move(EnBombf* this, PlayState* play) {
|
||||
func_8002F850(play, &this->actor);
|
||||
this->actor.velocity.y *= -0.5f;
|
||||
} else if (this->timer >= 4) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -267,7 +267,7 @@ void EnBox_FallOnSwitchFlag(EnBox* this, PlayState* play) {
|
||||
s32 treasureFlag = this->dyna.actor.params & 0x1F;
|
||||
|
||||
if (treasureFlag >= ENBOX_TREASURE_FLAG_UNK_MIN && treasureFlag < ENBOX_TREASURE_FLAG_UNK_MAX) {
|
||||
func_8002F5F0(&this->dyna.actor, play);
|
||||
Actor_SetClosestSecretDistance(&this->dyna.actor, play);
|
||||
}
|
||||
|
||||
if (this->unk_1A8 >= 0) {
|
||||
@ -287,7 +287,7 @@ void func_809C9700(EnBox* this, PlayState* play) {
|
||||
Player* player = GET_PLAYER(play);
|
||||
|
||||
if (treasureFlag >= ENBOX_TREASURE_FLAG_UNK_MIN && treasureFlag < ENBOX_TREASURE_FLAG_UNK_MAX) {
|
||||
func_8002F5F0(&this->dyna.actor, play);
|
||||
Actor_SetClosestSecretDistance(&this->dyna.actor, play);
|
||||
}
|
||||
|
||||
if (Math3D_Vec3fDistSq(&this->dyna.actor.world.pos, &player->actor.world.pos) > SQ(150.0f)) {
|
||||
@ -323,7 +323,7 @@ void EnBox_AppearOnSwitchFlag(EnBox* this, PlayState* play) {
|
||||
s32 treasureFlag = this->dyna.actor.params & 0x1F;
|
||||
|
||||
if (treasureFlag >= ENBOX_TREASURE_FLAG_UNK_MIN && treasureFlag < ENBOX_TREASURE_FLAG_UNK_MAX) {
|
||||
func_8002F5F0(&this->dyna.actor, play);
|
||||
Actor_SetClosestSecretDistance(&this->dyna.actor, play);
|
||||
}
|
||||
|
||||
if (Flags_GetSwitch(play, this->switchFlag)) {
|
||||
@ -337,7 +337,7 @@ void EnBox_AppearOnRoomClear(EnBox* this, PlayState* play) {
|
||||
s32 treasureFlag = this->dyna.actor.params & 0x1F;
|
||||
|
||||
if (treasureFlag >= ENBOX_TREASURE_FLAG_UNK_MIN && treasureFlag < ENBOX_TREASURE_FLAG_UNK_MAX) {
|
||||
func_8002F5F0(&this->dyna.actor, play);
|
||||
Actor_SetClosestSecretDistance(&this->dyna.actor, play);
|
||||
}
|
||||
|
||||
if (Flags_GetTempClear(play, this->dyna.actor.room) && !Player_InCsMode(play)) {
|
||||
@ -424,7 +424,7 @@ void EnBox_WaitOpen(EnBox* this, PlayState* play) {
|
||||
func_8002DBD0(&this->dyna.actor, &sp4C, &player->actor.world.pos);
|
||||
if (sp4C.z > -50.0f && sp4C.z < 0.0f && fabsf(sp4C.y) < 10.0f && fabsf(sp4C.x) < 20.0f &&
|
||||
Player_IsFacingActor(&this->dyna.actor, 0x3000, play)) {
|
||||
func_8002F554(&this->dyna.actor, play, 0 - (this->dyna.actor.params >> 5 & 0x7F));
|
||||
Actor_OfferGetItemNearby(&this->dyna.actor, play, 0 - (this->dyna.actor.params >> 5 & 0x7F));
|
||||
}
|
||||
if (Flags_GetTreasure(play, this->dyna.actor.params & 0x1F)) {
|
||||
EnBox_SetupAction(this, EnBox_Open);
|
||||
|
@ -127,7 +127,7 @@ void func_809CAEA0(EnBrob* this) {
|
||||
void func_809CAEF4(EnBrob* this) {
|
||||
Animation_MorphToPlayOnce(&this->skelAnime, &object_brob_Anim_000290, -5.0f);
|
||||
this->unk_1AE -= 125.0f;
|
||||
Actor_SetColorFilter(&this->dyna.actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->actionFunc = func_809CB2B8;
|
||||
}
|
||||
|
@ -694,7 +694,7 @@ void func_809D0584(EnBw* this, PlayState* play) {
|
||||
if ((this->damageEffect == 1) || (this->damageEffect == 0xE)) {
|
||||
if (this->unk_23C == 0) {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
func_809D03CC(this);
|
||||
this->unk_248 = 0.0f;
|
||||
}
|
||||
@ -705,7 +705,7 @@ void func_809D0584(EnBw* this, PlayState* play) {
|
||||
}
|
||||
if (((this->unk_221 == 1) || (this->unk_221 == 4)) && (this->actor.colChkInfo.health == 0)) {
|
||||
if (this->unk_220 != 0) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
if (func_800355E4(play, &this->collider2.base)) {
|
||||
this->unk_230 = 0;
|
||||
this->actor.scale.y -= 0.009f;
|
||||
@ -719,7 +719,7 @@ void func_809D0584(EnBw* this, PlayState* play) {
|
||||
}
|
||||
} else if ((this->unk_220 != 1) && (this->unk_220 != 6)) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_BUBLEWALK_DAMAGE);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
if (this->unk_220 != 5) {
|
||||
func_809D01CC(this);
|
||||
}
|
||||
|
@ -348,7 +348,7 @@ void EnClearTag_Update(Actor* thisx, PlayState* play2) {
|
||||
|
||||
this->collider.base.acFlags &= ~AC_HIT;
|
||||
this->crashingTimer = 20;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 5);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 5);
|
||||
this->acceleration.x = Rand_CenteredFloat(15.0f);
|
||||
this->acceleration.y = Rand_CenteredFloat(15.0f);
|
||||
this->acceleration.z = Rand_CenteredFloat(15.0f);
|
||||
|
@ -213,7 +213,7 @@ void func_809DF778(EnCow* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = func_809DF730;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_MILK, 10000.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MILK, 10000.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -222,7 +222,7 @@ void func_809DF7D8(EnCow* this, PlayState* play) {
|
||||
this->actor.flags &= ~ACTOR_FLAG_16;
|
||||
Message_CloseTextbox(play);
|
||||
this->actionFunc = func_809DF778;
|
||||
func_8002F434(&this->actor, play, GI_MILK, 10000.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MILK, 10000.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -157,7 +157,7 @@ void EnCrow_SetupDamaged(EnCrow* this, PlayState* play) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_KAICHO_DEAD);
|
||||
|
||||
if (this->actor.colChkInfo.damageEffect == 3) { // Ice arrows
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
for (i = 0; i < 8; i++) {
|
||||
iceParticlePos.x = ((i & 1 ? 7.0f : -7.0f) * scale) + this->actor.world.pos.x;
|
||||
iceParticlePos.y = ((i & 2 ? 7.0f : -7.0f) * scale) + this->actor.world.pos.y;
|
||||
@ -166,13 +166,13 @@ void EnCrow_SetupDamaged(EnCrow* this, PlayState* play) {
|
||||
((Rand_ZeroOne() * 0.15f) + 0.85f) * scale);
|
||||
}
|
||||
} else if (this->actor.colChkInfo.damageEffect == 2) { // Fire arrows and Din's Fire
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
|
||||
for (i = 0; i < 4; i++) {
|
||||
EffectSsEnFire_SpawnVec3f(play, &this->actor, &this->actor.world.pos, 50.0f * scale, 0, 0, i);
|
||||
}
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
}
|
||||
|
||||
if (this->actor.flags & ACTOR_FLAG_15) {
|
||||
@ -196,7 +196,7 @@ void EnCrow_SetupTurnAway(EnCrow* this) {
|
||||
this->aimRotX = -0x1000;
|
||||
this->aimRotY = this->actor.yawTowardsPlayer + 0x8000;
|
||||
this->skelAnime.playSpeed = 2.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 255, 0, 5);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 5);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->actionFunc = EnCrow_TurnAway;
|
||||
}
|
||||
|
@ -386,9 +386,9 @@ void EnDekubaba_SetupHit(EnDekubaba* this, s32 arg1) {
|
||||
Actor_SetScale(&this->actor, this->size * 0.01f);
|
||||
|
||||
if (arg1 == 2) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 155, 0, 62);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 155, COLORFILTER_BUFFLAG_OPA, 62);
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 42);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 42);
|
||||
}
|
||||
|
||||
this->actionFunc = EnDekubaba_Hit;
|
||||
@ -442,7 +442,7 @@ void EnDekubaba_SetupSway(EnDekubaba* this) {
|
||||
this->stemSectionAngle[1] = -0x4800;
|
||||
|
||||
EnDekubaba_DisableHitboxes(this);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 35);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 35);
|
||||
this->collider.base.acFlags &= ~AC_ON;
|
||||
this->actionFunc = EnDekubaba_Sway;
|
||||
}
|
||||
@ -1020,7 +1020,7 @@ void EnDekubaba_DeadStickDrop(EnDekubaba* this, PlayState* play) {
|
||||
return;
|
||||
}
|
||||
|
||||
func_8002F554(&this->actor, play, GI_DEKU_STICKS_1);
|
||||
Actor_OfferGetItemNearby(&this->actor, play, GI_DEKU_STICKS_1);
|
||||
}
|
||||
|
||||
// Update and associated functions
|
||||
|
@ -214,7 +214,8 @@ void EnDekunuts_SetupBeDamaged(EnDekunuts* this) {
|
||||
this->actor.speedXZ = 10.0f;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_NUTS_DAMAGE);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_NUTS_CUTBODY);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, Animation_GetLastFrame(&gDekuNutsDamageAnim));
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gDekuNutsDamageAnim));
|
||||
}
|
||||
|
||||
void EnDekunuts_SetupBeStunned(EnDekunuts* this) {
|
||||
@ -223,7 +224,7 @@ void EnDekunuts_SetupBeStunned(EnDekunuts* this) {
|
||||
this->actionFunc = EnDekunuts_BeStunned;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0,
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
Animation_GetLastFrame(&gDekuNutsDamageAnim) * this->animFlagAndTimer);
|
||||
}
|
||||
|
||||
|
@ -482,7 +482,7 @@ void EnDh_CollisionCheck(EnDh* this, PlayState* play) {
|
||||
if (player->unk_844 != 0) {
|
||||
this->unk_258 = player->unk_845;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
lastHealth = this->actor.colChkInfo.health;
|
||||
if (Actor_ApplyDamage(&this->actor) == 0) {
|
||||
EnDh_SetupDeath(this);
|
||||
|
@ -383,7 +383,7 @@ void EnDha_UpdateHealth(EnDha* this, PlayState* play) {
|
||||
if (this->actor.colChkInfo.damageEffect == 0 || this->actor.colChkInfo.damageEffect == 6) {
|
||||
return;
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
if (Actor_ApplyDamage(&this->actor) == 0) {
|
||||
EnDha_SetupDeath(this);
|
||||
this->actor.colChkInfo.health = 8;
|
||||
|
@ -459,7 +459,7 @@ void func_809EEA00(EnDivingGame* this, PlayState* play) {
|
||||
if ((this->unk_292 == Message_GetState(&play->msgCtx) && Message_ShouldAdvance(play))) {
|
||||
Message_CloseTextbox(play);
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, GI_SCALE_SILVER, 90.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_SCALE_SILVER, 90.0f, 10.0f);
|
||||
this->actionFunc = func_809EEA90;
|
||||
}
|
||||
}
|
||||
@ -469,7 +469,7 @@ void func_809EEA90(EnDivingGame* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = func_809EEAF8;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_SCALE_SILVER, 90.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_SCALE_SILVER, 90.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -370,18 +370,18 @@ void EnDns_Talk(EnDns* this, PlayState* play) {
|
||||
void func_809EFDD0(EnDns* this, PlayState* play) {
|
||||
if (this->actor.params == 0x9) {
|
||||
if (CUR_UPG_VALUE(UPG_DEKU_STICKS) < 2) {
|
||||
func_8002F434(&this->actor, play, GI_DEKU_STICK_UPGRADE_20, 130.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DEKU_STICK_UPGRADE_20, 130.0f, 100.0f);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_DEKU_STICK_UPGRADE_30, 130.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DEKU_STICK_UPGRADE_30, 130.0f, 100.0f);
|
||||
}
|
||||
} else if (this->actor.params == 0xA) {
|
||||
if (CUR_UPG_VALUE(UPG_DEKU_NUTS) < 2) {
|
||||
func_8002F434(&this->actor, play, GI_DEKU_NUT_UPGRADE_30, 130.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DEKU_NUT_UPGRADE_30, 130.0f, 100.0f);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_DEKU_NUT_UPGRADE_40, 130.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DEKU_NUT_UPGRADE_40, 130.0f, 100.0f);
|
||||
}
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->dnsItemEntry->getItemId, 130.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->dnsItemEntry->getItemId, 130.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -255,7 +255,7 @@ void EnDntJiji_Talk(EnDntJiji* this, PlayState* play) {
|
||||
Message_CloseTextbox(play);
|
||||
func_8002DF54(play, NULL, 7);
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, this->getItemId, 400.0f, 200.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 400.0f, 200.0f);
|
||||
this->actionFunc = EnDntJiji_SetupGivePrize;
|
||||
}
|
||||
}
|
||||
@ -265,7 +265,7 @@ void EnDntJiji_SetupGivePrize(EnDntJiji* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = EnDntJiji_GivePrize;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->getItemId, 400.0f, 200.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 400.0f, 200.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -91,7 +91,7 @@ void EnDodojr_Destroy(Actor* thisx, PlayState* play) {
|
||||
|
||||
void EnDodojr_DoSwallowedBombEffects(EnDodojr* this) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_IT_BOMB_EXPLOSION);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
}
|
||||
|
||||
void EnDodojr_SpawnLargeDust(EnDodojr* this, PlayState* play, s32 count) {
|
||||
@ -359,7 +359,7 @@ s32 EnDodojr_CheckDamaged(EnDodojr* this, PlayState* play) {
|
||||
(this->actionFunc != EnDodojr_StunnedBounce)) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->stunTimer = 120;
|
||||
Actor_SetColorFilter(&this->actor, 0, 200, 0, 120);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, 120);
|
||||
EnDodojr_SetupFlipBounce(this);
|
||||
this->actionFunc = EnDodojr_StunnedBounce;
|
||||
}
|
||||
@ -577,7 +577,7 @@ void EnDodojr_DeathSequence(EnDodojr* this, PlayState* play) {
|
||||
|
||||
if (this->counter != 0) {
|
||||
if (this->actor.colorFilterTimer == 0) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, this->counter);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, this->counter);
|
||||
this->counter--;
|
||||
}
|
||||
} else {
|
||||
|
@ -497,7 +497,7 @@ void EnDodongo_SwallowBomb(EnDodongo* this, PlayState* play) {
|
||||
&this->bombSmokeEnvColor, 400, 10, 10);
|
||||
}
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_IT_BOMB_EXPLOSION);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0x78, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 120, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -676,7 +676,7 @@ void EnDodongo_Death(EnDodongo* this, PlayState* play) {
|
||||
EnDodongo_SpawnBombSmoke(this, play);
|
||||
}
|
||||
} else if (this->actor.colorFilterTimer == 0) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0x78, 0, 4);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 120, COLORFILTER_BUFFLAG_OPA, 4);
|
||||
}
|
||||
if (SkelAnime_Update(&this->skelAnime)) {
|
||||
if (this->timer == 0) {
|
||||
@ -721,12 +721,12 @@ void EnDodongo_CollisionCheck(EnDodongo* this, PlayState* play) {
|
||||
this->damageEffect = this->actor.colChkInfo.damageEffect;
|
||||
if ((this->actor.colChkInfo.damageEffect == 1) || (this->actor.colChkInfo.damageEffect == 0xF)) {
|
||||
if (this->actionState != DODONGO_STUNNED) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
EnDodongo_SetupStunned(this);
|
||||
}
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0x78, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 120, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
if (Actor_ApplyDamage(&this->actor) == 0) {
|
||||
EnDodongo_SetupDeath(this, play);
|
||||
} else {
|
||||
|
@ -90,7 +90,7 @@ void EnDs_GiveOddPotion(EnDs* this, PlayState* play) {
|
||||
this->actionFunc = EnDs_DisplayOddPotionText;
|
||||
gSaveContext.subTimerState = SUBTIMER_STATE_OFF;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_ODD_POTION, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_ODD_POTION, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -98,7 +98,7 @@ void EnDs_TalkAfterBrewOddPotion(EnDs* this, PlayState* play) {
|
||||
if ((Message_GetState(&play->msgCtx) == TEXT_STATE_EVENT) && Message_ShouldAdvance(play)) {
|
||||
Message_CloseTextbox(play);
|
||||
this->actionFunc = EnDs_GiveOddPotion;
|
||||
func_8002F434(&this->actor, play, GI_ODD_POTION, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_ODD_POTION, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -170,7 +170,7 @@ void EnDs_GiveBluePotion(EnDs* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnDs_Talk;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_BOTTLE_POTION_BLUE, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOTTLE_POTION_BLUE, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -189,7 +189,7 @@ void EnDs_OfferBluePotion(EnDs* this, PlayState* play) {
|
||||
case 2: // have 100 rupees and empty bottle
|
||||
Rupees_ChangeBy(-100);
|
||||
this->actor.flags &= ~ACTOR_FLAG_16;
|
||||
func_8002F434(&this->actor, play, GI_BOTTLE_POTION_BLUE, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOTTLE_POTION_BLUE, 10000.0f, 50.0f);
|
||||
this->actionFunc = EnDs_GiveBluePotion;
|
||||
return;
|
||||
}
|
||||
|
@ -522,7 +522,7 @@ void func_809FEC70(EnDu* this, PlayState* play) {
|
||||
} else {
|
||||
f32 xzRange = this->actor.xzDistToPlayer + 1.0f;
|
||||
|
||||
func_8002F434(&this->actor, play, GI_GORONS_BRACELET, xzRange, fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_GORONS_BRACELET, xzRange, fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -281,14 +281,14 @@ void EnEiyer_SetupHurt(EnEiyer* this) {
|
||||
this->actor.gravity = 0.0f;
|
||||
this->actor.velocity.y = 0.0f;
|
||||
this->actor.speedXZ = 5.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
this->collider.base.acFlags &= ~AC_ON;
|
||||
this->actionFunc = EnEiyer_Hurt;
|
||||
}
|
||||
|
||||
void EnEiyer_SetupDie(EnEiyer* this) {
|
||||
this->timer = 20;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
|
||||
if (this->collider.info.bumper.dmgFlags != (DMG_BOOMERANG | DMG_EXPLOSIVE | DMG_DEKU_NUT)) {
|
||||
this->actor.speedXZ = 6.0f;
|
||||
@ -317,7 +317,7 @@ void EnEiyer_SetupStunned(EnEiyer* this) {
|
||||
this->actor.velocity.y = 0.0f;
|
||||
this->actor.gravity = -1.0f;
|
||||
this->collider.dim.height = sColCylInit.dim.height + 8;
|
||||
Actor_SetColorFilter(&this->actor, 0, 200, 0, 80);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
this->collider.base.atFlags &= ~AT_ON;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->actionFunc = EnEiyer_Stunned;
|
||||
|
@ -661,7 +661,7 @@ void func_80A0329C(EnElf* this, PlayState* play) {
|
||||
|
||||
if (!(this->fairyFlags & FAIRY_FLAG_BIG)) {
|
||||
// GI_MAX in this case allows the player to catch the actor in a bottle
|
||||
func_8002F434(&this->actor, play, GI_MAX, 80.0f, 60.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAX, 80.0f, 60.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -393,7 +393,7 @@ void EnExItem_TargetPrizeApproach(EnExItem* this, PlayState* play) {
|
||||
} else {
|
||||
getItemId = GI_BULLET_BAG_50;
|
||||
}
|
||||
func_8002F434(&this->actor, play, getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 2000.0f, 1000.0f);
|
||||
this->actionFunc = EnExItem_TargetPrizeGive;
|
||||
}
|
||||
}
|
||||
@ -406,7 +406,7 @@ void EnExItem_TargetPrizeGive(EnExItem* this, PlayState* play) {
|
||||
} else {
|
||||
getItemId = (CUR_UPG_VALUE(UPG_BULLET_BAG) == 2) ? GI_BULLET_BAG_50 : GI_BULLET_BAG_40;
|
||||
|
||||
func_8002F434(&this->actor, play, getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 2000.0f, 1000.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -214,7 +214,7 @@ void EnFirefly_SetupFall(EnFirefly* this) {
|
||||
Animation_Change(&this->skelAnime, &gKeeseFlyAnim, 0.5f, 0.0f, 0.0f, ANIMMODE_LOOP_INTERP, -3.0f);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_FFLY_DEAD);
|
||||
this->actor.flags |= ACTOR_FLAG_4;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 40);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
this->actionFunc = EnFirefly_Fall;
|
||||
}
|
||||
|
||||
@ -248,7 +248,7 @@ void EnFirefly_SetupFlyAway(EnFirefly* this) {
|
||||
|
||||
void EnFirefly_SetupStunned(EnFirefly* this) {
|
||||
this->timer = 80;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 80);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
this->auraType = KEESE_AURA_NONE;
|
||||
this->actor.velocity.y = 0.0f;
|
||||
this->skelAnime.playSpeed = 3.0f;
|
||||
@ -263,7 +263,7 @@ void EnFirefly_SetupFrozenFall(EnFirefly* this, PlayState* play) {
|
||||
this->actor.flags |= ACTOR_FLAG_4;
|
||||
this->auraType = KEESE_AURA_NONE;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0xFF);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 255);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_FFLY_DEAD);
|
||||
|
||||
for (i = 0; i <= 7; i++) {
|
||||
|
@ -710,7 +710,7 @@ void EnFish_OrdinaryUpdate(EnFish* this, PlayState* play) {
|
||||
EnFish_BeginRespawn(this);
|
||||
} else if (EnFish_InBottleRange(this, play)) {
|
||||
// GI_MAX in this case allows the player to catch the actor in a bottle
|
||||
func_8002F434(&this->actor, play, GI_MAX, 80.0f, 20.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAX, 80.0f, 20.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -395,7 +395,7 @@ void EnFloormas_SetupTakeDamage(EnFloormas* this) {
|
||||
} else {
|
||||
this->actor.world.rot.y = Actor_WorldYawTowardActor(&this->actor, this->collider.base.ac) + 0x8000;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x14);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 20);
|
||||
this->actionFunc = EnFloormas_TakeDamage;
|
||||
this->actor.speedXZ = 5.0f;
|
||||
this->actor.velocity.y = 5.5f;
|
||||
@ -412,9 +412,9 @@ void EnFloormas_SetupFreeze(EnFloormas* this) {
|
||||
Animation_Change(&this->skelAnime, &gWallmasterJumpAnim, 1.5f, 0, 20.0f, ANIMMODE_ONCE, -3.0f);
|
||||
this->actor.speedXZ = 0.0f;
|
||||
if (this->actor.colChkInfo.damageEffect == 4) {
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
if (this->actor.scale.x > 0.004f) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
} else {
|
||||
|
@ -1013,7 +1013,7 @@ void EnFr_Deactivate(EnFr* this, PlayState* play) {
|
||||
this->actionFunc = EnFr_Idle;
|
||||
} else {
|
||||
this->actionFunc = EnFr_GiveReward;
|
||||
func_8002F434(&this->actor, play, this->reward, 30.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->reward, 30.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1022,7 +1022,7 @@ void EnFr_GiveReward(EnFr* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnFr_SetIdle;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->reward, 30.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->reward, 30.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -247,7 +247,8 @@ void EnFw_Run(EnFw* this, PlayState* play) {
|
||||
Math_SmoothStepToF(&this->actor.scale.x, 0.024999999f, 0.08f, 0.6f, 0.0f);
|
||||
Actor_SetScale(&this->actor, this->actor.scale.x);
|
||||
if (this->actor.colorFilterTimer == 0) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->explosionTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA,
|
||||
this->explosionTimer);
|
||||
this->explosionTimer--;
|
||||
}
|
||||
|
||||
@ -265,7 +266,8 @@ void EnFw_Run(EnFw* this, PlayState* play) {
|
||||
}
|
||||
} else {
|
||||
if (!(this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) || this->actor.velocity.y > 0.0f) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->damageTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA,
|
||||
this->damageTimer);
|
||||
return;
|
||||
}
|
||||
DECR(this->damageTimer);
|
||||
|
@ -344,7 +344,7 @@ void EnFz_ApplyDamage(EnFz* this, PlayState* play) {
|
||||
switch (this->actor.colChkInfo.damageEffect) {
|
||||
case 0xF:
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 8);
|
||||
if (this->actor.colChkInfo.health != 0) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_FREEZAD_DAMAGE);
|
||||
vec.x = this->actor.world.pos.x;
|
||||
@ -365,7 +365,7 @@ void EnFz_ApplyDamage(EnFz* this, PlayState* play) {
|
||||
|
||||
case 2:
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 8);
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_FREEZAD_DEAD);
|
||||
EnFz_SetupMelt(this);
|
||||
|
@ -350,7 +350,7 @@ void func_80A2FA50(EnGb* this, PlayState* play) {
|
||||
|
||||
void func_80A2FB40(EnGb* this, PlayState* play) {
|
||||
if (Message_GetState(&play->msgCtx) == TEXT_STATE_DONE && Message_ShouldAdvance(play)) {
|
||||
func_8002F434(&this->dyna.actor, play, GI_BOTTLE_EMPTY, 100.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->dyna.actor, play, GI_BOTTLE_EMPTY, 100.0f, 10.0f);
|
||||
this->actionFunc = func_80A2FBB0;
|
||||
}
|
||||
}
|
||||
@ -360,7 +360,7 @@ void func_80A2FBB0(EnGb* this, PlayState* play) {
|
||||
this->dyna.actor.parent = NULL;
|
||||
this->actionFunc = func_80A2FC0C;
|
||||
} else {
|
||||
func_8002F434(&this->dyna.actor, play, GI_BOTTLE_EMPTY, 100.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->dyna.actor, play, GI_BOTTLE_EMPTY, 100.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -512,7 +512,7 @@ void EnGe1_WaitTillItemGiven_Archery(EnGe1* this, PlayState* play) {
|
||||
} else {
|
||||
getItemId = GI_HEART_PIECE;
|
||||
}
|
||||
func_8002F434(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -541,7 +541,7 @@ void EnGe1_BeginGiveItem_Archery(EnGe1* this, PlayState* play) {
|
||||
getItemId = GI_HEART_PIECE;
|
||||
}
|
||||
|
||||
func_8002F434(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
}
|
||||
|
||||
void EnGe1_TalkWinPrize_Archery(EnGe1* this, PlayState* play) {
|
||||
|
@ -451,7 +451,7 @@ void EnGe2_WaitTillCardGiven(EnGe2* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnGe2_SetActionAfterTalk;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -460,7 +460,7 @@ void EnGe2_GiveCard(EnGe2* this, PlayState* play) {
|
||||
Message_CloseTextbox(play);
|
||||
this->actor.flags &= ~ACTOR_FLAG_16;
|
||||
this->actionFunc = EnGe2_WaitTillCardGiven;
|
||||
func_8002F434(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -556,7 +556,9 @@ void EnGe2_Update(Actor* thisx, PlayState* play) {
|
||||
} else if (this->collider.base.acFlags & AC_HIT) {
|
||||
if ((this->collider.info.acHitInfo != NULL) &&
|
||||
(this->collider.info.acHitInfo->toucher.dmgFlags & DMG_HOOKSHOT)) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 120, 0, 400);
|
||||
//! @bug duration parameter is larger than 255 which messes with the internal bitpacking of the colorfilter.
|
||||
//! Because of the duration being tracked as an unsigned byte it ends up being truncated to 144
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 400);
|
||||
this->actor.update = EnGe2_UpdateStunned;
|
||||
return;
|
||||
}
|
||||
|
@ -141,7 +141,7 @@ void EnGe3_WaitTillCardGiven(EnGe3* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnGe3_Wait;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -150,7 +150,7 @@ void EnGe3_GiveCard(EnGe3* this, PlayState* play) {
|
||||
Message_CloseTextbox(play);
|
||||
this->actor.flags &= ~ACTOR_FLAG_16;
|
||||
this->actionFunc = EnGe3_WaitTillCardGiven;
|
||||
func_8002F434(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_GERUDOS_CARD, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1373,12 +1373,12 @@ void EnGeldB_CollisionCheck(EnGeldB* this, PlayState* play) {
|
||||
if ((this->actor.colChkInfo.damageEffect == GELDB_DMG_STUN) ||
|
||||
(this->actor.colChkInfo.damageEffect == GELDB_DMG_FREEZE)) {
|
||||
if (this->action != GELDB_STUNNED) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
EnGeldB_SetupStunned(this);
|
||||
}
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
if (Actor_ApplyDamage(&this->actor) == 0) {
|
||||
if (this->keyFlag != 0) {
|
||||
key = Item_DropCollectible(play, &this->actor.world.pos, this->keyFlag | ITEM00_SMALL_KEY);
|
||||
|
@ -245,7 +245,7 @@ void EnGm_ProcessChoiceIndex(EnGm* this, PlayState* play) {
|
||||
Message_ContinueTextbox(play, 0xC8);
|
||||
this->actionFunc = func_80A3DD7C;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_SWORD_KNIFE, 415.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_SWORD_KNIFE, 415.0f, 10.0f);
|
||||
this->actionFunc = func_80A3DF00;
|
||||
}
|
||||
break;
|
||||
@ -262,7 +262,7 @@ void func_80A3DF00(EnGm* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = func_80A3DF60;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_SWORD_KNIFE, 415.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_SWORD_KNIFE, 415.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -226,7 +226,7 @@ s16 EnGo_UpdateTalkState(PlayState* play, Actor* thisx) {
|
||||
unkState = NPC_TALK_STATE_IDLE;
|
||||
break;
|
||||
case 0x3036:
|
||||
func_8002F434(thisx, play, GI_TUNIC_GORON, xzRange, yRange);
|
||||
Actor_OfferGetItem(thisx, play, GI_TUNIC_GORON, xzRange, yRange);
|
||||
SET_INFTABLE(INFTABLE_10D); // EnGo exclusive flag
|
||||
unkState = NPC_TALK_STATE_ACTION;
|
||||
break;
|
||||
@ -972,7 +972,7 @@ void EnGo_GetItem(EnGo* this, PlayState* play) {
|
||||
|
||||
yDist = fabsf(this->actor.yDistToPlayer) + 1.0f;
|
||||
xzDist = this->actor.xzDistToPlayer + 1.0f;
|
||||
func_8002F434(&this->actor, play, getItemId, xzDist, yDist);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, xzDist, yDist);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -278,8 +278,8 @@ s32 EnGo2_SpawnDust(EnGo2* this, u8 initialTimer, f32 scale, f32 scaleStep, s32
|
||||
|
||||
void EnGo2_GetItem(EnGo2* this, PlayState* play, s32 getItemId) {
|
||||
this->getItemId = getItemId;
|
||||
func_8002F434(&this->actor, play, getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
}
|
||||
|
||||
s32 EnGo2_GetDialogState(EnGo2* this, PlayState* play) {
|
||||
@ -1791,8 +1791,8 @@ void EnGo2_SetupGetItem(EnGo2* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnGo2_SetGetItem;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -561,7 +561,7 @@ void EnGoma_SetupStunned(EnGoma* this, PlayState* play) {
|
||||
}
|
||||
|
||||
void EnGoma_Stunned(EnGoma* this, PlayState* play) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 180, 0, 2);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 180, COLORFILTER_BUFFLAG_OPA, 2);
|
||||
this->visualState = 2;
|
||||
|
||||
if (this->actionTimer != 0) {
|
||||
@ -652,7 +652,7 @@ void EnGoma_UpdateHit(EnGoma* this, PlayState* play) {
|
||||
|
||||
this->actor.colChkInfo.health -= swordDamage;
|
||||
EnGoma_SetupHurt(this, play);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 5);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 5);
|
||||
this->hurtTimer = 13;
|
||||
}
|
||||
} else {
|
||||
|
@ -205,7 +205,7 @@ void EnHintnuts_SetupLeave(EnHintnuts* this, PlayState* play) {
|
||||
void EnHintnuts_SetupFreeze(EnHintnuts* this) {
|
||||
Animation_PlayLoop(&this->skelAnime, &gHintNutsFreezeAnim);
|
||||
this->actor.flags &= ~ACTOR_FLAG_0;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 100);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 100);
|
||||
this->actor.colorFilterTimer = 1;
|
||||
this->animFlagAndTimer = 0;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_NUTS_FAINT);
|
||||
|
@ -246,7 +246,7 @@ void EnHonotrap_EyeIdle(EnHonotrap* this, PlayState* play) {
|
||||
|
||||
void EnHonotrap_SetupEyeOpen(EnHonotrap* this) {
|
||||
this->actionFunc = EnHonotrap_EyeOpen;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x28);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 40);
|
||||
this->timer = 30;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EV_RED_EYE);
|
||||
}
|
||||
|
@ -155,7 +155,7 @@ void func_80A6E740(EnHs* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
func_80A6E3A0(this, func_80A6E630);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_ODD_MUSHROOM, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_ODD_MUSHROOM, 10000.0f, 50.0f);
|
||||
}
|
||||
|
||||
this->unk_2A8 |= 1;
|
||||
@ -166,7 +166,7 @@ void func_80A6E7BC(EnHs* this, PlayState* play) {
|
||||
switch (play->msgCtx.choiceIndex) {
|
||||
case 0:
|
||||
func_80A6E3A0(this, func_80A6E740);
|
||||
func_8002F434(&this->actor, play, GI_ODD_MUSHROOM, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_ODD_MUSHROOM, 10000.0f, 50.0f);
|
||||
break;
|
||||
case 1:
|
||||
Message_ContinueTextbox(play, 0x10B4);
|
||||
|
@ -410,8 +410,8 @@ s32 EnHy_IsOsAnimeObjectLoaded(EnHy* this, PlayState* play) {
|
||||
|
||||
void func_80A6F7CC(EnHy* this, PlayState* play, s32 getItemId) {
|
||||
this->unkGetItemId = getItemId;
|
||||
func_8002F434(&this->actor, play, getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
}
|
||||
|
||||
u16 func_80A6F810(PlayState* play, Actor* thisx) {
|
||||
@ -1054,8 +1054,8 @@ void func_80A714C4(EnHy* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = func_80A71530;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->unkGetItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->unkGetItemId, this->actor.xzDistToPlayer + 1.0f,
|
||||
fabsf(this->actor.yDistToPlayer) + 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -215,7 +215,7 @@ void EnIceHono_CapturableFlame(EnIceHono* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
} else if (EnIceHono_InBottleRange(this, play)) {
|
||||
// GI_MAX in this case allows the player to catch the actor in a bottle
|
||||
func_8002F434(&this->actor, play, GI_MAX, 60.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAX, 60.0f, 100.0f);
|
||||
}
|
||||
|
||||
if (this->actor.xzDistToPlayer < 200.0f) {
|
||||
|
@ -745,7 +745,7 @@ void EnIk_UpdateDamage(EnIk* this, PlayState* play) {
|
||||
return;
|
||||
}
|
||||
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
|
||||
prevHealth = this->actor.colChkInfo.health;
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
|
@ -779,7 +779,7 @@ void EnInsect_Update(Actor* thisx, PlayState* play) {
|
||||
if (!(this->insectFlags & INSECT_FLAG_UNCATCHABLE) && sCaughtCount < 4 &&
|
||||
EnInsect_InBottleRange(this, play) &&
|
||||
// GI_MAX in this case allows the player to catch the actor in a bottle
|
||||
func_8002F434(&this->actor, play, GI_MAX, 60.0f, 30.0f)) {
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAX, 60.0f, 30.0f)) {
|
||||
sCaughtCount++;
|
||||
}
|
||||
}
|
||||
|
@ -371,9 +371,9 @@ void EnIshi_Wait(EnIshi* this, PlayState* play) {
|
||||
if (this->actor.xzDistToPlayer < 90.0f) {
|
||||
// GI_NONE in these cases allows the player to lift the actor
|
||||
if (type == ROCK_LARGE) {
|
||||
func_8002F434(&this->actor, play, GI_NONE, 80.0f, 20.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_NONE, 80.0f, 20.0f);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_NONE, 50.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_NONE, 50.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -128,7 +128,7 @@ void func_80A89160(EnJs* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
En_Js_SetupAction(this, func_80A8910C);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_BOMBCHUS_10, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOMBCHUS_10, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -362,7 +362,7 @@ void EnKarebaba_DeadItemDrop(EnKarebaba* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play) || this->actor.params == 0) {
|
||||
EnKarebaba_SetupDead(this);
|
||||
} else {
|
||||
func_8002F554(&this->actor, play, GI_DEKU_STICKS_1);
|
||||
Actor_OfferGetItemNearby(&this->actor, play, GI_DEKU_STICKS_1);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1224,7 +1224,7 @@ void func_80A99504(EnKo* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = func_80A99560;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_POACHERS_SAW, 120.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_POACHERS_SAW, 120.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -330,7 +330,7 @@ void EnKusa_Main(EnKusa* this, PlayState* play) {
|
||||
if (this->actor.xzDistToPlayer < 400.0f) {
|
||||
CollisionCheck_SetOC(play, &play->colChkCtx, &this->collider.base);
|
||||
if (this->actor.xzDistToPlayer < 100.0f) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -434,7 +434,7 @@ void EnKz_SetupGetItem(EnKz* this, PlayState* play) {
|
||||
getItemId = this->isTrading == true ? GI_EYEBALL_FROG : GI_TUNIC_ZORA;
|
||||
yRange = fabsf(this->actor.yDistToPlayer) + 1.0f;
|
||||
xzRange = this->actor.xzDistToPlayer + 1.0f;
|
||||
func_8002F434(&this->actor, play, getItemId, xzRange, yRange);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, xzRange, yRange);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -96,7 +96,7 @@ void EnLightbox_Update(Actor* thisx, PlayState* play) {
|
||||
thisx->velocity.y *= IREG(60) / 100.0f;
|
||||
thisx->bgCheckFlags &= ~BGCHECKFLAG_GROUND;
|
||||
} else {
|
||||
func_8002F580(thisx, play);
|
||||
Actor_OfferCarry(thisx, play);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -326,7 +326,7 @@ void func_80AA0EA0(EnMa1* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = func_80AA0EFC;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_WEIRD_EGG, 120.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_WEIRD_EGG, 120.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -586,7 +586,7 @@ void EnMb_SetupClubDead(EnMb* this) {
|
||||
void EnMb_SetupStunned(EnMb* this) {
|
||||
this->state = ENMB_STATE_STUNNED;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
if (this->damageEffect == ENMB_DMGEFF_STUN_ICE) {
|
||||
this->iceEffectTimer = 40;
|
||||
} else {
|
||||
@ -1395,7 +1395,7 @@ void EnMb_CheckColliding(EnMb* this, PlayState* play) {
|
||||
}
|
||||
} else {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFA, 0, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 250, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
if (this->actor.params == ENMB_TYPE_CLUB) {
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
EnMb_SetupClubDead(this);
|
||||
|
@ -95,14 +95,14 @@ void func_80AACA94(EnMk* this, PlayState* play) {
|
||||
Interface_SetSubTimer(240);
|
||||
CLEAR_EVENTINF(EVENTINF_MARATHON_ACTIVE);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_EYE_DROPS, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_EYE_DROPS, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
void func_80AACB14(EnMk* this, PlayState* play) {
|
||||
if (Actor_TextboxIsClosing(&this->actor, play)) {
|
||||
this->actionFunc = func_80AACA94;
|
||||
func_8002F434(&this->actor, play, GI_EYE_DROPS, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_EYE_DROPS, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -196,14 +196,14 @@ void func_80AACFA0(EnMk* this, PlayState* play) {
|
||||
this->actionFunc = func_80AACA40;
|
||||
SET_ITEMGETINF(ITEMGETINF_10);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
void func_80AAD014(EnMk* this, PlayState* play) {
|
||||
if (Actor_TextboxIsClosing(&this->actor, play)) {
|
||||
this->actionFunc = func_80AACFA0;
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, 10000.0f, 50.0f);
|
||||
}
|
||||
|
||||
this->flags |= 1;
|
||||
|
@ -128,7 +128,7 @@ void EnMs_Talk(EnMs* this, PlayState* play) {
|
||||
Message_ContinueTextbox(play, 0x4069); // not enough rupees text
|
||||
return;
|
||||
}
|
||||
func_8002F434(&this->actor, play, GI_MAGIC_BEAN, 90.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAGIC_BEAN, 90.0f, 10.0f);
|
||||
this->actionFunc = EnMs_Sell;
|
||||
return;
|
||||
case 1: // no
|
||||
@ -145,7 +145,7 @@ void EnMs_Sell(EnMs* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnMs_TalkAfterPurchase;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_MAGIC_BEAN, 90.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MAGIC_BEAN, 90.0f, 10.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -465,7 +465,7 @@ void func_80AB6450(EnNiw* this, PlayState* play) {
|
||||
this->actionFunc = func_80AB6BF8;
|
||||
} else {
|
||||
// GI_NONE in this case allows the player to lift the actor
|
||||
func_8002F434(&this->actor, play, GI_NONE, 25.0f, 10.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_NONE, 25.0f, 10.0f);
|
||||
func_80AB5BF8(this, play, 1);
|
||||
}
|
||||
}
|
||||
@ -487,7 +487,7 @@ void func_80AB6570(EnNiw* this, PlayState* play) {
|
||||
this->actionFunc = func_80AB6BF8;
|
||||
return;
|
||||
}
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
} else {
|
||||
if (this->path != 0) {
|
||||
this->unk_2A6 = 1;
|
||||
@ -696,7 +696,7 @@ void func_80AB6D08(EnNiw* this, PlayState* play) {
|
||||
this->actionFunc = func_80AB6BF8;
|
||||
} else {
|
||||
if (this->timer5 >= 6) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
func_80AB5BF8(this, play, 2);
|
||||
}
|
||||
|
@ -309,13 +309,13 @@ void func_80ABA654(EnNiwLady* this, PlayState* play) {
|
||||
if (!GET_ITEMGETINF(ITEMGETINF_0C)) {
|
||||
this->actor.parent = NULL;
|
||||
this->getItemId = GI_BOTTLE_EMPTY;
|
||||
func_8002F434(&this->actor, play, GI_BOTTLE_EMPTY, 100.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOTTLE_EMPTY, 100.0f, 50.0f);
|
||||
this->actionFunc = func_80ABAC00;
|
||||
return;
|
||||
}
|
||||
if (this->unk_26C == 1) {
|
||||
this->getItemId = GI_RUPEE_PURPLE;
|
||||
func_8002F434(&this->actor, play, GI_RUPEE_PURPLE, 100.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_RUPEE_PURPLE, 100.0f, 50.0f);
|
||||
this->actionFunc = func_80ABAC00;
|
||||
}
|
||||
this->actionFunc = func_80ABA244;
|
||||
@ -390,7 +390,7 @@ void func_80ABA9B8(EnNiwLady* this, PlayState* play) {
|
||||
case 0:
|
||||
Message_CloseTextbox(play);
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, GI_POCKET_EGG, 200.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_POCKET_EGG, 200.0f, 100.0f);
|
||||
this->actionFunc = func_80ABAC00;
|
||||
break;
|
||||
case 1:
|
||||
@ -418,7 +418,7 @@ void func_80ABAB08(EnNiwLady* this, PlayState* play) {
|
||||
case 0:
|
||||
Message_CloseTextbox(play);
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, GI_COJIRO, 200.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_COJIRO, 200.0f, 100.0f);
|
||||
this->actionFunc = func_80ABAC00;
|
||||
break;
|
||||
case 1:
|
||||
@ -444,7 +444,7 @@ void func_80ABAC00(EnNiwLady* this, PlayState* play) {
|
||||
if (LINK_IS_ADULT) {
|
||||
getItemId = !GET_ITEMGETINF(ITEMGETINF_2C) ? GI_POCKET_EGG : GI_COJIRO;
|
||||
}
|
||||
func_8002F434(&this->actor, play, getItemId, 200.0f, 100.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 200.0f, 100.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -315,16 +315,16 @@ s32 EnNy_CollisionCheck(EnNy* this, PlayState* play) {
|
||||
FALLTHROUGH;
|
||||
case 0xF:
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
break;
|
||||
case 1:
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
break;
|
||||
case 2:
|
||||
this->unk_1CA = 4;
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -240,7 +240,7 @@ void EnOkuta_SetupShoot(EnOkuta* this, PlayState* play) {
|
||||
|
||||
void EnOkuta_SetupWaitToDie(EnOkuta* this) {
|
||||
Animation_MorphToPlayOnce(&this->skelAnime, &gOctorokHitAnim, -5.0f);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xB);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 11);
|
||||
this->collider.base.acFlags &= ~AC_HIT;
|
||||
Actor_SetScale(&this->actor, 0.01f);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_OCTAROCK_DEAD1);
|
||||
@ -255,7 +255,7 @@ void EnOkuta_SetupDie(EnOkuta* this) {
|
||||
|
||||
void EnOkuta_SetupFreeze(EnOkuta* this) {
|
||||
this->timer = 80;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
this->actionFunc = EnOkuta_Freeze;
|
||||
}
|
||||
|
||||
|
@ -1318,7 +1318,7 @@ void EnOssan_GiveItemWithFanfare(PlayState* play, EnOssan* this) {
|
||||
Player* player = GET_PLAYER(play);
|
||||
|
||||
osSyncPrintf("\n" VT_FGCOL(YELLOW) "初めて手にいれた!!" VT_RST "\n\n");
|
||||
func_8002F434(&this->actor, play, this->shelfSlots[this->cursorIndex]->getItemId, 120.0f, 120.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->shelfSlots[this->cursorIndex]->getItemId, 120.0f, 120.0f);
|
||||
play->msgCtx.msgMode = MSGMODE_TEXT_CLOSING;
|
||||
play->msgCtx.stateTimer = 4;
|
||||
player->stateFlags2 &= ~PLAYER_STATE2_29;
|
||||
@ -1649,7 +1649,7 @@ void EnOssan_State_GiveItemWithFanfare(EnOssan* this, PlayState* play, Player* p
|
||||
this->stateFlag = OSSAN_STATE_ITEM_PURCHASED;
|
||||
return;
|
||||
}
|
||||
func_8002F434(&this->actor, play, this->shelfSlots[this->cursorIndex]->getItemId, 120.0f, 120.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->shelfSlots[this->cursorIndex]->getItemId, 120.0f, 120.0f);
|
||||
}
|
||||
|
||||
void EnOssan_State_ItemPurchased(EnOssan* this, PlayState* play, Player* player) {
|
||||
|
@ -772,7 +772,7 @@ void EnPeehat_SetStateBoomerangStunned(EnPeehat* this) {
|
||||
}
|
||||
this->bladeRotVel = 0;
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
Actor_SetColorFilter(&this->actor, 0, 200, 0, 80);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
EnPeehat_SetupAction(this, EnPeehat_StateBoomerangStunned);
|
||||
}
|
||||
@ -789,7 +789,7 @@ void EnPeehat_Adult_SetStateDie(EnPeehat* this) {
|
||||
this->bladeRotVel = 0;
|
||||
this->isStateDieFirstUpdate = 1;
|
||||
this->actor.speedXZ = 0.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
this->state = PEAHAT_STATE_DYING;
|
||||
this->scaleShift = 0.0f;
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
@ -894,7 +894,7 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) {
|
||||
return;
|
||||
} else {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_PIHAT_DAMAGE);
|
||||
}
|
||||
|
||||
@ -907,7 +907,7 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) {
|
||||
pos.z = Rand_CenteredFloat(20.0f) + this->actor.world.pos.z;
|
||||
EffectSsEnFire_SpawnVec3f(play, &this->actor, &pos, 70, 0, 0, -1);
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, 100);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, 100);
|
||||
}
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
EnPeehat_Adult_SetStateDie(this);
|
||||
|
@ -270,7 +270,7 @@ void EnPoField_SetupDamage(EnPoField* this) {
|
||||
}
|
||||
this->collider.base.acFlags &= ~(AC_HIT | AC_ON);
|
||||
this->actor.speedXZ = 5.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 16);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 16);
|
||||
this->actionFunc = EnPoField_Damage;
|
||||
}
|
||||
|
||||
|
@ -309,7 +309,7 @@ void func_80AD95D8(EnPoSisters* this) {
|
||||
this->actor.speedXZ = 10.0f;
|
||||
}
|
||||
this->unk_199 &= ~0xB;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x10);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 16);
|
||||
this->actionFunc = func_80ADAAA4;
|
||||
}
|
||||
|
||||
|
@ -300,7 +300,7 @@ void func_80ADE28C(EnPoh* this) {
|
||||
}
|
||||
this->colliderCyl.base.acFlags &= ~AC_ON;
|
||||
this->actor.speedXZ = 5.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x10);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 16);
|
||||
this->actionFunc = func_80ADEECC;
|
||||
}
|
||||
|
||||
|
@ -729,12 +729,13 @@ void EnRd_SetupStunned(EnRd* this) {
|
||||
this->stunnedBySunsSong = true;
|
||||
this->sunsSongStunTimer = 600;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_LIGHT_ARROW_HIT);
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, -0x7F38, 0, 0xFF);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, COLORFILTER_INTENSITY_FLAG | 200,
|
||||
COLORFILTER_BUFFLAG_OPA, 255);
|
||||
} else if (this->damageEffect == REDEAD_DMGEFF_HOOKSHOT) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xC8, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
} else {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_LIGHT_ARROW_HIT);
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0xC8, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 200, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
}
|
||||
|
||||
EnRd_SetupAction(this, EnRd_Stunned);
|
||||
@ -744,7 +745,7 @@ void EnRd_Stunned(EnRd* this, PlayState* play) {
|
||||
if (this->stunnedBySunsSong && (this->sunsSongStunTimer != 0)) {
|
||||
this->sunsSongStunTimer--;
|
||||
if (this->sunsSongStunTimer >= 255) {
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0xC8, 0, 0xFF);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 200, COLORFILTER_BUFFLAG_OPA, 255);
|
||||
}
|
||||
|
||||
if (this->sunsSongStunTimer == 0) {
|
||||
@ -818,10 +819,10 @@ void EnRd_UpdateDamage(EnRd* this, PlayState* play) {
|
||||
this->sunsSongStunTimer = 0;
|
||||
|
||||
if (this->damageEffect == REDEAD_DMGEFF_FIRE_MAGIC) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
this->fireTimer = 40;
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
}
|
||||
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
|
@ -355,7 +355,7 @@ void func_80AE57F0(EnReeba* this, PlayState* play) {
|
||||
this->unk_276 = 14;
|
||||
this->actor.speedXZ = -8.0f;
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
this->actionfunc = func_80AE5854;
|
||||
}
|
||||
|
||||
@ -446,7 +446,7 @@ void func_80AE5A9C(EnReeba* this, PlayState* play) {
|
||||
void func_80AE5BC4(EnReeba* this, PlayState* play) {
|
||||
this->actor.speedXZ = -8.0f;
|
||||
this->actor.world.rot.y = this->actor.yawTowardsPlayer;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
this->unk_278 = 14;
|
||||
this->actor.flags &= ~ACTOR_FLAG_0;
|
||||
this->actionfunc = func_80AE5C38;
|
||||
@ -528,7 +528,8 @@ void func_80AE5EDC(EnReeba* this, PlayState* play) {
|
||||
if ((this->actor.colChkInfo.health > 1) && (this->unk_27E != 4)) {
|
||||
this->unk_27E = 4;
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
80);
|
||||
this->actionfunc = func_80AE58EC;
|
||||
break;
|
||||
}
|
||||
@ -536,7 +537,8 @@ void func_80AE5EDC(EnReeba* this, PlayState* play) {
|
||||
case 13: // hookshot/longshot
|
||||
if ((this->actor.colChkInfo.health > 2) && (this->unk_27E != 4)) {
|
||||
this->unk_27E = 4;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
80);
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->actionfunc = func_80AE58EC;
|
||||
break;
|
||||
@ -561,13 +563,14 @@ void func_80AE5EDC(EnReeba* this, PlayState* play) {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
this->unk_27C = 2;
|
||||
this->unk_27E = 2;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 80);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
this->actionfunc = func_80AE58EC;
|
||||
break;
|
||||
case 1: // unknown
|
||||
if (this->unk_27E != 4) {
|
||||
this->unk_27E = 4;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 80);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
80);
|
||||
this->actionfunc = func_80AE58EC;
|
||||
}
|
||||
break;
|
||||
|
@ -453,7 +453,8 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) {
|
||||
this->stopScroll = false;
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
this->invincibilityTimer = 40;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, this->invincibilityTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU,
|
||||
this->invincibilityTimer);
|
||||
if (this->hasPlayer) {
|
||||
EnRr_SetupReleasePlayer(this, play);
|
||||
} else if (this->actor.colChkInfo.health != 0) {
|
||||
@ -468,7 +469,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) {
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
this->dropType = RR_DROP_RANDOM_RUPEE;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
this->effectTimer = 20;
|
||||
EnRr_SetupStunned(this);
|
||||
return;
|
||||
@ -479,7 +480,8 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) {
|
||||
}
|
||||
if (this->actor.colorFilterTimer == 0) {
|
||||
this->effectTimer = 20;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU,
|
||||
80);
|
||||
}
|
||||
EnRr_SetupStunned(this);
|
||||
return;
|
||||
@ -488,12 +490,12 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) {
|
||||
if (this->actor.colChkInfo.health == 0) {
|
||||
this->dropType = RR_DROP_RUPEE_RED;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
EnRr_SetupStunned(this);
|
||||
return;
|
||||
case RR_DMG_STUN: // Boomerang and Hookshot
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
EnRr_SetupStunned(this);
|
||||
return;
|
||||
}
|
||||
|
@ -1574,7 +1574,7 @@ void func_80AEE568(EnRu1* this, PlayState* play) {
|
||||
if ((this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) && (this->actor.speedXZ == 0.0f) &&
|
||||
(this->actor.minVelocityY == 0.0f)) {
|
||||
func_80AEE02C(this);
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
this->action = 27;
|
||||
func_80AEADD8(this);
|
||||
} else if (this->actor.yDistToWater > 0.0f) {
|
||||
@ -1675,7 +1675,7 @@ void func_80AEE7C4(EnRu1* this, PlayState* play) {
|
||||
s32 func_80AEEAC8(EnRu1* this, PlayState* play) {
|
||||
if (this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) {
|
||||
func_80AEE02C(this);
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
this->action = 27;
|
||||
func_80AEADD8(this);
|
||||
return true;
|
||||
@ -1693,7 +1693,7 @@ void func_80AEEB24(EnRu1* this, PlayState* play) {
|
||||
}
|
||||
|
||||
void func_80AEEBB4(EnRu1* this, PlayState* play) {
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
}
|
||||
|
||||
void func_80AEEBD4(EnRu1* this, PlayState* play) {
|
||||
@ -1845,7 +1845,7 @@ void func_80AEF1F0(EnRu1* this, PlayState* play, UNK_TYPE arg2) {
|
||||
Message_CloseTextbox(play);
|
||||
SET_INFTABLE(INFTABLE_143);
|
||||
func_80AED6DC(this, play);
|
||||
func_8002F580(&this->actor, play);
|
||||
Actor_OfferCarry(&this->actor, play);
|
||||
this->action = 27;
|
||||
func_80AEADD8(this);
|
||||
}
|
||||
|
@ -392,7 +392,7 @@ s32 EnSb_UpdateDamage(EnSb* this, PlayState* play) {
|
||||
yawDiff = this->actor.yawTowardsPlayer - this->actor.shape.rot.y;
|
||||
if ((hitY < 30.0f) && (hitY > 10.0f) && (yawDiff >= -0x1FFF) && (yawDiff < 0x2000)) {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
tookDamage = true;
|
||||
}
|
||||
}
|
||||
@ -400,7 +400,7 @@ s32 EnSb_UpdateDamage(EnSb* this, PlayState* play) {
|
||||
case 2: // fire arrow, dins fire
|
||||
this->fire = 4;
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
tookDamage = true;
|
||||
break;
|
||||
case 1: // hookshot/longshot
|
||||
@ -410,7 +410,7 @@ s32 EnSb_UpdateDamage(EnSb* this, PlayState* play) {
|
||||
yawDiff = this->actor.yawTowardsPlayer - this->actor.shape.rot.y;
|
||||
if ((hitY < 30.0f) && (hitY > 10.0f) && (yawDiff >= -0x1FFF) && (yawDiff < 0x2000)) {
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
tookDamage = true;
|
||||
EnSb_SetupCooldown(this, 0);
|
||||
}
|
||||
|
@ -463,7 +463,8 @@ void EnSkb_CheckDamage(EnSkb* this, PlayState* play) {
|
||||
this->setColliderAT = false;
|
||||
if (this->actor.colChkInfo.damageEffect == 1) {
|
||||
if (this->actionState != SKB_BEHAVIOR_STUNNED) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA,
|
||||
80);
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
EnSkb_SetupStunned(this);
|
||||
}
|
||||
@ -480,7 +481,8 @@ void EnSkb_CheckDamage(EnSkb* this, PlayState* play) {
|
||||
}
|
||||
colorFilterDuration = 25;
|
||||
}
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, colorFilterDuration);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA,
|
||||
colorFilterDuration);
|
||||
if (!Actor_ApplyDamage(&this->actor)) {
|
||||
EnSkb_SetupDeath(this, play);
|
||||
return;
|
||||
|
@ -591,14 +591,14 @@ s32 EnSkj_CollisionCheck(EnSkj* this, PlayState* play) {
|
||||
yawDiff = this->actor.yawTowardsPlayer - this->actor.world.rot.y;
|
||||
if ((this->action == 2) || (this->action == 6)) {
|
||||
if ((yawDiff > 0x6000) || (yawDiff < -0x6000)) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
EnSkj_SetupDie(this);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
Actor_ApplyDamage(&this->actor);
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
|
||||
if (this->actor.colChkInfo.health != 0) {
|
||||
if (this->hitsUntilDodge != 0) {
|
||||
@ -1036,7 +1036,8 @@ void EnSkj_SariaSongTalk(EnSkj* this, PlayState* play) {
|
||||
EnSkj_SetupWaitInRange(this);
|
||||
} else {
|
||||
func_80AFFE24(this);
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, EnSkj_GetItemXzRange(this), EnSkj_GetItemYRange(this));
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, EnSkj_GetItemXzRange(this),
|
||||
EnSkj_GetItemYRange(this));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1050,7 +1051,7 @@ void func_80AFFE44(EnSkj* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
EnSkj_SetupPostSariasSong(this);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_HEART_PIECE, EnSkj_GetItemXzRange(this), EnSkj_GetItemYRange(this));
|
||||
Actor_OfferGetItem(&this->actor, play, GI_HEART_PIECE, EnSkj_GetItemXzRange(this), EnSkj_GetItemYRange(this));
|
||||
}
|
||||
}
|
||||
|
||||
@ -1528,7 +1529,7 @@ void EnSkj_WonOcarinaMiniGame(EnSkj* this, PlayState* play) {
|
||||
|
||||
void EnSkj_WaitToGiveReward(EnSkj* this, PlayState* play) {
|
||||
if ((Message_GetState(&play->msgCtx) == TEXT_STATE_DONE) && Message_ShouldAdvance(play)) {
|
||||
func_8002F434(&this->actor, play, sOcarinaGameRewards[gSaveContext.ocarinaGameRoundNum], 26.0f, 26.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, sOcarinaGameRewards[gSaveContext.ocarinaGameRoundNum], 26.0f, 26.0f);
|
||||
this->actionFunc = EnSkj_GiveOcarinaGameReward;
|
||||
}
|
||||
}
|
||||
@ -1538,7 +1539,7 @@ void EnSkj_GiveOcarinaGameReward(EnSkj* this, PlayState* play) {
|
||||
this->actor.parent = NULL;
|
||||
this->actionFunc = EnSkj_FinishOcarinaGameRound;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, sOcarinaGameRewards[gSaveContext.ocarinaGameRoundNum], 26.0f, 26.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, sOcarinaGameRewards[gSaveContext.ocarinaGameRoundNum], 26.0f, 26.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -291,7 +291,7 @@ void EnSsh_SetColliderScale(EnSsh* this, f32 scale, f32 radiusMod) {
|
||||
|
||||
s32 EnSsh_Damaged(EnSsh* this) {
|
||||
if ((this->stunTimer == 120) && (this->stateFlags & SSH_STATE_STUNNED)) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xC8, 0, this->stunTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, this->stunTimer);
|
||||
}
|
||||
if (DECR(this->stunTimer) != 0) {
|
||||
Math_SmoothStepToS(&this->maxTurnRate, 0x2710, 0xA, 0x3E8, 1);
|
||||
|
@ -450,7 +450,8 @@ s32 EnSt_CheckHitBackside(EnSt* this, PlayState* play) {
|
||||
if (this->stunTimer == 0) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
|
||||
this->stunTimer = 120;
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xC8, 0, this->stunTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA,
|
||||
this->stunTimer);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@ -459,7 +460,8 @@ s32 EnSt_CheckHitBackside(EnSt* this, PlayState* play) {
|
||||
this->gaveDamageSpinTimer = 1;
|
||||
Animation_ChangeByInfo(&this->skelAnime, sAnimationInfo, ENST_ANIM_3);
|
||||
this->takeDamageSpinTimer = this->skelAnime.animLength;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->takeDamageSpinTimer);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA,
|
||||
this->takeDamageSpinTimer);
|
||||
if (Actor_ApplyDamage(&this->actor)) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_STALTU_DAMAGE);
|
||||
return false;
|
||||
|
@ -250,7 +250,7 @@ void EnSth_GivePlayerItem(EnSth* this, PlayState* play) {
|
||||
break;
|
||||
}
|
||||
|
||||
func_8002F434(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, getItemId, 10000.0f, 50.0f);
|
||||
}
|
||||
|
||||
void EnSth_GiveReward(EnSth* this, PlayState* play) {
|
||||
|
@ -329,7 +329,7 @@ s32 func_80B0C9F0(EnSw* this, PlayState* play) {
|
||||
if ((this->collider.base.acFlags & AC_HIT) || phi_v1) {
|
||||
this->collider.base.acFlags &= ~AC_HIT;
|
||||
this->unk_392 = 0x10;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->unk_392);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_OPA, this->unk_392);
|
||||
if (Actor_ApplyDamage(&this->actor) != 0) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_STALTU_DAMAGE);
|
||||
return true;
|
||||
|
@ -365,7 +365,7 @@ void EnSyatekiMan_EndGame(EnSyatekiMan* this, PlayState* play) {
|
||||
this->getItemId = GI_RUPEE_PURPLE;
|
||||
}
|
||||
}
|
||||
func_8002F434(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
this->actionFunc = EnSyatekiMan_GivePrize;
|
||||
break;
|
||||
case SYATEKI_RESULT_ALMOST:
|
||||
@ -394,7 +394,7 @@ void EnSyatekiMan_GivePrize(EnSyatekiMan* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = EnSyatekiMan_FinishPrize;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, this->getItemId, 2000.0f, 1000.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -945,9 +945,9 @@ void EnTa_GiveItemInLonLonHouse(EnTa* this, PlayState* play) {
|
||||
}
|
||||
this->stateFlags &= ~TALON_STATE_FLAG_GIVING_MILK_REFILL;
|
||||
} else if (this->stateFlags & TALON_STATE_FLAG_GIVING_MILK_REFILL) {
|
||||
func_8002F434(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_BOTTLE_MILK_FULL, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOTTLE_MILK_FULL, 10000.0f, 50.0f);
|
||||
}
|
||||
this->stateFlags |= TALON_STATE_FLAG_TRACKING_PLAYER;
|
||||
}
|
||||
@ -957,7 +957,7 @@ void EnTa_TalkAfterCuccoGameFirstWon(EnTa* this, PlayState* play) {
|
||||
Message_CloseTextbox(play);
|
||||
this->stateFlags &= ~TALON_STATE_FLAG_GIVING_MILK_REFILL;
|
||||
EnTa_SetupAction(this, EnTa_GiveItemInLonLonHouse, EnTa_AnimRunToEnd);
|
||||
func_8002F434(&this->actor, play, GI_BOTTLE_MILK_FULL, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_BOTTLE_MILK_FULL, 10000.0f, 50.0f);
|
||||
}
|
||||
}
|
||||
|
||||
@ -980,7 +980,7 @@ void EnTa_WaitBuyMilkOrPlayCuccoGameResponse(EnTa* this, PlayState* play) {
|
||||
this->stateFlags |= TALON_STATE_FLAG_GIVING_MILK_REFILL;
|
||||
EnTa_SetupAction(this, EnTa_GiveItemInLonLonHouse, EnTa_AnimRunToEnd);
|
||||
Rupees_ChangeBy(-30);
|
||||
func_8002F434(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
@ -1077,7 +1077,7 @@ void EnTa_TalkAfterCuccoGameWon(EnTa* this, PlayState* play) {
|
||||
Message_CloseTextbox(play);
|
||||
this->stateFlags |= TALON_STATE_FLAG_GIVING_MILK_REFILL;
|
||||
EnTa_SetupAction(this, EnTa_GiveItemInLonLonHouse, EnTa_AnimRunToEnd);
|
||||
func_8002F434(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_MILK, 10000.0f, 50.0f);
|
||||
} else {
|
||||
Message_ContinueTextbox(play, 0x208A);
|
||||
EnTa_SetupAction(this, EnTa_TalkGeneralInLonLonHouse, EnTa_AnimRunToEnd);
|
||||
|
@ -135,7 +135,7 @@ void func_80B17934(EnTakaraMan* this, PlayState* play) {
|
||||
Rupees_ChangeBy(-10);
|
||||
this->unk_214 = 1;
|
||||
this->actor.parent = NULL;
|
||||
func_8002F434(&this->actor, play, GI_DOOR_KEY, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DOOR_KEY, 2000.0f, 1000.0f);
|
||||
this->actionFunc = func_80B17A6C;
|
||||
} else {
|
||||
Message_CloseTextbox(play);
|
||||
@ -160,7 +160,7 @@ void func_80B17A6C(EnTakaraMan* this, PlayState* play) {
|
||||
if (Actor_HasParent(&this->actor, play)) {
|
||||
this->actionFunc = func_80B17AC4;
|
||||
} else {
|
||||
func_8002F434(&this->actor, play, GI_DOOR_KEY, 2000.0f, 1000.0f);
|
||||
Actor_OfferGetItem(&this->actor, play, GI_DOOR_KEY, 2000.0f, 1000.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1211,7 +1211,7 @@ void func_80862154(EnTest* this) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_STAL_DAMAGE);
|
||||
this->unk_7C8 = 8;
|
||||
this->actor.speedXZ = -2.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
EnTest_SetupAction(this, func_808621D4);
|
||||
}
|
||||
|
||||
@ -1255,7 +1255,7 @@ void func_80862398(EnTest* this) {
|
||||
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_STAL_DAMAGE);
|
||||
this->unk_7C8 = 9;
|
||||
this->actor.speedXZ = -2.0f;
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
EnTest_SetupAction(this, func_80862418);
|
||||
}
|
||||
|
||||
@ -1298,9 +1298,9 @@ void EnTest_SetupStunned(EnTest* this) {
|
||||
this->actor.speedXZ = -4.0f;
|
||||
|
||||
if (this->lastDamageEffect == STALFOS_DMGEFF_LIGHT) {
|
||||
Actor_SetColorFilter(&this->actor, -0x8000, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
|
||||
if (this->lastDamageEffect == STALFOS_DMGEFF_FREEZE) {
|
||||
this->iceTimer = 36;
|
||||
|
@ -856,14 +856,14 @@ void EnTite_CheckDamage(Actor* thisx, PlayState* play) {
|
||||
// Stun if Tektite hit by nut, boomerang, hookshot, ice arrow or ice magic
|
||||
if ((thisx->colChkInfo.damageEffect == 1) || (thisx->colChkInfo.damageEffect == 0xF)) {
|
||||
if (this->action != TEKTITE_STUNNED) {
|
||||
Actor_SetColorFilter(thisx, 0, 0x78, 0, 0x50);
|
||||
Actor_SetColorFilter(thisx, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
Actor_ApplyDamage(thisx);
|
||||
EnTite_SetupStunned(this);
|
||||
}
|
||||
// Otherwise apply damage and handle death where necessary
|
||||
} else {
|
||||
if ((thisx->colorFilterTimer == 0) || ((thisx->colorFilterParams & 0x4000) == 0)) {
|
||||
Actor_SetColorFilter(thisx, 0x4000, 0xFF, 0, 8);
|
||||
Actor_SetColorFilter(thisx, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8);
|
||||
Actor_ApplyDamage(thisx);
|
||||
}
|
||||
if (thisx->colChkInfo.health == 0) {
|
||||
|
@ -588,9 +588,9 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) {
|
||||
func_800F5ACC(NA_BGM_MINI_BOSS);
|
||||
if (this->actor.colChkInfo.damageEffect == 1) {
|
||||
if (sAlpha == 255) {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, 80);
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0, 0xFF, 0x2000, 0x50);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU, 80);
|
||||
}
|
||||
} else {
|
||||
this->actor.flags &= ~ACTOR_FLAG_0;
|
||||
@ -604,9 +604,9 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) {
|
||||
this->stateFlags3 |= PLAYER_STATE3_0;
|
||||
sActionState = ENTORCH2_DAMAGE;
|
||||
if (sAlpha == 255) {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 12);
|
||||
} else {
|
||||
Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0xC);
|
||||
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_XLU, 12);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user