From b7a94fa085d74eca77c27d559c7b4378b4e4f6d4 Mon Sep 17 00:00:00 2001 From: MonteCrysto Date: Tue, 30 Sep 2025 23:34:11 +0200 Subject: [PATCH] Fix some issues (I actually forgot to compile) --- include/card.h | 2 +- source/joker_effects.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/card.h b/include/card.h index e403b33..40f2dc4 100644 --- a/include/card.h +++ b/include/card.h @@ -38,7 +38,7 @@ #define IMPOSSIBLY_HIGH_CARD_VALUE 100 // Card types -typedef struct +typedef struct Card { u8 suit; u8 rank; diff --git a/source/joker_effects.c b/source/joker_effects.c index df1acb6..f441195 100644 --- a/source/joker_effects.c +++ b/source/joker_effects.c @@ -341,7 +341,7 @@ static JokerEffect reserved_parking_joker_effect(Joker *joker, Card *scored_card int hand_size = hand_get_size(); for (int i = 0; i < hand_size; i++ ) { - if ((random() % 2 == 0) && card_is_face(scored_card)) { + if ((random() % 2 == 0) && card_is_face(hand[i]->card)) { effect.money += 1; } } @@ -451,12 +451,12 @@ static JokerEffect odd_todd_joker_effect(Joker *joker, Card *scored_card) { } __attribute__((unused)) -static JokerEffect abstract_joker_effect(Joker *joker, Card *scored_card) { +static JokerEffect acrobat_joker_effect(Joker *joker, Card *scored_card) { JokerEffect effect = {0}; if (scored_card == NULL) return effect; - // 0 remaining hands mean it's the last hand + // 0 remaining hands mean we're scoring the last hand if (get_num_hands_remaining() == 0) { effect.xmult = 3; } @@ -514,7 +514,7 @@ const JokerInfo joker_registry[] = { { COMMON_JOKER, 4, abstract_joker_effect }, { UNCOMMON_JOKER, 6, bull_joker_effect}, - { UNCOMMON_JOKER, ?, abstract_joker_effect }, + { UNCOMMON_JOKER, ?, acrobat_joker_effect }, #endif };