1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-17 04:20:44 +00:00

Quake Documentation Pass (#1402)

* begin quake docs

* continue cleanup

* quake offset

* many more docs

* cleanup

* more cleanup

* cleanup headers

* move quake value to internal

* update, still need to test shake zoom/yaw

* more docs

* better docs

* add file descriptions

* fix comment

* explain random index

* cleanup comments

* better type 6 docs

* expand orientation comment

* fix old names, add comment

* remove comment, twas a mistake

* easy PR feedback

* duration in dec

* rm offset, clear up roll

* oops

* merge shakeInfo and QuakeCamData

* match order that always appears in code

* more PR suggestions

* adjust comment

* zeroVec

* rm extra space

* roman PR suggestions
This commit is contained in:
engineer124 2022-10-15 02:16:37 -04:00 committed by GitHub
parent d1d946a197
commit 9675051377
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
64 changed files with 737 additions and 620 deletions

View file

@ -5,6 +5,7 @@
*/
#include "z_bg_bdan_objects.h"
#include "quake.h"
#include "assets/objects/object_bdan_objects/object_bdan_objects.h"
#define FLAGS ACTOR_FLAG_4
@ -221,15 +222,15 @@ void func_8086C1A0(BgBdanObjects* this, PlayState* play) {
}
void func_8086C29C(BgBdanObjects* this, PlayState* play) {
s32 temp;
s32 quakeIndex;
if (this->timer != 0) {
this->timer--;
if (this->timer == 0) {
temp = Quake_Add(GET_ACTIVE_CAM(play), 1);
Quake_SetSpeed(temp, 0x3A98);
Quake_SetQuakeValues(temp, 0, 1, 0xFA, 1);
Quake_SetCountdown(temp, 0xA);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_1);
Quake_SetSpeed(quakeIndex, 0x3A98);
Quake_SetPerturbations(quakeIndex, 0, 1, 250, 1);
Quake_SetDuration(quakeIndex, 10);
}
}

View file

@ -8,6 +8,7 @@
#include "overlays/actors/ovl_En_Wall_Tubo/z_en_wall_tubo.h"
#include "overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.h"
#include "assets/objects/object_bowl/object_bowl.h"
#include "quake.h"
#include "vt.h"
#define FLAGS (ACTOR_FLAG_4 | ACTOR_FLAG_5)
@ -151,10 +152,10 @@ void BgBowlWall_FallDoEffects(BgBowlWall* this, PlayState* play) {
EffectSsHahen_SpawnBurst(play, &effectPos, 10.0f, 0, 50, 15, 3, HAHEN_OBJECT_DEFAULT, 10, NULL);
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_IT_BOMB_EXPLOSION);
}
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 1);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_1);
Quake_SetSpeed(quakeIndex, 0x7FFF);
Quake_SetQuakeValues(quakeIndex, 300, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 30);
Quake_SetPerturbations(quakeIndex, 300, 0, 0, 0);
Quake_SetDuration(quakeIndex, 30);
this->timer = 20;
this->actionFunc = BgBowlWall_FinishFall;
}

View file

@ -169,7 +169,7 @@ void BgDdanKd_LowerStairs(BgDdanKd* this, PlayState* play) {
func_80033480(play, &pos1, 20.0f, 1, effectStrength * 135.0f, 60, 1);
func_8003555C(play, &pos1, &velocity, &accel);
}
Camera_AddQuake(&play->mainCamera, 0, effectStrength * 0.6f, 3);
Camera_RequestQuake(&play->mainCamera, 0, effectStrength * 0.6f, 3);
Audio_PlaySfxGeneral(NA_SE_EV_PILLAR_SINK - SFX_FLAG, &this->dyna.actor.projectedPos, 4,
&gSfxDefaultFreqAndVolScale, &gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
}

View file

@ -211,7 +211,7 @@ void BgGanonOtyuka_Fall(BgGanonOtyuka* this, PlayState* play) {
(s16)Rand_ZeroFloat(100.0f) + 250, 5, (s16)Rand_ZeroFloat(5.0f) + 15);
}
func_80033DB8(play, 10, 15);
Actor_RequestQuake(play, 10, 15);
SfxSource_PlaySfxAtFixedWorldPos(play, &this->dyna.actor.world.pos, 40, NA_SE_EV_BOX_BREAK);
}
Actor_Kill(&this->dyna.actor);

View file

@ -7,6 +7,7 @@
#include "z_bg_haka_huta.h"
#include "assets/objects/object_hakach_objects/object_hakach_objects.h"
#include "overlays/actors/ovl_En_Rd/z_en_rd.h"
#include "quake.h"
#define FLAGS ACTOR_FLAG_4
@ -179,10 +180,10 @@ void func_8087D720(BgHakaHuta* this, PlayState* play) {
this->counter++;
if (this->counter == 6) {
this->actionFunc = BgHakaHuta_DoNothing;
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 0x7530);
Quake_SetQuakeValues(quakeIndex, 4, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 2);
Quake_SetPerturbations(quakeIndex, 4, 0, 0, 0);
Quake_SetDuration(quakeIndex, 2);
} else if (this->counter == 0) {
this->counter = 6;
this->actionFunc = BgHakaHuta_DoNothing;

View file

@ -6,6 +6,7 @@
#include "z_bg_heavy_block.h"
#include "assets/objects/object_heavy_object/object_heavy_object.h"
#include "quake.h"
#include "vt.h"
#define FLAGS 0
@ -331,10 +332,10 @@ void BgHeavyBlock_Wait(BgHeavyBlock* this, PlayState* play) {
break;
}
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 25000);
Quake_SetQuakeValues(quakeIndex, 1, 1, 5, 0);
Quake_SetCountdown(quakeIndex, 10);
Quake_SetPerturbations(quakeIndex, 1, 1, 5, 0);
Quake_SetDuration(quakeIndex, 10);
this->actionFunc = BgHeavyBlock_LiftedUp;
}
}
@ -398,25 +399,25 @@ void BgHeavyBlock_Fly(BgHeavyBlock* this, PlayState* play) {
Flags_SetSwitch(play, (this->dyna.actor.params >> 8) & 0x3F);
Actor_Kill(&this->dyna.actor);
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 28000);
Quake_SetQuakeValues(quakeIndex, 14, 2, 100, 0);
Quake_SetCountdown(quakeIndex, 30);
Quake_SetPerturbations(quakeIndex, 14, 2, 100, 0);
Quake_SetDuration(quakeIndex, 30);
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 2);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_2);
Quake_SetSpeed(quakeIndex, 12000);
Quake_SetQuakeValues(quakeIndex, 5, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 999);
Quake_SetPerturbations(quakeIndex, 5, 0, 0, 0);
Quake_SetDuration(quakeIndex, 999);
SfxSource_PlaySfxAtFixedWorldPos(play, &this->dyna.actor.world.pos, 30, NA_SE_EV_ELECTRIC_EXPLOSION);
return;
case HEAVYBLOCK_UNBREAKABLE_OUTSIDE_CASTLE:
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_STONE_BOUND);
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 28000);
Quake_SetQuakeValues(quakeIndex, 16, 2, 120, 0);
Quake_SetCountdown(quakeIndex, 40);
Quake_SetPerturbations(quakeIndex, 16, 2, 120, 0);
Quake_SetDuration(quakeIndex, 40);
this->actionFunc = BgHeavyBlock_Land;
Flags_SetSwitch(play, (this->dyna.actor.params >> 8) & 0x3F);
@ -424,18 +425,18 @@ void BgHeavyBlock_Fly(BgHeavyBlock* this, PlayState* play) {
case HEAVYBLOCK_UNBREAKABLE:
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_BUYOSTAND_STOP_U);
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 28000);
Quake_SetQuakeValues(quakeIndex, 14, 2, 100, 0);
Quake_SetCountdown(quakeIndex, 40);
Quake_SetPerturbations(quakeIndex, 14, 2, 100, 0);
Quake_SetDuration(quakeIndex, 40);
this->actionFunc = BgHeavyBlock_Land;
break;
default:
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 28000);
Quake_SetQuakeValues(quakeIndex, 14, 2, 100, 0);
Quake_SetCountdown(quakeIndex, 40);
Quake_SetPerturbations(quakeIndex, 14, 2, 100, 0);
Quake_SetDuration(quakeIndex, 40);
this->actionFunc = BgHeavyBlock_Land;
}

