Importing Sound Effects from MM3D (#179)

* Add sfx & update Audio_PlayActorSound2

* more sfx

* Match Enemies sfxId

* Update with PR

* Update sfx for new pr

* Fix commit
This commit is contained in:
engineer124 2021-06-12 11:08:47 +10:00 committed by GitHub
parent 54aef44a9e
commit c203b9b606
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
34 changed files with 2803 additions and 135 deletions

View File

@ -1541,7 +1541,7 @@ void CollisionCheck_SpawnShieldParticlesMetalSound(GlobalContext* globalCtx, Vec
void CollisionCheck_SpawnShieldParticlesMetal2(GlobalContext* globalCtx, Vec3f* v);
void CollisionCheck_SpawnShieldParticlesWood(GlobalContext* globalCtx, Vec3f* v, Vec3f* pos);
s32 CollisionCheck_CylSideVsLineSeg(f32 radius, f32 height, f32 offset, Vec3f* actorPos, Vec3f* itemPos, Vec3f* itemProjPos, Vec3f* out1, Vec3f* out2);
void func_800E8EA0(GlobalContext* globalCtx, Actor* actor, u16 param_3);
void func_800E8EA0(GlobalContext* globalCtx, Actor* actor, u16 textId);
s32 nop_800E8ED0(UNK_TYPE4 param_1);
void nop_800E8EE0(UNK_TYPE4 param_1);
s32 nop_800E8EEC(UNK_TYPE4 param_1);
@ -2882,7 +2882,7 @@ void func_8014ADBC(GlobalContext* globalCtx, UNK_PTR puParm2);
void func_80150D08(GlobalContext* globalCtx, u32 uParm2);
// void func_801514B0(void);
void func_801518B0(GlobalContext* globalCtx, u32 uParm2, Actor* uParm3);
void func_80151938(GlobalContext* globalCtx, u16 param_2);
void func_80151938(GlobalContext* globalCtx, u16 textId);
void func_80151A68(GlobalContext* globalCtx, u16 param_2);
void func_80151BB4(GlobalContext* globalCtx, u32 uParm2);
// void func_80151C9C(void);
@ -3844,8 +3844,8 @@ void func_8019E014(void);
// void func_8019EB2C(void);
// void func_8019F024(void);
// void func_8019F05C(void);
void play_sound(u16 param_1);
void func_8019F128(u16 param_1);
void play_sound(u16 sfxId);
void func_8019F128(u16 sfxId);
// void func_8019F170(void);
void func_8019F1C0(Vec3f* pos, u16 sfxId);
void func_8019F208(void);
@ -3861,7 +3861,7 @@ void func_8019F230(void);
// void func_8019F780(void);
// void func_8019F7D8(void);
// void func_8019F830(void);
void func_8019F88C(Vec3f* arg0, UNK_TYPE arg1, UNK_TYPE arg2);
void func_8019F88C(Vec3f* arg0, u16 sfxId, UNK_TYPE arg2);
// void func_8019F900(void);
// void func_8019FA18(void);
void func_8019FAD8(Vec3f* param_1, u16 param_2, f32 param_3);

2662
include/sfx.h Normal file

File diff suppressed because it is too large Load Diff

View File

@ -17,6 +17,7 @@
#include <xstdio.h>
#include <unk.h>
#include <sfx.h>
#include <color.h>
#include <ichain.h>

View File

@ -1,9 +1,9 @@
#include <ultra64.h>
#include <global.h>
void func_800E8EA0(GlobalContext* globalCtx, Actor* actor, u16 param_3) {
func_80151938(globalCtx, param_3);
actor->textId = param_3;
void func_800E8EA0(GlobalContext* globalCtx, Actor* actor, u16 textId) {
func_80151938(globalCtx, textId);
actor->textId = textId;
}
s32 nop_800E8ED0(UNK_TYPE4 param_1) {

View File

@ -1486,9 +1486,9 @@ void CollisionCheck_HitSolid(GlobalContext* globalCtx, ColliderInfo* info, Colli
if (flags == TOUCH_SFX_NORMAL && collider->colType != COLTYPE_METAL) {
EffectSsHitMark_SpawnFixedScale(globalCtx, 0, hitPos);
if (collider->actor == NULL) {
play_sound(0x1806);
play_sound(NA_SE_IT_SHIELD_BOUND);
} else {
func_8019F1C0(&collider->actor->projectedPos, 0x1806);
func_8019F1C0(&collider->actor->projectedPos, NA_SE_IT_SHIELD_BOUND);
}
} else if (flags == TOUCH_SFX_NORMAL) {
EffectSsHitMark_SpawnFixedScale(globalCtx, 3, hitPos);
@ -1500,16 +1500,16 @@ void CollisionCheck_HitSolid(GlobalContext* globalCtx, ColliderInfo* info, Colli
} else if (flags == TOUCH_SFX_HARD) {
EffectSsHitMark_SpawnFixedScale(globalCtx, 0, hitPos);
if (collider->actor == NULL) {
play_sound(0x1806);
play_sound(NA_SE_IT_SHIELD_BOUND);
} else {
func_8019F1C0(&collider->actor->projectedPos, 0x1806);
func_8019F1C0(&collider->actor->projectedPos, NA_SE_IT_SHIELD_BOUND);
}
} else if (flags == TOUCH_SFX_WOOD) {
EffectSsHitMark_SpawnFixedScale(globalCtx, 1, hitPos);
if (collider->actor == NULL) {
play_sound(0x1837);
play_sound(NA_SE_IT_REFLECTION_WOOD);
} else {
func_8019F1C0(&collider->actor->projectedPos, 0x1837);
func_8019F1C0(&collider->actor->projectedPos, NA_SE_IT_REFLECTION_WOOD);
}
}
}
@ -1520,9 +1520,9 @@ void CollisionCheck_HitSolid(GlobalContext* globalCtx, ColliderInfo* info, Colli
s32 CollisionCheck_SwordHitAudio(Collider* at, ColliderInfo* acInfo) {
if (at->actor != NULL && at->actor->category == ACTORCAT_PLAYER) {
if (acInfo->elemType == ELEMTYPE_UNK0) {
func_8019F1C0(&at->actor->projectedPos, 0x1811);
func_8019F1C0(&at->actor->projectedPos, NA_SE_IT_SWORD_STRIKE);
} else if (acInfo->elemType == ELEMTYPE_UNK1) {
func_8019F1C0(&at->actor->projectedPos, 0x1824);
func_8019F1C0(&at->actor->projectedPos, NA_SE_IT_SWORD_STRIKE_HARD);
} else if (acInfo->elemType == ELEMTYPE_UNK2) {
func_8019F1C0(&at->actor->projectedPos, 0);
} else if (acInfo->elemType == ELEMTYPE_UNK3) {
@ -1566,7 +1566,7 @@ void CollisionCheck_HitEffects(GlobalContext* globalCtx, Collider* at, ColliderI
} else if (sHitInfo[ac->colType].effect == HIT_WOOD) {
if (at->actor == NULL) {
CollisionCheck_SpawnShieldParticles(globalCtx, hitPos);
play_sound(0x1837);
play_sound(NA_SE_IT_REFLECTION_WOOD);
} else {
CollisionCheck_SpawnShieldParticlesWood(globalCtx, hitPos, &at->actor->projectedPos);
}
@ -1579,9 +1579,9 @@ void CollisionCheck_HitEffects(GlobalContext* globalCtx, Collider* at, ColliderI
} else {
EffectSsHitMark_SpawnFixedScale(globalCtx, 0, hitPos);
if (ac->actor == NULL) {
play_sound(0x1806);
play_sound(NA_SE_IT_SHIELD_BOUND);
} else {
func_8019F1C0(&ac->actor->projectedPos, 0x1806);
func_8019F1C0(&ac->actor->projectedPos, NA_SE_IT_SHIELD_BOUND);
}
}
}
@ -3860,7 +3860,7 @@ void CollisionCheck_SpawnShieldParticles(GlobalContext* globalCtx, Vec3f* v) {
*/
void CollisionCheck_SpawnShieldParticlesMetal(GlobalContext* globalCtx, Vec3f* v) {
CollisionCheck_SpawnShieldParticles(globalCtx, v);
play_sound(0x1808);
play_sound(NA_SE_IT_SHIELD_REFLECT_SW);
}
/**
@ -3868,7 +3868,7 @@ void CollisionCheck_SpawnShieldParticlesMetal(GlobalContext* globalCtx, Vec3f* v
*/
void CollisionCheck_SpawnShieldParticlesMetalSound(GlobalContext* globalCtx, Vec3f* v, Vec3f* pos) {
CollisionCheck_SpawnShieldParticles(globalCtx, v);
func_8019F1C0(pos, 0x1808);
func_8019F1C0(pos, NA_SE_IT_SHIELD_REFLECT_SW);
}
/**
@ -3908,7 +3908,7 @@ void CollisionCheck_SpawnShieldParticlesWood(GlobalContext* globalCtx, Vec3f* v,
shieldParticleInitWood.lightPoint.z = shieldParticleInitWood.position.z;
Effect_Add(globalCtx, &effectIndex, 3, 0, 1, &shieldParticleInitWood);
func_8019F1C0(pos, 0x1837);
func_8019F1C0(pos, NA_SE_IT_REFLECTION_WOOD);
}
/**

View File

@ -794,7 +794,7 @@ void EffectSsEnIce_SpawnFlyingVec3f(GlobalContext* globalCtx, Actor* actor, Vec3
initParams.scale = scale;
if (actor != NULL) {
Audio_PlayActorSound2(actor, 0x874);
Audio_PlayActorSound2(actor, NA_SE_PL_FREEZE_S);
}
EffectSs_Spawn(globalCtx, EFFECT_SS_EN_ICE, 80, &initParams);
@ -895,7 +895,7 @@ void EffectSsEnFire_SpawnVec3f(GlobalContext* globalCtx, Actor* actor, Vec3f* po
initParams.bodyPart = bodyPart;
if (actor != NULL) {
Audio_PlayActorSound2(actor, 0x2822);
Audio_PlayActorSound2(actor, NA_SE_EV_FLAME_IGNITION);
}
EffectSs_Spawn(globalCtx, EFFECT_SS_EN_FIRE, 128, &initParams);
@ -915,7 +915,7 @@ void EffectSsEnFire_SpawnVec3s(GlobalContext* globalCtx, Actor* actor, Vec3s* po
initParams.bodyPart = bodyPart;
if (actor != NULL) {
Audio_PlayActorSound2(actor, 0x2822);
Audio_PlayActorSound2(actor, NA_SE_EV_FLAME_IGNITION);
}
EffectSs_Spawn(globalCtx, EFFECT_SS_EN_FIRE, 128, &initParams);

View File

@ -598,7 +598,7 @@ void EnItem00_Update(Actor* thisx, GlobalContext* globalCtx) {
}
if ((this->actor.params <= ITEM00_RUPEE_RED) || (this->actor.params == ITEM00_RUPEE_ORANGE)) {
play_sound(0x4803);
play_sound(NA_SE_SY_GET_RUPY);
} else if (getItemId != GI_NONE) {
if (Actor_HasParent(&this->actor, globalCtx)) {
Actor_SetCollectibleFlag(globalCtx, this->collectibleFlag);
@ -606,7 +606,7 @@ void EnItem00_Update(Actor* thisx, GlobalContext* globalCtx) {
}
return;
} else {
play_sound(0x4824);
play_sound(NA_SE_SY_GET_ITEM);
}
Actor_SetCollectibleFlag(globalCtx, this->collectibleFlag);
@ -872,7 +872,7 @@ EnItem00* Item_DropCollectible(GlobalContext* globalCtx, Vec3f* spawnPos, u32 pa
spawnedActor = Actor_Spawn(&globalCtx->actorCtx, globalCtx, ACTOR_EN_ELF, spawnPos->x, spawnPos->y + 40.0f,
spawnPos->z, 0, 0, 0, ((((param7F00 >> 8) & 0x7F) << 9) & 0xFE00) | 0x102);
if (!Actor_GetCollectibleFlag(globalCtx, (param7F00 >> 8) & 0x7F)) {
func_800F0568(globalCtx, spawnPos, 0x28, 0x28E7);
func_800F0568(globalCtx, spawnPos, 40, NA_SE_EV_BUTTERFRY_TO_FAIRY);
}
} else {
spawnedActor =
@ -880,7 +880,7 @@ EnItem00* Item_DropCollectible(GlobalContext* globalCtx, Vec3f* spawnPos, u32 pa
spawnPos->z, 0, 0, 0, ((((param7F00 >> 8) & 0x7F) & 0x7F) << 9) | 7);
if (param20000 == 0) {
if (!Actor_GetCollectibleFlag(globalCtx, (param7F00 >> 8) & 0x7F)) {
func_800F0568(globalCtx, spawnPos, 0x28, 0x28E7);
func_800F0568(globalCtx, spawnPos, 40, NA_SE_EV_BUTTERFRY_TO_FAIRY);
}
}
}
@ -947,7 +947,7 @@ Actor* Item_DropCollectible2(GlobalContext* globalCtx, Vec3f* spawnPos, u32 para
spawnPos->z, 0, 0, 0, ((((param7F00 >> 8) & 0x7F) & 0x7F) << 9) | 7);
}
if (Actor_GetCollectibleFlag(globalCtx, (param7F00 >> 8) & 0x7F) == 0) {
func_800F0568(globalCtx, spawnPos, 0x28, 0x28E7);
func_800F0568(globalCtx, spawnPos, 40, NA_SE_EV_BUTTERFRY_TO_FAIRY);
}
} else {
params = func_800A7650(params);
@ -1105,7 +1105,7 @@ void Item_DropCollectibleRandom(GlobalContext* globalCtx, Actor* fromActor, Vec3
if (gSaveContext.health < 0x11) {
Actor_Spawn(&globalCtx->actorCtx, globalCtx, ACTOR_EN_ELF, spawnPos->x, spawnPos->y + 40.0f,
spawnPos->z, 0, 0, 0, 2);
func_800F0568(globalCtx, spawnPos, 0x28, 0x28E7);
func_800F0568(globalCtx, spawnPos, 40, NA_SE_EV_BUTTERFRY_TO_FAIRY);
return;
}

View File

@ -648,8 +648,8 @@ void func_801000CC(u16 sfxId) {
func_8019F128(sfxId);
}
void func_801000F4(s32 a0, u16 a1) {
func_8019F1C0(a0, a1);
void func_801000F4(s32 a0, u16 sfxId) {
func_8019F1C0(a0, sfxId);
}
void Lib_Vec3f_TranslateAndRotateY(Vec3f* translation, s16 a, Vec3f* src, Vec3f* dst) {

View File

@ -150,7 +150,7 @@ void ArmsHook_Shoot(ArmsHook* this, GlobalContext* globalCtx) {
}
}
this->timer = 0;
func_8019F1C0(&this->actor.projectedPos, 0x1814);
func_8019F1C0(&this->actor.projectedPos, NA_SE_IT_HOOKSHOT_STICK_CRE);
return;
}
@ -262,10 +262,10 @@ void ArmsHook_Shoot(ArmsHook* this, GlobalContext* globalCtx) {
}
}
func_808C1154(this);
func_8019F1C0(&this->actor.projectedPos, 0x1829);
func_8019F1C0(&this->actor.projectedPos, NA_SE_IT_HOOKSHOT_STICK_OBJ);
} else {
CollisionCheck_SpawnShieldParticlesMetal(globalCtx, &this->actor.world.pos);
func_8019F1C0(&this->actor.projectedPos, 0x1813);
func_8019F1C0(&this->actor.projectedPos, NA_SE_IT_HOOKSHOT_REFLECT);
}
} else {
if (CHECK_BTN_ANY(globalCtx->state.input[0].press.button,

View File

@ -129,7 +129,7 @@ void BgCtowerGear_Splash(BgCtowerGear* this, GlobalContext* globalCtx) {
}
}
}
Audio_PlayActorSound2(&this->dyna.actor, 0x291B);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_WATERWHEEL_LEVEL);
}
}
@ -177,7 +177,7 @@ void BgCtowerGear_Update(Actor* thisx, GlobalContext* globalCtx) {
this->dyna.actor.shape.rot.x -= 0x1F4;
} else if (type == CENTER_COG) {
this->dyna.actor.shape.rot.y += 0x1F4;
func_800B9010(&this->dyna.actor, 0x2085);
func_800B9010(&this->dyna.actor, NA_SE_EV_WINDMILL_LEVEL - SFX_FLAG);
} else if (type == WATER_WHEEL) {
this->dyna.actor.shape.rot.z -= 0x1F4;
BgCtowerGear_Splash(this, globalCtx);

View File

@ -110,7 +110,7 @@ void BgCtowerRot_CorridorRotate(BgCtowerRot* this, GlobalContext* globalCtx) {
func_800DFAC8(globalCtx->cameraPtrs[0], 0x11);
this->dyna.actor.shape.rot.z = rotZ * 16.384f;
if (globalCtx->csCtx.frames == 0x84) {
play_sound(0x4859);
play_sound(NA_SE_SY_SPIRAL_DASH);
}
}
@ -120,12 +120,12 @@ void BgCtowerRot_DoorDoNothing(BgCtowerRot* this, GlobalContext* globalCtx) {
void BgCtowerRot_DoorClose(BgCtowerRot* this, GlobalContext* globalCtx) {
if (!Math_SmoothStepToF(&this->timer, 0.0f, 0.1f, 15.0f, 0.1f)) {
if (this->dyna.actor.params == MAIN_DOOR) {
Audio_PlayActorSound2(&this->dyna.actor, 0x2893);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_STONEDOOR_STOP);
ActorCutscene_Stop(this->dyna.actor.cutscene);
}
this->actionFunc = BgCtowerRot_DoorDoNothing;
} else if (this->dyna.actor.params == 1) {
func_800B9010(&this->dyna.actor, 0x201E);
func_800B9010(&this->dyna.actor, NA_SE_EV_STONE_STATUE_OPEN - SFX_FLAG);
}
this->dyna.actor.world.pos.x =
this->dyna.actor.home.pos.x + (Math_SinS(this->dyna.actor.world.rot.y) * this->timer);

View File

@ -106,7 +106,7 @@ void func_80B6DD9C(BgHakaCurtain* this, GlobalContext* globalCtx) {
func_80B6DE80(this);
return;
}
func_800B9010(&this->dyna.actor, 0x218D);
func_800B9010(&this->dyna.actor, NA_SE_EV_CURTAIN_DOWN - SFX_FLAG);
}
void func_80B6DE80(BgHakaCurtain* this) {

View File

@ -190,15 +190,15 @@ void BgKin2Fence_HandleMaskCode(BgKin2Fence* this, GlobalContext* globalCtx) {
if (hitMask >= 0) {
nextMask = (s8)gSaveContext.spiderHouseMaskOrder[this->masksHit];
if (hitMask == nextMask) {
play_sound(0x4807);
play_sound(NA_SE_SY_TRE_BOX_APPEAR);
this->masksHit += 1;
BgKin2Fence_SpawnEyeSparkles(this, globalCtx, nextMask);
} else {
play_sound(0x4806);
play_sound(NA_SE_SY_ERROR);
this->masksHit = 0;
}
}
this->collider.base.acFlags &= 0xFFFD;
this->collider.base.acFlags &= ~2;
this->cooldownTimer = 5;
if (this->masksHit > 5) {
BgKin2Fence_SetupPlayOpenCutscene(this);

View File

@ -109,7 +109,7 @@ void BgLadder_ActionStartCutscene(BgLadder* this, GlobalContext* globalCtx) {
if (ActorCutscene_GetCanPlayNext(this->dyna.actor.cutscene)) {
ActorCutscene_StartAndSetUnkLinkFields(this->dyna.actor.cutscene, &this->dyna.actor);
this->dyna.actor.draw = BgLadder_Draw;
Audio_PlayActorSound2(&this->dyna.actor, 0x2997);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_SECRET_LADDER_APPEAR);
this->action = BgLadder_ActionFadeIn;
} else {
ActorCutscene_SetIntentToPlay(this->dyna.actor.cutscene);

View File

@ -58,7 +58,7 @@ void BgTobira01_Open(BgTobira01* this, GlobalContext* globalCtx) {
if (this->timer != prevTimer) {
if (1) {}
Audio_PlayActorSound2(&this->dyna.actor, 0x2143);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_STONEDOOR_OPEN_S - SFX_FLAG);
this->dyna.actor.world.pos.y = (this->yOffset = (this->timer * (5.0f / 3.0f)) + this->dyna.actor.home.pos.y);
this->timer2 = 180;
}

View File

@ -111,7 +111,7 @@ void DoorAna_WaitClosed(DoorAna* this, GlobalContext* globalCtx) {
if (grottoIsOpen) {
this->actor.params &= ~DOORANA_TYPE_BITRANGE;
DoorAna_SetupAction(this, DoorAna_WaitOpen);
play_sound(0x4802); // CORRECT_CHIME sfx
play_sound(NA_SE_SY_CORRECT_CHIME);
}
func_800B8C50(&this->actor, globalCtx);

View File

@ -86,12 +86,12 @@ void EnCha_Ring(EnCha* this, GlobalContext* globalCtx) {
void EnCha_Idle(EnCha* this, GlobalContext* globalCtx) {
if (gSaveContext.weekEventReg[60] & 4) {
Audio_PlayActorSound2(&this->actor, 0x289E);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_DOOR_BELL);
gSaveContext.weekEventReg[60] &= 0xFB;
this->actor.home.rot.z = 0x7D0;
}
if (this->collider.base.acFlags & AC_HIT) {
Audio_PlayActorSound2(&this->actor, 0x289E);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_DOOR_BELL);
this->actor.home.rot.z = 0x7D0;
if (!(gSaveContext.weekEventReg[51] & 4)) {
gSaveContext.weekEventReg[51] |= 4;

View File

@ -76,7 +76,7 @@ void EnDyExtra_Update(Actor* thisx, GlobalContext* globalCtx) {
EnDyExtra* this = THIS;
DECR(this->unk14C);
Audio_PlayActorSound2(&this->actor, 0xC4U);
Audio_PlayActorSound2(&this->actor, NA_SE_PL_SPIRAL_HEAL_BEAM - SFX_FLAG);
this->actionFunc(this, globalCtx);
Actor_SetVelocityAndMoveYRotationAndGravity(&this->actor);
}

View File

@ -132,7 +132,7 @@ void EnEncount2_Popped(EnEncount2* this, GlobalContext* globalCtx) {
EnEncount2_InitParticles(this, &curPos, 10);
}
Audio_PlayActorSound2(&this->dyna.actor, 0x2949); // NA_SE_EV_MUJURA_BALLOON_BROKEN
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_MUJURA_BALLOON_BROKEN);
this->deathTimer = 30;
this->actionFunc = EnEncount2_Die;
}

View File

@ -162,7 +162,7 @@ void EnFg_Idle(EnFg* this, GlobalContext* globalCtx) {
switch (EnFg_GetDamageEffect(this)) {
case FG_DMGEFFECT_DEKUSTICK:
this->actor.flags &= ~1;
Audio_PlayActorSound2(&this->actor, 0x28E4);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FROG_CRY_1);
this->skelAnime.animPlaybackSpeed = 0.0f;
this->actor.shape.shadowDraw = NULL;
this->actor.scale.x *= 1.5f;
@ -188,8 +188,8 @@ void EnFg_Idle(EnFg* this, GlobalContext* globalCtx) {
break;
case FG_DMGEFFECT_EXPLOSION:
this->actor.flags &= ~1;
Audio_PlayActorSound2(&this->actor, 0x28E3);
if(1) {}
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FROG_CRY_0);
if (1) {}
this->actor.params = FG_BLACK;
this->skelAnime.animPlaybackSpeed = 0.0f;
ac = this->collider.base.ac;
@ -204,7 +204,7 @@ void EnFg_Idle(EnFg* this, GlobalContext* globalCtx) {
break;
default:
if (DECR(this->timer) == 0) {
Audio_PlayActorSound2(&this->actor, 0x28B1);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FROG_JUMP);
EnFg_UpdateAnimation(&this->skelAnime, 3);
this->actor.velocity.y = 10.0f;
this->timer = Rand_S16Offset(30, 30);
@ -239,7 +239,7 @@ void EnFg_Jump(EnFg* this, GlobalContext* globalCtx) {
break;
case FG_DMGEFFECT_EXPLOSION:
this->actor.flags &= ~1;
Audio_PlayActorSound2(&this->actor, 0x28E3);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FROG_CRY_0);
EnFg_UpdateAnimation(&this->skelAnime, 0);
this->actor.params = FG_BLACK;
this->skelAnime.animPlaybackSpeed = 0.0f;

View File

@ -335,7 +335,7 @@ void EnGinkoMan_WaitForDialogueInput(EnGinkoMan* this, GlobalContext* globalCtx)
case 0x44E: // "...So, what'll it be?
if (globalCtx->msgCtx.choiceIndex == GINKOMAN_CHOICE_YES) {
if ((gSaveContext.roomInf[127][0] & 0xFFFF) >= 5000) {
play_sound(0x4806); // NA_SE_SY_ERROR
play_sound(NA_SE_SY_ERROR);
func_801518B0(globalCtx, 0x45F, &this->actor);
this->curTextId = 0x45F; // bank full, cannot accept more
} else {
@ -344,7 +344,7 @@ void EnGinkoMan_WaitForDialogueInput(EnGinkoMan* this, GlobalContext* globalCtx)
func_801518B0(globalCtx, 0x44F, &this->actor);
this->curTextId = 0x44F; // "All right! so..."
} else {
play_sound(0x4806); // NA_SE_SY_ERROR
play_sound(NA_SE_SY_ERROR);
func_801518B0(globalCtx, 0x458, &this->actor);
this->curTextId = 0x458; // you haven't even gotten a single rup
}
@ -358,7 +358,7 @@ void EnGinkoMan_WaitForDialogueInput(EnGinkoMan* this, GlobalContext* globalCtx)
case 0x452: // Really? are you really depositing rupees?
if (globalCtx->msgCtx.choiceIndex == GINKOMAN_CHOICE_YES) {
if (gSaveContext.rupees < globalCtx->msgCtx.bankRupeesSelected) {
play_sound(0x4806); // NA_SE_SY_ERROR
play_sound(NA_SE_SY_ERROR);
func_800BDC5C(&this->skelAnime, animations, GINKO_SITTING);
func_801518B0(globalCtx, 0x459, &this->actor);
this->curTextId = 0x459; // HEY you dont have that much
@ -420,13 +420,13 @@ void EnGinkoMan_WaitForDialogueInput(EnGinkoMan* this, GlobalContext* globalCtx)
if (globalCtx->msgCtx.choiceIndex == GINKOMAN_CHOICE_YES) {
if ((s32)((gSaveContext.roomInf[127][0] & 0xFFFF)) <
((s32)(globalCtx->msgCtx.bankRupeesSelected + this->serviceFee))) {
play_sound(0x4806); // NA_SE_SY_ERROR
play_sound(NA_SE_SY_ERROR);
func_800BDC5C(&this->skelAnime, animations, GINKO_FLOORSMACKING);
func_801518B0(globalCtx, 0x476, &this->actor);
this->curTextId = 0x476; // you dont have enough deposited to withdrawl
} else if (D_801C1E2C[(gSaveContext.inventory.upgrades & gUpgradeMasks[4]) >> gUpgradeShifts[4]] < (globalCtx->msgCtx.bankRupeesSelected + gSaveContext.rupees)) {
// check if wallet is big enough
play_sound(0x4806); // NA_SE_SY_ERROR
play_sound(NA_SE_SY_ERROR);
func_801518B0(globalCtx, 0x475, &this->actor);
this->curTextId = 0x475; // You can't hold that many in your wallet
} else {
@ -517,7 +517,7 @@ void EnGinkoMan_Dialogue(EnGinkoMan* this, GlobalContext* globalCtx) {
if ((this->skelAnime.animCurrentSeg == object_ginko_floorsmacking_anim) &&
func_801378B8(&this->skelAnime, this->skelAnime.animFrameCount)) {
Audio_PlayActorSound2(&this->actor, 0x2992); // NA_SE_EV_BANK_MAN_HAND_HIT
Audio_PlayActorSound2(&this->actor, NA_SE_EV_BANK_MAN_HAND_HIT);
}
}
@ -585,7 +585,7 @@ void EnGinkoMan_SetupStamp(EnGinkoMan* this) {
void EnGinkoMan_Stamp(EnGinkoMan* this, GlobalContext* globalCtx) {
if ((this->curTextId == 0x464) // "Hey, relax! It doesn't leave any marks, and it's not gonna hurt."
&& (func_801378B8(&this->skelAnime, 10.0f))) {
Audio_PlayActorSound2(&this->actor, 0x2993); // NA_SE_EV_HANKO "stamp"
Audio_PlayActorSound2(&this->actor, NA_SE_EV_HANKO); // "stamp"
}
if (func_801378B8(&this->skelAnime, this->skelAnime.animFrameCount)) {

View File

@ -320,15 +320,15 @@ void func_808F374C(EnIn* this, GlobalContext* globalCtx) {
if (this->skelAnime.animCurrentSeg == &D_06016484 || this->skelAnime.animCurrentSeg == &D_060170DC) {
if (func_801378B8(&this->skelAnime, 8.0f)) {
func_8019F88C(&this->actor.projectedPos, 0x6856, 2);
func_8019F88C(&this->actor.projectedPos, NA_SE_VO_IN_LASH_0, 2);
if (Rand_ZeroOne() < 0.3f) {
func_8019F1C0(&this->actor.projectedPos, 0x1844);
func_8019F1C0(&this->actor.projectedPos, NA_SE_IT_INGO_HORSE_NEIGH);
}
func_8019F1C0(&this->actor.projectedPos, 0x181E);
func_8019F1C0(&this->actor.projectedPos, NA_SE_IT_LASH);
}
}
if (this->skelAnime.animCurrentSeg == &D_060198A8 && func_801378B8(&this->skelAnime, 20.0f)) {
Audio_PlayActorSound2(&this->actor, 0x6854);
Audio_PlayActorSound2(&this->actor, NA_SE_VO_IN_CRY_0);
}
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime)) {
this->unk486 = this->unk488 %= 8;
@ -390,9 +390,9 @@ void func_808F39DC(EnIn* this, GlobalContext* globalCtx) {
this->actor.textId = textId;
this->actionFunc = func_808F395C;
if (this->unk4B0 == 2) {
Audio_PlayActorSound2(&this->actor, 0x6855);
Audio_PlayActorSound2(&this->actor, NA_SE_VO_IN_LOST);
} else {
Audio_PlayActorSound2(&this->actor, 0x687C);
Audio_PlayActorSound2(&this->actor, NA_SE_VO_IN_JOY0);
}
}
@ -574,10 +574,10 @@ void func_808F4054(GlobalContext* globalCtx, EnIn* this, s32 arg2, u16 textId) {
}
}
void func_808F4108(EnIn* this, GlobalContext* globalCtx, u16 arg2) {
void func_808F4108(EnIn* this, GlobalContext* globalCtx, u16 textId) {
func_800B86C8(&this->actor, globalCtx, &this->unk4A4->actor);
this->actor.textId = 0;
this->unk4A4->actor.textId = arg2;
this->unk4A4->actor.textId = textId;
this->unk4A4->unk48C = 2;
this->unk48C = 0;
}
@ -597,7 +597,7 @@ s32 func_808F4150(GlobalContext* globalCtx, EnIn* this, s32 arg2, MessageContext
func_800E8EA0(globalCtx, &this->actor, 0x3475);
}
} else {
play_sound(0x4806);
play_sound(NA_SE_SY_ERROR);
func_800E8EA0(globalCtx, &this->actor, 0x3473);
}
} else {
@ -629,7 +629,7 @@ s32 func_808F4270(GlobalContext* globalCtx, EnIn* this, s32 arg2, MessageContext
}
}
} else {
play_sound(0x4806);
play_sound(NA_SE_SY_ERROR);
if (arg4 != 0) {
func_800E8EA0(globalCtx, &this->actor, 0x3473);
} else {
@ -769,7 +769,7 @@ s32 func_808F4414(GlobalContext* globalCtx, EnIn* this, s32 arg2) {
ret = false;
}
} else {
play_sound(0x4806);
play_sound(NA_SE_SY_ERROR);
func_800E8EA0(globalCtx, &this->actor, 0x3468);
ret = false;
}
@ -1021,7 +1021,7 @@ s32 func_808F4414(GlobalContext* globalCtx, EnIn* this, s32 arg2) {
ret = false;
}
} else {
play_sound(0x4806);
play_sound(NA_SE_SY_ERROR);
func_800E8EA0(globalCtx, &this->actor, 0x3468);
ret = false;
}
@ -1346,9 +1346,9 @@ void func_808F5C98(EnIn* this, GlobalContext* globalCtx) {
}
if (this->unk4A8 == 2) {
if (this->unk4B0 == 2) {
Audio_PlayActorSound2(&this->actor, 0x6855);
Audio_PlayActorSound2(&this->actor, NA_SE_VO_IN_LOST);
} else {
Audio_PlayActorSound2(&this->actor, 0x687C);
Audio_PlayActorSound2(&this->actor, NA_SE_VO_IN_JOY0);
}
this->unk4A8 = 3;
} else if (this->unk4A8 < 3) {

View File

@ -61,8 +61,8 @@ s32 EnJcMato_CheckForHit(EnJcMato* this, GlobalContext* globalCtx) {
this->collider.dim.worldSphere.center.y = this->pos.y;
this->collider.dim.worldSphere.center.z = this->pos.z;
if ((this->collider.base.acFlags & 2) && !this->hitFlag && (this->actor.colChkInfo.damageEffect == 0xF)) {
this->collider.base.acFlags &= 0xFFFD;
Audio_PlayActorSound2(&this->actor, 0x4807);
this->collider.base.acFlags &= ~2;
Audio_PlayActorSound2(&this->actor, NA_SE_SY_TRE_BOX_APPEAR);
globalCtx->interfaceCtx.unk25C = 1;
this->hitFlag = 1;
return 1;

View File

@ -199,7 +199,7 @@ void EnMinifrog_Jump(EnMinifrog* this) {
if (func_801378B8(&this->skelAnime, 4.0f)) {
this->actor.bgCheckFlags &= ~1;
this->actor.velocity.y = 6.0f;
Audio_PlayActorSound2(&this->actor, 0x28B1);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FROG_JUMP);
this->jumpState = MINIFROG_STATE_AIR;
}
break;
@ -286,7 +286,7 @@ void EnMinifrog_ReturnFrogCutscene(EnMinifrog* this, GlobalContext* globalCtx) {
default:
func_801477B4(globalCtx);
EnMinifrog_SetCamera(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 30, 0x3A87);
func_800F0568(globalCtx, &this->actor.world.pos, 30, NA_SE_EN_NPC_FADEAWAY);
if (this->actor.cutscene != -1) {
if (ActorCutscene_GetCurrentIndex() == this->actor.cutscene) {
ActorCutscene_Stop(this->actor.cutscene);

View File

@ -115,9 +115,9 @@ void EnNutsball_Update(Actor* thisx, GlobalContext* globalCtx) {
EffectSsHahen_SpawnBurst(globalCtx, &spawnBurstPos, 0x40C00000, 0, 7, 3, 15, HAHEN_OBJECT_DEFAULT, 10,
NULL);
if (this->actor.params == 1) {
func_800F0568(globalCtx, &this->actor.world.pos, 20, 0x28F4);
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EV_NUTS_BROKEN);
} else {
func_800F0568(globalCtx, &this->actor.world.pos, 20, 0x38C0);
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EN_OCTAROCK_ROCK);
}
Actor_MarkForDeath(&this->actor);
}

View File

@ -359,10 +359,10 @@ void EnPametfrog_PlaceSnapper(EnPametfrog* this, GlobalContext* globalCtx) {
void EnPametfrog_JumpOnGround(EnPametfrog* this, GlobalContext* globalCtx) {
if (func_801378B8(&this->skelAnime, 1.0f)) {
Audio_PlayActorSound2(&this->actor, 0x395B);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_JUMP);
} else if (func_801378B8(&this->skelAnime, 11.0f)) {
EnPametfrog_JumpWaterEffects(this, globalCtx);
Audio_PlayActorSound2(&this->actor, 0x2902);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_WALK_WATER);
}
}
@ -385,7 +385,7 @@ void func_8086A724(EnPametfrog* this, GlobalContext* globalCtx) {
void func_8086A80C(EnPametfrog* this) {
this->freezeTimer = 40;
Audio_PlayActorSound2(&this->actor, 0x389E);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_COMMON_FREEZE);
func_800BCB70(&this->actor, 0, 255, 0, 40);
this->mode = 30;
this->unk_2C8 = 0.75f;
@ -394,7 +394,7 @@ void func_8086A80C(EnPametfrog* this) {
void func_8086A878(EnPametfrog* this) {
this->freezeTimer = 40;
Audio_PlayActorSound2(&this->actor, 0x389E);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_COMMON_FREEZE);
func_800BCB70(&this->actor, 0, 255, 0, 40);
}
@ -491,7 +491,7 @@ void EnPametfrog_SetupFallOffSnapper(EnPametfrog* this, GlobalContext* globalCtx
eye.y = this->actor.focus.pos.y + 100.0f;
eye.z = (Math_CosS(yaw) * 300.0f) + this->actor.focus.pos.z;
func_8016970C(globalCtx, this->camId, &this->actor.focus.pos, &eye);
Audio_PlayActorSound2(&this->actor, 0x38D3);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_DAMAGE);
this->actionFunc = EnPametfrog_FallOffSnapper;
}
@ -518,7 +518,7 @@ void EnPametfrog_SetupJumpToWall(EnPametfrog* this) {
this->actor.shape.rot.x = 0;
this->actor.shape.rot.z = 0;
this->actor.bgCheckFlags &= ~8;
Audio_PlayActorSound2(&this->actor, 0x39A1);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_VOICE2);
this->actionFunc = EnPametfrog_JumpToWall;
}
@ -561,7 +561,7 @@ void EnPametfrog_SetupWallCrawl(EnPametfrog* this) {
this->skelAnime.animPlaybackSpeed = 1.0f;
}
Audio_PlayActorSound2(&this->actor, 0x39A9);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_RUNAWAY);
this->actor.speedXZ = 8.0f;
this->timer = Rand_S16Offset(35, 15);
this->actionFunc = EnPametfrog_WallCrawl;
@ -617,11 +617,11 @@ void EnPametfrog_WallCrawl(EnPametfrog* this, GlobalContext* globalCtx) {
}
if (func_801378B8(&this->skelAnime, 15.0f)) {
Audio_PlayActorSound2(&this->actor, 0x3828);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_BOMCHU_WALK);
}
if (((globalCtx->gameplayFrames % 60) == 0) && (Rand_ZeroOne() < 0.8f)) {
Audio_PlayActorSound2(&this->actor, 0x38D2);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_REAL);
}
if ((this->timer == 0) ||
@ -649,7 +649,7 @@ void EnPametfrog_SetupWallPause(EnPametfrog* this) {
this->wallRotation = (Rand_ZeroOne() < 0.5f ? -1 : 1) * (0x1000 + randFloat) * (M_PI / (15 * 0x8000));
}
this->timer = 15;
Audio_PlayActorSound2(&this->actor, 0x39AC);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_RUNAWAY2);
this->actionFunc = EnPametfrog_WallPause;
}
@ -667,7 +667,7 @@ void EnPametfrog_WallPause(EnPametfrog* this, GlobalContext* globalCtx) {
Math3D_CrossProduct(&this->unk_2DC, &this->unk_2D0, &this->unk_2E8);
func_8086A238(this);
if (((globalCtx->gameplayFrames % 60) == 0) && (Rand_ZeroOne() < 0.8f)) {
Audio_PlayActorSound2(&this->actor, 0x38D2);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_REAL);
}
if (this->timer == 0) {
@ -747,7 +747,7 @@ void EnPametfrog_SetupJumpOnSnapper(EnPametfrog* this) {
this->actor.shape.rot.y = Actor_YawBetweenActors(&this->actor, this->actor.child);
this->actor.world.rot.y = this->actor.shape.rot.y;
this->actor.params = ENPAMETFROG_JUMP_ON_SNAPPER;
Audio_PlayActorSound2(&this->actor, 0x395C);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_GREET);
this->actionFunc = EnPametfrog_JumpOnSnapper;
}
@ -798,9 +798,9 @@ void EnPametfrog_SetupFallInAir(EnPametfrog* this, GlobalContext* globalCtx) {
this->collider.base.acFlags &= ~1;
this->timer = 10;
if (this->actor.colChkInfo.health == 0) {
Audio_PlayActorSound2(&this->actor, 0x38D6);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_DEAD);
} else {
Audio_PlayActorSound2(&this->actor, 0x38D3);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_DAMAGE);
}
func_800BCB70(&this->actor, 0x4000, 0xFF, 0, 0x10);
@ -856,7 +856,7 @@ void EnPametfrog_SetupFallOnGround(EnPametfrog* this, GlobalContext* globalCtx)
this->timer = 5;
func_8086A068(this, globalCtx);
EnPametfrog_JumpWaterEffects(this, globalCtx);
Audio_PlayActorSound2(&this->actor, 0x2902);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_WALK_WATER);
this->actionFunc = EnPametfrog_FallOnGround;
}
@ -942,7 +942,7 @@ void EnPametfrog_SetupSpawnFrog(EnPametfrog* this, GlobalContext* globalCtx) {
vec1.z = (Math_CosS(yaw) * 20.0f) + this->actor.world.pos.z;
this->collider.base.ocFlags1 &= ~1;
func_800B0DE0(globalCtx, &vec1, &D_801D15B0, &D_801D15B0, &primColor, &envColor, 800, 50);
func_800F0568(globalCtx, &this->actor.world.pos, 40, 0x3A86);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EN_NPC_APPEAR);
Actor_SetRoomClearedTemp(globalCtx, globalCtx->roomContext.currRoom.num);
for (i = 0; i < 25; i++) {
vel.x = randPlusMinusPoint5Scaled(5.0f);
@ -1079,9 +1079,9 @@ void EnPametfrog_MeleeAttack(EnPametfrog* this, GlobalContext* globalCtx) {
((this->skelAnime.animCurrentSeg == &D_0600F048) && func_801378B8(&this->skelAnime, 27.0f))) {
this->collider.base.atFlags |= 1;
if (this->skelAnime.animCurrentSeg == &D_06003F28) {
Audio_PlayActorSound2(&this->actor, 0x3966);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_KICK);
} else {
Audio_PlayActorSound2(&this->actor, 0x3961);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_PUNCH1);
}
} else {
this->collider.base.atFlags &= ~1;
@ -1094,7 +1094,7 @@ void func_8086CB4C(EnPametfrog* this) {
this->collider.base.atFlags &= ~1;
this->collider.base.acFlags &= ~1;
this->actor.speedXZ = 10.0f;
Audio_PlayActorSound2(&this->actor, 0x38D3);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_DAMAGE);
func_800BCB70(&this->actor, 0x4000, 0xFF, 0, 20);
func_800BE5CC(&this->actor, &this->collider, 0);
this->actor.shape.rot.y = this->actor.world.rot.y + 0x8000;
@ -1147,7 +1147,7 @@ void EnPametfrog_SetupCallSnapper(EnPametfrog* this, GlobalContext* globalCtx) {
s16 yawDiff;
SkelAnime_ChangeAnimTransitionStop(&this->skelAnime, &D_06001B08, 3.0f);
Audio_PlayActorSound2(&this->actor, 0x395C);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_FROG_GREET);
this->actor.flags &= ~1;
this->actor.colChkInfo.health = 6;
this->actor.world.rot.y = Actor_YawToPoint(&this->actor, &this->actor.home.pos);
@ -1339,7 +1339,7 @@ void EnPametfrog_Update(Actor* thisx, GlobalContext* globalCtx) {
this->unk_2C8 = unk2C4;
this->unk_2C8 = unk2C4 > 0.75f ? 0.75f : this->unk_2C8;
} else if (!Math_StepToF(&this->unk_2CC, 0.75f, (3.0f/160.0f))) {
func_800B9010(&this->actor, 0x20B2);
func_800B9010(&this->actor, NA_SE_EV_ICE_FREEZE - SFX_FLAG);
}
}
}

View File

@ -207,7 +207,7 @@ void EnPoFusen_IncrementMalonPop(EnPoFusen* this) {
void EnPoFusen_Pop(EnPoFusen* this, GlobalContext* globalCtx) {
Actor_Spawn(&globalCtx->actorCtx, globalCtx, ACTOR_EN_CLEAR_TAG, this->actor.world.pos.x,
this->actor.world.pos.y + 20.0f, this->actor.world.pos.z, 255, 255, 200, 2);
Audio_PlayActorSound2(&this->actor, 0x180E); // NA_SE_IT_BOMB_EXPLOSION sfx
Audio_PlayActorSound2(&this->actor, NA_SE_IT_BOMB_EXPLOSION);
Actor_MarkForDeath(&this->actor);
}

View File

@ -185,7 +185,7 @@ void func_80930DDC(EnTuboTrap* this, GlobalContext* globalCtx) {
if (((this->actor.bgCheckFlags & 0x20) != 0) && (this->actor.yDistToWater > 15.0f)) {
func_80930B60(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2817);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_BOMB_DROP_WATER);
func_8093089C(this, globalCtx);
Actor_MarkForDeath(&this->actor);
return;
@ -193,8 +193,8 @@ void func_80930DDC(EnTuboTrap* this, GlobalContext* globalCtx) {
if ((this->collider.base.atFlags & AT_BOUNCED) != 0) {
this->collider.base.atFlags &= ~AT_BOUNCED;
func_809308F4(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x1808);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2887);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_IT_SHIELD_REFLECT_SW);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_POT_BROKEN);
func_8093089C(this, globalCtx);
Actor_MarkForDeath(&this->actor);
return;
@ -202,8 +202,8 @@ void func_80930DDC(EnTuboTrap* this, GlobalContext* globalCtx) {
if ((this->collider.base.acFlags & AC_HIT) != 0) {
this->collider.base.acFlags &= ~AC_HIT;
func_809308F4(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2802);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2887);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_EXPLOSION);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_POT_BROKEN);
func_8093089C(this, globalCtx);
Actor_MarkForDeath(&this->actor);
return;
@ -212,16 +212,16 @@ void func_80930DDC(EnTuboTrap* this, GlobalContext* globalCtx) {
this->collider.base.atFlags &= ~AT_HIT;
if (&player->base == this->collider.base.at) {
func_809308F4(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2887);
func_800F0568(globalCtx, &player2->base.world.pos, 0x28, 0x83E);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_POT_BROKEN);
func_800F0568(globalCtx, &player2->base.world.pos, 40, NA_SE_PL_BODY_HIT);
func_8093089C(this, globalCtx);
Actor_MarkForDeath(&this->actor);
return;
}
}
if (((this->actor.bgCheckFlags & 8) != 0) || ((this->actor.bgCheckFlags & 1) != 0)) {
if ((this->actor.bgCheckFlags & 8) || (this->actor.bgCheckFlags & 1)) {
func_809308F4(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x28, 0x2887);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_POT_BROKEN);
func_8093089C(this, globalCtx);
Actor_MarkForDeath(&this->actor);
}
@ -257,7 +257,7 @@ void func_80931004(EnTuboTrap* this, GlobalContext* globalCtx) {
this->targetHeight += weirdvalue;
}
this->originPos = this->actor.world.pos;
Audio_PlayActorSound2(&this->actor, 0x28C4);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_POT_MOVE_START);
this->actionFunc = func_80931138;
}
}
@ -284,9 +284,14 @@ void func_809311C4(EnTuboTrap* this, GlobalContext* globalCtx) {
f32 dY = this->originPos.y - this->actor.world.pos.y;
f32 dZ = this->originPos.z - this->actor.world.pos.z;
Audio_PlayActorSound2(&this->actor, 0x3037);
//! @bug should be NA_SE_EN_TUBOOCK_FLY - SFX_FLAG
// In OoT, NA_SE_EN_TUBOOCK_FLY is the value 0x3837
// But in MM, certain sfxIds got reordered and devs forgot to update:
// In MM, NA_SE_EN_MIZUBABA2_ATTACK is the old value 0x3837
// In MM, NA_SE_EN_TUBOOCK_FLY is the new value 0x3AE0
Audio_PlayActorSound2(&this->actor, NA_SE_EN_MIZUBABA2_ATTACK - SFX_FLAG);
if ((SQ(dX) + SQ(dY) + SQ(dZ) > 57600.0f)) { // 240.0f ^ 2
if ((SQ(dX) + SQ(dY) + SQ(dZ) > SQ(240.0f))) {
Math_ApproachF(&this->actor.gravity, -3.0f, 0.2f, 0.5f);
}

View File

@ -168,11 +168,11 @@ s32 func_80A357A8(ObjBell* this, GlobalContext* globalCtx) {
this->unk_20E = 10;
switch (this->dyna.actor.colChkInfo.damageEffect) {
case 15:
Audio_PlayActorSound2(&this->dyna.actor, 0x28F3);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_BIGBELL);
func_80A35510(this, 1);
break;
case 14:
Audio_PlayActorSound2(&this->dyna.actor, 0x28F3);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_BIGBELL);
func_80A35510(this, 2);
break;
default:

View File

@ -140,9 +140,9 @@ void func_80B3C624(ObjGhaka* this, GlobalContext* globalCtx) {
func_80B3C2C4(this, globalCtx);
gSaveContext.weekEventReg[20] |= 0x20;
func_80B3C260(this);
func_8019F1C0(&D_80B3C960, 0x2835);
func_8019F1C0(&D_80B3C960, NA_SE_EV_BLOCK_BOUND);
} else {
func_8019F1C0(&D_80B3C960, 0x200A);
func_8019F1C0(&D_80B3C960, NA_SE_EV_ROCK_SLIDE - SFX_FLAG);
}
}

View File

@ -73,7 +73,7 @@ void ObjHsStump_SetupAppear(ObjHsStump* this, GlobalContext* globalCtx) {
this->framesAppeared = 0;
this->rotAngle = 0;
this->rotFactor = 3640.0f;
func_8019F128(0x3A86);
func_8019F128(NA_SE_EN_NPC_APPEAR);
this->actionFunc = ObjHsStump_Appear;
}

View File

@ -273,13 +273,13 @@ void ObjKibako_Idle(ObjKibako* this, GlobalContext* globalCtx) {
} else if ((this->actor.bgCheckFlags & 0x20) && (this->actor.yDistToWater > 19.0f)) {
ObjKibako_WaterBreak(this, globalCtx);
ObjKibako_SpawnCollectible(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 20, 0x28AA); // NA_SE_EV_WOODBOX_BREAK
func_800F0568(globalCtx, &this->actor.world.pos, 40, 0x28C5);
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EV_WOODBOX_BREAK);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_DIVE_INTO_WATER_L);
Actor_MarkForDeath(&this->actor);
} else if (this->collider.base.acFlags & 2) {
ObjKibako_AirBreak(this, globalCtx);
ObjKibako_SpawnCollectible(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 0x14, 0x28AA); // NA_SE_EV_WOODBOX_BREAK
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EV_WOODBOX_BREAK);
Actor_MarkForDeath(&this->actor);
} else {
Actor_SetVelocityAndMoveYRotationAndGravity(&this->actor);
@ -328,7 +328,7 @@ void ObjKibako_Held(ObjKibako* this, GlobalContext* globalCtx) {
if (fabsf(this->actor.speedXZ) < 0.1f) {
ObjKibako_SetupIdle(this);
this->collider.base.ocFlags1 &= ~8;
Audio_PlayActorSound2(&this->actor, 0x28AB); // NA_SE_EV_PUT_DOWN_WOODBOX
Audio_PlayActorSound2(&this->actor, NA_SE_EV_PUT_DOWN_WOODBOX);
} else {
Actor_SetVelocityAndMoveYRotationAndGravity(&this->actor);
ObjKibako_SetupThrown(this);
@ -371,14 +371,14 @@ void ObjKibako_Thrown(ObjKibako* this, GlobalContext* globalCtx) {
if ((this->actor.bgCheckFlags & 0xB) || (atHit) || (this->timer <= 0)) {
ObjKibako_AirBreak(this, globalCtx);
ObjKibako_SpawnCollectible(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 20, 0x28AA); // NA_SE_EV_WOODBOX_BREAK
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EV_WOODBOX_BREAK);
Actor_MarkForDeath(&this->actor);
} else {
if (this->actor.bgCheckFlags & 0x40) {
ObjKibako_WaterBreak(this, globalCtx);
ObjKibako_SpawnCollectible(this, globalCtx);
func_800F0568(globalCtx, &this->actor.world.pos, 20, 0x28AA); // NA_SE_EV_WOODBOX_BREAK
func_800F0568(globalCtx, &this->actor.world.pos, 40, 0x28C5);
func_800F0568(globalCtx, &this->actor.world.pos, 20, NA_SE_EV_WOODBOX_BREAK);
func_800F0568(globalCtx, &this->actor.world.pos, 40, NA_SE_EV_DIVE_INTO_WATER_L);
Actor_MarkForDeath(&this->actor);
} else {
if (this->actor.velocity.y < -0.05f) {

View File

@ -264,7 +264,7 @@ void ObjLightSwitch_SetupAsleep(ObjLightswitch* this) {
void ObjLightSwitch_Asleep(ObjLightswitch* this, GlobalContext* globalCtx) {
if (this->colorShiftTimer == 0) {
Audio_PlayActorSound2(&this->actor, 0x286F); // sfx NA_SE_EV_SUN_MARK_FLASH
Audio_PlayActorSound2(&this->actor, NA_SE_EV_SUN_MARK_FLASH);
}
this->colorShiftTimer++;
@ -277,7 +277,7 @@ void ObjLightSwitch_Asleep(ObjLightswitch* this, GlobalContext* globalCtx) {
ObjLightSwitch_SetupEnabled(this);
} else if (this->colorShiftTimer == 15) {
this->faceState = LIGHTSWITCH_FACE_WAKING;
Audio_PlayActorSound2(&this->actor, 0x2815); // sfx NA_SE_EV_FOOT_SWITCH
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FOOT_SWITCH);
}
}
@ -335,7 +335,7 @@ void ObjLightSwitch_Disabled(ObjLightswitch* this, GlobalContext* globalCtx) {
ObjLightswitch_SetupIdle(this);
} else if (this->colorShiftTimer == 15) {
this->faceState = LIGHTSWITCH_FACE_ASLEEP;
Audio_PlayActorSound2(&this->actor, 0x2815); // NA_SE_EV_FOOT_SWITCH
Audio_PlayActorSound2(&this->actor, NA_SE_EV_FOOT_SWITCH);
}
}
@ -350,7 +350,7 @@ void ObjLightSwitch_Fade(ObjLightswitch* this, GlobalContext* globalCtx) {
if (this->colorAlpha < 0) {
Actor_MarkForDeath(&this->actor);
} else {
func_800B9010(&this->actor, 0x321F); // sfx NA_SE_EN_COMMON_EXTINCT_LEV "burn into ashes"
func_800B9010(&this->actor, NA_SE_EN_COMMON_EXTINCT_LEV - SFX_FLAG); // "burn into ashes"
}
}

View File

@ -158,7 +158,7 @@ s32 ObjTokeiStep_OpenProcess(ObjTokeiStep* this, GlobalContext* globalCtx) {
if (prevBounced && panel->numBounces < 3 && panel->startFallingTimer <= 0) {
finalPosY = panelXOffsets[i] + this->dyna.actor.world.pos.y;
if (!panel->hasSoundPlayed) {
Audio_PlayActorSound2(&this->dyna.actor, 0x2945);
Audio_PlayActorSound2(&this->dyna.actor, NA_SE_EV_CLOCK_TOWER_STAIR_MOVE);
panel->hasSoundPlayed = true;
}
panel->posChangeY += -2.5f;