Fix Duplicate Reticles in Anchor (#6520)

This commit is contained in:
A Green Spoon
2026-04-17 08:50:55 +09:00
committed by GitHub
parent 1876435e98
commit 412b60a02f
3 changed files with 8 additions and 5 deletions
@@ -36,7 +36,7 @@ void RegisterAdditionalReticles() {
bool shouldRegister = CVAR_BOW_RETICLE_VALUE || CVAR_BOOMERANG_RETICLE_VALUE;
COND_VB_SHOULD(VB_DRAW_ADDITIONAL_RETICLES, shouldRegister, {
Player* player = GET_PLAYER(gPlayState);
Player* player = va_arg(args, Player*);
Actor* heldActor = player->heldActor;
if (CVAR_BOW_RETICLE_VALUE &&
((player->heldItemAction >= PLAYER_IA_BOW && player->heldItemAction <= PLAYER_IA_BOW_LIGHT) ||
@@ -540,10 +540,11 @@ typedef enum {
// #### `result`
// ```c
// true
// (this->heldItemAction == PLAYER_IA_HOOKSHOT) ||
// (this->heldItemAction == PLAYER_IA_LONGSHOT)
// ```
// #### `args`
// - None
// - '*Player'
VB_DRAW_ADDITIONAL_RETICLES,
// #### `result`
+4 -2
View File
@@ -1906,8 +1906,10 @@ void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Ve
}
if (this->actor.scale.y >= 0.0f) {
if (GameInteractor_Should(VB_DRAW_ADDITIONAL_RETICLES, (this->heldItemAction == PLAYER_IA_HOOKSHOT) ||
(this->heldItemAction == PLAYER_IA_LONGSHOT))) {
if (GameInteractor_Should(VB_DRAW_ADDITIONAL_RETICLES,
(this->heldItemAction == PLAYER_IA_HOOKSHOT) ||
(this->heldItemAction == PLAYER_IA_LONGSHOT),
this)) {
Matrix_MultVec3f(&D_80126184, &this->unk_3C8);
if (heldActor != NULL) {