View file

@ -6,6 +6,7 @@
#include "z_bg_hidan_hamstep.h"
#include "assets/objects/object_hidan_objects/object_hidan_objects.h"
#include "quake.h"
#define FLAGS 0
@ -308,10 +309,10 @@ void func_80888860(BgHidanHamstep* this, PlayState* play) {
if (1) {}
if (this->unk_244 == 1) {
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -15536);
Quake_SetQuakeValues(quakeIndex, 0, 0, 500, 0);
Quake_SetCountdown(quakeIndex, 20);
Quake_SetPerturbations(quakeIndex, 0, 0, 500, 0);
Quake_SetDuration(quakeIndex, 20);
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_BLOCK_BOUND);
Rumble_Request(this->dyna.actor.xyzDistToPlayerSq, 255, 20, 150);
func_80888638(this, play);
@ -367,10 +368,10 @@ void func_80888A58(BgHidanHamstep* this, PlayState* play) {
if (1) {}
if (this->unk_244 == 1) {
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 3);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -15536);
Quake_SetQuakeValues(quakeIndex, 20, 1, 0, 0);
Quake_SetCountdown(quakeIndex, 7);
Quake_SetPerturbations(quakeIndex, 20, 1, 0, 0);
Quake_SetDuration(quakeIndex, 7);
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_BLOCK_BOUND);
Rumble_Request(SQ(100.0f), 255, 20, 150);

View file

@ -6,6 +6,7 @@
#include "z_bg_jya_kanaami.h"
#include "assets/objects/object_jya_obj/object_jya_obj.h"
#include "quake.h"
#define FLAGS 0
@ -96,16 +97,17 @@ void func_8089993C(BgJyaKanaami* this) {
void func_80899950(BgJyaKanaami* this, PlayState* play) {
s32 pad[2];
s32 quakeId;
s32 quakeIndex;
this->unk_168 += 0x20;
if (Math_ScaledStepToS(&this->dyna.actor.world.rot.x, 0x4000, this->unk_168)) {
func_80899A08(this);
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_TRAP_BOUND);
quakeId = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quakeId, 25000);
Quake_SetQuakeValues(quakeId, 2, 0, 0, 0);
Quake_SetCountdown(quakeId, 16);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 25000);
Quake_SetPerturbations(quakeIndex, 2, 0, 0, 0);
Quake_SetDuration(quakeIndex, 16);
}
}

View file

@ -6,6 +6,7 @@
#include "z_bg_mori_bigst.h"
#include "assets/objects/object_mori_objects/object_mori_objects.h"
#include "quake.h"
#define FLAGS ACTOR_FLAG_4
@ -169,14 +170,15 @@ void BgMoriBigst_Fall(BgMoriBigst* this, PlayState* play) {
void BgMoriBigst_SetupLanding(BgMoriBigst* this, PlayState* play) {
s32 pad;
s32 quake;
s32 quakeIndex;
BgMoriBigst_SetupAction(this, BgMoriBigst_Landing);
this->waitTimer = 18;
quake = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quake, 25000);
Quake_SetQuakeValues(quake, 5, 0, 0, 0);
Quake_SetCountdown(quake, 16);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 25000);
Quake_SetPerturbations(quakeIndex, 5, 0, 0, 0);
Quake_SetDuration(quakeIndex, 16);
}
void BgMoriBigst_Landing(BgMoriBigst* this, PlayState* play) {

View file

@ -6,6 +6,7 @@
#include "z_bg_mori_rakkatenjo.h"
#include "assets/objects/object_mori_objects/object_mori_objects.h"
#include "quake.h"
#define FLAGS (ACTOR_FLAG_4 | ACTOR_FLAG_5)
@ -146,7 +147,7 @@ void BgMoriRakkatenjo_Fall(BgMoriRakkatenjo* this, PlayState* play) {
static f32 bounceVel[] = { 4.0f, 1.5f, 0.4f, 0.1f };
s32 pad;
Actor* thisx = &this->dyna.actor;
s32 quake;
s32 quakeIndex;
Actor_MoveForward(thisx);
if ((thisx->velocity.y < 0.0f) && (thisx->world.pos.y <= 403.0f)) {
@ -162,10 +163,11 @@ void BgMoriRakkatenjo_Fall(BgMoriRakkatenjo* this, PlayState* play) {
403.0f - (thisx->world.pos.y - 403.0f) * bounceVel[this->bounceCount] / fabsf(thisx->velocity.y);
thisx->velocity.y = bounceVel[this->bounceCount];
this->bounceCount++;
quake = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quake, 50000);
Quake_SetQuakeValues(quake, 5, 0, 0, 0);
Quake_SetCountdown(quake, 5);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, 50000);
Quake_SetPerturbations(quakeIndex, 5, 0, 0, 0);
Quake_SetDuration(quakeIndex, 5);
}
}
}

View file

