From 982f598e012be511d5eefc32dee691be1334eb21 Mon Sep 17 00:00:00 2001 From: djevangelia <263709373+djevangelia@users.noreply.github.com> Date: Sat, 8 Aug 2026 22:39:09 +0200 Subject: Savestates, add `sEffectContext` (#7042) --- soh/src/code/z_eff_blure.c | 4 +++- soh/src/code/z_player_lib.c | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'soh/src/code') diff --git a/soh/src/code/z_eff_blure.c b/soh/src/code/z_eff_blure.c index 28534cb6b..56e595149 100644 --- a/soh/src/code/z_eff_blure.c +++ b/soh/src/code/z_eff_blure.c @@ -73,7 +73,7 @@ void EffectBlure_AddVertex(EffectBlure* this, Vec3f* p1, Vec3f* p2) { } // SoH: dumb doo doo command to change the type of a weapon's blur on the fly. Link's Swords with unique trail colors. -void EffectBlure_ChangeType(EffectBlure* this, int type) { +void EffectBlureShip_ChangeType(EffectBlure* this, int type) { this->trailType = type; } @@ -206,6 +206,7 @@ s32 EffectBlure_Update(void* thisx) { static u8 changed = 0; u8 reset = 0; + // SoH switch (this->trailType) { case TRAIL_TYPE_BOOMERANG: if (CVarGetInteger(CVAR_COSMETIC("Trails.Boomerang.Changed"), 0)) { @@ -322,6 +323,7 @@ s32 EffectBlure_Update(void* thisx) { } } + // Vanilla code from here on if (this == NULL) { return 0; } diff --git a/soh/src/code/z_player_lib.c b/soh/src/code/z_player_lib.c index fe2f783f0..bf93c117c 100644 --- a/soh/src/code/z_player_lib.c +++ b/soh/src/code/z_player_lib.c @@ -1807,7 +1807,7 @@ void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Ve D_80126080.x = this->unk_85C * 5000.0f; func_80090A28(this, sp124); if (this->meleeWeaponState != 0) { - EffectBlure_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), TRAIL_TYPE_STICK); + EffectBlureShip_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), TRAIL_TYPE_STICK); func_800906D4(play, this, sp124); } else { Math_Vec3f_Copy(&this->meleeWeaponInfo[0].tip, &sp124[0]); @@ -1829,8 +1829,8 @@ void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Ve D_80126080.x = 1500.0f; } else { D_80126080.x = sMeleeWeaponLengths[Player_GetMeleeWeaponHeld(this)]; - EffectBlure_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), - sSwordTypes[Player_GetMeleeWeaponHeld(this)]); + EffectBlureShip_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), + sSwordTypes[Player_GetMeleeWeaponHeld(this)]); } func_80090A28(this, spE4); -- cgit v1.2.3