@ -315,7 +315,7 @@ void BgPoEvent_BlockFall(BgPoEvent* this, PlayState* play) {
BgPoEvent_CheckBlock(this);
} else {
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_STONE_BOUND);
func_80033E88(&this->dyna.actor, play, 5, 5);
Actor_RequestQuakeAndRumble(&this->dyna.actor, play, 5, 5);
func_80088B34(this->timer);
if (firstFall == 0) {
firstFall = 1;

View file

@ -6,6 +6,7 @@
#include "z_bg_spot12_gate.h"
#include "assets/objects/object_spot12_obj/object_spot12_obj.h"
#include "quake.h"
#define FLAGS 0
@ -104,16 +105,18 @@ void func_808B317C(BgSpot12Gate* this) {
void func_808B318C(BgSpot12Gate* this, PlayState* play) {
s32 pad;
s32 var;
s32 quakeIndex;
Math_StepToF(&this->dyna.actor.velocity.y, 1.6f, 0.03f);
if (Math_StepToF(&this->dyna.actor.world.pos.y, this->dyna.actor.home.pos.y + 200.0f,
this->dyna.actor.velocity.y)) {
func_808B3274(this);
var = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(var, -0x3CB0);
Quake_SetQuakeValues(var, 3, 0, 0, 0);
Quake_SetCountdown(var, 0xC);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -0x3CB0);
Quake_SetPerturbations(quakeIndex, 3, 0, 0, 0);
Quake_SetDuration(quakeIndex, 12);
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_BRIDGE_OPEN_STOP);
} else {
func_8002F974(&this->dyna.actor, NA_SE_EV_METALGATE_OPEN - SFX_FLAG);

View file

@ -552,7 +552,7 @@ void BossDodongo_Explode(BossDodongo* this, PlayState* play) {
this->actionFunc = BossDodongo_LayDown;
Audio_PlayActorSfx2(&this->actor, NA_SE_IT_BOMB_EXPLOSION);
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DODO_K_DAMAGE);
func_80033E88(&this->actor, play, 4, 10);
Actor_RequestQuakeAndRumble(&this->actor, play, 4, 10);
this->health -= 2;
// make sure not to die from the bomb explosion
@ -677,7 +677,7 @@ void BossDodongo_Walk(BossDodongo* this, PlayState* play) {
}
if (this->subCamId == SUB_CAM_ID_DONE) {
func_80033E88(&this->actor, play, 4, 10);
Actor_RequestQuakeAndRumble(&this->actor, play, 4, 10);
} else {
this->unk_1B6 = 10;
Rumble_Override(0.0f, 180, 20, 100);
@ -758,7 +758,7 @@ void BossDodongo_Roll(BossDodongo* this, PlayState* play) {
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DODO_K_ROLL - SFX_FLAG);
if ((this->unk_19E & 7) == 0) {
Camera_AddQuake(&play->mainCamera, 2, 1, 8);
Camera_RequestQuake(&play->mainCamera, 2, 1, 8);
}
if (!(this->unk_19E & 1)) {
@ -787,12 +787,12 @@ void BossDodongo_Roll(BossDodongo* this, PlayState* play) {
this->unk_228 = 9200.0f;
this->actor.velocity.y = 20.0f;
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DODO_K_COLI);
Camera_AddQuake(&play->mainCamera, 2, 6, 8);
Camera_RequestQuake(&play->mainCamera, 2, 6, 8);
sp50.x = this->actor.world.pos.x;
sp50.y = this->actor.world.pos.y + 60.0f;
sp50.z = this->actor.world.pos.z;
func_80033480(play, &sp50, 250.0f, 40, 800, 10, 0);
func_80033E88(&this->actor, play, 6, 15);
Actor_RequestQuakeAndRumble(&this->actor, play, 6, 15);
} else {
this->actor.velocity.y = 15.0f;
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DODO_K_COLI2);
@ -1395,7 +1395,7 @@ void BossDodongo_DeathCutscene(BossDodongo* this, PlayState* play) {
Math_SmoothStepToF(&this->actor.world.pos.z, cornerPos->z + sp184.z, 1.0f, this->unk_1E4, 0.0f);
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DODO_K_ROLL - SFX_FLAG);
if ((this->unk_19E & 7) == 0) {
Camera_AddQuake(&play->mainCamera, 2, 1, 8);
Camera_RequestQuake(&play->mainCamera, 2, 1, 8);
}
if (!(this->unk_19E & 1)) {
Actor_SpawnFloorDustRing(play, &this->actor, &this->actor.world.pos, 40.0f, 3, 8.0f, 500, 10,

View file

@ -629,7 +629,7 @@ void BossFd_Fly(BossFd* this, PlayState* play) {
this->holePosition.x = this->targetPosition.x;
this->holePosition.z = this->targetPosition.z;
func_80033E1C(play, 1, 0x50, 0x5000);
Actor_RequestQuakeWithSpeed(play, 1, 80, 0x5000);
if (this->introState != BFD_CS_NONE) {
this->timers[0] = 50;
} else {
@ -673,7 +673,7 @@ void BossFd_Fly(BossFd* this, PlayState* play) {
this->timers[1] = 10;
Audio_PlaySfxGeneral(NA_SE_EV_EXPLOSION, &this->actor.projectedPos, 4, &gSfxDefaultFreqAndVolScale,
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
func_80033E1C(play, 3, 0xA, 0x7530);
Actor_RequestQuakeWithSpeed(play, 3, 10, 0x7530);
this->work[BFD_ROCK_TIMER] = 300;
}
} else {
@ -979,14 +979,14 @@ void BossFd_Fly(BossFd* this, PlayState* play) {
if (this->work[BFD_ACTION_STATE] < BOSSFD_SKULL_FALL) {
if ((this->actor.prevPos.y < 90.0f) && (90.0f <= this->actor.world.pos.y)) {
this->timers[4] = 80;
func_80033E1C(play, 1, 80, 0x5000);
Actor_RequestQuakeWithSpeed(play, 1, 80, 0x5000);
this->work[BFD_ROAR_TIMER] = 40;
this->work[BFD_MANE_EMBERS_TIMER] = 30;
this->work[BFD_SPLASH_TIMER] = 10;
}
if ((this->actor.prevPos.y > 90.0f) && (90.0f >= this->actor.world.pos.y)) {
this->timers[4] = 80;
func_80033E1C(play, 1, 80, 0x5000);
Actor_RequestQuakeWithSpeed(play, 1, 80, 0x5000);
this->work[BFD_MANE_EMBERS_TIMER] = 30;
this->work[BFD_SPLASH_TIMER] = 10;
}

View file

@ -243,7 +243,7 @@ void BossFd2_Emerge(BossFd2* this, PlayState* play) {
bossFd->faceExposed = 0;
bossFd->holePosition.x = this->actor.world.pos.x;
bossFd->holePosition.z = this->actor.world.pos.z;
func_80033E1C(play, 1, 0x32, 0x5000);
Actor_RequestQuakeWithSpeed(play, 1, 50, 0x5000);
this->work[FD2_ACTION_STATE] = 1;
this->work[FD2_HOLE_COUNTER]++;
this->actor.world.pos.y = -200.0f;

View file

@ -1897,7 +1897,7 @@ void BossGanon_PoundFloor(BossGanon* this, PlayState* play) {
this->actor.world.pos.y = 60.0f;
this->unk_1C2 = 2;
this->timers[0] = 10;
func_80033E88(&this->actor, play, 0xA, 0x14); // rumble
Actor_RequestQuakeAndRumble(&this->actor, play, 10, 20);
this->unk_19C = 35;
this->unk_19E = 0;
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GANON_HIT_GND_IMP);

View file

@ -170,7 +170,7 @@ void func_808FD4D4(BossGanon2* this, PlayState* play, s16 arg2, s16 arg3) {
}
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_MGANON_WALK);
func_80033E88(&this->actor, play, 2, 0xA);
Actor_RequestQuakeAndRumble(&this->actor, play, 2, 10);
}
void func_808FD5C4(BossGanon2* this, PlayState* play) {
@ -2004,7 +2004,7 @@ void BossGanon2_Update(Actor* thisx, PlayState* play) {
UPDBGCHECKINFO_FLAG_0 | UPDBGCHECKINFO_FLAG_2);
if (this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) {
if (this->actor.velocity.y < -5.0f) {
func_80033E88(&this->actor, play, 5, 20);
Actor_RequestQuakeAndRumble(&this->actor, play, 5, 20);
func_80078884(NA_SE_IT_BOMB_EXPLOSION);
}
this->actor.velocity.y = 0.0f;

View file

@ -1309,7 +1309,7 @@ void BossGoma_FloorAttack(BossGoma* this, PlayState* play) {
if (Animation_OnFrame(&this->skelanime, 10.0f)) {
BossGoma_PlayEffectsAndSfx(this, play, 3, 5);
func_80033E88(&this->actor, play, 5, 15);
Actor_RequestQuakeAndRumble(&this->actor, play, 5, 15);
}
if (Animation_OnFrame(&this->skelanime, Animation_GetLastFrame(&gGohmaAttackAnim))) {
@ -1434,7 +1434,7 @@ void BossGoma_FallJump(BossGoma* this, PlayState* play) {
BossGoma_SetupFloorLand(this);
this->actor.velocity.y = 0.0f;
BossGoma_PlayEffectsAndSfx(this, play, 0, 8);
func_80033E88(&this->actor, play, 5, 0xF);
Actor_RequestQuakeAndRumble(&this->actor, play, 5, 15);
}
}
@ -1451,7 +1451,7 @@ void BossGoma_FallStruckDown(BossGoma* this, PlayState* play) {
BossGoma_SetupFloorLandStruckDown(this);
this->actor.velocity.y = 0.0f;
BossGoma_PlayEffectsAndSfx(this, play, 0, 8);
func_80033E88(&this->actor, play, 0xA, 0xF);
Actor_RequestQuakeAndRumble(&this->actor, play, 10, 15);
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOMA_DAM1);
}
}
@ -1847,7 +1847,7 @@ void BossGoma_UpdateHit(BossGoma* this, PlayState* play) {
}
this->timer = 4;
func_80033E88(&this->actor, play, 4, 0xC);
Actor_RequestQuakeAndRumble(&this->actor, play, 4, 12);
}
}
}

View file

@ -1758,7 +1758,7 @@ void BossVa_SetupSupportCut(BossVa* this, PlayState* play) {
sFightPhase++;
Actor_Spawn(&play->actorCtx, play, ACTOR_BOSS_VA, this->armTip.x, this->armTip.y + 20.0f, this->armTip.z, 0,
this->actor.shape.rot.y, 0, stumpParams);
Camera_AddQuake(&play->mainCamera, 2, 11, 8);
Camera_RequestQuake(&play->mainCamera, 2, 11, 8);
this->burst = false;
this->timer2 = 0;
BossVa_SetupAction(this, BossVa_SupportCut);

View file

@ -6,6 +6,7 @@
#include "z_door_shutter.h"
#include "overlays/actors/ovl_Boss_Goma/z_boss_goma.h"
#include "quake.h"
#include "assets/objects/object_gnd/object_gnd.h"
#include "assets/objects/object_goma/object_goma.h"
@ -31,7 +32,7 @@ void DoorShutter_Destroy(Actor* thisx, PlayState* play);
void DoorShutter_Update(Actor* thisx, PlayState* play);
void DoorShutter_Draw(Actor* thisx, PlayState* play);
void func_8099803C(PlayState* play, s16 y, s16 countdown, s16 camId);
void DoorShutter_RequestQuakeAndRumble(PlayState* play, s16 quakeY, s16 quakeDuration, s16 camId);
void DoorShutter_SetupType(DoorShutter* this, PlayState* play);
void func_80996A54(DoorShutter* this, PlayState* play);
void func_80996B00(DoorShutter* this, PlayState* play);
@ -560,7 +561,7 @@ void func_80997220(DoorShutter* this, PlayState* play) {
}
void func_809973E8(DoorShutter* this, PlayState* play) {
s32 quakeId;
s32 quakeIndex;
if (this->dyna.actor.velocity.y < 20.0f) {
Math_StepToF(&this->dyna.actor.velocity.y, 20.0f, 8.0f);
@ -572,10 +573,10 @@ void func_809973E8(DoorShutter* this, PlayState* play) {
false);
}
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_STONE_BOUND);
quakeId = Quake_Add(Play_GetCamera(play, CAM_ID_MAIN), 3);
Quake_SetSpeed(quakeId, -32536);
Quake_SetQuakeValues(quakeId, 2, 0, 0, 0);
Quake_SetCountdown(quakeId, 10);
quakeIndex = Quake_Request(Play_GetCamera(play, CAM_ID_MAIN), 3);
Quake_SetSpeed(quakeIndex, -32536);
Quake_SetPerturbations(quakeIndex, 2, 0, 0, 0);
Quake_SetDuration(quakeIndex, 10);
Rumble_Request(this->dyna.actor.xyzDistToPlayerSq, 180, 20, 100);
func_80997220(this, play);
}
@ -604,7 +605,7 @@ void func_809975C0(DoorShutter* this, PlayState* play) {
this->unk_164 = 10;
Audio_PlayActorSfx2(&this->dyna.actor, NA_SE_EV_STONE_BOUND);
func_8099803C(play, 2, 10, parent->subCamId);
DoorShutter_RequestQuakeAndRumble(play, 2, 10, parent->subCamId);
Actor_SpawnFloorDustRing(play, &this->dyna.actor, &this->dyna.actor.world.pos, 70.0f, 20, 8.0f, 500, 10,
true);
}
@ -766,11 +767,11 @@ void DoorShutter_Draw(Actor* thisx, PlayState* play) {
}
}
void func_8099803C(PlayState* play, s16 y, s16 countdown, s16 camId) {
s16 quakeId = Quake_Add(Play_GetCamera(play, camId), 3);
void DoorShutter_RequestQuakeAndRumble(PlayState* play, s16 quakeY, s16 quakeDuration, s16 camId) {
s16 quakeIndex = Quake_Request(Play_GetCamera(play, camId), QUAKE_TYPE_3);
Rumble_Override(0.0f, 180, 20, 100);
Quake_SetSpeed(quakeId, 20000);
Quake_SetQuakeValues(quakeId, y, 0, 0, 0);
Quake_SetCountdown(quakeId, countdown);
Quake_SetSpeed(quakeIndex, 20000);
Quake_SetPerturbations(quakeIndex, quakeY, 0, 0, 0);
Quake_SetDuration(quakeIndex, quakeDuration);
}

View file

@ -262,7 +262,7 @@ void func_809BD1C8(EnBigokuta* this, PlayState* play) {
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_DAIOCTA_LAND_WATER);
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_GOLON_LAND_BIG);
func_80033E88(&this->actor, play, 0xA, 8);
Actor_RequestQuakeAndRumble(&this->actor, play, 10, 8);
}
void func_809BD2E4(EnBigokuta* this) {

View file

@ -7,7 +7,7 @@
#include "z_en_bili.h"
#include "assets/objects/object_bl/object_bl.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_12 | ACTOR_FLAG_14)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_IGNORE_QUAKE | ACTOR_FLAG_14)
void EnBili_Init(Actor* thisx, PlayState* play);
void EnBili_Destroy(Actor* thisx, PlayState* play);

View file

@ -319,7 +319,7 @@ void EnBom_Update(Actor* thisx, PlayState* play2) {
play->envCtx.adjAmbientColor[0] = play->envCtx.adjAmbientColor[1] = play->envCtx.adjAmbientColor[2] = 250;
Camera_AddQuake(&play->mainCamera, 2, 0xB, 8);
Camera_RequestQuake(&play->mainCamera, 2, 11, 8);
thisx->params = BOMB_EXPLOSION;
this->timer = 10;
thisx->flags |= ACTOR_FLAG_5;

View file

@ -428,7 +428,7 @@ void EnBombf_Update(Actor* thisx, PlayState* play) {
play->envCtx.adjLight1Color[0] = play->envCtx.adjLight1Color[1] = play->envCtx.adjLight1Color[2] = 250;
play->envCtx.adjAmbientColor[0] = play->envCtx.adjAmbientColor[1] = play->envCtx.adjAmbientColor[2] =
250;
Camera_AddQuake(&play->mainCamera, 2, 0xB, 8);
Camera_RequestQuake(&play->mainCamera, 2, 11, 8);
thisx->params = BOMBFLOWER_EXPLOSION;
this->timer = 10;
thisx->flags |= ACTOR_FLAG_5;

View file

@ -1,7 +1,7 @@
#include "z_en_crow.h"
#include "assets/objects/object_crow/object_crow.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_12 | ACTOR_FLAG_14)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_IGNORE_QUAKE | ACTOR_FLAG_14)
void EnCrow_Init(Actor* thisx, PlayState* play);
void EnCrow_Destroy(Actor* thisx, PlayState* play);

View file

@ -200,7 +200,7 @@ void EnEiyer_SetupAppearFromGround(EnEiyer* this) {
this->collider.base.atFlags &= ~AT_ON;
this->collider.base.acFlags &= ~AC_ON;
this->actor.flags &= ~(ACTOR_FLAG_0 | ACTOR_FLAG_12);
this->actor.flags &= ~(ACTOR_FLAG_0 | ACTOR_FLAG_IGNORE_QUAKE);
this->actor.shape.shadowScale = 0.0f;
this->actor.shape.yOffset = 0.0f;
this->actionFunc = EnEiyer_AppearFromGround;
@ -231,7 +231,7 @@ void EnEiyer_SetupAmbush(EnEiyer* this, PlayState* play) {
this->collider.info.bumper.dmgFlags = DMG_DEFAULT;
this->basePos = this->actor.world.pos;
this->actor.world.rot.y = this->actor.shape.rot.y;
this->actor.flags |= ACTOR_FLAG_12;
this->actor.flags |= ACTOR_FLAG_IGNORE_QUAKE;
this->collider.base.acFlags &= ~AC_ON;
this->actor.shape.shadowScale = 65.0f;
this->actor.shape.yOffset = 600.0f;

View file

@ -1,5 +1,6 @@
#include "z_en_encount2.h"
#include "overlays/actors/ovl_En_Fire_Rock/z_en_fire_rock.h"
#include "quake.h"
#include "vt.h"
#include "assets/objects/object_efc_star_field/object_efc_star_field.h"
@ -91,11 +92,11 @@ void EnEncount2_Wait(EnEncount2* this, PlayState* play) {
}
break;
case ENCOUNT2_ACTIVE_DEATH_MOUNTAIN:
if ((this->deathMountainSpawnerTimer == 1) || (!this->isQuaking)) {
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 1);
if ((this->deathMountainSpawnerTimer == 1) || !this->isQuaking) {
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_1);
Quake_SetSpeed(quakeIndex, 0x7FFF);
Quake_SetQuakeValues(quakeIndex, 50, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 300);
Quake_SetPerturbations(quakeIndex, 50, 0, 0, 0);
Quake_SetDuration(quakeIndex, 300);
this->isQuaking = true;
}
FALLTHROUGH;

View file

@ -212,7 +212,7 @@ void EnFhgFire_LightningStrike(EnFhgFire* this, PlayState* play) {
(s16)(Rand_ZeroOne() * 100.0f) + 240, FHGFLASH_LIGHTBALL_GREEN);
}
}
func_80033E88(&this->actor, play, 4, 10);
Actor_RequestQuakeAndRumble(&this->actor, play, 4, 10);
}
break;

View file

@ -198,7 +198,7 @@ void EnFireRock_Fall(EnFireRock* this, PlayState* play) {
switch (this->type) {
case FIRE_ROCK_SPAWNED_FALLING1:
case FIRE_ROCK_SPAWNED_FALLING2:
func_80033E88(&this->actor, play, 5, 2);
Actor_RequestQuakeAndRumble(&this->actor, play, 5, 2);
FALLTHROUGH;
case FIRE_ROCK_BROKEN_PIECE1:
Actor_SpawnFloorDustRing(play, &this->actor, &this->actor.world.pos, this->actor.shape.shadowScale, 1,

View file

@ -8,7 +8,7 @@
#include "assets/objects/object_firefly/object_firefly.h"
#include "overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_12 | ACTOR_FLAG_14)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_IGNORE_QUAKE | ACTOR_FLAG_14)
void EnFirefly_Init(Actor* thisx, PlayState* play);
void EnFirefly_Destroy(Actor* thisx, PlayState* play);

View file

@ -2,6 +2,7 @@
#include "overlays/actors/ovl_En_Bom/z_en_bom.h"
#include "assets/objects/gameplay_keep/gameplay_keep.h"
#include "assets/objects/object_oF1d_map/object_oF1d_map.h"
#include "quake.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_3 | ACTOR_FLAG_4 | ACTOR_FLAG_5)
@ -1628,14 +1629,14 @@ void EnGo2_Destroy(Actor* thisx, PlayState* play) {
void EnGo2_CurledUp(EnGo2* this, PlayState* play) {
u8 index = this->actor.params & 0x1F;
s16 height;
s32 quake;
s32 quakeIndex;
if (Animation_OnFrame(&this->skelAnime, this->skelAnime.endFrame)) {
if ((this->actor.params & 0x1F) == GORON_DMT_BIGGORON) {
quake = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quake, -0x3CB0);
Quake_SetQuakeValues(quake, 8, 0, 0, 0);
Quake_SetCountdown(quake, 16);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -0x3CB0);
Quake_SetPerturbations(quakeIndex, 8, 0, 0, 0);
Quake_SetDuration(quakeIndex, 16);
} else {
EnGo2_GetDustData(this, 1);
}

View file

@ -791,7 +791,7 @@ void EnGoma_Draw(Actor* thisx, PlayState* play) {
this->actor.naviEnemyId = NAVI_ENEMY_GOHMA_LARVA;
Matrix_Translate(this->actor.world.pos.x,
this->actor.world.pos.y +
((this->actor.shape.yOffset * this->actor.scale.y) + play->mainCamera.skyboxOffset.y),
((this->actor.shape.yOffset * this->actor.scale.y) + play->mainCamera.quakeOffset.y),
this->actor.world.pos.z, MTXMODE_NEW);
Matrix_RotateX(BINANG_TO_RAD_ALT(this->slopePitch), MTXMODE_APPLY);
Matrix_RotateZ(BINANG_TO_RAD_ALT(this->slopeRoll), MTXMODE_APPLY);

View file

@ -8,6 +8,7 @@
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
#include "assets/objects/gameplay_keep/gameplay_keep.h"
#include "assets/objects/object_goroiwa/object_goroiwa.h"
#include "quake.h"
#include "vt.h"
#define FLAGS ACTOR_FLAG_4
@ -358,7 +359,7 @@ s32 EnGoroiwa_MoveDownToNextWaypoint(EnGoroiwa* this, PlayState* play) {
f32 nextPointY;
f32 thisY;
f32 yDistToFloor;
s32 quakeIdx;
s32 quakeIndex;
CollisionPoly* floorPoly;
Vec3f checkPos;
f32 floorY;
@ -379,10 +380,10 @@ s32 EnGoroiwa_MoveDownToNextWaypoint(EnGoroiwa* this, PlayState* play) {
if (this->actor.velocity.y < 0.0f && this->actor.world.pos.y <= nextPointY) {
if (this->bounceCount == 0) {
if (this->actor.xzDistToPlayer < 600.0f) {
quakeIdx = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quakeIdx, -0x3CB0);
Quake_SetQuakeValues(quakeIdx, 3, 0, 0, 0);
Quake_SetCountdown(quakeIdx, 7);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -0x3CB0);
Quake_SetPerturbations(quakeIndex, 3, 0, 0, 0);
Quake_SetDuration(quakeIndex, 7);
}
this->rollRotSpeed = 0.0f;
if (!(this->stateFlags & ENGOROIWA_IN_WATER)) {

View file

@ -427,7 +427,7 @@ void func_80A74EBC(EnIk* this, PlayState* play) {
sp2C.z = this->actor.world.pos.z + Math_CosS(this->actor.shape.rot.y + 0x6A4) * 70.0f;
sp2C.y = this->actor.world.pos.y;
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_IRONNACK_HIT_GND);
Camera_AddQuake(&play->mainCamera, 2, 0x19, 5);
Camera_RequestQuake(&play->mainCamera, 2, 25, 5);
Rumble_Request(this->actor.xzDistToPlayer, 255, 20, 150);
CollisionCheck_SpawnShieldParticles(play, &sp2C);
}

View file

@ -8,7 +8,7 @@
#include "overlays/actors/ovl_En_Insect/z_en_insect.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
#include "assets/objects/gameplay_field_keep/gameplay_field_keep.h"
#include "quake.h"
#include "vt.h"
#define FLAGS ACTOR_FLAG_23
@ -420,7 +420,7 @@ void EnIshi_Fly(EnIshi* this, PlayState* play) {
s32 pad;
s16 type = this->actor.params & 1;
s32 pad2;
s32 quakeIdx;
s32 quakeIndex;
Vec3f contactPos;
if (this->actor.bgCheckFlags & (BGCHECKFLAG_GROUND | BGCHECKFLAG_WALL)) {
@ -432,10 +432,10 @@ void EnIshi_Fly(EnIshi* this, PlayState* play) {
sDustSpawnFuncs[type](this, play);
}
if (type == ROCK_LARGE) {
quakeIdx = Quake_Add(GET_ACTIVE_CAM(play), 3);
Quake_SetSpeed(quakeIdx, -0x3CB0);
Quake_SetQuakeValues(quakeIdx, 3, 0, 0, 0);
Quake_SetCountdown(quakeIdx, 7);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIndex, -0x3CB0);
Quake_SetPerturbations(quakeIndex, 3, 0, 0, 0);
Quake_SetDuration(quakeIndex, 7);
Rumble_Request(this->actor.xyzDistToPlayerSq, 255, 20, 150);
}
Actor_Kill(&this->actor);

View file

@ -862,7 +862,7 @@ void EnMb_ClubAttack(EnMb* this, PlayState* play) {
EffectSsBlast_SpawnWhiteShockwave(play, &effSpawnPos, &effWhiteShockwaveDynamics,
&effWhiteShockwaveDynamics);
func_80033480(play, &effSpawnPos, 2.0f, 3, 0x12C, 0xB4, 1);
Camera_AddQuake(&play->mainCamera, 2, 0x19, 5);
Camera_RequestQuake(&play->mainCamera, 2, 25, 5);
func_800358DC(&this->actor, &effSpawnPos, &this->actor.world.rot, flamesParams, 20, flamesUnused, play, -1,
NULL);
EnMb_SetupClubWaitAfterAttack(this);
@ -1044,7 +1044,7 @@ void EnMb_ClubDamaged(EnMb* this, PlayState* play) {
Animation_PlayOnce(&this->skelAnime, &gEnMbClubStandUpAnim);
this->timer3 = 0;
Rumble_Request(this->actor.xzDistToPlayer, 255, 20, 150);
Camera_AddQuake(&play->mainCamera, 2, 25, 5);
Camera_RequestQuake(&play->mainCamera, 2, 25, 5);
} else {
EnMb_SetupClubWaitPlayerNear(this);
}
@ -1105,7 +1105,7 @@ void EnMb_ClubDead(EnMb* this, PlayState* play) {
Rumble_Request(this->actor.xzDistToPlayer, 255, 20, 150);
Actor_SpawnFloorDustRing(play, &this->actor, &effPos, 50.0f, 10, 3.0f, 400, 60, false);
Audio_PlayActorSfx2(&this->actor, NA_SE_EN_RIZA_DOWN);
Camera_AddQuake(&play->mainCamera, 2, 25, 5);
Camera_RequestQuake(&play->mainCamera, 2, 25, 5);
}
}

View file

@ -7,7 +7,7 @@
#include "z_en_po_desert.h"
#include "assets/objects/object_po_field/object_po_field.h"
#define FLAGS (ACTOR_FLAG_4 | ACTOR_FLAG_7 | ACTOR_FLAG_12)
#define FLAGS (ACTOR_FLAG_4 | ACTOR_FLAG_7 | ACTOR_FLAG_IGNORE_QUAKE)
void EnPoDesert_Init(Actor* thisx, PlayState* play);
void EnPoDesert_Destroy(Actor* thisx, PlayState* play);

View file

@ -8,7 +8,7 @@
#include "assets/objects/gameplay_keep/gameplay_keep.h"
#include "assets/objects/object_po_field/object_po_field.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_5 | ACTOR_FLAG_12)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_5 | ACTOR_FLAG_IGNORE_QUAKE)
void EnPoField_Init(Actor* thisx, PlayState* play);
void EnPoField_Destroy(Actor* thisx, PlayState* play);

View file

@ -8,7 +8,7 @@
#include "overlays/actors/ovl_En_Honotrap/z_en_honotrap.h"
#include "assets/objects/object_tk/object_tk.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_3 | ACTOR_FLAG_4 | ACTOR_FLAG_12 | ACTOR_FLAG_16)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_3 | ACTOR_FLAG_4 | ACTOR_FLAG_IGNORE_QUAKE | ACTOR_FLAG_16)
void EnPoRelay_Init(Actor* thisx, PlayState* play);
void EnPoRelay_Destroy(Actor* thisx, PlayState* play);

View file

@ -8,7 +8,7 @@
#include "assets/objects/gameplay_keep/gameplay_keep.h"
#include "assets/objects/object_po_sisters/object_po_sisters.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_9 | ACTOR_FLAG_12 | ACTOR_FLAG_14)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_9 | ACTOR_FLAG_IGNORE_QUAKE | ACTOR_FLAG_14)
void EnPoSisters_Init(Actor* thisx, PlayState* play);
void EnPoSisters_Destroy(Actor* thisx, PlayState* play);

View file

@ -8,7 +8,7 @@
#include "assets/objects/object_poh/object_poh.h"
#include "assets/objects/object_po_composer/object_po_composer.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_12)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_IGNORE_QUAKE)
void EnPoh_Init(Actor* thisx, PlayState* play);
void EnPoh_Destroy(Actor* thisx, PlayState* play);

View file

@ -7,7 +7,7 @@
#include "z_en_vali.h"
#include "assets/objects/object_vali/object_vali.h"
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_12)
#define FLAGS (ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_4 | ACTOR_FLAG_IGNORE_QUAKE)
void EnVali_Init(Actor* thisx, PlayState* play);
void EnVali_Destroy(Actor* thisx, PlayState* play);

View file

@ -191,7 +191,7 @@ void EnVbBall_Update(Actor* thisx, PlayState* play2) {
if ((this->actor.params == 100) || (this->actor.params == 101)) {
Actor_Kill(&this->actor);
if (this->actor.params == 100) {
func_80033E88(&this->actor, play, 5, 0xA);
Actor_RequestQuakeAndRumble(&this->actor, play, 5, 10);
}
if (this->actor.params == 100) {
spawnNum = 2;

View file

@ -5,6 +5,7 @@
*/
#include "z_en_wall_tubo.h"
#include "quake.h"
#include "vt.h"
#include "overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.h"
#include "overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.h"
@ -91,10 +92,10 @@ void EnWallTubo_DetectChu(EnWallTubo* this, PlayState* play) {
func_80078884(NA_SE_SY_TRE_BOX_APPEAR);
this->timer = 60;
EffectSsBomb2_SpawnLayered(play, &this->explosionCenter, &effVelocity, &effAccel, 200, 40);
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 1);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_1);
Quake_SetSpeed(quakeIndex, 0x7FFF);
Quake_SetQuakeValues(quakeIndex, 100, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 100);
Quake_SetPerturbations(quakeIndex, 100, 0, 0, 0);
Quake_SetDuration(quakeIndex, 100);
this->actionFunc = EnWallTubo_SetWallFall;
break;
}

View file

@ -80,7 +80,7 @@ void func_80B43A94(EnYukabyun* this, PlayState* play) {
this->unk_150--;
}
if (this->unk_150 == 0) {
this->actor.flags |= ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_12;
this->actor.flags |= ACTOR_FLAG_0 | ACTOR_FLAG_2 | ACTOR_FLAG_IGNORE_QUAKE;
this->actionfunc = func_80B43AD4;
}
}

View file

@ -7,6 +7,7 @@
#include "z_obj_lift.h"
#include "assets/objects/object_d_lift/object_d_lift.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
#include "quake.h"
#define FLAGS ACTOR_FLAG_4
@ -142,10 +143,10 @@ void func_80B96560(ObjLift* this, PlayState* play) {
if (((this->dyna.actor.params >> 8) & 7) == 7) {
func_80B967C0(this);
} else {
quakeIndex = Quake_Add(GET_ACTIVE_CAM(play), 1);
quakeIndex = Quake_Request(GET_ACTIVE_CAM(play), QUAKE_TYPE_1);
Quake_SetSpeed(quakeIndex, 10000);
Quake_SetQuakeValues(quakeIndex, 2, 0, 0, 0);
Quake_SetCountdown(quakeIndex, 20);
Quake_SetPerturbations(quakeIndex, 2, 0, 0, 0);
Quake_SetDuration(quakeIndex, 20);
func_80B9664C(this);
}
}

View file

@ -72,10 +72,10 @@ void OceffWipe_Draw(Actor* thisx, PlayState* play) {
s32 i;
Vec3f eye;
Vtx* vtxPtr;
Vec3f vec;
Vec3f quakeOffset;
eye = GET_ACTIVE_CAM(play)->eye;
Camera_GetSkyboxOffset(&vec, GET_ACTIVE_CAM(play));
Camera_GetQuakeOffset(&quakeOffset, GET_ACTIVE_CAM(play));
OPEN_DISPS(play->state.gfxCtx, "../z_oceff_wipe.c", 346);
@ -103,7 +103,7 @@ void OceffWipe_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW);
Matrix_Translate(eye.x + quakeOffset.x, eye.y + quakeOffset.y, eye.z + quakeOffset.z, MTXMODE_NEW);
Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Translate(0.0f, 0.0f, -z, MTXMODE_APPLY);

View file

@ -66,10 +66,10 @@ void OceffWipe2_Draw(Actor* thisx, PlayState* play) {
s32 pad[2];
Vec3f eye;
Vtx* vtxPtr;
Vec3f vec;
Vec3f quakeOffset;
eye = GET_ACTIVE_CAM(play)->eye;
Camera_GetSkyboxOffset(&vec, GET_ACTIVE_CAM(play));
Camera_GetQuakeOffset(&quakeOffset, GET_ACTIVE_CAM(play));
if (this->timer < 32) {
z = Math_SinS(this->timer << 9) * 1330;
} else {
@ -91,7 +91,7 @@ void OceffWipe2_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW);
Matrix_Translate(eye.x + quakeOffset.x, eye.y + quakeOffset.y, eye.z + quakeOffset.z, MTXMODE_NEW);
Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Translate(0.0f, 0.0f, -z, MTXMODE_APPLY);

View file

@ -67,10 +67,10 @@ void OceffWipe3_Draw(Actor* thisx, PlayState* play) {
s32 pad[2];
Vec3f eye;
Vtx* vtxPtr;
Vec3f vec;
Vec3f quakeOffset;
eye = GET_ACTIVE_CAM(play)->eye;
Camera_GetSkyboxOffset(&vec, GET_ACTIVE_CAM(play));
Camera_GetQuakeOffset(&quakeOffset, GET_ACTIVE_CAM(play));
if (this->counter < 32) {
z = Math_SinS(this->counter << 9) * 1330;
} else {
@ -92,7 +92,7 @@ void OceffWipe3_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW);
Matrix_Translate(eye.x + quakeOffset.x, eye.y + quakeOffset.y, eye.z + quakeOffset.z, MTXMODE_NEW);
Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Translate(0.0f, 0.0f, -z, MTXMODE_APPLY);

View file

@ -65,10 +65,10 @@ void OceffWipe4_Draw(Actor* thisx, PlayState* play) {
s32 pad[2];
Vec3f eye;
Vtx* vtxPtr;
Vec3f vec;
Vec3f quakeOffset;
eye = GET_ACTIVE_CAM(play)->eye;
Camera_GetSkyboxOffset(&vec, GET_ACTIVE_CAM(play));
Camera_GetQuakeOffset(&quakeOffset, GET_ACTIVE_CAM(play));
if (this->timer < 16) {
z = Math_SinS(this->timer * 1024) * 1330.0f;
} else {
@ -90,7 +90,7 @@ void OceffWipe4_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW);
Matrix_Translate(eye.x + quakeOffset.x, eye.y + quakeOffset.y, eye.z + quakeOffset.z, MTXMODE_NEW);
Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Translate(0.0f, 0.0f, -z, MTXMODE_APPLY);

View file

@ -6,6 +6,7 @@
#include "ultra64.h"
#include "global.h"
#include "quake.h"
#include "overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.h"
#include "overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.h"
@ -7690,16 +7691,16 @@ s32 func_80842964(Player* this, PlayState* play) {
return func_8083B040(this, play) || func_8083B644(this, play) || func_8083E5A8(this, play);
}
void func_808429B4(PlayState* play, s32 speed, s32 y, s32 countdown) {
s32 quakeIdx = Quake_Add(Play_GetCamera(play, CAM_ID_MAIN), 3);
void Player_RequestQuake(PlayState* play, s32 speed, s32 y, s32 duration) {
s32 quakeIndex = Quake_Request(Play_GetCamera(play, CAM_ID_MAIN), QUAKE_TYPE_3);
Quake_SetSpeed(quakeIdx, speed);
Quake_SetQuakeValues(quakeIdx, y, 0, 0, 0);
Quake_SetCountdown(quakeIdx, countdown);
Quake_SetSpeed(quakeIndex, speed);
Quake_SetPerturbations(quakeIndex, y, 0, 0, 0);
Quake_SetDuration(quakeIndex, duration);
}
void func_80842A28(PlayState* play, Player* this) {
func_808429B4(play, 27767, 7, 20);
Player_RequestQuake(play, 27767, 7, 20);
play->actorCtx.unk_02 = 4;
Player_RequestRumble(this, 255, 20, 150, 0);
func_8002F7DC(&this->actor, NA_SE_IT_HAMMER_HIT);
@ -8209,7 +8210,7 @@ s32 func_80843E64(PlayState* play, Player* this) {
}
func_80837AE0(this, 40);
func_808429B4(play, 32967, 2, 30);
Player_RequestQuake(play, 32967, 2, 30);
Player_RequestRumble(this, impactInfo->rumbleStrength, impactInfo->rumbleDuration,
impactInfo->rumbleDecreaseRate, 0);
func_8002F7DC(&this->actor, NA_SE_PL_BODY_HIT);
@ -8415,7 +8416,7 @@ void func_80844708(Player* this, PlayState* play) {
func_80832264(play, this, GET_PLAYER_ANIM(PLAYER_ANIMGROUP_17, this->modelAnimType));
this->linearVelocity = -this->linearVelocity;
func_808429B4(play, 33267, 3, 12);
Player_RequestQuake(play, 33267, 3, 12);
Player_RequestRumble(this, 255, 20, 150, 0);
func_8002F7DC(&this->actor, NA_SE_PL_BODY_HIT);
func_80832698(this, NA_SE_VO_LI_CLIMB_END);